Commit Graph

20387 Commits

Author SHA1 Message Date
Surabhi Vishnoi
2e17c21b55 qcacmn: Enable CFG80211_SINGLE_NETDEV_MULTI_LINK_SUPPORT for kernel-6.6
Currently, CFG80211_SINGLE_NETDEV_MULTI_LINK_SUPPORT is enabled based on
__ANDROID_COMMON_KERNEL__ and kernel version greater than equal to 5.15.

Enable it for above condition or if kernel version is greater than or
equal to 6.6.

Change-Id: I12ae6bf116e37999c935012485651bfadf8b9b2a
CRs-Fixed: 3681611
2024-01-12 11:44:00 -08:00
Surabhi Vishnoi
1446cc3832 qcacmn: Fix mismatched format compilation error
Fix compilation error due to mismatched format type in log.

Change-Id: I9cb80f38ada13f623240fa1e5f3a53a632dac78d
CRs-Fixed: 3678442
2024-01-12 11:43:49 -08:00
Vinod Kumar Pirla
95b011605e qcacmn: Enhance allowed security modes for EHT via OEM cfg
Certain APs available to end users may allow EHT/MLO config
in non-WPA3 security modes (like WPA2). Current implementation
will not allow connection to such APs in EHT/MLO and instead
downgrades to 11ax mode.

OEMs may want to control this driver behavior via INI based
on the requirement. To allow connecting to such APs in EHT/MLO
a new INI is introduced as a bitmap. The default value of this
INI will not allow connection to any of those APs in EHT/MLO.

Change-Id: I3e657f3f4ba1f5efc9263cb90bcd1773233975ac
CRs-Fixed: 3693813
2024-01-11 13:09:30 -08:00
Vinod Kumar Pirla
c739c3b6cd qcacmn: Only allow partner links with matching RSN caps
Each link in MLO can have different RSN capabilities with
different AKMs, PMF capability, UC/MC cipher suites and so on.
For any choice of links for MLO connection, the AKMs of the
links should have one common AKM.

Eliminate partner links without overlapping AKMs from MLO
connection.
Modify partner link AKM to match assoc link AKM, so that
only overlapping AKM is chosen even though an AKM with
higher security exists for partner link.

Change-Id: I9573e938789a4b95ae824872845d31008861f6f2
CRs-Fixed: 3693814
2024-01-11 13:09:19 -08:00
Vinod Kumar Pirla
01e1c46c4e qcacmn: Generate ML prb rsp from assoc rsp
For non-TxMBSSID ML AP ML probe req may not receive any response
from MBSSID AP and later partner link may fail to connect as
scan entry is not present.
Introduce new flag to suggest whether the partner link scan entry
is present or not in the scan DB. If flag is set to true, generate
scan entry for such links.

Introduce new APIs which will generate ML probe resp using
the per-STA profile of partner link from assoc resp frame.

Introduce API to get the current candidate scan entry from
connect request.

Change-Id: I1c33956b01eb468afa26be5b0bfba634ee3a0aee
CRs-Fixed: 3675830
2024-01-10 09:54:22 -08:00
Karthik Kantamneni
29002e8730 qcacmn: Handle ipa_init when opt_ipa_wifi is not supported
Handle ipa_init when opt_ipa_wifi capability is not supported
by IPA subsystem.

Change-Id: I6a120589b4ba6b60a1c15420c545f4768cff047b
CRs-Fixed: 3695354
2024-01-10 04:43:19 -08:00
Abhinav Kumar
abcf99cc9c qcacmn: Update EHT cap IE as per current country code
On set country code, host updates EHT cap IE to FW via
WMI_VDEV_SET_IE_CMDID command. 320 MHz BW capability in
EHT cap IE should be as per new country code.

Change-Id: I3b80dbeee6f35dacc41f15612373ea7f8efc5803
CRs-Fixed: 3670311
2024-01-09 16:49:45 -08:00
Vinod Kumar Myadam
f8a9ddcbd5 qcacmn: Rate limit excessive logging while getting descriptor
Excessive logging in wlan_mgmt_txrx_desc_get if descritor is
not found.

Rate limit excessive logging in error log.

