Commit Graph

46 Commits

Author SHA1 Message Date
Srinivas Dasari
2021b8ee2c qcacld-3.0: Add connectivity log for BTM drop/block
Currently, driver drops BTM frames in unsupported cases,
e.g. connected to MBO AP without PMF capability, concurrent P2P
session present which doesn't allow STA roaming.

Add connectivity log support and indicate the reason for BTM
drop/block.

Define interface for userspace as below,
New subtype: WLAN_CONN_DIAG_BTM_BLOCK_EVENT
New enum to fill sub_reason for BTM_BLOCK_EVENT type

Change-Id: I87115da57d275a94c5ae69252ec09bcad698e47c
CRs-Fixed: 3699042
2024-01-09 06:21:01 -08:00
Vijay Raj
739e08d0be qcacld-3.0: Add support for T2LM connectivity logging from STA
T2LM Req/Resp Connectivity logging is not supported if
the T2LM request is initiated from STA.

Add support for T2LM Request/Response connectivity logging
when T2LM request is initiated from the STA.

Change-Id: If61b5ba7c7eb9ec5687d271afc300737df8fdf8d
CRs-Fixed: 3689209
2024-01-05 07:48:41 -08:00
Vijay Raj
3bf9181471 qcacld-3.0: Modify Connecting event to log for No candidate scenario
"CONNECTING" connectivity event is not logged during
NO CANDIDATE scenario which resulting in breaking of
connectivity logging mechanism.

Modify wlan_connectivity_connecting_event() api
to get connect request parameter as argument in
order to log CONNECTING event.

Change-Id: I040446db189c55ade3c6d0aa993388789f9881af
CRs-Fixed: 3678172
2023-12-29 07:02:39 -08:00
Vijay Raj
5e6d32dccc qcacld-3.0: Modify MLO LINK status log to include supported link
For MLO LINK connectivity log, the links not associated
during connection are also included as part of
inactive links which breaks the sanity of logging
mechanism.

Modify MLO LINK connectivity event to send the
associated link band bitmap in order facilitate
userspace to find links associated in current
connection and in turn find the inactive links
in a particular instance.

Change-Id: I7a490e9bf8a6666620d1c57b9f8047a22bf78fc5
CRs-Fixed: 3674048
2023-12-29 07:02:33 -08:00
Pragaspathi Thilagaraj
b74100cbb7 qcacld-3.0: Send STA_INFO connectivity event after roaming
Driver sends STA_INFO event with self mac addresses for each link
before initial connection. With the new requirement to send the
STA_INFO after every roam to detect the change in mac address, add
the sta info call after reassoc response is received and roaming
status is successful.

CRs-Fixed: 3653662
Change-Id: I18ecbdfea47fb3524154f799ea0c4777276cb34a
2023-11-14 05:27:49 -08:00
Pragaspathi Thilagaraj
46d9d017f1 qcacld-3.0: Fix minor diag logging issues
Update the diag interface files with minor fixes to include
qdf_packed attribute for missing structure and fix the enum
wlan_roam_failure_reason_code ordering to be in sync with WMI

Change-Id: I3b4f6296e7d80c9d27e4f66dd2092c0110aaa766
CRs-Fixed: 3659386
2023-11-10 14:36:14 -08:00
Vijay Raj
eb8f76bea2 qcacld-3.0: Modify timestamp value for MLO link switch log
For event EVENT_WLAN_MLO_LINK_STATUS, the Fw send the
fw_timestamp value in milliseconds for MLO link
switch connectivity log. However, the userspace
expects the fw_timestamp value in microseconds.

For connecting fail connectivity logging, connecting
fail reason code mismatch is observed between host
and userspace.

Modify the api wlan_connectivity_mld_link_status_event()
to send the fw_timestamp value in microseconds instead
on milliseconds.

Introduce wlan_diag_connect_fail_reason enum to
facilitate proper conversion of connect fail reason
code between host and userspace.

Change-Id: I92b4f294c0e4bc68c809fbf7d01ab950eca83ac9
CRs-Fixed: 3637399
2023-11-06 06:50:08 -08:00
Pragaspathi Thilagaraj
cbb69cf1b2 qcacld-3.0: Fix SAE authentication connectivity logs during roam
When SAE roaming happens, the preauth event BSSID is used to
trigger external authentication to userspace and frame exchange
also happens with this BSSID. But while caching the info
corresponding to this frames, the current connected AP bssid is
used. This causes failure while fetching the cached entries.

