Commit Graph

26 Commits

Author SHA1 Message Date
Jeff Johnson
4086862b28 qcacld-3.0: Fix Common Services Documentation
The kernel-doc script identified multiple documentation issues in
components/cmn_services, so fix them.

Change-Id: Ifdc8cefcbf7b31dc3e91cc3c5dab7cccd331e473
CRs-Fixed: 3363114
2023-01-10 11:30:44 -08:00
Vijay Raj
4470bb6708 qcacld-3.0: Add diag logging support for measurement report
Introduce diag logging support for Neighbor report and
beacon report via event id EVENT_WLAN_NBR_RPT and
EVENT_WLAN_BCN_RPT.

For Neighbor report token, ssid, report number, frequency
list and frequency is sent. For Beacon report token, mode,
operating class, channel, duration, request_mode and report
number is sent.

Change-Id: I7ef407fa729e608ad0a7036f024acbf8b5180181
CRs-Fixed: 3370758
2023-01-06 00:27:44 -08:00
vijaraj
53b00c93a3 qcacld-3.0: Add diag logging support for EAPOL start
Add new entry in the enum qca_conn_diag_log_event_type in
order to support EAPOL start packet.

Change-Id: I540ef257ee9425eef016302648844ebf01647372
CRs-Fixed: 3314689
2022-10-19 22:30:25 -07:00
Pragaspathi Thilagaraj
df6cc68e7f qcacld-3.0: Update the AKM data type
Currently the AKM information is sent as uint16_t variable
this leads to truncation of 1byte in connecting event of
advanced connectivity logging.

Update the AKM data type from uint16_t to uint32_t.

Change-Id: Ibe359636cb32b66ed99ee8ccb8ce33299908325b
CRs-Fixed: 3307515
2022-10-14 08:30:59 -07:00
Jeff Johnson
76d0561767 qcacld-3.0: components: cmn_services: Fix misspellings
Fix misspellings in components/cmn_services/...

Change-Id: I9ba9e4ea7a193db8b686adf7f31d141bdeea64bf
CRs-Fixed: 3303649
2022-10-03 03:45:53 -07:00
vijaraj
356a5cde4e qcacld-3.0: Fix incorrect reason code logging for Deauth/Disassoc
During Deauth/Disassoc event logging, reason code is being
logged as '0' irrespective of the real reason code.

Modified the api wlan_connectivity_mgmt_event() and
api cm_roam_mgmt_frame_event() to og correct value of
the reason code.

Change-Id: I6d5ba65a9ae312dc82e70202fe598da27a033ff3
CRs-Fixed: 3297871
2022-09-22 19:18:31 -07:00
Pragaspathi Thilagaraj
74d3b5dbcb qcacld-3.0: Enable SAE auth cache api for Diag logging
SAE authentication frames during roaming should be cached and
printed after roam scan done print. This support is not present
in diag logging.
Enable SAE auth frame caching for diag logging.

Change-Id: I205bd2fd1c91253d1e6aaf3361857baf67ccd6fd
CRs-Fixed: 3254216
2022-08-27 15:15:33 -07:00
vijaraj
98152442f6 qcacld-3.0: Incorrect TX status in logging after Roaming
In the api cm_roam_mgmt_frame_event(), TX status is sent
without conversion to the userspace resulting in
wrong value of tx status during logging.

Correct this by converting the tx status value before
sending to userspace in order for userspace to properly
evaluate the tx status.

Change-Id: Ie4b6b8bff5e8b9c88edfaf303ce6a4ae370edd67
CRs-Fixed: 3250473
2022-08-15 20:43:56 -07:00
VIJAY RAJ
a5488c0b6b qcacld-3.0: TX status conversion for mgmt frame during diag logging
Wrong value of tx status sent to supplicant for MGMT frame
via diag logging.

Convert the tx status value to enum diag_tx_status specific value.

Change-Id: Iba6d8011280d41a874509d2a1b4fed9a16ee585c
CRs-Fixed: 3236363
2022-07-10 05:07:27 -07:00
VIJAY RAJ
f327e23c86 qcacld-3.0: Optimize logs in wlan_connectivity_mgmt_event
In api wlan_connectivity_mgmt_event(), the connecting status
is checked for every instance of wlan_connectivity_mgmt_event
resulting in excessive printing of wlan_cm_is_vdev_connecting
logs.