Change-Id: I929c5cca5dea94db4b618f0390d76a6ca83159a9
CRs-Fixed: 3696162
2024-01-09 02:57:43 -08:00
Aasir Rasheed
6a00a21f34 qcacmn: Use QDF_MAC_ADDR_FMT to print mac address
This change is to use QDF_MAC_ADDR_FMT to print mac address.

Change-Id: I2bd9beed55f8687356ba3b8a774cff32dbf61200
CRs-Fixed: 3676087
2024-01-08 23:32:49 -08:00
Srinivas Dasari
0c96c2267d qcacmn: Restore RSO state to upon link switch failure
RSO is stopped upon receiving link switch request to avoid the
race between link switch and roaming. RSO is enabled again once
link switch operation is successfully completed, i.e. upon connect
complete of the new link.
But link switch may fail due to multiple reasons (e.g. scan
result/partner info is not available for link switch) and the
connection is retained with single link as the other link is
already cleaned up as part of link switch request processing.
RSO is not enabled in such failure cases and thus firmware
doesn't roam even it finds a better candidate.
Restore RSO state to ENABLED upon link switch failure.
Also, cleanup the failed link bit in wlan_connected_links upon
link switch failure.

Change-Id: Ieefd7bf9615c80e7ab6ecdbee5c99d6e52857cc6
CRs-Fixed: 3681892
2024-01-08 04:49:06 -08:00
Karthik Kantamneni
743218686f qcacmn: Fix uninitialized mon status desc pool lock issue
Currently Mon status ring resources allocation and cleanup
is not in sync, during cleanup we are freeing more than allocated
for single MAC solutions like QCA6750.

Fix this by cleaning mon status ring resources properly for single
mac QCA6750.

Change-Id: I8c8564d106fda29f7a6a36f887aa3adee9dc1edf
CRs-Fixed: 3693448
2024-01-08 01:33:28 -08:00
Vinod Kumar Pirla
da11474ac2 qcacmn: Add MLD addr filter in link VDEV candidate selection
Wireless environment may have APs with same BSSID but different
MLD address and if any APs BSSID is similar to the current
candidates affiliated partner link BSSID, then receiving beacon
or probe resp from such APs will override the affiliated link's
scan entry and the MLD address may be different or NULL if the
AP is non-ML.

If link VDEV connection starts and during candidate selection
it may find the scan entry of this other AP and attempt to drive
connection will lead to creating ML link VDEV's peer with
different MLD address than assoc VDEV's peer.

Enhance scan filter to match MLD address for link VDEV to avoid
such scan entry override.

Change-Id: I11c9b4efdf2d60e92482b296d731d613a200bf0e
CRs-Fixed: 3668326
2024-01-04 02:53:14 -08:00
jinbao liu
b80337cee1 qcacmn: Refine htc_tx_completion_handler() log to avoid flooding
This change refines the log in htc_tx_completion_handler()
to avoid flooding by using qdf_rl_err().

Change-Id: If24f29cab89098a5e33f79aaa2cf43704b957d0f
CRs-Fixed: 3694797
2024-01-04 02:53:02 -08:00
Pragaspathi Thilagaraj
7ddc1542ad qcacmn: Don't send replay counter value for all FT AKMs
In roam_auth vendor event sent to userspace after roaming, the
QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_KEY_REPLAY_CTR attribute should
not be filled for any of the FT AKMs.
But currently its filled for below FT AKMs:
WLAN_CRYPTO_KEY_MGMT_FT_PSK
WLAN_CRYPTO_KEY_MGMT_FT_FILS_SHA256
WLAN_CRYPTO_KEY_MGMT_FT_FILS_SHA384
WLAN_CRYPTO_KEY_MGMT_FT_PSK_SHA384

This causes the GTK M1 frame received at the supplicant
to be dropped since EAPOL Key replay counter didn't increase
for PSK connection.
So disconnection occurs due to GTK handshake failure.

So don't fill the key replay counter attribute for all the
FT AKMs.

CRs-Fixed: 3674872
Change-Id: I34f88a8c8e8259a701b553284d492fe31597bea3
2024-01-02 16:36:42 -08:00
Vijay Raj
f57a86b4b9 qcacmn: Fix Connecting log to print during connect failure
For the NO Candidate scenario, the connecting event is
not logged resulting in breaking the connectivity logging
mechanism sanity.

