Commit Graph

18914 次程式碼提交

作者 SHA1 備註 提交日期
Harsh Kumar Bijlani
82afb1d8d2 qcacmn: Mask ppdu_id received in Tx HTT PPDU completion path
FW sends ppdu_id for every TLV in Tx HTT PPDU completion path.
This ppdu_id has 8 MSB bits filled with FW metadata which is different
for every TLV. Host uses this ppdu_id for list maintenance.
Presence of the FW metadata results in ppdu_id mismatch for different
TLVs even when they belong to the same PPDU.
Consider only LSB 24 bits for ppdu_id on host side.

Change-Id: Ic6ec780fe97f0597fcd841b33ac0dce33ad986c9
CRs-Fixed: 3445603
2023-04-05 09:04:11 -07:00
Shwetha G K
63843ae368 qcacmn: Populate additional params to CFR info
HAL changes to populate agc gain, CFO, rx_start_ts, mcs_rate and
gi_type to CFR info.

Change-Id: I20b4ce1b8c065349106cd999054ff08c7f3521ec
CRs-Fixed: 3453631
2023-04-05 02:04:58 -07:00
Pooja T C
933db0e737 qcacmn: Add QDF Module id for SOUNDING module
Added a QDF module id for SOUNDING module.

Change-Id: If237f91d52ad6f73921481e85327006563c9382b
CRs-Fixed: 3439637
2023-04-05 02:04:46 -07:00
Neha Bisht
9197d3b898 qcacmn: Update primary_umac_psoc_id field for new primary TQM peer
Update primary_umac_psoc_id field for new primary TQM peer

Change-Id: I397069a97ef0741b4c069302e59f4b9a2c005089
CRs-Fixed: 3451704
2023-04-05 02:04:33 -07:00
Namita Nair
92d4955468 qcacmn: Default routing for SAP mode with IPAoffload
CUrrently if IPA offload is enabled in SAP mode
the default Rx routing is to IPA serviced REO rings.
With this change the default raouting is set to
WLAN HOST serviced REO rings.

Change-Id: Ibf9dead063c9d9fbc6b1fd502342ea13456b2473
CRs-Fixed: 3421879
2023-04-04 19:52:00 -07:00
Jhalak Naik
e7058a73c6 qcacmn: Fix invalid memory access
Fix the spectral mode check to avoid invalid memory access.

Change-Id: Id95cf19457aa2eddee90568fa567e5f7859a0a53
CRs-Fixed: 3452841
2023-04-04 19:51:50 -07:00
Chaithanya Garrepalli
7b4de01928 qcacmn: Change invalid ml_group_id and chip_id values
Change invalid ml_group_id and chip_id to 255 (uint8_t max)

Change-Id: I609aee14c7e6874bc78ddec3130a5a1226fc2af5
CRs-Fixed: 3443177
2023-04-04 16:30:46 -07:00
Kiran Venkatappa
bd5b5ef599 qcacmn: Handle mlo setup soc down from detach path
mlo setup soc down indication can be called from soc_stop and detach
path. Add logic to handle multiple calls by ignoring down if the state
is already cleaned up.

Change-Id: I6f5c11cc30f38423661063d2834a5b4efa088a49
CRs-Fixed: 3450300
2023-04-04 14:41:16 -07:00
Amruta Kulkarni
d325372a5c qcacmn: Fix to remove mutex warnings
Mutex cannot be acquired or released from
interrupt context.
To fix the warning in log, do not acquire
or release log in while stopping t2lm timer

Change-Id: Ie1e885b162a22e327d3260fecbd71153b947e11b
CRs-Fixed: 3444779
2023-04-04 06:44:21 -07:00
Vijay Raj
968b7862c8 qcacmn: Introduce roam failure reason code for beacom miss event
Add new roam failure reason code for no ap found and final
beacon miss sent and reason code for no candidate found
and final beacon miss sent

Change-Id: I4c4813efdedd30bd65c7baf0110c292c5ae3573c
CRs-Fixed: 3437119
2023-04-04 05:07:27 -07:00
Ripan Deuri
73e98e34e8 qcacmn: Add CDP op to get SAWF MSDU Queue info
Add CDP op to get MSDU Queue info

