Commit Graph

19609 Commits

Author SHA1 Message Date
Gaurav Saini
1630288f30 qcacmn: Remove AST dependency for sawf
To eliminate the use of AST, using net dev to
find the peer related information, which helps
in avoiding the iterations of psoc list.
Passing the peer id as addition parameter to DP

Change-Id: I68e4ad8d5d62b2350ed0c2df66279de3fa9c0d83
CRs-Fixed: 3526799
2023-07-11 18:16:20 -07:00
Ripan Deuri
8c9b52f61d qcacmn: Add INI to disable AST indication
Add INI to disable AST indication. AST disable flag will be
sent to the target in resource config.

Change-Id: If30cac010681faf06bbcaa2d492d6843e3e675d0
CRs-Fixed: 3544223
2023-07-11 15:38:37 -07:00
Neha Bisht
ddd144bfd6 qcacmn: Fetch current primary soc from mld peer
Fetch current primary soc from mld peer instead of current link peer.

Change-Id: I6c9fc7712b16d938d47b1cd1b5e8bf75eaf352d0
CRs-Fixed: 3547555
2023-07-11 12:49:53 -07:00
Prakash Manjunathappa
fab64e0adc qcacmn: Allocate pdev attach bufs from page frag
Use page frag init time rx buffer allocation for efficient usage of memory.
Add ini dp_bufs_page_frag_allocs to disable and revert to original slab
nbuf allocations.

Change-Id: Iac78895addfe9da0118bc071c691a26216d6fda1
CRs-Fixed: 3553800
2023-07-11 12:49:43 -07:00
Balaji Pothunoori
02622819d0 qcacmn: Extract Rx data packet SGI from WMI_VDEV_SMART_MONITOR_EVENTID
Due to limitation uCode always filling SGI as long for VHT mode in
rx_msdu_start_tlv.

This change is to extract VHT Rx data packet SGI from
WMI_VDEV_SMART_MONITOR_EVENTID.

Change-Id: I5fcdc463ea2a6d83253e39cc377a2471aeb4e122
CRs-Fixed: 3477303
2023-07-11 12:49:32 -07:00
Amit Mehta
725454258b qcacmn: Add additional stats to dp_dev
Add additional stats to dp_vdev:
	1. tx. fragment_count
	2. rx.duplicate_count
	3. rx.fragment_count

Change-Id: Ib9fec3b5e7733bbdda09ae5598a092072ebaaee4
CRs-Fixed: 3554690
2023-07-11 12:49:22 -07:00
Edayilliam Jayadev
d06edf421b qcacmn: Handle out of order packet counters
Gracefully handle the scenario where the packet counter
of the current management frame is less than or equal to
the packet counter of the last management frame received
in the same link.

CRs-Fixed: 3525902
Change-Id: Iba7d2bd55fd8e969486439ef87a81c489658707c
2023-07-11 02:02:36 -07:00
Edayilliam Jayadev
8da0ec5f5a qcacmn: Handle zero duration management frames
Gracefully handle management frames with zero duration.

CRs-Fixed: 3525887
Change-Id: I60ef63f88b2c07d253679f54c9e9cb02d1d87860
2023-07-11 02:02:19 -07:00
Edayilliam Jayadev
dbcf99be3e qcacmn: Handle invalid reo params gracefully
Gracefully handle invalid reo parameters error.

CRs-Fixed: 3525856
Change-Id: I1bc18ed9224ea999bc792642dcb5081583cfa1f6
2023-07-11 02:01:27 -07:00
Edayilliam Jayadev
62d03ddb2c qcacmn: Add infrastructure to gracefully handle frames
Add infrastructure to gracefully handle frames in management
Rx reorder module.

Change-Id: I9d5302acfc020686b4c51b666fc7828dddf20ca7
CRs-Fixed: 3525838
2023-07-10 21:23:06 -07:00
Shreedhar Parande
a322f77e8f qcacmn: Define WMI callbacks for v2 ATF WMIs
Define and initialize new WMIs for v2 ATF.

Rename send_set_atf_cmd to send_atf_peer_list_cmd which
is more appropriate.

Change-Id: Icab17703a4ccea8e2b859bf6a18387fbd2234226
CRs-Fixed: 3542065
2023-07-10 21:22:56 -07:00
Sijun Wu
27f8cfff08 qcacmn: Add a set of nbuf fragment allocation APIs
It adds a set of frag way allocation APIs explicitly.
IPA Tx nbufs change to frag way allocation API, which saves memory.

Current __qdf_nbuf_alloc changes to non-frag way allocation by
default if SKB RECYLCER not defined.

