提交線圖

13463 次程式碼提交

作者 SHA1 備註 日期
Hariharan Basuthkar
d386ccb51a qcacmn: Check the num of reg_rules before setting AP power type
In reg_set_ap_pwr_and_update_chan_list, before setting the AP power type
check the number of reg_rules present for the input AP power type.

Change-Id: I3af82cf8b7ff6ed7525b5284390361a618da4140
CRs-Fixed: 3030223
2021-09-06 13:57:54 -07:00
Vignesh U
a0751b2b6b qcacmn: Fix LA compilation issues in AFC
/local/mnt/workspace/qcaswnbu/ec0e64b3bfc3f100861f/qsdk/build_dir/target-a
arch64_cortex-a53_musl-1.1.16/linux-ipq_ipq807x_64/qca-wifi-gf87d6f5-minim
al-profile/qca-wifi-gf87d6f5/os/linux/../../cmn_dev/iot_sim/core/
iot_sim_common.c:17:
/local/mnt/workspace/qcaswnbu/ec0e64b3bfc3f100861f/qsdk/build_dir/target-
aarch64_cortex-a53_musl-1.1.16/linux-ipq_ipq807x_64/qca-wifi-gf87d6f5-mini
mal-profile/qca-wifi-gf87d6f5/os/linux/../../cmn_dev/iot_sim/../../cmn_dev/
umac/regulatory/dispatcher/inc/reg_services_public_struct.h:28:26:
fatal error: wlan_reg_afc.h: No such file or directory
compilation terminated.

Change-Id: I6b739375a992a92d6c5830347ceffcae033021bf
2021-09-06 09:32:53 -07:00
Jeevan Kukkalli
4de1557d99 qcacmn: Release vdev ref in error cases
Release vdev reference in error cases while
collecting scan radio special vap stats

Change-Id: I030105f62fa8bb67c34c49950012f0e1dbf613a0
CRs-Fixed: 3025050
2021-09-06 09:32:48 -07:00
Kiran Venkatappa
03a407cea5 qcacmn: Add API to get pdev object from hw_link_id
Add API to lookup pdev object based on hw_link_id and return this with
reference held. Caller is responsible for releasing the ref

Change-Id: I6e3e371462c0d2a4b590b4a5de5c098a72577827
CRs-Fixed: 3026072
2021-09-06 03:12:28 -07:00
Surabhi Vishnoi
878eeb8f5d qcacmn: Add extension2 data to radiotap header
There is a requirement to get sequence number and tid for tx
data packets in packet capture mode. These fields are not
received as part of WBM tx completion, but are obtained from
FW in ppdu stats. As WBM tx completion and FW ppdu stats are
two different events, the ppdu_stats of previously sent ppdu
are filled in the radiotap header of current tx ppdu in packet
capture mode.

Enhance code to add required fields such as ppdu_id of tx current
ppdu and ppdu_id, tid, start_seq, ba_bitmap of previously sent ppdu
as extension2 to radiotap header. These fields will be added in
radiotap header only when add_rtap_ext2 is set.

Change-Id: I448a9c03a770b61ab802d855bc5f1a6587bd01b3
CRs-Fixed: 3004472
2021-09-06 00:55:05 -07:00
Hariharan Basuthkar
8fbbf2af16 qcacmn: Fix a compilation error in ucfg_reg_get_partial_afc_req_info
Fix a compilation error in ucfg_reg_get_partial_afc_req_info, when
CONFIG_AFC_SUPPORT is enabled.

Change-Id: I9834170b08bd72ee4201284c22211e3b1e5fc560
CRs-Fixed: 3029969
2021-09-04 23:16:19 -07:00
Harsh Kumar Bijlani
f366355211 qcacmn: Correct the HTT config parameters for Pine full monitor mode
For Pine full monitor configuration to FW, HTT config parameters are
incorrect. Make change to use correct config parameters.