Change-Id: If76a6e4209d80e5da6093632e0f3d99b9aeaef77
CRs-Fixed: 3435987
2023-04-03 04:31:44 -07:00
Namita Nair
9293b993f1 qcacmn: Handle return status when IPA UC not loaded
Currently if IPA UC is not loaded when opt wifi dp
is enabled, the return status is not handled correctly.
This causes the qdf_event_create to happen for ipa ctx
which later triggers an assert during ipa cleanup.
This fix will handle this scenario.

Change-Id: Ie0a38bd6745f54a37be422e1d352f6c2a7960bbc
CRs-Fixed: 3444783
2023-04-03 04:31:26 -07:00
Vignesh U
5dc7fe9a25 qcacmn: Unpack AFC structures
During initial AFC development it was assumed that AFC object would travel
till an application endpoint outside the driver, presumably till an
application of a different machine anything in the internet and therefore,
a packed and well formatted structure was propped for the AFC object.
However, when the AFC object leaves the driver, it is converted to an
object that has NL80211 TLVs to represent it. Therefore, the packed
AFC-request object is no longer a necessity. Moreover, since an unpacked
structure (or structures) is speed/time optimized, modify the packed
structures into unpacked structures.

Change-Id: I08db1911a355b6eebffa0e13def547c98ddf38d3
CRs-Fixed: 3431997
2023-04-03 01:36:23 -07:00
Harsh Kumar Bijlani
af094fe095 qcacmn: Add support to get stats for MLD interface
Add support to get stats for MLD interface in single netdev model

Change-Id: I223a5c003191147970be57b92e99f1df3c66b339
CRs-Fixed: 3444443
2023-04-03 01:36:11 -07:00
Krupali Dhanvijay
8ca91ab2bf qcacmn: Send Driver disconnect internal reason code to user space
Send the driver disconnect internal reason code as an event to user space
using QCA_NL80211_VENDOR_SUBCMD_DRIVER_DISCONNECT_REASON vendor command.

Change-Id: I0027675b809b94628b6c0c4b8e8286e38fa9f47d
CRs-Fixed: 3371398
2023-04-03 01:35:59 -07:00
Vignesh C
070e8af74f qcacmn: Add support for HMWDS add and reset cmds in Beryllium
Add HMWDS add-addr, rem-addr, reset-addr and reset-table support
to add, reset and remove AST HMWDS mac entries in Beryllium
chipsets.

wlanconfig athX hmwds add-addr wds_ni_macaddr wds_macaddr
wlanconfig athX hmwds reset-addr macaddr
wlanconfig athX hmwds reset-table
wlanconfig athX hmwds rem-addr wds_macaddr

Change-Id: Iaa110ba26a477fc0b77647a712c377029b038940
CRs-Fixed: 3429510
2023-04-03 01:35:47 -07:00
Namita Nair
2859221891 qcacmn: HTT layer fix fail_cnt for opt wifi dp
Move fail_cnt and abort_count to soc->stats
struct, so that we can retrieve stats
during a crash. Also fix few other errors
found during initial tests.

Change-Id: Ieaee10b2dd2b5e589c21aa50c83dcf352623275d
CRs-Fixed: 3428501
2023-04-02 22:58:03 -07:00
Neha Bisht
e12a986996 qcacmn: Fill src_info_valid field in HTT msg to FW
Fill src_info_valid field in HTT msg to FW

Change-Id: I597c482345eb84cac19a5ee891967a17845f300a
CRs-Fixed: 3449021
2023-04-02 13:11:53 -07:00
Namita Nair
bf8fcc25af qcacmn: Disable autonomy for opt wifi dp based on WLANflag
Currently IPA autonomy is disabled for opt wifi dp
feature inorder to set default packet routing
to HOST REO rings instead of IPA. The check currently
depends on the feature flag set from IPA.
But this does not handle the case if feature is
enabled from WLAN but disabled from IPA, as autonomy
will get enabled in this scenario and default packet
routing is set to IPA.
This fix will check if opt_wifi_dp feature is
enabled from WLAN and disable autonomy to
ensure the default routing is always set to
HOST REO rings.