Change-Id: I5f87ffac54c49f9af920775c13b6dfdd147476dd
CRs-Fixed: 3534452
2023-07-10 21:22:46 -07:00
Subrat Mishra
e6b159369e qcacmn: Extract WMI ATF 512 Max client support from FW
Extract WMI Service bit for ATF 512 Max client support advertised by
Firmware as part of wmi service ready.

Add rxops functions as for upper modules to get it.

Change-Id: I51e8dcaad96bdd29eb6fd4c37b0917127696ede6
CRs-Fixed: 3551661
2023-07-10 18:04:07 -07:00
Venkateswara Naralasetty
fc93f83a78 qcacmn: Add SWLM support for WCN6450
Changes required to support SWLM feature on wcn6450.

Change-Id: I306cba8dcefa8f34a9546285b33b974987aec625
CRs-Fixed: 3540269
2023-07-10 18:03:57 -07:00
Nandha Kishore Easwaran
6ca74c40fd qcacmn: Add alignment of 4 bytes back
This reverts commit Ib680547d2bcfe57b6eadda5301677d68e4a931a4

Change-Id: Iffc7f2cdab2d1015db4b3f0dfc0ea697e0388238
CRs-Fixed: 3552537
2023-07-10 15:03:04 -07:00
Venkateswara Naralasetty
a3a5a72bbd qcacmn: Add delayed reg write support for wcn6450
Current HAL delayed reg write is tied to SRNG notions, hence
implement delayed reg write logic in HIF since WCN6450 does
not use SRNG interface.

New feature flag FEATURE_HIF_DELAYED_REG_WRITE is introduced
to disable/enable this support.

Change-Id: Id7087ad53cd5879cf49ee0e84dd727de61137541
CRs-Fixed: 3519702
2023-07-10 12:14:13 -07:00
Sai Rupesh Chevuru
219a541da6 qcacmn: API to get the bridge peer
API to get the bridge peer if available

Change-Id: Ib93df6f95ad4bff4cb628be637799a5b40d20272
CRs-Fixed: 3552648
2023-07-10 12:14:02 -07:00
Deeksha Gupta
5bda5de6ce qcacmn: populate num_max_mlo_link_per_ml_bss in WMI init
Set num_max_mlo_link_per_ml_bss to WMI init command.

Change-Id: I48a46f66cea86ee660656509a9cd688e3e1f7541
CRs-Fixed: 3512393
2023-07-10 12:13:51 -07:00
Deeksha Gupta
589214a617 qcacmn: Extend wmi_service for n-link MLO connection
Extend wmi_service for n-link MLO connection.

Change-Id: I269d1730eb59dcf492aca675b0fbfc3e56a0fbb7
CRs-Fixed: 3512375
2023-07-10 12:13:40 -07:00
Prasanna JS
56a52faed0 qcacmn: Define a QCA vendor attr to config UL MU transmission
Define a new QCA vendor attribute to enable/disable trigger
based UL MU transmission.

Change-Id: Ide36ec4869dc462879a57ff9a1e06f9f48e5c8d0
CRs-Fixed: 3538865
2023-07-10 09:17:15 -07:00
Harsh Kumar Bijlani
aac3c82e06 qcacmn: Update Tx ingress received per core stats in exception path
Update Tx ingress receeived per core stats in exception path

Change-Id: Iebfbc0305b5032ca65135ffd1d3a80647c44f733
CRs-Fixed: 3552494
2023-07-10 02:34:11 -07:00
Li Feng
7f998d6240 qcacmn: Bypass hif apps irqs handle for single MSI case
Regarding to the platform suspend, generally the hif_bus_suspend() will
disable the CE irqs, however the irq is shared in the single MSI case,
so the MHI irq is disabled as well which cause no MHI ring event notified
in the following pci bus suspend.

The fix is to bypass hif apps irqs handle for single MSI case during
suspend-resume stage.

Change-Id: I4f9068900e85fe57c2a82d841846b3fff6da0696
CRs-Fixed: 3549884
2023-07-09 06:03:59 -07:00
Sri Vidya Gunturi
138833a0eb qcacmn: Masking MLO APIs for the non-MLDs
Masking the MLO API, mlo_setup_get_total_socs
using ic_eht_target check for non-MLDs in cmn_dev.

CRs-Fixed: 3551482
Change-Id: I8d585f534146f58beee605b2165bb0c51fc5bdb9
2023-07-08 11:11:44 -07:00
Subrat Mishra
5d85f97e90 qcacmn: Add north bound interface for ATF max client change
Add north bound interface to support increase ATF maximum client
changes.

