Commit Graph

13661 Commits

Author SHA1 Message Date
Rakesh Pillai
57e2c01e5e qcacmn: Peer id parsing changes for beryllium
Take care of the MLO peer bit indication to be
concatenated with peer_id to access the peer map
object.

Change-Id: Ia603a728101e83829a8906d1b847f42389e78ca6
CRs-Fixed: 3039326
2021-10-15 13:13:27 -07:00
Rakesh Pillai
2069fa6cdd qcacmn: Handle htt peer map/unmap v3
Add the handler for processing the htt
peer map/unamp v3 and MLO peer map/unmap msgs.

Change-Id: Ie2ab0b76e7aee566ca3b9637b83fd7a14718ab01
CRs-Fixed: 3039326
2021-10-15 13:13:22 -07:00
Rakesh Pillai
32046ad850 qcacmn: Vdev attach changes for MLO
Add mld mac address info during datapath
vdev attach.

Change-Id: I0ea22025d19be82be0c56809871e8513c3ce7962
CRs-Fixed: 3039326
2021-10-15 13:13:17 -07:00
Jinwei Chen
5c85cfb5a0 qcacmn: cdp/dp peer change for MLO
cdp/dp peer change for MLO

Change-Id: I9b8eb741317a0dc7337aff7e773148892e531ba2
CRs-Fixed: 3031166
2021-10-15 13:13:12 -07:00
Lincoln Tran
82ee197386 qcacmn: Store original connect req in connection types
When performing an MLO connection, the subsequent links need data
from the original connection request. There is no easy way to
determine if the connection is MLO or not at this point, so
store the original connect request regardless of the connection
type. Also make sure all instances are freed properly.

Change-Id: Iccce376ba36a8c49127b177fc4a1bac54aafb315
CRs-fixed: 3051842
2021-10-14 17:11:06 -07:00
Chaithanya Garrepalli
7387592290 qcacmn: Fix compilation issue for Hamiltion
Avoid setting TCL_R0_CMN_CONFIG register if this is
not defined in HW headers

Change-Id: I8fec6a5637deca8545da00fc8c631c0e26ba9a1e
2021-10-14 07:55:54 -07:00
Naga
8020841ce4 qcacmn: Add sanity check for monitor pdev
Add sanity check for monitor pdev while enabling
enhanced stats.

Change-Id: Icd1a2e7daf57d32d85d7c5ad5e11f0d6ea2456ee
CRs-Fixed: 3055767
2021-10-14 03:34:55 -07:00
sandhu
3de5365a37 qcacmn: Fix hamilton whunt compilation issue
Change-Id: I0ac3ab0530cfb645c0eef81aafc9d1ef6a35c776
CRs-Fixed: 3052592
2021-10-14 01:16:02 -07:00
Liangwei Dong
dffbb1b320 qcacmn: Fix SAE pmkid update issue
For SAE SAP, after full SAE authentication, only pmkid
will be sent down to driver, PMK len is zero.
Driver should accept the set pmksa without PMK.
Add check pmk length checking and if pmk len is zero,
driver allow the set pmksa.

Change-Id: Ic05dee4cce31233dbe6dfced05df54fe8972dd1f
CRs-Fixed: 3042899
2021-10-13 17:42:40 -07:00
Lincoln Tran
1b0df8b4fb qcacmn: Clear MLO cap bit in case of failure or disconnect complete
Clear the MLO capability bit in the following scenarios:
- On a successful disconnect complete
- On a failing connect complete
- Every time we fetch a new candidate
This will ensure subsequent connections are not effected by this bit.

Change-Id: I4cbda78715450b5db5bc25cb7f6a141d636b712b
CRs-fixed: 3054192
2021-10-13 15:23:01 -07:00
Chaithanya Garrepalli
3c3e5709ac qcacmn: Increse num TX rings for QCN9224
This change includes below
1) Changes needed to increase Tx rings to 4
2) Use WBM2SW4 ring for rx error in QCN9224
3) memset srng at alloc to avoid populating RBM_id
in per packet path and enable implicit RBM

Change-Id: Icbd5ac2378273b8f3c6adc41c611e29551fff22f
2021-10-13 13:12:19 -07:00
Shiva Krishna Pittala
de13832745 qcacmn: Populate and expose 320MHz spectral capabilities
Populate and expose the following 320MHz spectral capabilities.
  - Agile spectral scan support for 320MHz mode.
  - Number of detectors used for spectral scan in 320MHz mode.