Change-Id: I3673d7dbeefcadb45132ea300f4ec3ac22743b86
CRs-Fixed: 3450862
2023-04-02 06:53:35 -07:00
Aniruddha Mishra
dc75883972 qcacmn: Free buffer after processing flush_tlvs
Buffer was freed before processing the TLVs
(while flushing) leading to use after free access.

CRs-Fixed: 3425044
Change-Id: Ida3bcf9add95041c43b2b1e8e3450853bd0ed88c
2023-04-02 06:53:24 -07:00
Priyadarshnee Srinivasan
30e5729efd qcacmn: Fill only supported opclass in the AFC request buffer
In case of a split-phy 6 GHz radio, there are 6 GHz opclasses and cfis
that do not intersect with the chip range for a given pdev.
The current algorithm appends such opclasses with "num_cfis as 0" to
the AFC request buffer and the buffer with empty cfis are
sent to the AFC server.
This change ensures that the chip unsupported opclasses/cfis are not sent
to the AFC server.

Also, if the reg rule frequency range is not supported by the chip range,
reg_intersect_ranges() is expected to set the out_range as
{low_freq = 0,high_freq = 0}. However, it only sets the low_freq to 0.
Since high_freq is a non-zero value, the chip un-supported range is
considered as a valid range with frequency_low as 0.
This causes the following error from the AFC server:
"error": "The frequency range indicated in the Available Spectrum
Inquiry Request is at least partially outside of the frequency band
under the management of the AFC System (e.g. 5.925-6.425 GHz and
					6.525-6.875 GHz bands in US).

To fix this issue, assign high_freq also to 0 if the
reg rule frequency range is not supported by the chip range.

CRs-Fixed: 3442719
Change-Id: I5504376ac31203045b32e23f54a9ab6a41e63a3f
2023-04-02 05:17:27 -07:00
Namita Nair
d33baafbe5 qcacmn: WAR for opt_wifi_dp feature to disable IPA(1)
IPA_OFFLOAD will be enabled by  default for MSM.
This is a WAR to disable IPA offload during compile
time, based on the IPA_WDI_OPT_DPATH feature flag from IPA.
If the flag is not defined in the IPA test
module file, IPA offload path will be disabled.
This is a WAR, and will be fixed once a Kernel config is
available to enable or disable the optional wifi datapath
feature.

Change-Id: I7aad275f4d86a2ffc239f1fe343de31ec2988fad
CRs-Fixed: 3431972
2023-04-02 01:23:12 -07:00
Namita Nair
d252ffb791 Revert "qcacmn: WAR for opt_wifi_dp feature to disable IPA(2)"
This reverts commit 
with Change-Id: Ic1b961656f52fa009ab4c3b3d8d3cac305c2c7c4.

Change-Id: Idc5101d3bac08a64f7de0a828841222eca8d3c01
CRs-Fixed: 3443469
2023-04-02 01:23:03 -07:00
Namita Nair
149071276c qcacmn: WAR for opt_wifi_dp feature to disable IPA(2)
IPA_OFFLOAD path will be enabled by default for MSM,
inorder to support optional wifi datapath feature.
This change is a WAR to disable IPA offload during
compile time, if the feature is not enabled.
This is done using the IPA_WDI_OPT_DPATH feature flag
from IPA. If the flag is not defined in the IPA test
module file, IPA offload path and optional wifi dp
feature will be disabled.

This is a WAR, and will be fixed once a Kernel config is
available from IPA to enable or disable the optional
wifi datapath feature.

Change-Id: Ic1b961656f52fa009ab4c3b3d8d3cac305c2c7c4
CRs-Fixed: 3431972
2023-04-02 01:22:52 -07:00
Pavankumar Nandeshwar
4df32b4c7a qcacmn: Return gracefully if ingress device is NULL
If the ingress net device is NULL, return gracefully
from the API to check if the skb is from rmnet