Change-Id: I2a86cccc4834cb713b1c4a3624ae950ab9e02b3b
CRs-Fixed: 3503390
2023-07-08 11:11:35 -07:00
Devender Kumar
97b397502d qcacmn: Update the MAX value for dp rxdma ring size
Update the max value for dp rxdma ring size to 8192.

Change-Id: I6cb13ac9d25f243d07cd7da1014a21d31835eb81
CRs-Fixed: 3515920
2023-07-08 11:11:25 -07:00
Ashish Kumar Dhanotiya
8775d1b518 qcacmn: Update policy mgr device mode conversion API
Currently policy mgr api policy_mgr_convert_device_mode_to_qdf_type
accepts only QDF_OPMODE as an argument and converts it to
policy_mgr_con_mode. Also, name of this api does not reflect
the task this is doing.
With the new SAP mode for low latency low throughput SAP,
to convert the QDF_OPMODE to policy_mgr_con_mode, host driver
needs to know if it is ll_lt_sap or normal sap. To get this
information, update policy_mgr_convert_device_mode_to_qdf_type
api to accept the psoc and vdev id as parameters. Also, rename
this api to reflect the task this apiis doing.

Change-Id: Ib182d8091305fd9c4f35b424d7b4a751a61730ad
CRs-Fixed: 3525427
2023-07-08 11:11:14 -07:00
Jinwei Chen
6081fb19d6 qcacmn: Support dp monitor desc pool memory pre-allocation
Support dp monitor desc pool memory pre-allocation.

Change-Id: I7edd766a3f02be76c1e7342ac6a55c02b43474fa
CRs-Fixed: 3544435
2023-07-08 01:26:16 -07:00
Yu Wang
1632797f1c qcacmn: refine hif tasklet latency detection
When one of the enabled CE tasklet is executed, it will
check latency of all the others which are enabled, it's
redundant. Add a new API to check latency for a single
tasklet.
Add API to record sched time for a tasklet, which will
check the enablement of detection before recording the
time.

Change-Id: I515ca27fc2e97231397573b4903c001d29326bd2
CRs-Fixed: 3514285
2023-07-08 01:26:06 -07:00
Shashikala Prabhu
7f898dfcc2 qcacmn: Add buffer window for umac reset in progress
When the peer delete timer/vdev manager response timer expires, host checks
if the umac reset is in progress. If so, host will retrigger the timer.
It is possible that the umac reset is just completed and either of these
two timers got expired. In this case, host will assert saying that the peer
delete response/vdev manager response is not received from FW. FW may take
a few milliseconds to send the peer delete/vdev manager response to the
host after the umac recovery completes.

Hence, to avoid the crash, check if the umac reset was in progress during
the umac reset buffer window.

Add the below changes as well,
1) INI support to get the umac reset buffer window value.
2) Renamed the API dp_umac_reset_is_inprogress as
   dp_get_umac_reset_in_progress_state to return either
   CDP_UMAC_RESET_IN_PROGRESS or
   CDP_UMAC_RESET_IN_PROGRESS_DURING_BUFFER_WINDOW.

Change-Id: Ie15ef0731bad4b0ed955a479f00e297b7ba10729
CRs-Fixed: 3522665
2023-07-05 17:19:13 -07:00
Prasanna JS
0d36189af1 qcacmn: Add macro to check the phymode is EHT
Add macro to check the phymode is EHT when
WLAN_FEATURE_11BE not defined

Change-Id: If6ae8829c21d7cbed1740aa2f637f4b90dea1a3d
CRs-Fixed: 3546219
2023-07-05 17:19:02 -07:00
jinbao liu
252faaf14e qcacmn: Fix some potential uninitialized local variables
This change initializes some uninitialized local
variable to avoid arbitrary values in some cases.

Change-Id: I906528514c41132ead23433a8a91374b4309c543
CRs-Fixed: 3545869
2023-07-05 17:18:52 -07:00
Thirusenthil Kumaran J
f1ea292064 qcacmn: Set the VAP flag to block Tx after radar is hit
The change 'I4acd2f70707386f731e9b8fa2ef90a37868cbe23'
makes modifications in MLME and DP (Data Path) to optimize
the check for radar in per packet transmission path to
reduce CPU processing overheads. This new check is based on
a VAP variable that indicates whether radar is detected
or not.

Upon radar detection, send an indication to MLME through the
registered callbacks to update the status of the flag.

