Revīziju grafs

12949 Revīzijas

Autors SHA1 Ziņojums Datums
Venkateswara Swamy Bandaru
e914459b55 qcacmn: Move wmi assoc prints to wmi_debug
Move wmi assoc prints to wmi debug which is the case before
mlo assoc changes.

Change-Id: I8a6b84f3e85f25b3d999724eaf14d6b1c483832f
CRs-Fixed: 2951391
2021-05-27 08:08:19 -07:00
Sandeep Puligilla
45ee56c22e qcacmn: Add MLO Manager files
Add MLO manager files.

Change-Id: I059975f9e8910a510ddb7f904b1a7a7813e0981d
CRs-Fixed: 2875862
2021-05-27 08:08:15 -07:00
sheenam monga
b4602b3fea qcacmn: Add support to fetch BIG DATA fw cap
Add support to fetch fw capbality to handle
BIG data feature.

Change-Id: I3672230a26e2502164e991916404a5f6450f218e
CRs-Fixed: 2937221
2021-05-27 06:03:42 -07:00
Paul Zhang
66382eb3b6 qcacmn: ignore the default cc if cc has been set
Currently, for reg non-offload case, the cc will be
reset to default cc after disable and re-enable wifi.

To resolve this issue, following the logic about reg
offload case.

Change-Id: I5e3e00fdbef8ecadd472f09712fe093dee1b68b4
CRs-Fixed: 2907016
2021-05-27 06:03:37 -07:00
Amruta Kulkarni
6084c736c6 qcacmn: Use AES api's instead of the generic crypto api's
For Kernel version 5.4 and up use AES api's instead of
generic crypto api's referenced in qdf crypto module.

Change-Id: I92031d469d0da657dce4dcb8c603c82a1e182f1d
CRs-Fixed: 2947476
2021-05-27 06:03:32 -07:00
Vevek Venkatesan
26969d9267 qcacmn: add HI_TASKLET support for CE
Add HI_TASKLET support for CE, to improve priority
of CE tasklet higher than softirq, since CPU hogging
caused by RT thread.

Change-Id: I88fe8c048e908b9780745bb26b177acd2baf6a5c
CRs-Fixed: 2948946
2021-05-26 13:38:34 -07:00
Ashish Kumar Dhanotiya
3d451fc6a7 qcacmn: Add support to set 320 MHz channel params
Update reg_set_channel_params_for_freq function to add
support to set 320MHz channel params, for this below
mentioned changes are done:
Added a call to reg_fill_channel_list api which will fill
the 320MHz channel params.
Currently limitation of this implementation is that, this
will fill only first available channel if 320MHz band
channels are available. If list of all channels is required,
wlan_reg_fill_channel_list api should be used.

Change-Id: I1a617209a02e5bc8c07ae688bd3795fd707cac16
CRs-Fixed: 2952595
2021-05-26 09:20:58 -07:00
Ashish Kumar Dhanotiya
4bf0faa294 qcacmn: Add support to indicate nan channel support to fw
Add a new flag to indicate to fw that host will set the
nan_disable_flag for channels.

Change-Id: Ibf627bff77e1afb0849149a63981ca50476f6bfd
CRs-Fixed: 2949481
2021-05-26 09:20:54 -07:00
Priyadarshnee Srinivasan
1227b651fb qcacmn: Do not prohibit aspectral if DFS is NULL
Bring up a 5GHZ AP on HKV2 board and enable agile spectral scan
using "athssd -i wifi0 -j ath0 -a -f 5180" cmd. Agile spectral
scan fails to begin.

Agile spectral scan must not begin if RCAC is enabled as both cannot
run simultaneously. All the pdevs of the current PSOC are passed as an
input to 'target_if_is_aspectral_prohibited_by_adfs' to validate if
rcac is enabled on any of them. In case of HKV2, both 2G/5G PDEVs belong
to the same PSOC, when 2G PDEV is given as input, ucfg_dfs_get_rcac_enable
returns a failure as DFS is NULL.
Hence target_if_is_aspectral_prohibited_by_adfs returns a failure and
agile scan does not begin.