Change-Id: I81b8cea7f311fe581e83f2310155b83b28f2fd32
CRs-Fixed: 3445050
2023-04-01 17:12:46 -07:00
Aasir Rasheed
ca023bedc9 qcacmn: Register MLO get link state event handlers
Register and unregister the MLO get link state WMI event handler.

Change-Id: I7ac0a20949cc435907e433c279f14fd792415824
CRs-Fixed: 3432102
2023-04-01 09:15:27 -07:00
Aasir Rasheed
7962020d77 qcacmn: Add WMI params for MLO link state query
New TLVs for MLO link state information is introduced for
get link info command. Add WMI changes to add these TLV in
get link info command

Change-Id: Ib8d12a727ac6f59257dcce69174271330a065c77
CRs-Fixed: 3431076
2023-04-01 09:15:04 -07:00
Aasir Rasheed
8aa9879aa0 qcacmn: Add QCA vendor commands to set and get MLO links state information
Add a new vendor command and attributes to control and fetch the state
information of the MLO links affiliated with a specific interface.

This will enable user space to dynamically control the MLO links states
based on the latency, throughput and power save requirements.

Change-Id: I1ef710a6f3a1f8723bb3d1c564c0c803bfa0b587
CRs-Fixed: 3416250
2023-04-01 09:14:47 -07:00
Namita Nair
86e2e95fc5 qcacmn: Fix function name for opt_wifi_dp_cleanup
Fix the function name dp_ipa_opt_wifi_dp_cleanup()
for IPA_OPT_WIFI_DP not defined case.

Change-Id: Ie8d7db76add281025fd654d8a3e0017eddd6fbc4
CRs-Fixed: 3446301
2023-04-01 01:20:12 -07:00
Namita Nair
42381bb34d qcacmn: Handle RTPM counter for opt wifi dp
Inorder to keep the PCIe link up during
optional wifi dp transfer the
hif_force_wake_request() is called during
filter addition. This increments the rtpm_get counter.
Now if Wifi is disconnected before releasing the
filters, the corresponding hif_force_wake_release()
call is not made. This causes a mismatch in RTPM GET and
PUT calls and triggers an assert during hdd_wlan_stop_modules().
This change adds a cleanup call to release the force wake
and reduce the rtpm_put counter to prevent the assert.

Change-Id: Idd778275a015922376cf7eb0a7c3d92e75881fe8
CRs-Fixed: 3441186
2023-04-01 01:20:02 -07:00
Pavankumar Nandeshwar
2bea262d35 qcacmn: Change MSI configs for lower MSI line groups
ppe2tcl and Umac reset interrupts need dedicated irq lines.
Hence, group some of the existing dp groups togeather
to share MSI lines to make space for ppe2tcl and Umac reset
dedicated irqs.

Change-Id: I5181caeaeb4d0107b62e7ac812c2f829fd8215a2
CRs-Fixed: 3423553
2023-03-31 13:02:41 -07:00
Yu Wang
c46d796117 qcacmn: trigger panic if completing tasks takes too long
Trigger panic if it takes too long in completing
the tasks. And also modify the maximum retry count
if PANIC_ON_BUG is enabled to avoid false alarms.
It makes debug easier for tasklet stuck and schedule
latency related issues.

Change-Id: I521661c656d227ffb3f4c87ecd56bbfa938c9c25
CRs-Fixed: 3441248
2023-03-31 11:03:54 -07:00
Prakash Manjunathappa
543f94ced2 qcacmn: Do not subscribe for MC/BC frames
MC/BC frames are routed to FW ring based on routing config for MC/BC
data as SRC: FW2RXDMA and DST: RXDMA2DFW.
Data offload features in FW will take care of routing the MC/BC frames
to FW in both active and low power modes.

Change-Id: I09395978f890d9a23564bef4f974971f6de175df
CRs-Fixed: 3427204
2023-03-31 06:07:24 -07:00
Harsh Kumar Bijlani
9346230d59 qcacmn: Skip self peer for rdk stats flush on user request
Skip self peer for rdk stats flush when user makes a request for flush.