Change-Id: Id0582b5d79be672949f150907eb9ee64fa17d4f7
CRs-Fixed: 3528956
2023-07-05 17:18:41 -07:00
Amit Mehta
241f75e574 qcacmn: Release RTPM refcount if force wake release fails
Currently RTPM refcount is not released if force
wake release fails. This leads to mismatch in number of
RTPM get and put during RTPM de-init.
Fix this refcount release if force wake release fails.

Change-Id: I4334de57e00139c0d30d37d7e19a399760400a50
CRs-Fixed: 3544981
2023-07-05 17:18:31 -07:00
Pavankumar Nandeshwar
9f16b44a9b qcacmn: Add missing nbuf_count updates in qdf APIs
Add missing nbuf_count updates in qdf APIs which are used
for keeping track of nbufs in debug mode.

Change-Id: If031ec8860513dddb1704a75e4761ce14aa26f21
CRs-Fixed: 4728458
2023-07-05 17:18:21 -07:00
Nandha Kishore Easwaran
8a745cc343 qcacmn: Remove alignment of 4 bytes
Remove alignment of 4 bytes when allocating memory for Copy
engines. Copy engine buffer size is 2048 which is already
aligned to 4 bytes. This 4 byte alignment addition results in
64 bytes extra memory allocation for each skb since SKB_DATA_ALIGN
rounds it off to nearest 64.

Change-Id: Ib680547d2bcfe57b6eadda5301677d68e4a931a4
CRs-Fixed: 3533492
2023-07-05 17:18:11 -07:00
Varsha Mishra
eadb65cdde qcacmn: Update vlan tag in multipass received frames
All packets except TID 0 first come to REO error NULL queue.
This happens because only TID 0 queue is setup initially.
Added multipass specific code in NULL queue path.

Change-Id: I8103215ad3e28796c868caa3eec816b9d118da9d
CRs-Fixed: 3482796
2023-07-05 08:36:38 -07:00
Priyadarshnee Srinivasan
596b68de2e qcacmn: Add APIs to support RCSA and puncturing
Add API utils_dfs_get_radar_bitmap_from_nolie() to fetch the puncture
bitmap from NOL IE. Also, move dfs_convert_wlan_phymode_to_chwidth()
from oss to common code. Also, add a 11BE version of
utils_dfs_convert_wlan_phymode_to_chwidth() API.

CRs-Fixed: 3538818
Change-Id: I258452e122d259c7b16655b760f217073b8e2e9b
2023-07-05 08:36:22 -07:00
Neha Bisht
092276d49f qcacmn: Change num of packets to unsigned 64bit
Change number of packets datatype to unsigned 64bit and handle
respective print message changes.

Change-Id: I65e1ae90985b7d2fb29ea57f8034f5858491dae1
CRs-Fixed: 3534513
2023-07-05 08:36:10 -07:00
Namita Nair
b50ceeee79 qcacmn: Defer IPA SMMU mapping to OPT_DP reserve
Currently, IPA SMMU map/unmap is called as part
of init. This causes every nbuf to be mapped
to IPA in the Rx path, causing throughputs
to drop. This change resolves the problem by
deferring the IPA SMMU map/unmap
call to OPT_DP filter reserve/release, as
nbuf needs to be mapped to IPA only in this scenario.

Change-Id: If198a6c5f22af58fdaf9d9c020c74b1f76002e37
CRs-Fixed: 3496679
2023-07-04 22:36:13 -07:00
Sai Rupesh Chevuru
7830b92b9d qcacmn: primary umac update event to handle downgrade scenarios
Trigger the STA primary umac update event to umac
to handle downgrade scenarios.

Change-Id: I510d3d4443a978a8e2112f7372d0d1a03a508d18
CRs-Fixed: 3540314
2023-07-04 22:36:03 -07:00
Amit Mehta
54976d0150 qcacmn: Add changes to aggregate rx packet count
Add changes to aggregate rx packets count for
per link stats.

Change-Id: Iba3409751a36a2d1bbb7559289bdd6ae414678ac
CRs-Fixed: 3547369
2023-07-04 19:15:49 -07:00
Kenvish Butani
54b264c3a1 qcacmn: Fix RCU stall due to long SG list in RX Error path
RootCause:
WBM RX Error Ring, receives a packet from RXDMA with FCS Error
and MSDU Continuous Bit set. As MSDU continuous bit is set the
nbuf is added to temp SG list, but SG for these error is not
supported, hence the temp SG List never got reset and it
incremented hugely leading to high number of nbuf for
processing in list which lead to RCU stall