Add check to verify connection status for STA/CLI mode which
results in trimming of wlan_cm_is_vdev_connecting() logs.

Change-Id: I33d8d91e58a38b8998183e20bbf455ff94855c6d
CRs-Fixed: 3211801
2022-07-04 11:51:57 -07:00
VIJAY RAJ
ee9e38f2b0 qcacld-3.0: Send Connectivity diag event through netlink
Connectivity logs are sent through the vendor event to the
supplicant.

Modify the connectivity log flow through the diag event to
the supplicant in order to maintain single logging infrastructure.

Change-Id: Id5429349e00c16c23b76894744fef404b2266e9e
CRs-Fixed: 3218152
2022-06-29 15:46:26 -07:00
Pragaspathi Thilagaraj
701003d5dd qcacld-3.0: Add support to print aid and btcoex field
Add new tags for reassociation request and reassociation
response. Parse the association id from roam stats event
and send it over the connectivity logging event

Add support to print AID and BT-COEX field.

Change-Id: I7926b5c69a84404b666acfd5e2db30426d085881
CRs-Fixed: 3221624
2022-06-24 18:21:00 -07:00
Pragaspathi Thilagaraj
2bbd4b2892 qcacld-3.0: Log SAE authentication frames as part of roam logs
SAE authentication logging events are sent from host
driver during connection as well as during roaming.
But the other roaming frame related stats are printed
as part of the WMI_ROAM_STATS_EVENTID handling.
Since this roam stats event is received after preauth
frame related logs are queued to userspace, the order
of the logs are not correct.

Cache the SAE preauth logs in mlme and print them
upon receiving ROAM stats event. Read the firmware
service capability to decide if new caching needs
to be used or legacy behavior needs to be followed

Change-Id: I76381b9deef222f1481325974e2b5d9730eb2b67
CRs-Fixed: 3154147
2022-04-25 16:35:09 -07:00
Pragaspathi Thilagaraj
03337a051c qcacld-3.0: Send connectivity logs only for STA mode
Connectivity management frame logs are sent for SAP mode also but
should be sent for STA mode only.

Send connectivity/roaming logs only for station mode.

Change-Id: Ib9ae7824f7eca61fdce4c2c163a24554e7b2eb36
CRs-Fixed: 3165658
2022-04-04 21:00:13 -07:00
VIJAY RAJ
ebe3c21573 qcacld-3.0: Enable full scan logging in cm_roam_scan_info_event
In the api cm_roam_scan_info_event(), only for partial
roam scan the frequencies are logged in logcat. For full scan,
the expectation is to print the frequency count as the number
of characters for scanning all frequencies exceed 255.

Enable Roam full scan logging in api cm_roam_scan_info_event()

Change-Id: Ib644a4e8d85e434e8b826c7656cda1251134c4fa
CRs-Fixed: 3131791
2022-03-20 07:24:25 -07:00
abhinav kumar
4e2cc50408 qcacld-3.0: Send kernel time to userspace
Send kernel timestamp to userspace via a
new vendor attribute
QCA_WLAN_VENDOR_ATTR_DIAG_KERNEL_TIMESTAMP.

Change-Id: I085a1f140b5036895249723f6a5b34b18d9aa574
CRs-Fixed: 3146742
2022-03-16 19:33:46 -07:00
Pragaspathi Thilagaraj
4a48e7ab4e qcacld-3.0: Use correct attribute for BTM response target BSSID
Currently driver QCA_WLAN_VENDOR_ATTR_DIAG_BTM_TARGET_BSSID uses
instead of QCA_WLAN_VENDOR_ATTR_DIAG_BTM_TARGET_BSSID attribute
in the BTM response event. This causes the target bssid field to
be missed in BTM response print.
The WTC BTM response event is not queued when reason code is
non-zero.

Use QCA_WLAN_VENDOR_ATTR_DIAG_BTM_TARGET_BSSID attribute.
And queue the WTC btm response event.

Change-Id: Id713bfeda20c43148e95630f5c6e925b80418ca3
CRs-Fixed: 3071242
2021-11-18 14:28:29 -08:00
Wu Gao
7585fba94b qcacld-3.0: Fix compilation issue about 64-bit division
This change fixed compilation issue about the 64-bit division in
sdxlemur - a 32-bit architecture, which is not defined
"__aeabi_uldivmod" for the 32-bit architecture.