Add support to log CONNECTING connectivity log during
NO CANDIDATE found scenario in order to maintain the
logging mechanism sanity.

Change-Id: I534307802d28365ffea330e85b710074ab863c09
CRs-Fixed: 3678114
2023-12-29 07:03:09 -08:00
Jianmin Zhu
476e23f5cb qcacmn: Add service bit for p2p device update mac addr
Add service bit for p2p device update mac addr dynamically.

Change-Id: Ib957aa606c640e6b94db580e33a4454e90da2f49
CRs-Fixed: 3687270
2023-12-28 13:01:22 -08:00
Arun Kumar Khandavalli
a6fb445d02 qcacmn: Restrict max tbtt info length to current max supported length
Currently if the TBTT length is more than max supported length
driver doesn't the mld information from the RNR IE. This leads
to SLO rather than MLO.

Add the fix to restrict the max length to current supported max
length which helps to parse the ML information further
results in ML association.

CRs-Fixed: 3679296
Change-Id: Id8c58044be162f638ed5e74e0fd04aa0b77780f5
2023-12-28 13:01:10 -08:00
Yu Tian
803410c7fc qcacmn: Avoid using smp_processor_id when preemptible
Use qdf_get_cpu() as it takes care for disabling preemption.

Change-Id: I5ddbfd6f75b1659a193238858056937df36db86d
CRs-Fixed: 3691399
2023-12-27 11:42:07 -08:00
Yu Wang
dbaed14ee7 qcacmn: optimize code for register read/write
Optimize code for checking flag which indicates srngs initialization
during register read/write.

Change-Id: I6e3d2446b1df7214aaa90483046524c7cc01533f
CRs-Fixed: 3670754
2023-12-26 22:10:35 -08:00
Liangwei Dong
a62d430c2e qcacmn: Add QCA vendor command to query transmit power information
Add a new QCA subcommand QCA_NL80211_VENDOR_SUBCMD_REGULATORY_TPC_INFO
and related attributes qca_wlan_vendor_attr_tpc_links,
qca_wlan_vendor_attr_tpc definition to query transmit power information
on STA interface from the driver for a connected AP.

The information includes regulatory max transmit power limit, AP local
power constraint advertised from AP's Beacon and Probe Response frames.
For PSD power mode, the information includes PSD power levels for each
subchannel of operating bandwidth. The information is driver calculated
power limits based on current regulatory domain, AP local power
constraint and other IEs. The information will be set to target. Target
will decide final TX power based on this and chip specific power
conformance test limits (CTL), and SAR limits.

Change-Id: I196640cdd9e6454b040abb80b23d380c517ac118
CRs-Fixed: 3688242
2023-12-25 16:57:40 -08:00
Vinod Kumar Pirla
f26efecdf9 qcacmn: Add VSIE matching with select action OUI filter
In order to identify certain vendor APs, it generated
AP beacon from MBSSID nonTx profile shall include these
Vendor Specific IEs (VSIEs).
If any matching VSIE of interest is present, copy the
IE to generated frame.

Change-Id: Ic3566ad0123c7353d7ace1b0077d6a3730d10dc8
CRs-Fixed: 3682937
2023-12-21 04:35:11 -08:00
Asutosh Mohapatra
f4b53caa2a qcacmn: Handle ho failure for STA + STA roaming
Currently for STA + STA case, consider the below scenario:
1. Roam start received on vdev 2 & vdev 0. Vdev 2 roam
   serialization command becomes active and vdev 0 roam
   command is on the pending queue.
2. HO failure with AP0 received on vdev 2. This dequeues
   the vdev2 roam serialization command. Vdev0 roam command
   becomes active.
3. Roam synch indication received on vdev0 with peer AP as
   AP0 (which is the peer on vdev 2). So duplicate detection
   logic prevents same peer creation, so roam synch fails but
   its not indicated properly to firmware. This leads to
   disconnection of both the STAs.