Fix:
IN WBM RX Error Ring, SG is supported only for two kind of
errors i.e. NULL Desc and Unencrypted. For all other kind of
errors reported by HW with MSDU Continuous bit set, explicitly
reset MSDU continuous bit in nbuf

Change-Id: I8d5858ccefb89b93e1c4fb36609d747eef00e8f2
CRs-Fixed: 3532208
2023-07-04 19:15:39 -07:00
Chunquan Luo
fe2d300175 qcacmn: Add QCA vendor interface to support per-MLO link configurations
Add support for per-MLO link configurations in
QCA_NL80211_VENDOR_SUBCMD_SET_WIFI_CONFIGURATION and
QCA_NL80211_VENDOR_SUBCMD_GET_WIFI_CONFIGURATION commands.

Additionally, add documentation for
QCA_NL80211_VENDOR_SUBCMD_SET_WIFI_CONFIGURATION and
QCA_NL80211_VENDOR_SUBCMD_GET_WIFI_CONFIGURATION commands.

Change-Id: Id83912079b3a4876891ac48beb069b17d4b8ebbf
CRs-Fixed: 3540412
2023-07-04 19:15:28 -07:00
Chunquan Luo
0b81d02fd1 qcacmn: QCA vendor interface to control maximum allowed bandwidth update type
Add support to control maximum allowed bandwidth update type for
the current connection.

Change-Id: I27880a5a969adf46861a58907d1e9e8ec35f9053
CRs-Fixed: 3540098
2023-07-04 19:15:18 -07:00
Nidhi Jain
84327ba403 qcacmn: Change mlo_err to mlo_debug
Change mlo_err to mlo_debug to avoid prints for WIFI6/6E platforms.

Change-Id: I48d83683afd3fb0e6db7844a9254e1b78f9e2868
CRs-Fixed: 3532032
2023-07-04 15:41:31 -07:00
Himanshu Batra
6ebded7a71 qcacmn: Use qdf_list APIs instead of TAILQ APIs
Use qdf_list APIs instead of TAILQ APIs.

Change-Id: Ie82fe6450013838f4125073d1f9a6da41b8516ed
CRs-Fixed: 3545385
2023-07-03 12:54:05 -07:00
Prasanna JS
5f2fa5a090 qcacmn: Add target_if API to update SR threshold
Add target_if api to update SR threshold.

Change-Id: Ia2fd40a92598c772bb02998d938edb9b98ac253e
CRs-Fixed: 3374628
2023-07-03 12:53:54 -07:00
Jia Ding
442d77805c qcacmn: Fix buffer overflow for ipa_ctx->sys_pipe
ipa_ctx->sys_pipe[] is an array with size WLAN_IPA_MAX_SYSBAM_PIPE (4).
On MDM platforms, WLAN_IPA_MAX_IFACE could be set to 4 in defconfig.
E.g. on sdxpinn/hmt platform, CONFIG_NUM_IPA_IFACE is set to 4.

kiwi_v2_defconfig
CONFIG_NUM_IPA_IFACE := 4

With this, WLAN_IPA_RX_PIPE will be equal to 4, leading to array index
out of bounds buffer overflow.

Fix is to set WLAN_IPA_RX_PIPE to WLAN_IPA_MAX_SYSBAM_PIPE - 1 to point
to last index of ipa_ctx->sys_pipe[].

Change-Id: I4929aec92ed2064c5194ec18ad7b33574ba3c3e7
CRs-Fixed: 3545420
2023-07-01 13:35:20 -07:00
Asutosh Mohapatra
17ed1cfc4f qcacmn: Add enhancements to support SET_FCC_CHANNEL 2
Currently in host support is there for SET_FCC_CHANNEL
command for values 0, -1, 1.
Add changes to support SET_FCC_CHANNEL command for value 2.

Change-Id: I151ce33677406670bebc7a8861e34da3e4c5917a
CRs-Fixed: 3537395
2023-07-01 06:51:49 -07:00
Nijun Gong
ce14cb4467 qcacmn: Enable IPA pipe for second SAP
On sdxpinn target (first multi-core MDM platform) with rome
chip attached, it's required to enable IPA pipe for both SAP in
AP-AP mode, but currently only first AP has IPA pipe enabled.
The second AP always goes with sw path because wlan firmware isn't
notified to choose IPA path by wlan_ipa_uc_offload_enable_disable().

The fix is to always enable IPA for each SAP no matter how many
SAP are started if MDM_PLATFORM is defined.

Change-Id: I8a2048aae04e14aa840d7d9a2ccb287201336cf3
CRs-Fixed: 3532926
2023-06-30 23:49:11 -07:00