Change-Id: I964c8a28cea36b4e1e93c106540412c8cbfc7f29
CRs-Fixed: 3029362
2021-09-04 07:58:08 -07:00
Lincoln Tran
6deace5e8f qcacmn: Remove locking mechanism when getting link vdevs
Remove the locking mechanism when getting the link vdevs since it is
causing a deadlock.

Change-Id: I360bd1ad609cfe1d0eb3576b66aeeb93495811fa
CRs-fixed: 3025767
2021-09-03 18:17:27 -07:00
Hariharan Basuthkar
94e4707d98 qcacmn: Update 6G ap power type for every FW load
When the host driver is insmod-ed, and first time the pdev object
is created, the AP power mode starts with LPI. When the FW sends the AFC
power values, the Host switches to SP mode.

If 'wifi down and wifi up' happens, all the VAPs are deleted but
pdev object is retained in the memory. Since, during 'wifi down and
wifi up' the FW is reloaded again, the FW starts with LPI always.
However, since pdev object already exists the AP power mode variable
in the regulatory private object has the same old power mode.

To fix the problem described above, update the power mode whenever
the WMI_REG_CHAN_LIST_CC_EXT_EVENT is received from the target.

Change-Id: I7a349e4defcd50cd46117d8ee55bbe8c7c8f7e80
CRs-Fixed: 3028659
2021-09-03 11:03:50 -07:00
Surabhi Vishnoi
91674a4b07 qcacmn: Add support to parse HTT_PPDU_STATS_FOR_SMU_TLV
Firmware sends some ppdu stats required for packet capture
mode in new ppdu stats tlv HTT_PPDU_STATS_FOR_SMU_TLV.
Add code to parse it if feature is enabled via ini and
send the ppdu stats using wdi event to packet capture
component.

Change-Id: I5567007a91093dd342f37458760b3a61c040b779
CRs-Fixed: 3004476
2021-09-03 08:45:17 -07:00
Paul Zhang
17818ac91e qcacmn: Revise to include walt.h header
Since walt is msm-only scheduler group of features,
not upstreamed. Include walt.h header when CONFIG_SCHED_WALT
has been enabled.

CRs-Fixed: 3023820
Change-Id: Ib1aacae83ca4168eff958341f0feebe8ab37a4e7
2021-09-03 05:51:01 -07:00
Vignesh Viswanathan
1a7abca3c0 qcacmn: Add option to disable Cached Descriptor support
Some platforms do not support cached descripts for DP Rings.
Add support to set WLAN_CFG_DST_RING_CACHED_DESC to 0 and make
__qdf_nbuf_dma_inv_range as stub if DP_NO_CACHE_DESC_SUPPORT flag is
enabled during compilation.

Change-Id: Ic6b483be25c32f3f3c79b170fb7d7557a232b4ac
CRs-Fixed: 3027649
2021-09-03 05:50:56 -07:00
Adwait Nayak
fec569fb1f qcacmn: Compile qal_bridge.c only if DBDC_REPEATER_SUPPORT is enabled
qal_bridge.c has dependency on kernel bridge APIs and is required only
if DBDC_REPEATER_SUPPORT is enabled.

Remove qal_bridge.o from QDK Kbuild if DBDC_REPEATER_SUPPORT is not
enabled.

Change-Id: I7e8ae6f979f5323b99f4946b13c91c2a816f74a7
CRs-Fixed: 3027649
2021-09-03 05:50:52 -07:00
Vignesh U
fc7e74f044 qcacmn: Create intersected AFC channel before calling ACS
ACS needs the intersection of SP channel and the channel list in the AFC
response.

Create intersected AFC channel before calling ACS.

Change-Id: I9443edfc4d8b31edf5ae7e040c0743de9a0851b3
CRs-Fixed: 3023930
2021-09-03 03:25:12 -07:00
Vignesh U
a4b1ed87f0 qcacmn: Fix compilation error in reg_get_partial_afc_req_info
The function reg_get_partial_afc_req_info() declaration is different from
its definition prototype.