Change-Id: Ibea77d4ec8b1d9322ef82d1d48236836ffad24ec
CRs-Fixed: 3053059
2021-10-13 02:57:24 -07:00
Karthik Kantamneni
4c00b017c8 qcacmn: Add HIF events to track NAPI POLL exit time
Add HIF events to track NAPI POLL exit time, this gives
information about actual time spent by wlan host in napi softirq.

Change-Id: I7548fd05f2f7db714ac9bcf79171ffb3d478e936
CRs-Fixed: 3052902
2021-10-12 13:16:48 -07:00
Shiva Krishna Pittala
41879eb3ca qcacmn: Add QCA vendor attributes to indicate 320MHz spectral capabilities
Add a QCA vendor attribute to indicate agile spectral scan support for
320MHz mode. Add another attribute to indicate the number of
detectors used for spectral scan in 320MHz mode.

CRs-Fixed: 3045445
Change-Id: I4667e93e8074af122bfe9e08bededc439811afbf
2021-10-12 11:02:44 -07:00
Rakesh Pillai
e7c9776900 qcacmn: Fix the mask for tx completion near full irq
Currently the IRQ mask for tx completion near full
interrupt is not in sync with the tx completion rings
which are enabled for WCN7850.

Fix the mask for tx completion near full interrupt.

Change-Id: I1432191b260094060873406d48e04fde5b7bc35e
CRs-Fixed: 3052650
2021-10-12 04:52:16 -07:00
Nandha Kishore Easwaran
fa18b0fa88 qcacmn: Add new WDI event for HOST_SW_EVENT
Add new WDI event for WDI_EVENT_HOST_SW_EVENT which will be used by
pktlog.

Change-Id: Ie4e6a167e1118b430f418582af7ea9a8eb3aaf59
2021-10-12 02:29:41 -07:00
Naga
c46ec16889 qcacmn: Add change to modify if to ifdef
Add change to modify if to ifdef

Change-Id: I49e3841deb4168cbbc4e0a4f045413717aa97d2a
CRs-Fixed: 3050747
2021-10-12 02:29:35 -07:00
Naga
1648e13dbe qcacmn: Add HTT ring setup for monitor rings
Add HTT ring setup for monitor source and destination rings

CRs-Fixed: 3010856
Change-Id: Ice96ed938a25069fd60f07e2a4bebd9ad0184200
2021-10-12 02:29:29 -07:00
Naga
92ac36e016 qcacmn: Enable timer based low threshold interrupt
Enable timer based low threshold interrupt for waikiki monitor
tx/rx source rings

CRs-Fixed: 3010853
Change-Id: Ia33b110337e610ab9b5d7a9cecb61f6952cd3379
2021-10-12 02:29:23 -07:00
Naga
fa9b23b61f qcacmn: Enable monitor destination ring interrupt for waikiki
Enable monitor Tx/Rx ring interrupt for waikiki

CRs-Fixed: 3010851
Change-Id: I33537f7d4dbab700af7ccdb2ca511531fd3ade76
2021-10-12 02:29:17 -07:00
Naga
df329ebb84 qcacmn: Allocate and Initialize monitor rings
Allocate tx/rx monitor destination rings for waikiki

CRs-Fixed: 3010845
Change-Id: I1c6950188e2693cab648679d34d6731db53978f9
2021-10-12 02:29:11 -07:00
Naga
e1a6f926ed qcacmn: Add new HTT msg support for BE
- Add support htt msg for HTT_H2T_MSG_TYPE_TX_RING_SELECTION_CFG
  msg configuration
- Add support for configurable length dma
  per packet type for rx monitor.
- Add support for wordmask subscription for rx monitor.
- Add support for per packet msdu/mpdu logging config.
- Add support for tx monitor tlv subscription.
- Dummy APIs for 2.0 filter configuration

Change-Id: I36b18c03eff452537c2f051b24275b81ab98ebae
CRs-Fixed: 2991330
2021-10-12 02:29:05 -07:00
Naga
06cd379df0 qcacmn: Add support for Waikiki HAL Monitor
Add HAL specific structures and APIs to support
Waikiki monitor

Change-Id: Ie7516dcaff116ff03ff83e890d657b1b705a7484
CRs-Fixed: 3013523
2021-10-12 02:28:59 -07:00
Naga
5475a38feb qcacmn: Add support for BE monitor buf processing
Add support for BE monitor buffer processing