RCAC feature is only for 5GHZ channels and need not be validated for
2G PDEV. Hence do not block aspectral scan if DFS is NULL for 2G PDEV.

CRs-Fixed: 2947887
Change-Id: Icce2300f7ca2a4caf7d46cc23fe055f07f90266c
2021-05-25 16:54:14 -07:00
Aditya Sathish
13764f2b16 qcacmn: Release lock while allocating pfrm request
pfrm_request_irq() calls kmem_cache_alloc() which
needs to be called in a non-atomic context since
it can sleep.

The current call to pfrm_request_irq() is done
within a spinlock which disables preemption and
leads to sleep in an atomic context.

Avoid calling pfrm_request_irq() within atomic
context

CRs-Fixed: 2913515
Change-Id: Ic2b0a23360d4d2b753658499343f72bfb67ad82d
2021-05-21 12:12:33 -07:00
Aditya Sathish
7cd924cef5 qcacmn: Add support for EHT preamble
Add a new enum to the WMI_HOST_RATE_PREAMBLE to
support EHT rates.

CRs-Fixed: 2948129
Change-Id: I738e5d563146b7af88ae3c053df4dc049d7d08c6
2021-05-20 17:57:43 -07:00
Manikanta Pubbisetty
fe0463deb8 qcacmn: additional runtime PM stats for HTC layer
Add few more stats to the existing runtime PM stats for
HTC layer.

Change-Id: I1610acc534997b14ae070c48da03b4e07a00d9ef
CRs-Fixed: 2949969
2021-05-20 07:58:46 -07:00
Abhishek Singh
e5a60db99c qcacmn: Removed unused API for open and WEP check
Removed unused API for open and WEP check, as the logic, to check
open and WEP mode is not valid. If required proper API can
be added later.

Change-Id: Ia57bc28d40a70c8bd3b908400126c9741080a5fd
CRs-Fixed: 2949965
2021-05-20 07:58:41 -07:00
Manikanta Pubbisetty
536d86610b qcacmn: fix runtime PM get/put out of sync
Currently, in get_htc_send_packets() when the
hif_system_pm_state_check() fails, we are not doing a
runtime PM put operation for the corresponding get operation.
This imbalance will never make the system enter runtime suspend
state and also we do a BUG() when such imbalance is encountered
during runtime PM deinit. This change also fixes a potential
memory leak.

Change-Id: I3e5916005d583de42a49dd2dc0632bfcca1251e4
CRs-Fixed: 2947247
2021-05-20 05:56:55 -07:00
Gururaj Pandurangi
312cb2ceb1 qcacmn: Add new API to get chan list with band mask for SAP
Add new API reg_get_band_from_cur_chan_list to build a chan
list based on either primary/secondary current channel list
as per requirement.
The legacy API reg_get_band_channel_list uses primary
current chan list to build a channel list. SAP needs to use
a secondary current channel list. Add a new API for SAP,
reg_get_secondary_band_channel_list for the same. Both these
APIs will call new API reg_get_band_from_cur_chan_list
by passing primary/secondary current chan list respectively.

Change-Id: I1e5573ac9371fc3ce5dc2c387fbd1d47696a161a
CRs-Fixed: 2947516
2021-05-20 00:56:01 -07:00
Liangwei Dong
6291826a31 qcacmn: Fix group mgmt cipher error
The value of req->crypto.mgmt_ciphers is bit mask
of wlan_crypto_cipher_type, but the API
wlan_crypto_set_mgmtcipher expects the enum value of
wlan_crypto_cipher_type at present.
Fix by change wlan_crypto_set_mgmtcipher to use bit
mask of mgmt cipher type.

Change-Id: I2d262bbe3f47e41635097ef8ce5722a2baa38001
CRs-Fixed: 2946164
2021-05-19 19:32:55 -07:00
Jingxiang Ge
816f75d018 qcacmn: Limit rx diag event count in each work process
Current in wmi_rx_diag_event_work, rx diag event is processing
in a while loop, if there is continuous diag event comes from
fw, it is possible that it occupy the work queue, and other work
are not able to run.