To address the issue, first enqueue disconnect with high
priority set before removing roam command from serialization
so disconnect gets activated if roam was active for the
vdev.
Also while processing roam synch indication, check if peer is
found on different STA and send roam stop to fw so fw also
cleans up and initiates HO failure.

Change-Id: I379c03138b70580f44c2b96489ada030ec6fc20e
CRs-Fixed: 3686660
2023-12-21 02:23:02 -08:00
jinbao liu
cf8f844d0c qcacmn: Fix an array index out of bounds issue
Sometimes when the stats of MLD_PEER is requested, Access
Violation may occur because peer_stats[1], which does not
exit, may be accessed. This change fixes this issue by
aggregating the stats of all link_peer into peer_stats[0].

Change-Id: Ib8138d4b95bef39b084756dd9f9ffae67967100a
CRs-Fixed: 3678284
2023-12-20 18:30:54 -08:00
Yu Tian
efc1a90bed qcacmn: Add handler for REO HW queue map failure
When REO HW queue DMA maps failure, there is no
log output. Change will give more retires for such
map failure and output error log at last.

Change-Id: I11d6439b74fd4423441f3e0ce0ce18a4ee762e4b
CRs-Fixed: 3671197
2023-12-20 12:40:18 -08:00
Vinod Kumar Pirla
c3051ec402 qcacmn: Combine MLO VDEV and MLO LINK VDEV flags
If MLO link VDEV flag is set but MLO VDEV flag is not set
the APIs only checking for MLO link VDEV will assume VDEV
as ML but the APIs checking MLO VDEV will assume VDEV as
non-ML, this is not valid.

As per definition of MLO VDEV and MLO link VDEV:
 -If any VDEV is MLO link VDEV then it has to be MLO VDEV.
 -If any VDEV is not MLO VDEV then it shall not be MLO link VDEV.

Change contains following:
 -On clearing MLO VDEV flag, clear MLO link VDEV flag.
 -On setting MLO link VDEV flag, set MLO VDEV flag if not
  already set.

Change-Id: I8efeaa1cb75b37e5f7f2cc5c16067df677000c45
CRs-Fixed: 3657212
2023-12-15 01:57:45 -08:00
Vinod Kumar Pirla
4bf1baaed2 qcacmn: Include PID in SM history
Add PID name where SM events and transition
happened to help debug issues where the info
about which task started a certain event to
happen are crucial to rootcause the problem.

Change-Id: I208b46c6d0ec725ab0d9713bf2dd562c40719a24
CRs-Fixed: 3624811
2023-12-15 01:57:33 -08:00
Asutosh Mohapatra
56e6df6383 qcacmn: Send additional interface combinations to fw
As part of set feature set command, update STA_P2P,
STA_SAP, STA_NAN, STA_TDLS, STA_SAP_P2P, STA_SAP_NAN,
STA_P2P_NAN, STA_P2P_TDLS, STA_SAP_TDLS, STA_NAN_TDLS,
STA_SAP_P2P_TDLS, STA_SAP_NAN_TDLS, STA_P2P_P2P_TDLS,
STA_P2P_NAN_TDLS iface combinations to fw.

Change-Id: I360ee80778ce4a7a89341374ab3e861890507ef2
CRs-Fixed: 3674698
2023-12-14 09:10:54 -08:00
Vinod Kumar Pirla
b0ca707783 qcacmn: Set link switch conf inline with link switch connect
Successful link switch connect implies that the VDEV-Link mapping
changed in driver and FW expects success notification in link switch
confirmation after which FW updates internal fields to reflect this
VDEV-Link mapping same as in driver.
If driver receives SB disconnect while link switch is in progress,
it defers the SB disconnect and moves link switch to abort state.
As current state is in abort, host will forcefully sends failure
status to FW in link switch confirmation and immediately starts SB
disconnect and sends VDEV_STOP to FW. As link switch status is
failure, VDEV-Link mapping is not updated in FW and FW might send
another link switch request with params corresponding to previous
VDEV-Link mapping and leads to Host-FW out of sync issue.

If the status of link switch connect is success, then force link
switch confirmation status to success so that FW can update new
VDEV-Link mapping.