Change-Id: I2a25a798bbf1ec25aed4c4b2a7782b8d4b439a46
CRs-Fixed: 3444096
2023-03-31 06:07:09 -07:00
Jeevan Kukkalli
785b786014 qcacmn: Reduce log level to avoid console flooding
Reduce log level to debug from error to avoid console flooding
when low mem condition is hit.

Change-Id: I0341beed9059c4db2eba2cc481a797d67dd35b25
CRs-Fixed: 3442503
2023-03-31 06:06:54 -07:00
Harsh Kumar Bijlani
caa9b49954 qcacmn: Consider 4 address repeaters also for vdev stats
Consider 4 address repeaters also for vdev stats when operating in
WDS Extended mode.

Change-Id: I91d9bbeb2b917154da730b22b46645e76fa55c6f
CRs-Fixed: 3437803
2023-03-31 06:06:38 -07:00
Uraj Sasan
ab8cf64ef0 qcacmn: Connect if pri_umac & assoc link are same
Some devices in WDS station mode have limitation when connected
in 3 LINK MLD association where the Primary umac selected and assoc
link should be same. Make sure to have a sanity check before
going for association in such cases.

If the primary umac and assoc links are set to be different then
the connection will be rejected.

Change-Id: If56461a140d4685ba279b1babe04709d919d1650
CRs-Fixed: 3443733
2023-03-30 23:15:34 -07:00
Parikshit Gune
1598a12f5c qcacmn: Add RX stats support for Direct switch
Add support to send RX stats when Direct switch is
enabled. For WDS extended mode get the stats from
peer object, else take it from vdev object. These will
be accumulated by PPEDS module

Change-Id: I1f73c50679c416536cfc1ebaaeaec9b307e8bf56
CRs-Fixed: 3421251
2023-03-30 21:45:28 -07:00
Hariharan Ramanathan
543c9847e4 qcacmn: Change to store peer_id locally and use
Get peer_id from peer structure to a local variable and pass to hal api
in order to avoid race condition between peer delete and peer unmap.

Change-Id: Ib6a89f1defcfc8f66c1146a330a373a760520aa7
CRs-Fixed: 3444998
2023-03-30 18:30:39 -07:00
Krunalsinh Padhar
6f685b0907 qcacmn: send assoc resp only once for multilink
Do not send assoc response from wlan_mlo_peer_create for
multilink MLO connection. This makes sure that assoc resp
is invoked only once.

Change-Id: Id1acf20bd5e3e3beb16e0dc3073676c421825ae6
CRs-Fixed: 3443511
2023-03-30 18:30:29 -07:00
Mohammed Ahmed
b89db375d1 qcacmn: add hif_ce_desc_history to ssr driver dump
Current code doesn't have hif_ce_desc_history in ssr driver dump.
Fix this by adding the two data structs: hif_ce_desc_history_buff
and hif_ce_desc_history to the ssr driver dump regions.

Change-Id: I9256d94db6c3c3a3588e5729b9181efabdaf18ea
CRs-Fixed: 3443230
2023-03-30 14:44:40 -07:00
Paul Zhang
310c7ce085 qcacmn: Add enums for TDLS for MLO feature
1\ Add QDF_STATUS_TDLS_MLO_SYNC,
2\ Add WLAN_ELEMID_LINK_IDENTIFIER.

Change-Id: I58e912dc46a48b9ba7c2d411a2ccd7e107df1b22
CRs-Fixed: 3435983
2023-03-30 14:44:29 -07:00
Shreedhar Parande
3bdf816735 qcacmn: Add VDEV up check before deriving bridge peer PSOC
If VDEV state is not up, skip such VDEVs for creating
bridge peer.

CRs-Fixed: 3439647
Change-Id: Ibd5eaff197ed0ce984915fc197bcd33b6e674e37
2023-03-30 10:44:02 -07:00
Namita Nair
4e3bb0b849 qcacmn: Fix 2nd filter is null in opt wifi dp
Currently if IPA wants to add 2 filters and
send the filter params in 2 separate add
requests, HOST does not handle this correctly.
This causes the second filter params to be 0.
This change updates the correct index to be accessed.