Break the while loop so give a chance to other work.

Change-Id: I7af6d60aeb8c0524cc51d663658d5b17349daa60
CRs-Fixed: 2948839
2021-05-19 16:41:33 -07:00
abhinav kumar
ecd3f845e7 qcacmn: Handle invalid or unsupported AKM/unicast cipher
AP sets multiple AKM suites in RSN information of beacon
or unicast probe response. In case if the invalid or
unsupported AKM/unicast cipher suite present in the AKM
suite list, the driver detects it as wrong RSN IE and
drops it. This results Device driver doesn't send
authentication to initiate a connection to that AP even
one or more than one valid AKM suites present in RSN IE.

Ideally, the driver should able to initiate connection if
at least one AKM/unicast cipher is valid and supported in
AKM suite list.

Change-Id: I8ed525e3945e4e437d15b496c80b1ad2aef4cb65
CRs-Fixed: 2948248
2021-05-19 14:38:05 -07:00
Manikanta Pubbisetty
f9f324f168 qcacmn: change DP RX packet drop thresholds
The current limits of DP RX packet drop thresholds are huge;
In scenarios, where the processing of RX packets is slow, huge
number of packets will be held in the memory and could eventually
lead to out of memory issues. Reducing the thresholds to address
the problem.

Change-Id: I76a2622fb30cda615aeb27fcc9c8e548ffec3e51
CRs-Fixed: 2941885
2021-05-19 14:38:00 -07:00
Jianmin Zhu
ef56741282 qcacmn: Remove the unused CHAN_NUM functions
Clean up following functions:
dfs_mark_precac_done
dfs_unmark_precac_nol/utils_dfs_unmark_precac_nol
dfs_mlme_start_csa/mlme_start_csa
dfs_mlme_get_extchan/mlme_get_extchan
dfs_fill_chan_info
utils_dfs_get_channel_list
dfs_clear_nolhistory
dfs_getchanstate
dfs_radar_enable
os_timer_func
dfs_cac_timeout

Change-Id: Id0775ba34b6f1f6c7fedaea9711d81ca07956c70
CRs-Fixed: 2946423
2021-05-19 01:26:00 -07:00
Amruta Kulkarni
2ea97ac985 qcacmn: Change file names to cfg_*.h
Change file names from wlan_cfg_*.h to cfg_*.h

Change-Id: Id89dc307c08fc55f1777794453f2168755b5506d
CRs-Fixed: 2856372
2021-05-19 01:25:56 -07:00
Shashikala Prabhu
005e1f3dd7 qcacmn: Replace MAX_CHANNELS with NUM_CHANNELS in wifipos module
In wifipos component, channel info array is allocated for MAX_CHANNELS(255)
and passed to the regulatory module which uses NUM_CHANNELS to fill the
channels. NUM_CHANNELS can be more than 255. This may lead to an array out
of boundary access.

Use NUM_CHANNELS in wifipos component to allocate channel info array.
also, add a boundary check on the number of channels received from the
regulatory component.

Change-Id: I5b7a7a4767d8bbb259c5631cf744e57ee3e1effb
CRs-Fixed: 2938879
2021-05-18 23:31:34 -07:00
Yu Tian
434c3f1532 qcacmn: Add a force TX ring HP flush when TX is pending
There is a timing race condition between RTPM suspend flow and
DP TX flow. When TX is queued during RTPM suspend flow. TX
ring update may be delayed. Add a force TX HP flush when RTPM
is rejected due to TX pending frame. This can help to improve
TX pending frames delay when race condition happens.

Change-Id: I6f60f2902dfda630f81528dcf978da6644d18ba7
CRs-Fixed: 2942744
2021-05-18 21:30:19 -07:00
Karthik Kantamneni
4dc1443151 qcacmn: Track for unbalanced group irqs enable/disable
In wlan suspend and resume cases it is seen that group
irqs are getting disabled multiple times without getting
enabled which is causing irqs to be disabled permenantly.