Change-Id: Idd36e1343dd2af1d5ecaf3b8dcbaf7dc6839d560
CRs-Fixed: 3023862
2021-09-03 03:25:07 -07:00
Surabhi Vishnoi
9aaf9e8110 qcacmn: Remove rx packet capture events processing if feature is disabled
Currently, rx packet capture events processing happens even
when feature is disabled by ini. This incurs per packet overhead
in rx path.

The fix is to move all the processing from rx path to packet capture mode
component. Send only wdi event from rx path, when feature is enabled by
ini.

Change-Id: I647256b85117cd3373950c78a5a0ae7d6710e4e2
CRs-Fixed: 2969123
2021-09-03 03:25:02 -07:00
Hariharan Basuthkar
e1708ea080 qcacmn: Add a condition in reg_compute_chan_to_freq for 6G channel 2
When 6G IEEE channel 2 (5935 MHz) is enabled in the master channel list,
and if the channel 1 (5955 MHz) is the input to the API
reg_compute_chan_to_freq, the API returns 0 as the output channel
frequency.

Since the IEEE number 2 is greater than 1 (but in terms of frequency it
is a lesser value), the break condition in the for-loop gets
satisfied, and since the enum of channel 2 is equal to MIN_6GHZ_CHANNEL,
the API returns 0.

To fix this issue, in reg_chan_band_to_freq, handle 6G channel 2 as a
special case by directly returning its frequency, and also
skip it from the search space of reg_compute_chan_to_freq.

Change-Id: Ief79ee2d93f4d547688e10113a8105a763c767f8
CRs-Fixed: 3013255
2021-09-02 23:58:12 -07:00
Hariharan Basuthkar
b136efc7a5 qcacmn: Intersect AFC and SP regulatory power
While appending one of the 6g_master_channel lists (based on power
type) to the master channel list, if the power type is standard power,
intersect the standard power list with the afc power list and append
the intersected list to the master channel list if the afc power
list is available.

Change-Id: I606e765a4abd5cd71cf35a13ac799fdec8e87ffd
CRs-Fixed: 3023853
2021-09-02 14:32:05 -07:00
Karthik Kantamneni
48b496eabd qcacmn: Conditionally update BAR frame info to H.W
Host updates BAR info to H.W when out of order or 2K jump
BAR frame is received. But some AP's frequently transmitting
out of order BAR frames even before reception of all the
frames in the current window, if station updates window
and SSN based on BAR frame, RX frames sequence number in
older window range which are yet to be received suffers
REO aging timeout and causes RX packet delay to avoid
this skipping BAR update to H.W conditionally.

Change-Id: If56571ffc0dc0880d7104ea3bb193ed9766124dd
CRs-Fixed: 3015643
2021-09-02 12:16:58 -07:00
Hariharan Basuthkar
033605a031 qcacmn: Add a dispatcher API to read the ini AFC config
Add a regulatory dispatcher API to fetch the value of AFC action
from the ini config.

Change-Id: I053262f98991a656d1919817ce37227202a46bc3
CRs-Fixed: 2997899
2021-09-01 21:38:11 -07:00
Hariharan Basuthkar
8c2dd12d3c qcacmn: Fix driver crash observed during AFC request processing
Currently the AFC request buffer is being freed twice in
reg_free_expiry_afc_info and tgt_afc_event_handler.
Make changes to free the AFC req buffer only once.

Change-Id: I6d0f5c783a124da40eae6166132f7d7132cf76e4
2021-09-01 17:13:31 -07:00
Kiran Venkatappa
7aaef9935d qcacmn: Extract hw_link_id and store in target_if pdev context
hw_link_id is unique across psoc to identify pdev in multi-soc ML cases.
Exract hw_link_id from mac_phy_cap and provide APIs in target_if to set
and get this for pdev

Change-Id: I9dcc4c1e4b515e83151ca88f5f026c0dd0b04646
CRs-Fixed: 3023496
2021-09-01 17:13:27 -07:00
Kiran Venkatappa
f0c88a6cb9 qcacmn: Set QCN9224 ce attribute flags to zero for CE 12&13
CE 12 and 13 is assigned for CV prefetch. Set attribute flag for these
CE to zero as per current requrement from FW on Emulation.
This may be changed to different value based on future requirement.