Change-Id: Iaa9836f9089a2f8fcbf4d49e3c598f9a01aa8d06
CRs-Fixed: 3665211
2023-12-14 07:01:59 -08:00
Manikanta Pubbisetty
4015f3bf89 qcacmn: Do not setup CE write index offset for FW only CE rings
Currently for WCN6450, driver is updating the CE write index offset
used for CE register updates even for the CE rings that are firmware
only rings. This is resulting in a boot time WARN_ON.

Do not setup write index offset for CE rings that are used only by
the target firmware to avoid this early on boot time WARN_ON.

Change-Id: I241e11ad43f833b5cafc7cd303b935c10d9e6dd8
CRs-Fixed: 3670952
2023-12-12 06:35:19 -08:00
Yu Tian
2a709c7cec qcacmn: Add parameter to support drain RX rings only
Add a parameter to support drain RX related rings only.

Change-Id: Id30e92646698bd6b409468c98934a1716763d1e3
CRs-Fixed: 3675835
2023-12-11 00:04:31 -08:00
jinbao liu
b4f2073ac3 qcacmn: Optimize rx reorder queue setup
This change optimizes rx reorder queue setup by using
tid_bitmap, which contains a group of tids, to set up
multi tids at a time instead of one tid after another.

Change-Id: I161b0c812c436ef79d2d1db693b8d0ac41505878
CRs-Fixed: 3661593
2023-12-08 15:22:17 -08:00
Jianmin Zhu
7555136c16 qcacmn: Avoid assert for race condition issue
If wmi_update_stats_event_id handler is unregistered between
wmi_unified_get_event_handler_ix and wmi_handle->event_handler
called in __wmi_control_rx for race condition issue, assert will
happen for invalid event_handler.

To avoid it, validate wmi_handle->event_handler when call it.

Change-Id: Ibcb0c076c3d5f80f506f3338dd0c5ee313e5a9b7
CRs-Fixed: 3667177
2023-12-07 22:38:58 -08:00
jinbao liu
7f2e70fcec qcacmn: Add wmi APIs for multi rx reorder queue setup
Add wmi APIs for multi rx reorder queue setup to save setup time.

Change-Id: I5a4c89b88b4ba076d1883edc44b075fbceca27eb
CRs-Fixed: 3659035
2023-12-07 22:38:47 -08:00
Will Huang
6dc43655d9 qcacmn: Replace correct pointer to check NULL
To fix coding error which find by static analysis.

Change-Id: I46017721945aef60def49a8e90ffb2da1dfaf5e6
CRs-Fixed: 3642679
2023-12-07 14:50:23 -08:00
Chunquan Luo
6a767ada83 qcacmn: Optimize scan when P2P-GC connect
Cancel scan when P2P scan with BSSID and found BSSID.
Send flag to fw by WMI_SCAN_FLAG_EXT_P2P_REDUCE_TIME_SCAN.

Change the scan flag value align with fw change of:
I4760f4515c07f575df523d7e387c07113b277a6b

Change-Id: I6af3c5ae1027af36e0494f1eaceb7cb5aebec494
CRs-Fixed: 3659688
2023-12-06 10:55:27 -08:00
Venkateswara Naralasetty
958e0db9af qcacmn: fix out-of-bound issue in scattered list setup
Fix out-of-bound issue in scattered list setup.

Change-Id: I8a0c419227de3613d70229e1b6364d7e46dfbf7b
CRs-Fixed: 3664082
(cherry picked from commit 754a729a834a4a1661afaf38ca19be3161fcfd6f)
2023-12-06 06:58:03 -08:00
Will Huang
b55e7ac81f qcacmn: Add support of sending multiple COEX config
Add an API to support sending multiple COEX config in one WMI command.
This is to optimize and save target host to firmware WMI command
communication time.

Change-Id: Ie510ee3ebfca67a2b748c403ec52a8d7b597f676
CRs-Fixed: 3651226
2023-12-05 02:18:28 -08:00
Aasir Rasheed
98efc27f87 qcacmn: Reject add key when peer address is NULL
This is a valid scenario in case of WEP, where-in the
keys are passed by the user space during the connect
request but since we did not connect yet, so we do not know
the peer address yet.