Use correct BSSID to fetch the cached SAE authentication frames
for MLO SAE roaming. Enhance the error logs in some cases.
Update the driver authentication logs also to print the auth info.

Change-Id: Idd21f40cf0802879e83c10d91956662733b74666
CRs-Fixed: 3644706
2023-11-01 10:26:06 -07:00
Vijay Raj
72a9394643 qcacld-3.0: Modify Roam result log for MLO connection
For Roam result connectivity logging, bssid is not
printed for No ROAM case when connected to a MLO AP.

Expected Log when connected to MLO AP:
[Kernel Timestamp][ROAM] RESULT NO_ROAM
bssid=??:??:??:??:??:?? [Vendor Extra data]

Observed log when connected to a MLO AP:
[Kernel Timestamp][ROAM] RESULT NO_ROAM [Vendor Extra data]

Add "is_mlo" parameter to be sent in order indicate
userspace the whether the log belongs to MLO AP.
Modify BSSID to bss peer mac of assoc link to be
printed as part Roam Result No roam log when
connected to a MLO AP

Change-Id: Ia9acc1cf7c5377b595771f2718edd9dbf8f45367
CRs-Fixed: 3638160
2023-10-19 14:42:17 -07:00
Vijay Raj
840013c4db qcacld-3.0: Modify MLO setup logging for the connected links
For MLO setup connectivity logging, the Band info is
not included for the standby links, resulting in logging
in an inappropriate  format.

Expected Log format:
[Kernel Timestamp][MLD] SETUP band=? status=? bssid=?
link_id=? [Vendor Extra data]

Observed Log for standby link:
[kernel Timestamp][MLD] SETUP status=1 [vendor extra data]

Modify the MLO setup connectivity logging to log for
the links associated with the connection.

Change-Id: I2a8857ed123faf3c69c2a406eec506c6ed8c454b
CRs-Fixed: 3636343
2023-10-18 22:46:31 -07:00
Vinod Kumar Myadam
e4a6ca8d3c qcacld-3.0: Fix to populate band for stand by vdev
In T2LM status event currently band info is not populating
for the stand by vdev

Update band info for stand by vdev also

Change-Id: If7413158a1e3edf170ae04791d377a4ad6008544
CRs-Fixed: 3624562
2023-09-29 02:23:20 -07:00
Vijay Raj
0dc1988bb3 qcacld-3.0: Modify MGMT logs to add MLO Parameter after Roaming
MLO parameter is not observed in association/reassociation
request/response logs when connected to MLO AP.

Call api wlan_populate_mlo_mgmt_event_param() in the
api cm_roam_mgmt_frame_event() in order to populate
MLO parameter in MGMT frame logs after roaming.

Change-Id: I9dbd1a224ec861964a78883088440d79ae80cdd6
CRs-Fixed: 3620741
2023-09-25 05:15:37 -07:00
Vijay Raj
9f57a97491 qcacld-3.0: Introduce support for T2LM status for logging
Add support for T2LM status event for connectivity
logging.

For T2LM status event, band, tid_ul and tid_dl are
the parameter used for connectivity logging.

Change-Id: Ifdb763185af88617b90ea761e7d10cc35c628808
CRs-Fixed: 3609648
2023-09-25 01:29:14 -07:00
Vijay Raj
3a8a17e839 qcacld-3.0: Add MLO Reconfig event support for logging
Introduce support for MLO Reconfig event for connectivity
logging.

In MLO reconfig event, ban and link id are sent for
logging.

Change-Id: I2de6edff91ae344e2d9e11fb89216dab17384980
CRs-Fixed: 3606709
2023-09-20 23:59:19 -07:00
Vijay Raj
94f55718b5 qcacld-3.0: Add frequency to peer for Connectivity Logging
Introduce support to add frequency to peer in
order to enable Connectivity diag logging for
datapath related events

Change-Id: I634ddc0206530f1039a37fd60643877b2fdf7e87
CRs-Fixed: 3596250
2023-09-20 23:59:12 -07:00
Vijay Raj
3f5473b0b8 qcacld-3.0: Modify support for connecting event logging
Connecting event logs are to be sent after candidate
selection and not immediately after receiving
connect request.

Modify the connecting event logs to be sent after
sta info event logs.

Change-Id: I83b654ba0ef3458368ba7dd6353c5ab67077ec39
CRs-Fixed: 3599703
2023-09-20 20:09:03 -07:00
Vijay Raj
95cc423b9d qcacld-3.0: Add support for T2LM request/response event for logging
Add support for T2LM request/response event for
connectivity logging.