Track for unbalanced disabling/enabling group irqs which
helps to root cause the issue.

Change-Id: Ic1ef637c317f04b3299f17f19208df11ece3c013
CRs-Fixed: 2939809
2021-05-18 08:29:29 -07:00
Aditya Sathish
34bffddfd3 qcacmn: Scan channels only from the selected bands
Scan manager currently has two flags - scan_f_2ghz and scan_f_5ghz
for the requestor to specify which channel bands to scan.

Currently, these flags are not utilized by the scan manager to
control the channels selected as part of the scan request channel
list. As a result, specifying a particular band will not
limit the scan manager to scan only the mentioned band - instead
scanning all supported channels.

Add a check to use these flags to avoid channels from bands
which are not selected.

Change-Id: I86e17184b5bb67cbf951eee5d43a8f80a93718d6
CRs-Fixed: 2934215
2021-05-18 04:08:05 -07:00
sheenam monga
3cc8e6b591 qcacmn: Add QCA vendor interface to query usable channels
Add QCA vendor interface for userspace to get information of usable
channels for different interface types from the driver/firmware.

Change-Id: Ice662b9f14e95f32f853637e73bccd686678f278
CRs-Fixed: 2939047
2021-05-17 23:43:45 -07:00
Wu Gao
803ffc9308 qcacmn: Set max ta ra entries to 4 for QCA6490 and QCA6750
This is about CFR feature, set max ta ra entries to 4 for QCA6490 and
QCA6750 base on HW design.

Change-Id: Ief62ac394e3991a896d9bb954289e63ac105e74e
CRs-Fixed: 2939149
2021-05-17 18:56:06 -07:00
sandhu
9dc81d7965 qcacmn: Add HTT HTC tx completion based packet free
Add CE4 tx completion for htt htc packets. current logic
uses htt htc misc list to free packets.

Change-Id: Iea15d0dba544d3cc7581b11aa7ab7e5c0024133a
CRs-Fixed: 2630768
2021-05-17 18:56:02 -07:00
Manikanta Pubbisetty
273504da32 qcacmn: add TX packet threshold for DP SWLM
Add TX packet threshold while considering for TX write
coalescing. This helps improve low throughput TCP DL &
UL cases.

Change-Id: Ida2585b2473c9af4e898bde34e9b8cd35f0bdf51
CRs-Fixed: 2946896
2021-05-17 13:04:15 -07:00
Tiger Yu
183db750e3 qcacmn: Use qdf_assert_always instead of qdf_assert when rx_desc NULL
Use the qdf_assert_always instead of qdf_assert when rx_desc is NULL
getting by dp_rx_cookie_2_va_mon_status to capture real problem here
since the qdf_assert does not do anything.

Change-Id: I480917ecaf30f9faa4fdcda93c09a59e972a7e1c
CRs-Fixed: 2944083
2021-05-17 13:04:11 -07:00
Liangwei Dong
ee47c12a75 qcacmn: Add 5720 to outdoor frequency for JP
New regdomain of MKKN added channel 144 to JP.
Add 144 (5720Mhz) to JP outdoor frequency.

Change-Id: Ic50dd3aeb4e192672b71c7173b9fd4b4072b0e0a
CRs-fixed: 2943076
2021-05-17 10:51:39 -07:00
Amir Patel
f3c74a6bc4 qcacmn: Memset struct cdp_rx_indication_ppdu to zero
To avoid reading junk values, memset struct cdp_rx_indication_ppdu to zero.

Change-Id: I9216eb0bbf2f0befbcd67d2a5d400e70ed058851
CRs-Fixed: 2940690
2021-05-17 03:10:37 -07:00
Basamma Yakkanahalli
418f1c828d qcacmn: remove unused WCN7850 emulation device id
Removed unused WCN7850_EMULATION_DEVICE_ID.