Change-Id: I70073aa45b6999a42ed230835a2a7dd7b650edad
CRs-Fixed: 3025570
2021-09-01 09:03:17 -07:00
Sridhar Selvaraj
bfb04859c6 qcacmn: Reset skip_bssid_copy flag in split profile parsing
While parsing MBSS IE split profiles, bssid copy flag
is not reset in between sub element parsing resulting
in skipping the bssid copy for next non tx profile.

Reset skip_bssid_copy flag for each sub element parsing
so that correct bssid is copied for next non tx profile

CRs-Fixed: 3019298
Change-Id: I429190b21a3ddafdc75a73e8b063f6b6f629492a
2021-09-01 09:03:13 -07:00
Aditya Kodukula
4b05def09d qcacmn: Update QCA mDNS Offload vendor command
Update kernel documentation of mDNS offload vendor command.

Change-Id: I939e0e6c48731f42691ab9952184695be40ba3a0
CRs-Fixed: 3026714
2021-09-01 00:33:37 -07:00
Rhythm Patwa
7a9dc17c65 qcacmn: Add support for AFC Host service flags
Add support for AFC specific Host service flags to switch
between LPI only and SP+LPI, disable AFC timer and request ID checks
in target.

Change-Id: I34d6adcad6e4a2cd6383c941ed07b98059daeed0
2021-08-31 22:23:51 -07:00
Wu Gao
64da7093a2 qcacmn: Not change RSSI of cfr meta data to dBm
Since target already converts RSSI from SNR to dBm for QCA6490 and
WCN7850, so don't convert them again in host side.

Change-Id: Ie35f3821a802f2e65b61f4891f2ca9c632fa1477
CRs-Fixed: 3024119
2021-08-31 20:04:45 -07:00
Hariharan Basuthkar
258d7f4c16 qcacmn: Implement the 6G AFC power event processing
Add regulatory functions to handle the WMI_AFC_EVENTID. This
includes processing the AFC power information received from the FW,
and constructing the AFC channel list in the regulatory component.

Change-Id: I5da8fc7faae847476f88ff35b20e6444115af7f1
CRs-Fixed: 3023789
2021-08-31 14:44:50 -07:00
Bing Sun
7fcc2ebd13 qcacmn: Fix issue when getting rnr
When getting rnr IE information, instead of getting rnr pointer through
input parameter,  we can just return rnr pointer.

Change-Id: I57f683eb86bb813018a38fa3a6286e9b6e40037f
CRs-Fixed: 3025194
2021-08-31 12:23:26 -07:00
abhinav kumar
2e92c9f7a5 qcacmn: Add QCA vendor attribute to configure ROAM_BAND
Add a QCA vendor attribute to configure the driver to use
roam band set by userpace. This attribute is also used to
get the configured roam band from the driver.

Change-Id: I5ea7f9d12b2a01e1b4baa43e46342af34bebba49
CRs-Fixed: 3009747
2021-08-31 07:54:59 -07:00
Kiran Venkatappa
718f574750 qcacmn: MLO setup, teardown, ready WMI API
Add WMI APIs for MLO setup, ready and teardown command send and extract
routines

Change-Id: If986124032c4fb9bb3ed2ffbf2ac6db8fe9e0f1f
CRs-Fixed: 2981067
2021-08-31 07:54:54 -07:00
Ashish Kumar Dhanotiya
8082901907 qcacmn: Set default value of mawc_nlo_enabled ini as 0
Set value of mawc_nlo_enabled ini as 0 by default.

Change-Id: I7779072deecc9390f3df929355788ee8d73cb48f
CRs-Fixed: 3024972
2021-08-31 07:54:49 -07:00
aloksing
ca013a2078 qcacmn: Add enhanced stats flag
Add enhanced stat flag in dp pdev to make independent of monitor ko