Change-Id: Ib0a4853d46585d9529e990177fb8da20382c2fdb
CRs-Fixed: 3441196
2023-03-30 09:01:34 -07:00
Rahul Gusain
4e7ff1e143 qcacmn: fetch roam vdev from pdev obj
Driver extracts the vdev from peer, self mac address and
vdev_id. But in some APIs, there can be below scenarios
For example:
1. peer is not available for that vdev( roam vdev),
2. API does not have vdev_id,
3. mac address is not known or incorrect,
4. there is no session available.
While roaming, there can be scenario where driver need to
fetch the vdev before peer creation and session is not
available.
For this, driver introduces new API to fetch roam vdev from
pdev object.

Change-Id: I4a2521773b893a8dc0553335bcadac5a84fbc300
CRs-Fixed: 3441493
2023-03-30 09:01:23 -07:00
Nandha Kishore Easwaran
109969b938 qcacmn: Add pci slot to legacy irq names
Add pci slot to legacy irq names so that it is easy to
analyze the interrupts.

Change-Id: I0c11c3399c0b9f1d6d4136d158e5ab4a571f4f52
CRs-Fixed: 3438542
2023-03-30 09:01:12 -07:00
Tallapragada Kalyan
e4798ea69b qcacmn: optimization changes to improve RX KPI for WIN
done the following changes to improve the RX path KPI
	1. remove the extra invalidate in RX path as
	we no longer dirty the RX TLV cache lines.
	we now store the rx error codes in nbuf cb instead
	of RX TLVs reserved memory bytes.

	2. with features like flow tag and wds extended mode
	enabled by default, the rx_fast_flag is always set
       	to false, this resulted	in lot more instructions
       	being executed in RX path.
	Now we ensured this flag is at least set for other
	features which are not enabled by default.

Change-Id: I04c6bdc52a2b3f1248b822a108d8bd1a70abcc7c
CRs-Fixed: 3406505
2023-03-30 02:32:40 -07:00
Shiva Krishna Pittala
45da3822ae qcacmn: Fix use-after-free of MGMT Rx params in wlan_mgmt_rx_reo_algo_entry
Once an incoming MGMT frame is inserted in the MGMT Rx REO egress list from
wlan_mgmt_rx_reo_algo_entry(), there is always a possibility that the same
frame could be sent to upper layers from the other CPUs before
wlan_mgmt_rx_reo_algo_entry() completes its execution in the original
MGMT Rx path. This means that nbuf and MGMT Rx params of a given frame
could be freed before wlan_mgmt_rx_reo_algo_entry() completes.
Hence, make sure to not access frame's nbuf and MGMT Rx params once the
list updates are done for that frame.

Change-Id: I91cbdef4b1ea5b81d39606e47a46021f30193ce5
CRs-Fixed: 3433621
2023-03-30 02:32:30 -07:00
Santosh Anbu
a9419151d6 qcacmn: Support MAC filtering for York platform
Add change to support MAC based filtering for York platform.

Change-Id: I4815c53f3d4babd11f3ebae95175d0ba0871aafe
CRs-Fixed: 3442299
2023-03-30 02:32:20 -07:00
Adwait Nayak
c2c736472a qcacmn: Subscribe RX PPDU START USER INFO TLV for pktlog modes
As of now, RX PPDU START USER INFO TLV is not subscribed as
part of pktlog. Since enable_ol_stats is set by default and
it subscribes RX PPDU START USER INFO TLV, we can see
RX PPDU START USER INFO TLV being available as part of pktlog
data. But recently, with all the automation testing scripts
it is decided to set enable_ol_stats to 0, hence subscription
of RX PPDU START USER INFO TLV is taken care during the filter
set up for all the pktlog modes.

Change-Id: Ib8c7e668a17fcb8e791784d29ef6f00fbdd2df34
CRs-Fixed: 3440721
2023-03-29 11:30:04 -07:00