Change-Id: I66a148accd25cfa9be6c7db35e4f89b569478947
2021-05-17 00:52:14 -07:00
Yu Tian
73de559075 qcacmn: avoid of HTC buffer double free in HTC send failure case
HTC buffer is freed in enqueue failure case. Then it is requeued to
htt_htc_pkt_misclist also. In deinit flow, misclist entry should be
cleared, so buffer double free is hit in this stage. Make a change
to not requeue this frame to misclist.

Change-Id: I0211c4b548d7df7176ee72a83e21f8fcf7fa464c
CRs-Fixed: 2942972
2021-05-16 22:47:56 -07:00
Lincoln Tran
edd2ccb240 qcacmn: Add second current channel list
For some concurrency scenarios, there is a need to have each session
operate in independent power modes. To achieve this, add a second
current channel list to store info for the secondary power mode.
Also add the APIs to read from the secondary channel list.

Change-Id: Ib1bd712645de05786ea6d4bbfe6163c385bdfeaa
CRs-fixed: 2944483
2021-05-14 10:46:27 -07:00
Hariharan Basuthkar
84952bbe19 qcacmn: Increase the host DFS status timeout value
On a partial offload chipset, when radar is detected on a DFS channel,
the host dfs wait timer (timeout of 200ms) is started, but there is a
delay in sending the avg_params to the FW. This delay happens for approx
330ms due to some high priority interrupt, due to this, the thread that
sends the avg_params to the FW seems to be suspended.

Host timer expiry is seen, and due to this there is a new target channel
chosen and multivdev restart is sent to the FW (the vdev is in restart
progress state). At this moment, the FW spoof timer (timeout is 300ms)
gets expired and a status code of 1 (indicating spoof failure) is sent
in the host dfs status WMI event. Due to this, the DFS channels are
blocked and the channel list is rebuilt with only non-DFS channels.
A non-DFS channel is chosen as the target channel. Since the vdev SM is
currently in restart progress state, when radar event is posted to the
vdev SM, assert is triggered and this leads to a crash.

The timeout value of the host timer is 200ms and the FW timer is 300ms.
The Host timer should be greater than the FW timer.

Therefore, increase the Host status timeout value from 200ms to 350ms.

Change-Id: I86858377fd5041922f232a1ac3d5ab781c7a63c1
CRs-Fixed: 2936809
2021-05-13 22:30:01 -07:00
Varsha Mishra
01c0c273d1 qcacmn: Drop fragmented multicast/broadcast frames
CVE-2020-26145
Broadcast and multicast frames should never be fragmented. Several devices
process broadcasted fragments as normal unfragmented frames. Moreover, some
devices accept plaintext fragmented broadcast or multicast frames in
protected Wi-Fi networks. An adversary can abuse this to inject packets
by encapsulating them in a fragmented plaintext broadcast frame. Even
unicast packets can be encapsulated in broadcast Wi-Fi frames and hence
be injected.

Change-Id: I3181a05e177cf9374a14edb748bc5001d058e0f3
CRs-Fixed: 2893212
2021-05-13 15:32:23 -07:00
Kai Chen
c089dc5216 qcacmn: remove duplicate definition for radiotap header
Move duplicate radiotap header definition to header file

Change-Id: Ieb833f26c6c433c7917cc2196d4957102501672c
2021-05-13 15:32:20 -07:00
Varsha Mishra
6c720adf28 qcacmn: Enable peer authorize by default
Drop non-EAPOL frames from unauthorized peer in security mode.
Enabling this feature by default with this change.

Change-Id: I9878b37088149e34f456a38a9c0f722e4c5ee49a
CRs-Fixed: 2943789
2021-05-13 15:32:16 -07:00
Nandha Kishore Easwaran
718d6aeece qcacmn: Add configurable option for MSI interrupts
Provide multiple combinations to configure the msi interrupts
of DP and CE based on the number of MSIs available in the platform.
Number of MSIs used for CE and DP can be changed by modifying the
MSI assignment table in platform driver. Best possible mask for that
MSI is automatically chosen based on predetermined settings.