Change-Id: I6da989db54829e28ce680fc9671eb9b866e4b2b1
CRs-Fixed: 3020454
2021-08-31 05:39:42 -07:00
Subrat Dash
8525330652 qcacmn: Add WMI support to send the wds AST commands to fw
Add host WMI APIs to send WMI_PEER_ADD_WDS_ENTRY_CMDID,
WMI_PEER_REMOVE_WDS_ENTRY_CMDID, and WMI_PEER_UPDATE_WDS_ENTRY_CMDID
to the Fw.

Change-Id: I32afdac7c366b647ee3196bcb76531295e640b8b
CRs-Fixed: 2997227
2021-08-31 05:39:37 -07:00
Rakesh Pillai
ffb8752cf3 qcacmn: Print TXBF related stats
Add support to print the TXBF related FW stats

Change-Id: Ib3e2ac04df114d588a66fdf5e30b2a0cfdffcc8f
CRs-Fixed: 3001216
2021-08-31 03:26:28 -07:00
Santosh Anbu
bb40ebd9a8 qcacmn: Use vdev list when dispatch sync complete event to MLO
In few of the scenarios, as part of sync complete handling mld_dev_context
lock is been acquired, which causes deadlock as it is already taken before
dispatching the event.

Hence get the vdev list under lock and reference taken and then dispatch
mlo_sync_complete individually.

Change-Id: Id23dba89276ecaadb02cd3a39a66b4fca3f97c7c
CRs-Fixed: 2924329
2021-08-31 01:15:41 -07:00
Santosh Anbu
d445d62fd9 qcacmn: MLO quiet vdev bitmap support for AP
Add change to support indication of quiet vdev for MLO AP context.

Change-Id: I7368e023976c29ae98fef2b86ef6aee0b7621390
CRs-Fixed: 2924329
2021-08-31 01:15:33 -07:00
Shiva Krishna Pittala
e0ff191da1 qcacmn: Add QCA vendor attribute indicating the spectral scan bandwidth
Add the following vendor attribute to indicate the bandwidth to be used for
Spectral scan operation.
 - QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_BANDWIDTH

CRs-Fixed: 3024152
Change-Id: I8ffc5f4d0106cb293ac81408e3b691fc29808080
2021-08-30 15:47:16 -07:00
Yue Ma
674474c55a qcacmn: Add CONFIG_CNSS_OUT_OF_TREE flag
Use CONFIG_CNSS_OUT_OF_TREE to control if CNSS family drivers are
built from in-kernel-tree source or out-of-kernel-tree source since
the exposed header files will be in different paths. This is also
for backward compatibility.

Change-Id: I698492f175ea140e6854c372f366a63f36de24c9
CRs-fixed: 3022556
2021-08-30 13:38:44 -07:00
Amir Patel
437f0113c8 qcacmn: Use atomic variant mem alloc API while in ndo_get_stats
When kernel calls driver callback to get stats, dev_get_stats()->
ndo_get_stats64() .Host driver allocates memory using
kmalloc (size, GFP_KERNEL) routine,
but as ndo_get_stats is under RCU lock but not in interrupt
context(in_irq = 0, in_interrupt = 0, irq_disable = 1),
qdf_mem_malloc () uses ‘GFP_KERNEL’ to allocate memory,
leading to backtrace.
As per kernel doc
(https://www.kernel.org/doc/Documentation/networking/statistics.rst),
while in ndo_get_stats64 () API, driver should not calling a routing
which can sleep. Use atomic variant of qdf_mem_malloc() to fix this.

Change-Id: I3585b93d227a36b4b01c9c4f72d878c6cdb44cd4
CRs-Fixed:3020603
2021-08-30 02:57:31 -07:00
Shivani Soni
d06d841dc6 qcacmn: Add support for VOW Reo and Rxdma error statistics
Support for Rx REO and Rxdma error statistics for version 3

Change-Id: I2a558f62d6d7b66658bb064810d0ea13528d9a28
2021-08-29 00:54:41 -07:00
Srinivas Dasari
92ba4703ca qcacmn: Add roam_pmkid_request to wmi_ops
Add extract_roam_pmkid_request to wmi_ops to allow cld driver
to register the corresponding callback.

Change-Id: Ifa9cd73d6d62e7411b78b15086d7e166559f6d1c
CRs-Fixed: 3014249
2021-08-28 00:29:38 -07:00
Vijay Patil
e5748271d3 qcacmn: Add extract_auth_offload_event to wmi_ops
Add extract_auth_offload_event to wmi_ops to allow cld driver to
register the corresponding callback.

Change-Id: Ie3417f44360021570ce678ce1c3f949a92424494
CRs-Fixed: 3010510
2021-08-28 00:29:33 -07:00
Utkarsh Bhatnagar
b7ab2f5cd7 qcacmn: Add support for Thermal Stats Events
Add support for extracting Thermal Stats Events
from thermal event TLV for FW event
WMI_THERM_THROT_STATS_EVENTID.

Also, added support for FW Cmd to request for
Thermal Stats: WMI_REQUEST_THERMAL_STATS_CMDID

Change-Id: I2bc80d082bda45e2255371bcb0c31d35d9806525
CRs-Fixed: 3016845
2021-08-27 10:23:50 -07:00
Abhijit Pradhan
bd02b05aa5 qcacmn: Move repetitive function bodies into a single function
The body of the two following functions:
1)reg_get_num_sp_freq_ranges,
2)reg_cp_freq_ranges
have much in common.

