In wlan_hdd_get_station_stats, NULL checking for
pdev_stats fails as it doesn't pass pdev stats info
to hdd layer. stats will not pass to userspace, it will
display tx bitrate unknown in command "iw p2p0 link" or
"iw p2p0 station dump".
issue only happen on p2p0 and not on wlan0. as wlan0 can
use cached stats in __wlan_hdd_cfg80211_ll_stats_get.
Fix is pass pdev stats info to hdd layer in
get_station_stats_cb.
regression cause is:
Iaefc5629872431cbc6c24090b1edb6cebdad995a
Change-Id: I33b608988aa288e0f8139524de5e20fcbba4f2be
CRs-Fixed: 3457955
Currently host driver doesn't fill peer mac address
per ml vdev for station stats request as part of peer
stats request hence incorrect stats sent to userspace.
To address this issue, save peer mac per ml vdev in
request info structure.
Change-Id: Iebb1b810e112743602607e31d779be2ba1d48f90
CRs-Fixed: 3450665
In the driver, if CLUB_LL_STATS_AND_GET_STATION feature is
enabled, host requests Link Layer stats and station stats
from firmware periodically using a single WMI command.
Host then sends LL_STATS to userspace and caches station stats
in the adapter. Whenever userspace queries station stats, based
on the sta_stats_cached_timestamp, host returns cached stats
from adapter instead of sending a new WMI request.
The current issue, as part of station stats firmware also sends
connection_tx_power stats, which aren't cached into the adapter.
So, whenever userspace queries get_tx_power via nl commands,
host sends a WMI request to firmware for tx_power leading to
platform wakeups and power impacts.
To resolve this issue, cache the tx_power sent by firmware into
the adapter during station stats and return the cached value to
the user space.
Change-Id: Iaefc5629872431cbc6c24090b1edb6cebdad995a
CRs-Fixed: 3439323
Refactor tgt_mc_cp_stats_send_raw_station_stats into
vdev_mc_cp_stats and peer_mc_cp_stats functions to
improve code readability.
Change-Id: I5b313a84f4dd758d0b166940f055153bfae345a6
CRs-Fixed: 3442881
The tgt_send_cp_big_data_stats_req() prototype was added by:
qcacld-3.0: Add support for big data stats
Change-Id I3642035d9f25237c80b529da78c51bb1ccf0035a
However a function with that name is not actually present. Instead,
the struct wlan_lmac_if_cp_stats_tx_ops::send_req_big_data_stats()
function pointer is used to send the request.
Since the prototype is unused, remove it.
Change-Id: I1a05c40d2ae639e4b6333362661e9012786a467c
CRs-Fixed: 3430267
Currently in the driver as part of ML unified_ll_get_sta stats,
the peer mac address for partner link is not being updated in
the callback function, causing driver to report incorrect
stats to upper layers.
To fix this issue, update peer mac address before invoking
vdev station stats callback function.
Change-Id: I39c460467a3572aad05e4c5fab136a844b753941
CRs-Fixed: 3421153
Currently callers are calling the wlan_mlme_get_sap_max_peers() API
to get the max number of peers without initializing the output
parameter.
In case of failure in wlan_mlme_get_sap_max_peers() API,
sap_max_num_peers can have uninitialized value which can lead to
undefined behavior.
To fix this issue, initialize the output parameter before calling
wlan_mlme_get_sap_max_peers()
CRs-Fixed: 3337315
Change-Id: I83ecaf80ccee7d92a66fe561c0a1a7bd409fd64c
The kernel-doc script identified several documentation issues in
the cp_stats component, so fix them.
Change-Id: I33e42894365048b75a23f1a2070de72a975d456f
CRs-Fixed: 3340094
Based on the new requirement, fw fills the tx packet counts per mcs
and rx packet count per mcs index in the peer extd stats event.
Add logic to parse tx packet count per mcs and rx packet count per mcs
from peer extd stats event.
Change-Id: I4cd8c1ed5dd6942022d9f930f8de0bcbcb679eb5
CRs-Fixed: 3289683
Currently channel info stats are stored in LIM. Refactor
code to store channel info stats in cp stats component.
Change-Id: I2e7219c112e96916d3b73f974dd9803b9c2821c3
CRs-Fixed: 3265722
Host driver rate limits successive get_txpower
calls within 3 seconds, and sends cached stats
from the hdd_stats. However, max_tx_power is
not updated in the hdd_stats. Therefore,
the cached tx power is always 0 dBm.
Also, the hdd_stats would be only updated when
CP stats are received from the firmware for
get_station/dump_station calls. get_station is not
periodically queried for SAP interface from the
framework. Therefore, tx power for SAP interface will
always be 0 even if hdd_stats gets updated.
To fix this, instead of hdd_stats, return the
max tx power from the pdev stats cached on the pdev.
Change-Id: I0c8d8baab790c7344bd8913158f8eda63736474e
CRs-Fixed: 3230649
Scenarios are:
1. Host receives ROAM_START from firmware
2. Host receives EAPOL M1 from AP, host forwarded
it to supplicant and supplicant buffered it (with
timer 100 msec) to process it after association
completion.
3. Host starts processing CP stats request, which
holds RTNL kernel lock
4. Host starts a CP_STATS_WAIT_TIME_STAT (800 msec)
timer and sends WMI_REQUEST_STATS_CMDID to FW.
So cp stats are holding the RTNL lock.
5. In waiting state host/FW completed roaming within
a few milliseconds. Host Call roamed indication
to the kernel. Kernel post it to the Work queue
to indicate this to the supplicant. The Work
queue requires the RTNL lock to send the
indication to the supplicant.
6. Now Kernel is waiting on the RTNL lock taken by
the CP stats request which is waiting for the CP
stats response (WMI_UPDATE_STATS_EVENTID).
7. Host receives CP stats response but the host is
unable to handle it with the below reason.
8. Timed out happens for WMI_UPDATE_STATS_EVENTID,
then Kernel takes RTNL lock to indicate
association/roam completion status to the
supplicant.
9. As Kernel is sending association indication
after CP_STATS_WAIT_TIME_STAT (800 msec), by
this time supplicant deleted buffered EAPOL
first frame, this results in DUT failing to
initiate the 4-WAY handshake.
10. Finally AP sends the Deauthentication frame
to DUT.
Reason for unable to process CP stats response :
As per the current design, While processing Roaming,
the host deletes the old peer and creates a new peer
for roamed AP. If the Host receives cp stats response
after peer delete due to roaming, the host is unable
to stop waiting for timer CP_STATS_WAIT_TIME_STAT
and fails to release RTNL kernel lock till timeout.
After time out only, Kernel can take RTNL lock to
indicate association/roam completion status to the
supplicant.
Fix is to stop the wait timer CP_STATS_WAIT_TIME_STAT
and release RTNL kernel lock even in case peer has
deleted by HOST for which CP stats request sent.
Change-Id: Ie5b5275da10a06da50b2fbb8ab206b78f2c64d6a
CRs-Fixed: 3234063
Currently, the driver gets the last vdev's chain rssi stats
if fw reports more than one vdev's chain rssi stats, it causes
the last one stats overwrites the former one and the last stats
may not be expected for the request vdev.
To resolve this issue, compare the vdev id before getting the
stats.
Change-Id: Ib789d148a010460108ed73b92ef603cf78c1493a
CRs-Fixed: 3212917
Add EHT MCS to rate mapping for NSS 1 and NSS 2.
Update TX/RX bitrate for EHT connection depending on current MCS/NSS
configuration.
Change-Id: I0c55beab2c6b9a9609d5a2e454a0c0e8c1312d09
CRs-Fixed: 3181127
In the current driver implementation, check for ml_vdev_count
before invoking get_station_cb for MLO station stats is missing.
This causes timeout and failure to get station stats.
To resolve this issue, add sanity check for ml_vdev_count
before invoking get_station_cb for MLO station stats.
Change-Id: I2e8fca1b732b1e8638cec6536ea70d2174c287f7
CRs-Fixed: 3209608
If macro WLAN_FEATURE_11BE_MLO is enable, get_station_stats_cb for
TYPE_STATION_STATS is called only if last_req->ml_vdev_info.ml_vdev_count
none zero when WMI_UPDATE_STATS_EVENTID event comes back.
This causes timeout and fail to get station stats for legacy device or for
MLO device which does not set last_req->ml_vdev_info.ml_vdev_count.
To resolve this issue, add sanity check legacy device before invoking the
callback and set last_req->ml_vdev_info.ml_vdev_count if it is MLO device.
Change-Id: I8ca325482fc32de87cbedcba7d4af17d3876cbbc
CRs-Fixed: 3202588
As part of MLO stats feature, add support to process get_station
stats for all MLO vdevs and store them in the corresponding adapters.
Change-Id: I21034f7769290603f1540c84aed55cc0a39defcf
CRs-Fixed: 3181022
As part of MLO stats feature, add support to process link layer
stats for all MLO vdevs and store them in the corresponding adapters.
Change-Id: Ia6d731c94eaa3a355a9deae61d07dd06c5d412bd
CRs-Fixed: 3181021
In special case, tasklet(ksoftirqd/0) that handle WMI event was stuck
for 4 sec, SSR was triggered for timeout waiting for resume
event from FW during RTPM resume.
During SSR, cp_stats_tx_ops->inc_wake_lock_stats callback was cleared,
later WOW_WAKEUP_HOST_EVENTID was received, callback was executed, assert
happened.
Change-Id: Ib9ae7d61d1b415e9857657725ffd2ae1efd4795c
CRs-Fixed: 3165730
Reduce the log level for the frequent acceptable errors
to reduce the roam latencies.
Change-Id: I9f5405025948d160e6fcd65ecca05dce7670ea84
CRs-Fixed: 3150439
In P2P connect process, GO and GC send deauth/disassoc at the
end of WPS. GO send disassoc and free station info. GO receive
deauth from GC, and send cmd WLAN_SER_CMD_GET_DISCONNECT_STATS
to get disconnect stats.
If GO send deauth and free peer info before receive deauth
from GC. Wlan_objmgr_get_peer return null, and peer is null.
Cmd of WLAN_SER_CMD_GET_DISCONNECT_STATS will never be
released since get_peer_rssi_cb will never be called.
And cmd will timeout, which is not expected.
If we call get_peer_rssi_cb without check, cmd will release.
Also csr_get_peer_rssi_cb will check peer is null or not.
Change-Id: I10b496526e259711a4dd7a91b7388ac79bb54fef
CRs-Fixed: 3119513
Currently there is no support to read bmiss stats from fw.
With this change, add support to read bmiss stats from fw.
Change-Id: I77594d05fbcd295aff4c625ba5f4f33cbc491063
CRs-Fixed: 3097304
Support to deliver below mlme event to SON:
MLME_EVENT_VDEV_STATE,
MLME_EVENT_INST_RSSI,
MLME_EVENT_TX_PWR_CHANGE.
Change-Id: I0535d80cea155f5b94abecfa609d34940e57cdd7
CRs-Fixed: 3054810
There are duplicate macros for the same purpose, hence
replace WLAN_ALL_SESSIONS_DIALOG_ID with TWT_ALL_SESSIONS_DIALOG_ID.
Change-Id: I63130869eed8dffcce85fe6a04586592ab3eaca2
CRs-Fixed: 3047686
In ucfg_twt_get_all_peer_session_params peer reference is
acquired and its not released leading to the reference leak,
leading to vdev destroy timeout.
Release the peer reference to resolve the issue.
Change-Id: I9992376473c30365f15fcdb8e374c856bc169d6b
CRs-Fixed: 3027189
Currently, host prints only one peer info instead of
all peer info as part of oem_ss initiated broadcast
SAP TWT get_status command.
Add a support to print all peer info if oem_ss sends
broadcast SAP TWT get_status command.
Change-Id: I0a617f655b7a5486582cb47a4602b30514ffae88
CRs-Fixed: 2970487
Validate fw capability to handle big data command before sending
big data stats request to fw.
Change-Id: Id7df4c3ac36e25761938758472ea9281c174a8c9
CRs-Fixed: 2937523
Add support for TWT get_status command in SAP
As part of this change, TWT get_status command is supported
if
1. If particular dialog_id and particular mac_addr are
present
2. If dialog_id = 0 and particular mac_addr are present
3. If no parameter present
Change-Id: I5ce1719da7f9a3988ba6e1f04455a06faf9687c6
CRs-Fixed: 2937999
Implement support for sending new control path stats
infrastructure via WMI_REQUEST_CTRL_PATH_STATS_CMDID and
WMI_CTRL_PATH_STATS_EVENTID in cp stats component. Also add
support for TWT Get statistics through this new method.
Change-Id: I62b3a525cde797cd5b809ca9e8e6c91d5651c6b4
CRs-Fixed: 2851016
Reduce excessive logging for roaming path to reduce latency.
Also remove function and line prints in roam debug related
logging.
Change-Id: Ida6fc55886c944126720f8bdd4b944765426ccc6
CRs-Fixed: 2847773
Periodically request pdev stats from FW to receive channel noise floor
information after monitor vdev has been brought up, based on the band
currently being sniffed. Use the band information as a secondary parameter
when sending periodic request to fw so a single noise floor value is sent
to host. Pass this noise floor information to dp_pdev to be populated in
radiotap header.
Change-Id: I488e4985392cb646ffdee914359fa995dbeb025e
CRs-Fixed: 2833458
Stats event from target might have several sub events, and some event
has no peer stats but have adv/ext2 peer stats.
Check ext/ext2 peer stats even no peer stats in
target_if_cp_stats_extract_peer_stats(). Fix copy adv stats size error
in tgt_mc_cp_stats_prepare_n_send_raw_station_stats(). Although
get_station_stats_cb and get_peer_stats_cb is union callbacks,
better to assign to get_station_stats_cb because it is for
TYPE_STATION_STATS.
Change-Id: I0bead0cbb8b549cc538ef4a7327f0a8303c90bd1
CRs-Fixed: 2801842
Host sets WMI_REQUEST_PMF_BCN_PROTECT_STAT bit in stats_id param of
WMI_REQUEST_STATS_CMDID command. Firmware supporting pmf beacon
protection stats responds host with stats in wmi_update_stats_id
event. Host extracts PMF beacon protection stats from wmi_update_stats_id
event. Host adds PMF beacon protection stats in the response of vendor
command QCA_NL80211_VENDOR_SUBCMD_GET_STA_INFO for STA mode.
Change-Id: Ib3cb06e03dbccdb9fa1782d414ed734bd97aa309
CRs-Fixed: 2705236
WMI handler is registered for twt_session_stats event.
Upon wmi event twt session parameters are extracted and
cached in peer mc_cp_stats. UMAC APIs are provided to
retrieve TWT session parameters from north bound
interface(hdd) using twt peer's mac_addr/session dialog_id
CRs-Fixed: 2730732
Change-Id: I8ce38ac6be97e844e26e03751c6d6cca981b82b4
Release lock when psoc_mc_stats is NULL in
ucfg_mc_cp_stats_inc_wake_lock_stats API.
Change-Id: Ibf316d848b2e1d0a4189eb4cebac27922ce30dcd
CRs-Fixed: 2702093
Update multicast and broadcast rx packet count on
receiving wmi update stats event from firmware by
fetching the peer stats from DP layer.
Change-Id: I0befdbe952aa4e773bbe072affaf698819b3a80f
CRs-Fixed: 2709871