Change-Id: I2284d778d4813c1fae81db6db4257ef965730ebc
CRs-Fixed: 3668405
2023-12-02 08:16:57 -08:00
Aasir Rasheed
c062f5394b qcacmn: Implement crypto locking mechanism
Implement a locking mechanism for retrieving and
storing crypto keys. Currently, due to race condition,
Host driver is fetching information in one thread while
simultaneously writing key information in another thread,
resulting in synchronization issues.

This change is to add lock mechanism while reading and writing
crypto keys.

Change-Id: I156b619cf7c3c052ad3122a6f808d732fb5e4f51
CRs-Fixed: 3669552
2023-12-02 08:16:46 -08:00
Aasir Rasheed
3327d001de qcacmn: Increase priority for the 6 GHz + 2 GHz combination
Increase priority for the 6 GHz + 2 GHz combination,
even when 5 GHz + 6 GHz MLSR is enabled.

This modification aims to emphasize frequency prioritization for
frequency not on same mac.

Change-Id: I159c673b8f1d772e2f557df9e9811292a65a4bb6
CRs-Fixed: 3672983
2023-12-02 08:16:15 -08:00
Liangwei Dong
9dc8b77e85 qcacmn: Add set link source data structure
Add new data structure to save the external/internal set link
request. The different source of request has different priority.
In some situations, a certain request may not be honored if
it conflicts with higher priority request.

Change-Id: Ia0bce7b50436e4e2b52d2c4948c7aa8a3a7a0a97
CRs-Fixed: 3654159
2023-12-01 02:35:57 -08:00
Srinivas Dasari
cc617c7e50 qcacmn: Reject link switch if chan_switch is in progress on current MLD
Currently, firmware doesn't send CSA event to host when there is
a link_switch request is given to host. Similarly, it doesn't
send link_switch if CSA is in progress.
Host driver can also initiate channel switch operation when
it detects a change in the Operation IEs(HT_INFO/VHT_OP/HE_OP/
EHT_OP, etc..) from beacon/probe rsp. When link switch is
started by firmware and if host also triggers VDEV_RESTART
due to a change in the beacon at the same time, VDEV_RESTART
timeout happens as vdev lock is held by link switch module
in firmware.
So, host driver can't allow link switch when such VDEV_RESTART
is in progress.

Add an MLD level check when CSA/chan_switch is started and reject
link switch request if it's set.

Change-Id: If5b7fbcbf214684c28d0129546376220a147bce9
CRs-Fixed: 3655049
2023-12-01 02:35:18 -08:00
Manikanta Pubbisetty
4bafb26a4c qcacmn: Fix batch interrupt threshold logic for WCN6450
Unlike lithium family, batch interrupt thresholds for Rhine targets
are not based on the entry size (descriptor size in dwords); Instead
the configuration should be a simple integer value. If interrupt has
to be raised after every copy transaction then batch counter threshold
shall be set to 1, so on and so forth.

Change-Id: Ic51f361c5f079d48668ec9b46dd79f04bcb43b14
CRs-Fixed: 3659426
2023-11-29 08:08:18 -08:00
Aasir Rasheed
eef8ab17ed qcacmn: Add check to enable/disable MLSR
Enable/disable 5GL+5GH MLSR by retrieving mlo_5gl_5gh_mlsr cfg
attribute.

Change-Id: I9250cdc09e462b74db93ae733f1b334e71696aea
CRs-Fixed: 3662649
2023-11-28 04:08:45 -08:00
Srinivas Dasari
91f4b92931 qcacmn: Add debug logs at WMI layer to dump the mcast filters
Currently, mcast filter mac addresses are logged at PM layer
as part of filter preparation, but it's difficult to understand
which mac address are sent to firmware.
Add logs for the same at WMI layer to dump the final mcast
filters.

Change-Id: I43c8b0e1107129a0070f141eb3edda75349d5233
CRs-Fixed: 3669791
2023-11-28 04:08:34 -08:00
Rakesh Pillai
d149d2a2e8 qcacmn: Do not unmap buffer if MSDU done is not set
Currently if the msdu_done bit is not set in the
rx_pkt_tlvs, the buffer is unmapped and freed.
There was an issue seen where hardware accessed a
buffer address, which probably was delivered to driver
without DMA of data to the buffer (thereby unmapped
and freed before hw attempted second access). This
results in unwanted recovery.