Change-Id: I2b7563e7a2c4d7e091ed093774b4f24047791708
CRs-Fixed: 3010502
2021-10-12 02:28:53 -07:00
Naga
69bd3e218f qcacmn: Add buffer mgmt support for BE monitor
Add support to allocate, free and replenish
rx and tx monitor buffers.

Change-Id: I9e59f4466740c0cf29a02711b6a112715e0224ab
CRs-Fixed: 3010486
2021-10-12 02:28:48 -07:00
Naga
9d6b212c7a qcacmn: Add sw desc pool support for BE monitor
Add APIs to allocate, free, init and deinit
sw descriptor pool for rx and tx monitor.

Change-Id: I03287cf3c590ace91825f16a7b0c5752c04fc8ed
CRs-Fixed: 3010468
2021-10-12 02:28:41 -07:00
Naga
84c4158c87 qcacmn: Add support for BE Monitor soc attach
- Change to allocate BE specific monitor soc
- Allocate, initialize soc and pdev level monitor rings
- HTT srng setup for source ring
- Dummy APIs to allocate, initialize sw desc pool

Change-Id: Icf90994e7bd76017cf3c83ae00449d839967321d
CRs-Fixed: 2991298
2021-10-12 02:28:36 -07:00
Naga
db1a6c8418 qcacmn: Add new data structures and ops for BE monitor
- New data structures are added for BE monitor support
  - dp_mon_soc_be  - to maintain soc level BE specific fields
  - dp_mon_pdev_be - to maintain pdev BE specific fields
  - dp_mon_desc_pool - to maintain descriptor pool
- Monitor ops are updated for 2.0 and corresponding dummy APIs
  are added.
- dp_mon_filter_srng_type is enhanced for TxMON

Change-Id: I12a2fbc53e4eecc7a191b7aa925431298d0a9f54
CRs-Fixed: 2991276
2021-10-12 02:28:30 -07:00
Naga
3289db4279 qcacmn: Monitor code segregation
- Features common to both Li and BE and
  their APIs are retained files at dp/wifi3.0/monitor.
- New monitor ops are introduced if there
  is a requirement for divergence of API.
- Diverged API definitions for 1.0 are captured
  in this change.

All of code in below files are moved to 1.0
- dp_rx_mon_dest.c -> 1.0/dp_rx_mon_dest_1.0.c
- dp_rx_mon_status -> 1.0/dp_rx_mon_status_1.0.c

Only Li and HMT specific are moved for below file
- dp_mon_filter.c -> 1.0/dp_mon_filter_1.0.c
- dp_mon.c -> 1.0/dp_mon_1.0.c

Change-Id: I44d163b27565b86068d80e1d97ec11d0b4a081d4
CRs-Fixed: 2991248
2021-10-12 02:28:25 -07:00
Naga
cca6b74fe7 qcacmn: Add new directory structure for Monitor
- dp/wifi.3.0/monitor/ => directory for monitor specific code
  - dp_rx_mon.c: status TLV procesing + packet buffer processing
  - dp_rx_mon.h: Rx monitor header file common for Li and Be
  - dp_mon_filter.c: Monitor filter configuration
  - dp_mon_filter.h: Monitor filter header file common for Li and BE

  - 1.0/ => directory for Lithium specific handling
    - dp_rx_mon_1.0.h: Rx Monitor specific header file
    - dp_rx_mon_dest_1.0.c: Packet buffer processing
    - dp_rx_mon_status_1.0.c: status TLV processing
    - dp_mon_filter_1.0.c: Rx Filter configuration
    - dp_mon_filter_1.0.h: Rx Filter configuration header
    - dp_mon_1_0.h - Li specific monitor ops
    - dp_mon_1_0.c - Li monitor ops handling

  - 2.0/ => directory for BE specific handling
    - dp_rx_mon_2.0.h: Rx Monitor specific header file
    - dp_rx_mon_2.0.c: Packet buffer processing
    - dp_rx_mon_status_2.0.c: status TLV processing
    - dp_tx_mon_2.0.h: Tx Monitor specific header file
    - dp_tx_mon_2.0.c: Packet buffer processing
    - dp_tx_mon_status_2.0.c: status TLV processing
    - dp_mon_filter_2.0.c: Rx and Tx Filter configuration
    - dp_mon_filter_2.0.h: Filter configuration specific header
    - dp_mon_2.0.h: BE specific monitor ops and defs header file
    - dp_mon_2.0.c: BE specific monitor ops handling