For T2LM request/response band, token, status, tx_status and
is_rx parameter are logged for the event.

Change-Id: I5d65c99896ec26b67b763679b105036975a938d5
CRs-Fixed: 3607151
2023-09-18 15:31:50 -07:00
Pragaspathi Thilagaraj
406a6d568e qcacld-3.0: Add API for sending ML Link state diag event
Add connectivity logging API to send ML Link state switch
diag event.
When ML link gets enabled/disabled, this event will be
sent.
EVENT_WLAN_MLO_LINK_STATUS is the diag event for ML link
state switch event.

Change-Id: Ie10f1208875f86a5a5892ee2cfb2fabe18f200e4
CRs-Fixed: 3610060
2023-09-15 21:08:23 -07:00
Vijay Raj
454a96b1bd qcacld-3.0: Add support for MLO specific data for RRM logging
Add support to add band info for Neighbor report request,
Neighbor request response, Beacon report request and
Beacon report response logging for MLO usecase.

Band info will indicate the band of the link involved
in MLO connection.

Change-Id: I758be63f085be46244f727a842806fb27660e8dd
CRs-Fixed: 3583958
2023-09-11 07:02:14 -07:00
Vijay Raj
2ee8079a6b qcacld-3.0: Add support for MLO setup event logging
Introduce support for MLO setup event for connectivity
logging.

For MLO setup event bssid, band, link_id and status
are sent as part of logging.

Change-Id: Idd16b4ec7eeb245a5ce99b383bd40f169f579ebc
CRs-Fixed: 3605678
2023-09-09 19:31:43 -07:00
Vijay Raj
873554a96c qcacld-3.0: Modify Roam Scan start and Roam candidate info logging
Modify the api cm_roam_trigger_info_event() in order to add
band info for Roam scan diag logging for MLO usecase.

Modify the api cm_roam_candidate_info_event() to indicate
MLO connection during Roam candidate logging.

Change-Id: Ib42e8362ee091716110c2aa3513a6f6b5653681f
CRs-Fixed: 3582383
2023-09-08 04:10:23 -07:00
Vijay Raj
4eb27f1d6a qcacld-3.0: Add MLO support for MGMT event logging
Introduce MLO support for Management event logging.

Add band info to indicate the bands of the link
requested for setup during Association/Disassociation
request frame.

Modify bssid info to send only the bssid of the AP
associated to the frame exchange link.

Add MLD mac address support during Association/disassociation
event logs.

Change-Id: I84e53a486ae5ae3f4f2f3f9c42658e1392e64b13
CRs-Fixed: 3603786
2023-09-08 04:09:44 -07:00
Vijay Raj
8255bcee81 qcacld-3.0: Introduce support for STA info logging
Add support for STA info logging via api
wlan_connectivity_sta_info_event()

STA info logs is sent immediately after the
connect request initiated from userspace.

Change-Id: I92c42c9ca27f90acae23452e8fba1f2b20396214
CRs-Fixed: 3597543
2023-08-29 15:03:46 -07:00
Vijay Raj
43e28bd8e5 qcacld-3.0: Add diag logging support for STA info and MLO events
Introduce diag logging for STA info event and MLO events
via eventid EVENT_WLAN_CONN_STA_INFO, EVENT_WLAN_MLO_SETUP,
EVENT_WLAN_MLO_RECONFIG, EVENT_WLAN_MLO_T2LM_STATUS,
EVENT_WLAN_MLD_T2LM_REQ_RESP, EVENT_WLAN_MLO_T2LM_TEARDOWN
and EVENT_WLAN_MLO_LINK_STATUS

For MLO specific events band, link_id, status, tid_ul,
tid_dl, token, tx_status, reason active_links and
previous active links are sent.

For STA INFO event is_mlo flag, mld_macaddr, 2.4GHz_mac,
5GHz_mac and 6GHz_mac.

Change-Id: I1aa6195a481319f85cad26893789439c5c8291ea
CRs-Fixed: 3568508
2023-08-24 21:14:56 -07:00
Vijay Raj
fb8e6d4f3e qcacld-3.0: Remove unused legacy logging for BTM event
Diag logging is used for connectivity logging of
BTM event.

Remove unused legacy connectivity logging mechanism for
BTM events.

Change-Id: I65dc5fe5f071fd74eeed2433894a238318ce76ab
CRs-Fixed: 3470401
2023-05-05 01:56:23 -07:00
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
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
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
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