Change-Id: I02b44fb033631d69d97f2d8d2d3f698541d37aad
2021-05-13 12:33:04 -07:00
Manikanta Pubbisetty
2359af8cea qcacmn: defer reo queue descriptor free
In some RX backpressure cases, we see the HW accessing REO
queue descriptors of a deleted peer(after the queue descriptors
are unmapped/freed), this is leading to SMMU faults. There are
cases where the HW is accessing the stale REO queue descriptors
after ~12seconds after the queue descriptors were freed.

In order to avoid the problem, HW team has suggested to defer
unmapping/free of REO Queue descriptors. Add the logic for the
same.

Change-Id: I5b1fb966dc75b963ccc9d22c40272c8d1d8d6026
CRs-Fixed: 2939223
2021-05-13 12:32:59 -07:00
Linux Build Service Account
6fdeb852e0 Merge "qcacmn: Fix smmu fault for IPA TX buffer unmapped" 2021-05-13 10:09:57 -07:00
Gerrit - the friendly Code Review server
a3c3ef14a8 Merge changes into wlan-cmn.driver.lnx.2.0 2021-05-13 09:36:46 -07:00
Jianmin Zhu
2c9dd68894 qcacmn: Fix smmu fault for IPA TX buffer unmapped
It's regression of change: qcacmn: Fix smmu fault for tx buffer unmapped.
Only 1 tx buffer is smmu mapped for IPA with it.
During STA-SAP tethering, when IPA access 2nd tx buffer, smmu fault
happens.

Remove qdf_assert_always since it already exists in
__dp_ipa_handle_buf_smmu_mapping.

Change-Id: Ife8ed17d85a8bcfc507c312001af4b905c9b3a27
CRs-Fixed: 2937435
2021-05-13 08:21:39 -07:00
Yeshwanth Sriram Guntuka
81c70ce74b qcacmn: Modify check to ensure consecutive PN for frags
Modify check to ensure packet number is consecutive for
fragments and drop the fragments if the check fails.

Change-Id: I2ca0ef6211594ba35aae894e6a385d3d5778bff6
CRs-Fixed: 2874369
2021-05-13 06:20:10 -07:00
Yeshwanth Sriram Guntuka
df22eee823 qcacmn: Register API to flush frags in dp peer ops
Register dp_peer_flush_frags API in dp peer ops
for flushing fragments for a particular peer.

Change-Id: Ia179d3160bdc306ec965c465134042c66a0c40a6
CRs-Fixed: 2874366
2021-05-13 06:20:05 -07:00
Yeshwanth Sriram Guntuka
817481b5e3 qcacmn: Add CDP intf to flush fragments for a particular peer
Add CDP interface support for flushing fragments for a
particular peer.

Change-Id: Ic59843408037b9c858599be13727422c2e3031cd
CRs-Fixed: 2875946
2021-05-13 06:20:01 -07:00
Abhishek Singh
532d6ae75f qcacmn: Do not drop the beacon in case of RSN len is less than 2
For security cert TC, RSNIE length can be 1 but if the beacon is
dropped, old entry will remain in scan cache and cause cert TC
failure as connection with old entry with valid RSN IE will pass.

So instead of dropping the frame, do not store the RSN pointer so
that old entry is overwritten.

Change-Id: I2fe4d2dd2352be6850f7a18a2ec829733ded7ee8
CRs-Fixed: 2944120
2021-05-13 01:12:56 -07:00
Karthik Kantamneni
6370333013 qcacmn: Make QDF NBUF history size configurable
Some of the targets require more QDF nbuf history
size, so making the size configurable keeping
default same.

Change-Id: Ic4ac43a1eacb1e58c0a05b794349525d614d7fc8
CRs-Fixed: 2929968
2021-05-12 20:57:57 -07:00
Yeshwanth Sriram Guntuka
8c4c0044cb qcacmn: Do not intrabss forward EAPOL frames
Do not forward EAPOL frames that have DA different
from the SAP vdev mac addr.

Change-Id: I23959e38b5cbd845d369bebd6913150eca4551bf
CRs-Fixed: 2860248
2021-05-12 18:42:31 -07:00