Change-Id: I74b5408460b5f2f4b31f73947b55d97dfe3b971e
CRs-Fixed: 2991215
2021-10-12 02:28:19 -07:00
Edayilliam Jayadev
d9667ef801 qcacmn: Prevent out of order delivery of mgmt frames
Keep track of the global time stamp of the last
management frame delivered to the upper layer.
Drop all the frames older than the last delivered
frame.

CRs-Fixed: 3049671
Change-Id: Ibe0cc239f7af38da63ea8c405b3f89fc9473ea57
2021-10-12 00:09:10 -07:00
Aditya Kodukula
6a5c5db59d qcacmn: Add Support to offload icmp feature to fw
Send command with required parameters to offload icmp
feature to fw.

Change-Id: Iefac64a34e274830f0c1c82589b2f35817306a64
CRs-Fixed: 3042454
2021-10-12 00:09:06 -07:00
Venkateswara Swamy Bandaru
ab2c08d63e qcacmn: Add wmi support for eht vdev params
Add wmi support for eht vdev params
mu mode, puncturing mode, ltf config, dcm
and range extension configs.

Change-Id: I6cfc0297a4a323775614f28717c50109558dd401
CRs-Fixed: 3052104
2021-10-11 14:56:04 -07:00
Chaithanya Garrepalli
b733f89803 qcacmn: change RxDMA rings to DMAC mode for QCN9224
For Waikiki use same SW2RxDMA ring for both radios

Change-Id: I33ab1749afada08e97d0b16fe68773c2d5532a15
2021-10-11 08:06:37 -07:00
Chaithanya Garrepalli
60db195327 qcacmn: Change to route vdev_id exceptions to FW
Configure HW to route vdev_id mismatch exceptions
packets to FW.

Change-Id: I8baf4a2f299ddda253a9cd3c247054a0e546af23
2021-10-11 04:51:39 -07:00
Shiva Krishna Pittala
409ffbfda0 qcacmn: Pass report parameters to FFT bin byte swap function
Pass report parameters to FFT bin byte swap function instead of
FFT bin length adjustment WAR.

Change-Id: I02a280bc4e8e0839c894a70258e1f16a784c08a6
CRs-Fixed: 3051559
2021-10-11 02:35:48 -07:00
Yu Tian
112813c1b7 qcacmn: Add API to get TX pending in WoW state
This change is used to provide an API for PMO module to
check whether there are pending TX frames before HOST sends
wake up indication to FW. PMO module uses this to indicate
FW whehter to discard HWDTIM.

Change-Id: Icc3271e87e376e3313fddc5f4f99e39daeaf6af7
CRs-Fixed: 3046947
2021-10-11 00:30:47 -07:00
Pragaspathi Thilagaraj
ce387c8fd3 qcacmn: Validate SSID first while fetching peer pmksa
Validate the SSID & cache ID if SSID length is present in the
pmksa entry, as in FILS case only SSID and cache id are filled
and BSSID is not filled.

So validate the BSSID only if the SSID is not present.

Change-Id: Ia0a31f953869f00495fad597bb564ec706425312
CRs-Fixed: 3051530
2021-10-08 23:15:58 -07:00
abhinav kumar
7427e70f15 qcacmn: Fix race condition between connect and disconnect
Scenario: In case of STA + STA, NB/SB issues disconnection for
vdev 0 when vdev 1 is in connecting state.

As connection is blocking serialization command and it can try
multiple candidates and can take upto 30+ sec, there is a
chance that disconnect may get timeout and is followed by
vdev delete from osif. This can lead to vdev delete sent
without vdev down/stop and bss peer delete for vdev 0.

So abort connection when trying for candidate if any of the
vdev is waiting for disconnect, to avoid disconnect timeout.

Change-Id: I7ef50b2e870317d2b095dd0385fcbe1c5b86fd20
CRs-Fixed: 3051567
2021-10-08 13:55:33 -07:00
Amit Mehta
76d60607f4 qcacmn: Ring History Display update
TP and HP values are assigned wrongly while
printing ring history. Fixing assignment.

Change-Id: I50ea90a3b49ab4d5459a3e0ddfa259f669764433
CRs-Fixed: 3051531
2021-10-08 08:17:32 -07:00
Harsh Kumar Bijlani
2cd98c7974 qcacmn: Restrict length of pdev backpressure event list
In current architecture, when host receives backpressure
event from FW, it prints pdev_id, ring_id, hp and tp values
for that ring in the tasklet context.
In same context, memory to hold the information of other
rings is allocate,  which then put into the list maintained
at pdev level and work is scheduled for printing this info.