Move the common part into a single function in order to optimize code size.

Change-Id: Ice9e925ef0e64baa41f867a92a3c3d2902374d74
CRs-Fixed: 3019338
2021-08-27 08:08:53 -07:00
Abhijit Pradhan
575da29354 qcacmn: Find the frequency ranges for AFC request
The regulatory rules contain the frequency ranges that are supported
by the current regulatory domain. Also every radio has a chip range
which indicates the range of frequencies supported by the radio. To
find the list of frequencies for the AFC request, add each regulatory
frequency range that are within the chip range to the AFC list of
frequency ranges. If a regulatory range has a partial overlap with the
chip range add only the overlapping part of the range to the AFC list
of frequency ranges.

Change-Id: Ida3e2217783db82fef2825c6a6603e79ef65951b
CRs-Fixed: 3019336
2021-08-27 08:08:48 -07:00
Shashikala Prabhu
d4c52fb8ef qcacmn: Remove the 'multi_link is null' error print
"scan_entry->ie_list.multi_link is null" print is
flooding the scan component. Hence, remove this print.

Change-Id: I921eea8afc2dba5637c7c02717e2d1fb544ba103
CRs-Fixed: 3023813
2021-08-27 08:08:43 -07:00
Hariharan Basuthkar
0b8e97ac32 qcacmn: Add dispatcher APIs for AFC in the regulatory
1) Add an ucfg dispatcher for reg_afc_start.
2) Add an API wlan_reg_get_afc_req_id, to fetch AFC request id.
3) Add an API wlan_reg_is_afc_expiry_event_received, to check if the AFC
   expiry event is received from the target.

Change-Id: I45841706c500e74632b60546d945cde4d634a5d2
CRs-Fixed: 3011675
2021-08-27 05:44:45 -07:00
Kiran Kumar Lokere
e2ada05cee qcacmn: Config support to use BSSID in probe request RA
User configuration support to use scan request BSSID value
in Probe Request frame RA during the scan.

Change-Id: I40d07e4c3e4814a9c816b3e426dcbb63df7ddf27
CRs-Fixed: 2945679
2021-08-27 01:06:23 -07:00
Will Huang
64d063094f qcacmn: Change beacon drop log to rate limit log
Although beacon drop info is important, but if continually print with
info level it will flood serial log and lead to low performance.
Security mode check is mandatory in 6Ghz band, so it is by default
enabled, so possible to see many beacon drop log because of this check.

Change beacon drop log to rate limit and fix one potential memory
leak in __scm_handle_bcn_probe().

Change-Id: Ic9032b99504d6ff41256d547e2d8fad101301589
CRs-Fixed: 3014786
2021-08-27 01:06:19 -07:00