Based on the above hypothesis, add a workaround
to skip the unmap-and-free of any buffer for which
the msdu_done bit was not set in the rx_pkt_tlv.
Also mark the corresponding rx_desc as in_err_state.

The rx_desc corresponding to such aforementioned
msdu_done failure msdus are stored in a rolling
list, where the old entry is force unmapped & freed
when a new entry needs to be added. This force
unmap-and-free of the oldest buffer gives an uncertain
amount of delay between it being reaped from rx ring and
actual unmap-and-free.

Change-Id: Ibf8f3c886118d532af818466cb46218d88146271
CRs-Fixed: 3667674
2023-11-28 04:08:22 -08:00
Asutosh Mohapatra
3ed7625c2a qcacmn: Check wmi service ext2 bit set with caution
Currently while checking for wmi service bit,  if
service bit is part of service ext2, host is not
validating if service bit index is valid or not,
and returns incorrect value.

For example, if host is checking for
WMI_SERVICE_PDEV_PARAM_IN_UTF_WMI and
num_wmi_service_ext_bitmap value is 4 then this service
bit can't be set, but seeing this value is set.

To address this issue if service ext2 bit
index is valid or not.

Change-Id: Ie4c766219e3793b46fa88dddb9544786142b92ef
CRs-Fixed: 3662190
2023-11-28 00:43:48 -08:00
Rakesh Pillai
5ffa24be87 qcacmn: Record msdu done fail buffers history
Record history of all the buffers where msdu_done
bit was not set.

Change-Id: Ibfe985cc8ecfed57eae2db26ef337c95ca4233c8
CRs-Fixed: 3662200
2023-11-27 08:55:05 -08:00
Rakesh Pillai
f7d4e2a300 qcacmn: Do not re-init rx_tid for non-first link peer
As per the current design, the rx_tids are shared across
all the link peers belonging to the same MLD. The rx_tids
are allocated and referenced from txrx_peer, which is common
for all the link peers.

But during the peer_setup, which happens during the initial
connection or during link switch, these rx_tids are being
initialized(or reinitialized) every time for each link peer.

This leads to a situation where:
1) The rx_tids may get re-initialized during the 2nd/3rd/subsequent
link peer setup, even after the BA session has been established via
the first link, thereby setting incorrect BA window size and other
BA parameters for all the non-first link peers. Even the BA session
status will be reset, which can lead to issues for fragmented packets
aggregation.

2) After link switch, when the new link peer is setup, it will be
setup with a default BA window size of 1, when the actual BA window
size has already been established earlier, thereby indicating
an incorrect BA window size for the switched-in link peer.

In order to mitigate the above mentioned issues, the full setup
of tids will only be done for first link peer. For all subsequent
link peers, only the re-order queue setup (wmi notification to fw)
will be done. Also, during the re-order queue setup for all the
non-first link peers, the BA window size will be updated from the
rx_tids in txrx_peer (if the BA session is active).

Change-Id: Ia3f7516ba6efd1014648ead1730712834f450c42
CRs-Fixed: 3657693
2023-11-27 00:31:55 -08:00
Asutosh Mohapatra
610a66531e qcacmn: Set AP power type after saving reg rules in pdev
Issue 1:
With this change - I1bdfd71245552a51fd5123931a7a6dcc16f2a942
host is setting AP power type before beofre saving reg
rules in pdev.

To address this issue, set AP power type after saving
reg rules in pdev.

Issue 2:
In reg_append_mas_chan_list_for_6g host is checking
the pdev_priv_obj->reg_cur_6g_ap_pwr_type before filling
6 GHz pdev current channel list. If some country supports
only LPI, and gindoor_channel_support is disabled,
the AP power type will be REG_CURRENT_MAX_AP_TYPE and host
won't fill supported 6 GHz channels in the pdev
current channel list.

To address this issue, remove the check of
reg_cur_6g_ap_pwr_type in reg_append_mas_chan_list_for_6g.

CRs-Fixed: 3663908
Change-Id: I1bdb5f24c1d7bfb3fe9755b145207a219662fc9d
2023-11-23 13:44:17 -08:00