In scenarios of heavy load, where the backpressure events
are continuously triggered, the list can grow to a bigger
one and printing of ring stats for all of these events can
be a heavy CPU hit.

As an optimization, restrict the depth of the list to 16
by checking the size of list when backpressure event is
received from FW. When list size reaches the max value (16),
then remove the entry from head and insert the new entry at tail.

Also in the worker thread, fetch only 1 entry from the list for
printing and schedule the work again if the list is not empty.

Change-Id: If4291b9d5ebee1e3d1eea80bbd0134faf090b2b8
CRs-Fixed: 3049635
2021-10-08 02:36:17 -07:00
Lincoln Tran
40e49db431 qcacmn: Add all membership selector elements
Include all elements from the BSS membership selector value encoding
table.

Change-Id: Ia9dda9aaa44d5c6ea83d750676511c1ed74bfb4b
CRs-fixed: 3050316
2021-10-07 23:15:56 -07:00
Bapiraju Alla
8354390c7d qcacmn: Add ML IE handling in util_scan_copy_beacon_data
Currently, ML IE address update is missing while copying the beacon data.
This may result in illegal memory access when ML IE accessed from copyied
scan entry after original scan entry got freed.

To avoid this, update ML IE address in new scan entry while copying
scan entry.

Change-Id: I6161481cbd13573b8177f122f7d26d177cc07aaa
CRs-Fixed: 3052302
2021-10-07 18:42:54 -07:00
Edayilliam Jayadev
8498476787 qcacmn: Add lock to protect reo algorithm entry
Add spin lock protect the critical section in reorder
algorithm entry.

CRs-Fixed: 3048994
Change-Id: I9bc6b30b2102dd14f0e5e2ba593e9a6bbbb72714
2021-10-07 18:42:49 -07:00
Shashikala Prabhu
f833646e06 qcacmn: Do not limit the max length of RSN/WPA IE as 28
Do not limit the max length of RSN/WPA IE as they can contain multiple AKM
and CIPHER. We need to consider all the variables to limit the max length.

Change-Id: I204f86d7c773d0c104ad1f58b3648d6c5577af94
CRs-Fixed: 3051247
2021-10-07 07:05:44 -07:00
Vignesh U
9abbd66770 qcacmn: Do not allow to set same 6G AP power mode
The API that takes in the input 6G AP power type and updates current
channel list, allows setting the same power type which is not needed and
is a costly operation.

Change-Id: Ia690f40a6796a0db243f0abd15f2eebc8340d1d9
CRs-Fixed: 3051502
2021-10-07 04:46:08 -07:00
Vignesh U
c47cd3f96c qcacmn: Reset AFC power event received status
The power event received status is set when AFC power event is received
and is reset unconditionally when AFC expiry event received.

Reset AFC power event received status only on receiving AFC expiry event
with sub-type AFC_EXPIRY_EVENT_SWITCH_TO_LPI.

Change-Id: Ib7c1d12cbc2797ddbb19d73fd38d82d100adf3d3
2021-10-07 04:46:04 -07:00
Himanshu Batra
069f37b825 qcacmn: Use osif_cfg as disconnect source for ML internal disconnect
In case when connect req is received while ML connect is in progress,
disconnect is issued with SB_disconnect as source but sb disconnect is
not handler in join active. So, send osif_cfg_disconnect as a source

Change-Id: I9604e23193ba3aef334f0873d2460a992b1914ea
2021-10-06 13:06:04 -07:00
Himanshu Batra
3c15eb5ff7 qcacmn: Update DP interrupt mask assignment table for IPA Offload
Update DP interrupt mask assignment table for IPA Offload

Change-Id: Id91ab040f52a4e3b81e38754cc500dad3ab2fd22
2021-10-06 07:36:29 -07:00
Hariharan Basuthkar
7a1cdfbd43 qcacmn: Intersect CFIs with SP chan list and AFC frequency range
When the frequency ranges and channel frequency indices in the AFC
server response are not the same, the current channel list has
channels enabled, that are absent in the CFIs.

This is because the AFC master channel list is built by intersecting
the frequency ranges in the AFC frequency object and state of the
channels in the SP AP master channel list.

To fix this issue, build the AFC master channel list by intersecting
the frequency ranges in the AFC frequency object and state of the
channels along with the CFIs received in the AFC channel objects from
the target.

Change-Id: I12cc54f90b75b9a7be491e7dd2e9c101be6dd1f6
CRs-Fixed: 3042040
2021-10-06 04:22:38 -07:00