Change-Id: Ief75e7903fe301f5641fa4f734dc8129a7501b7e
CRs-Fixed: 3067887
2021-11-03 08:23:03 -07:00
Pragaspathi Thilagaraj
c3548d50ff qcacld-3.0: Fix race between dequeue logs and deinit connectivity logging
As part of stop modules, the deinit connectivity logging happens and
the queue, all the pointers are deinitialized. But while
initializing the write pointer the write pointer spinlock is not
acquired. This results in null pointer dereference of write_ptr
from other context.

Protect the access to the write pointer before setting it to
NULL in wlan_connectivity_logging_stop().

Change-Id: I69dc57b9e661004203f58754824496953105726f
CRs-Fixed: 3054306
2021-10-14 19:23:48 -07:00
Pragaspathi Thilagaraj
7e90b8b5f5 qcacld-3.0: Fix missing attributes in connectivity logging events
Fix few missing attribute in below connectivity events:
QCA_WLAN_VENDOR_DIAG_EVENT_TYPE_EAP_RESPONSE
QCA_WLAN_VENDOR_DIAG_EVENT_TYPE_ROAM_SCORE_CURR_AP

Also send the roam candidate info properly to userspace.

Change-Id: Ia9c4f095316adf8f40294f1e119cad648749bb72
CRs-Fixed: 3037650
2021-09-28 21:11:51 -07:00
Pragaspathi Thilagaraj
9081371b4b qcacld-3.0: Add changes to send connectivity log events to userspace
Fill the QCA_NL80211_VENDOR_SUBCMD_DIAG_DATA event data and
send the event to userspace.
Add dispatch table for the connectivity events to lookup
attribute type, id and length.

Change-Id: I1fc8467409852a430874ac1d926b06ec8dafb736
CRs-Fixed: 3030085
2021-09-26 04:49:49 -07:00
Pragaspathi Thilagaraj
5e4b2f49ad qcacld-3.0: Fill and send connectivity logging management frame events
Fill the management frame data and enqueue the filled record to the logging
queue.
Frame sequence number, peer rssi, tx_status, authentiation algo,
authentication frame transaction sequence number will be filled to the
log record.

Change-Id: I069b7816fdc52eeed964d6586c52b58d1a5d5cd4
CRs-Fixed: 3030075
2021-09-26 04:49:44 -07:00
Pragaspathi Thilagaraj
f5c868fc78 qcacld-3.0: Stop connectivity logging after stop modules
When wifi is turned off, if the connectivity logging queue is
not empty, the wlan logging thread tries to dequeue the record
and send the logging event to the userspace. While performing
dequeue operation, the records from queue are copied to temporary
buffer before read pointer is incremented. There could be a
condition where this buffer is allocated in ini domain after stop
modules is done and freed in active domain if the wlan_logging
thread is preempted during stop modules.

So to avoid this domain mismatch, start the queue only if
start_modules is done and stop the queue after stop modules
to avoid dequeue being done during/after stop modules.

Change-Id: Ied8c36b19bc66474d3c4d8f913f3e3dbf9a574a0
CRs-Fixed: 3035644
2021-09-22 03:15:43 -07:00
abhinav kumar
9bb838865c qcacld-3.0: Send roam scan info to userspace
Host receives WMI_ROAM_STATS_EVENTID event
from fw whenever roam scan trigger happens.
Send roam scan details and candidate AP details
to userspace.

Change-Id: I92a35d7b15951321107db14ae588d66e82a8174e
CRs-Fixed: 3031391
2021-09-22 03:15:38 -07:00
Pragaspathi Thilagaraj
c575e2a228 qcacld-3.0: Enhance the dequeue logic to limit logs per second
Restrict the dequeue logic to send only 20 logs per second
to userspace. Add check to see if queue is empty before
trying to dequeue.

Change-Id: I778556c649d123718cf76c943c5b2ed7f6c6e8e5
CRs-Fixed: 3014554
2021-09-17 13:47:52 -07:00
Pragaspathi Thilagaraj
612fe2eca2 qcacld-3.0: Add infrastructure for connect/roam logging
Add new files for connect/roam logging. Add changes to
initialize the logging buffer.
Make changes to support enqueue/dequeue log.
Define enums for MAIN_TAG, Sub TAG, category.
Add structure definitions for logging buffer.

Change-Id: I1d283fcf464da90d4f5533214d480ddda156ec27
CRs-Fixed: 3013486
2021-09-17 13:47:47 -07:00