Revīziju grafs

10010 Revīzijas

Autors SHA1 Ziņojums Datums
Surya Prakash Raajen
21e219fe2f qcacmn: Reorder and optimize channel mode macros
Reorder channel mode macros to have macros in logical
order, and to optimize the channel modes to use
bit specific enums instead of single bit to reduce
the usage of number of bits. The changes are specific
to host

Example for Channel mode: IEEE80211_CHAN_HE20
Channel modes represents only the information regarding
to channel such as band, width, passive, DFS, blocked
40MHz_intolerant and so. It doesn't have information
regarding hwmode like 11ac,11ax.

CRs-Fixed: 2846331
Change-Id: I197de032a4d677a27b46028fa090a6eabe0c6086
2021-01-05 02:59:30 -08:00
Ashish Kumar Dhanotiya
48dee39efb qcacmn: Rate limit invalid channel number messages
Channel number can be invalid when finding out the enumeration for the
channel. Rate limit the messages for the same.

Change-Id: Ie6cf178482647547d58d4d9555763332d6598846
CRs-Fixed: 2843978
2021-01-04 18:46:29 -08:00
Ruben Columbus
60e9a2d116 qcacmn: add extra stats pdev and vdev lvl
stats added for descriptor alloc fail and tx outstanding too many

Change-Id: Ie2c676979f21e8f0ab217e8c666a8cdf3efbf7f1
2021-01-04 13:51:41 -08:00
Vevek Venkatesan
86f4aa6017 qcacmn: add sync between suspend and wow resume in runtime pm
In moselle, once wow enabled there is a possibility that wow wake
interrupt can be fired from FW during runtime suspend in-progress
in host, this will introduce a race between runtime suspend and
resume, so adding a synchronization between runtime suspend and
wow triggered runtime resume.

Change-Id: I38d6a24e4421697cc2d0090ba8d19884885596cb
CRs-Fixed: 2845672
2021-01-04 05:08:47 -08:00
Srinivas Dasari
82acedd149 qcacmn: Copy flags also when the 6g channels are sorted
Currently, 6g channels are sorted based on the weightage of each
channel. Frequencies are sorted but the flags associated to each
channel are not updated properly. So, channels carry invalid
flags to firmware and firmware may miss to scan few 6g channels
based on these flags and may scan few 6g channels unnecessarily.
Copy flags also while sorting frequencies to maintain the flags
of each channel as it is.
Also, change the type of phymode to enum scan_phy_mode
from uint32_t.

Change-Id: I0a2330faab1b738f2d7eff3d39ccbfffd51dfde0
CRs-Fixed: 2840029
2020-12-31 10:37:37 -08:00
Srinivas Dasari
865573d455 qcacmn: Possible buffer overflow while copying rnr info
A temporary variable "temp" is declared to use it while sorting
the channels based on the weightage/rnr info. This is declared
as a pointer to hold the reference of struct rnr_chan_weight but
memcpy is done to this without allocating memory.
Declare this as a variable instead of pointer to use it as an
intermediate variable for sorting.

Change-Id: If619f5fa462d5400f0a77e57317ac3c8debb34a5
CRs-Fixed: 2842819
2020-12-31 10:37:32 -08:00
Abhishek Ambure
2f21a68e2a qcacmn: Update bssid in cm request from cm_get_active_disconnect_req
To get active disconnect request host uses cm_get_active_disconnect_req
API. Update missed field BSSID into connection request from
cm_get_active_disconnect_req API.

Change-Id: I94fa3e14b4584b95b1d918390e5572fa8f112571
CRs-Fixed: 2846679
2020-12-30 11:24:50 -08:00
Karthik Kantamneni
c4845219dc qcacmn: Enhance debug info in rx descriptor
Add previously freed nbuf and buffer start address info in rx descriptor.
This helps in debugging use after free access of rx buffers.

Change-Id: I1c883bf049ce75dd0413b85946fe2982648d8004
CRs-Fixed: 2827151
2020-12-30 09:20:57 -08:00
Edayilliam Jayadev
9b98e19b51 qcacmn: Add Spectral disabled checks in some APIs
Add Spectral feature disable checks in some APIs
used by other modules.

CRs-Fixed: 2845252
Change-Id: I74d66da2aa85ab0f116ad1a6d2e859f3ee8eeeb9
2020-12-30 07:06:41 -08:00
Edayilliam Jayadev
c89f5e524d qcacmn: Fix return value of Spectral ucfg API
Return type of "ucfg_spectral_control" is QDF_STATUS.
Wrong return values are send for this APIs in case of errors.

CRs-Fixed: 2845251
Change-Id: I24f3beb44486753ad0eba706e9f2ac258067d82d
2020-12-30 07:06:37 -08:00
Edayilliam Jayadev
445c0a42c3 qcacmn: Fix return values of Spectral target APIs
Return type of "target_if_is_spectral_active" and
"target_if_is_spectral_enabled" is bool. Wrong return values
are send for this APIs in case of errors.

CRs-Fixed: 2845250
Change-Id: I2344676a1ada51e041bb5f7acac8aa22847bee5c
2020-12-30 07:06:33 -08:00
Edayilliam Jayadev
80a12b81ed qcacmn: Skip init/deinit/config if Spectral is disabled
If Spectral scan is disabled(agile and normal mode disabled)
skip init/deinit of Spectral module. Also avoid user requests
to configure/start/stop scan. If either agile or normal mode
is disabled block user requests for that mode alone.

CRs-Fixed: 2840335
Change-Id: I81148e5580fe4bf991b97cd086c8e3a9ca78e77d
2020-12-30 07:06:29 -08:00
Edayilliam Jayadev
b3affda43a qcacmn: Add APIs to check Spectral feature is disabled
Add utility APIs to check Spectral scan is disabled for
a given pdev/psoc/mode.

CRs-Fixed: 2840317
Change-Id: I6820cfc056c697434a138ddf9d8d93b5796a4722
2020-12-30 07:06:24 -08:00
Edayilliam Jayadev
3e679f9176 qcacmn: Add APIs to init Spectral feature caps in the upper layer
Add APIs to init Spectral feature caps in the upper layer of the
Spectral module.

CRs-Fixed: 2840249
Change-Id: Idfb34a9eec3a66c6d193be7bb828eeec30548ae7
2020-12-30 07:06:20 -08:00
Edayilliam Jayadev
19aaca7ff9 qcacmn: Add target if APIs to initialize spectral feature caps
Add target if APIs to initialize normal and agile Spectral
feature caps for a pdev.

CRs-Fixed: 2840247
Change-Id: I6c5385c2050007a5ff3f668ab3d6176328294549
2020-12-30 07:06:16 -08:00
Edayilliam Jayadev
dac2af9a3b qcacmn: Add APIs to get Spectral scan capability
Add APIs to check the agile and normal Spectral scan
capability of the target. This information is derived from
the advertisements from halphy via WMI events.

CRs-Fixed: 2840227
Change-Id: I2aae79b3342d8d74a1f4c00e813cae843a71106a
2020-12-30 07:06:12 -08:00
Edayilliam Jayadev
8f57245a44 qcacmn: Add Spectral feature capabilities
Add the following Spectral scan capabilities at the pdev level.
 a) Normal Spectral scan capability
 b) Agile Spectral scan capability for 20/40/80 MHz
 c) Agile Spectral scan capability for 160 MHz
 d) Agile Spectral scan capability for 80+80 MHz

Also change the definition of existing Spectral scan capability
at psoc level.

CRs-Fixed: 2840144
Change-Id: I18be48ec4095fa29b62800a9df58b72295747547
2020-12-30 07:06:08 -08:00
Edayilliam Jayadev
b3e677f722 qcacmn: Add WMI API to Spectral module's interface
Add WMI API "wmi_service_enabled" to Spectral module's
interface.

CRs-Fixed: 2840141
Change-Id: I2cb6363fd37c858f2a84ba1904c89033720d1a0a
2020-12-30 07:06:04 -08:00
Edayilliam Jayadev
962647ba6c qcacmn: Add "Spectral disable" WMI service bit
Add a new WMI service bit to indicate whether normal
Spectral scan is disabled.

CRs-Fixed: 2840128
Change-Id: I09314afeb5372f83b8356e06f245c83c7acbc85d
2020-12-30 07:06:00 -08:00
Bapiraju Alla
00678d250a qcacmn: Don't consider WMI_MIN_HEAD_ROOM in WMI msg length
Currently, Host driver assumes WMI_MIN_HEAD_ROOM is part of WMI
messages and Validations are done accordingly. But this
WMI_MIN_HEAD_ROOM is not considered in the firmware. Because of
this host may drop valid events.

To avoid this, Don't consider WMI_MIN_HEAD_ROOM while validating WMI
msg length.

Change-Id: I5f1fe12cfae570e636defb8a4a46ec154f988195
CRs-Fixed: 2844982
2020-12-29 15:49:55 -08:00
Rakesh Pillai
4138c9b7d8 qcacmn: Add API to set dma mask for device
Currently DMA mask for the device is set during hif_enable_bus.
If the datapath memory prealloc feature is enabled, there are
a few dma memory allocation which is done before the DMA mask
is set for the device. This leads to the aforementioned dma
memory pre-allocation to be attempted at the default DMA mask.
Due to this the entire device capability of dma address might
not be used.

Add hif api to set dma mask before hif is initialized. This
is needed to set dma mask in case of datapath memory pre allocation.

Change-Id: I6fd25d9cb6ab3aaacd6f959abe4e060e23f37095
CRs-Fixed: 2845020
2020-12-29 11:05:45 -08:00
Jeevan Kukkalli
ab63a2735b qcacmn: Include ALD headers
Include ALD core headers

Change-Id: I1b1e074a1615597b1bf166f28be768e5d82510b5
CRs-Fixed: 2844914
2020-12-29 03:16:13 -08:00
Amir Patel
76b9febd3d qcacmn: Delay allocation of rings for monitor mode
In existing implementation, for monitor mode below allocation
are done at pdev attach and init time.

	a. 64 monitor buffer allocation for RxDMA monitor buffer ring
	b. Link descriptor memory allocation for monitor link descriptor ring

This memory is waste of memory for customers not using monitor mode and
low memory profile.

To optimize this memory, allocate all buffers and link descriptor memory
at monitor vdev creation time.

Change-Id: I873c76d2f625a782532a101037915b0353928a5b
CRs-Fixed: 2829402
2020-12-29 03:16:09 -08:00
Santosh Anbu
d36905a34a qcacmn: Add null check for connect request bssid
Add null check for connect request bssid before copying the previous
bssid.

Change-Id: I5b674d99923335673cbcc3ddcbbbc4a6940bad47
CRs-Fixed: 2845808
2020-12-28 23:00:47 -08:00
Vulupala Shashank Reddy
86566328a2 qcacmn: Add WDI event for offload tx data for packet capture mode
Add WDI event and call wdi event handler to deliver offload tx
packets to packet capture mode.

Change-Id: I064ffaaebd13bcf2060d91c58a07b93ec741b133
CRs-Fixed: 2844731
2020-12-28 17:17:45 -08:00
Shikha Bakshi
84bbeeedec qcacmn: Rectify MODULE ID in display for qdf_cv_lvl
Rectify dispaly module ID for QDF_MODULE_ID_DP_RX_MON_DEST

Change-Id: I6aee8c38d67aad1a6a97325d2e9f1a16e1f4fbdd
2020-12-28 15:13:22 -08:00
Shiva Krishna Pittala
8f4dceb4bc qcacmn: Direct Buf Rx changes to support big-endain platform
Use the hal_srng APIs that handle byte-order conversion of ring pointers
for big-endian platforms.

Change-Id: I2664636d5d2a1abfd7b643ea4c4d63d328a9880f
CRs-Fixed: 2845047
2020-12-28 13:07:06 -08:00
Shiva Krishna Pittala
d692460e35 qcacmn: Add HAL srng access APIs that handle endianness conversions
Current implementation of hal_srng_access_start() reads the ring pointer
in the same byte-order as it is written by the target. This results in
byte-order mismatch on a big-endian Host because the WLAN target is
little-endian based. For most of the srngs, the target already takes of
this by converting the ring pointer to the host-order before writing to the
DDR. But for other srngs, the Host needs to handle the endianness
conversions. Add HAL APIs to do the same.

CRs-Fixed: 2844519
Change-Id: Ieb47391ac0acc3724e854f433915dd5b1219bebe
2020-12-28 13:07:03 -08:00
Himanshu Batra
6df2698a64 qcacmn: Notify kernel if connect fails after cfg change
Notify kernel if connect fails after cfg change

Change-Id: I7cdf9adf5452204411566bd7ac52d67dcbe35481
2020-12-28 13:06:58 -08:00
Vignesh Mohan
d32051f608 qcacmn: Replace radar checks to use regulatory channel list
In DFS, to check if a channel is radar, we use the flags that
are filled from UMAC to check for radar. Since the channel list
in UMAC are dynamically calculated, the dynamic flags will not be
consistent over multiple channel pointers.

Use the radar information in regulatory for individual subchannels
to check for radar in a given channel. Define these new APIs
under a feature specific macro.

Change-Id: I7f86560c3d29d2366c6506ccf63204263cbc0ef1
CRs-Fixed: 2841168
2020-12-28 10:57:47 -08:00
Nandha Kishore Easwaran
6547f0f671 qcacmn: Swap bytes of key_data in big endian platform
Swap each word of key_data before sending key install command.
This is needed since copy engine swap is enabled for big endian platform
and key needs to be plumbed in network byte order for decoding to happen
correctly.

Handle the swap in wmi layer since all other big endian conversions are
handled in this layer.

Change-Id: Ia6f0d579f3edaf32193c353ea2fe35cc40f55399
2020-12-28 08:56:09 -08:00
Min Liu
0671146738 qcacmn: Replace pdev_id with mac_id for ucfg_dcs APIs
Replace pdev_id with mac_id for ucfg_dcs APIs and update
related documentation.

Change-Id: Ie0dbe992c113aac597dbb6820acd3faba3ac9f3c
CRs-Fixed: 2843510
2020-12-28 01:57:33 -08:00
Vulupala Shashank Reddy
6735c84cff qcacmn: Add WDI event for rx packet to packet capture mode
Add WDI event and call wdi event handler for to deliver rx packet
to packet capture mode.

Change-Id: I856ac07f292047136431f67bb2654c855767e5e8
CRs-Fixed: 2844728
2020-12-24 09:52:42 -08:00
Vulupala Shashank Reddy
0366025b7f qcacmn: Add WDI event for tx completion for packet capture mode
Add WDI event and call wdi event handler for tx completion for
packet capture mode.

Change-Id: I99225dda53effc6ab5a80a32aa8aa082543855b2
CRs-Fixed: 2844724
2020-12-24 09:52:38 -08:00
Vijay Krishnan
d56177bd21 qcacmn: Add macro QCA_SUPPORT_DFS_CAC
Conditional compile dfs_cac functionalities to
avoid compilation issues.

Change-Id: Id81b51f071f9abfb666231f2b2005d3c594b7d1a
CRs-Fixed: 2843645
2020-12-24 09:52:34 -08:00
Vevek Venkatesan
16066cae2b qcacmn: fix error in NULL checking of rx_ring_history
rx_ring_history is an array of pointers, address of pointer is
always a non-NULL value, this always passed the NULL check,
which leads to NULL pointer dereference, fixing the same.

Change-Id: I401203a6f2a5930869cf4002ac0e714d3fdba62f
CRs-Fixed: 2844038
2020-12-24 07:40:22 -08:00
Jinwei Chen
b3511e0844 qcacmn: support FSE cache flushing suspend/resume
scenario:
FISA new FST entry is initialed, host will start one timer to
send HTT MSG DP_HTT_FST_CACHE_INVALIDATE_FULL to FW in 5 ms,
WOW suspending happened in the same time, PCIe bus get suspended.
5 ms later, HTT msg sending will try to prevent PCIe L1 to update
CE SRNG HP register, hit assert as PCIe bus suspended already.

suspend and cancel the FSE cache flushing timer when dp_bus_suspend,
resume it when dp_bus_resume.

CRs-Fixed: 2843214
Change-Id: Ie2bc115a0de068335d6c46749f52d205cc21f5a3
2020-12-24 04:50:29 -08:00
Kiran Kumar Lokere
982bf62718 qcacmn: Add support for keepalive with mgmt frame tx
Add support to configure the keep alive packet as management frame
to FW.

Change-Id: Icaf88f30981eeac2b282f35c3a719950e3e0d1df
CRs-Fixed: 2788504
2020-12-23 20:55:55 -08:00
Pragaspathi Thilagaraj
210ed2bc5f qcacmn: Add Vendor feature capability to notify TWT asynchronous response
The response for the respective TWT operations can either be synchronous
or asynchronous (wherever specified). If synchronous, the response to
this operation is obtained in the corresponding vendor command reply to
the user space. For asynchronous case, the response is obtained as an
event with the same operation type.

Drivers shall support either of these modes but not both simultaneously.
The support for asynchronous mode is advertised through the new flag
QCA_WLAN_VENDOR_FEATURE_TWT_ASYNC_SUPPORT. If the driver does not
include this flag, it shall support synchronous mode.

Change-Id: I359e12c5147b0115158d03a7a08d74beca78455c
CRs-Fixed: 2842872
2020-12-23 11:35:31 -08:00
Pragaspathi Thilagaraj
ae5d79bf9e qcacmn: Add new TWT operations and attributes to TWT Setup and Nudge
Define the following additional TWT operations:
QCA_WLAN_TWT_GET_STATS, QCA_WLAN_TWT_CLEAR_STATS,
QCA_WLAN_TWT_GET_CAPABILITIES, QCA_WLAN_TWT_SETUP_READY_NOTIFY.

Also define new attributes to qca_wlan_vendor_attr_twt_setup
and qca_wlan_vendor_attr_twt_nudge.

Change-Id: I687fd215c13aa12741d8ba7af23507f930d0ec81
CRs-Fixed: 2842072
2020-12-23 11:35:27 -08:00
Pragaspathi Thilagaraj
7815fdacc7 qcacmn: Add support for TWT wake duration and interval tolerance values
Add support to configure minimum and maximum wake duration
values, minimum and maximum wake interval values for TWT setup.

Change-Id: I69c328815be511833abce0fcd18649e136027f53
CRs-Fixed: 2827115
2020-12-23 11:35:23 -08:00
Himanshu Batra
267abe7138 qcacmn: Pass correct argument while delivering CM Scan Fail Event
Pass correct argument while delivering CM Scan Fail Event

Change-Id: I82fbf8326fd8e5cd8d0fe8a13c6cfe36605fca2d
CRs-Fixed: 2844043
2020-12-23 04:45:30 -08:00
Aakanksha Doda
03d2eeb345 qcacmn: Add support for Green AP SMPS feature
Add feature support for GAP SMPS mode

Change-Id: I40b9efb6ef22fe4bebdb30939f19d8d112065344
2020-12-23 02:44:58 -08:00
Shikha Bakshi
3eeace37b2 qcacmn: Modify logs for QDF_MODULE_ID_DP_CDP and QDF_MODULE_ID_DP_VDEV
Add macros like dp_cdp_debug, dp_cdp_err, dp_cdp_info, dp_vdev_info,
dp_vdev_err, etc. to define logs

Change-Id: I176c0579af9b5ef2f14846fac1e8182309636464
CRs-Fixed: 2840489
2020-12-22 18:47:49 -08:00
Shikha Bakshi
3de99369a0 qcacmn: Modify Logs for QDF_MODULE_ID_RX
Add macros dp_rx_info, dp_rx_debug, dp_rx_err,etc.
to define logs

Change-Id: I75820f9f19f876d9fb91b977f56e205b3e275444
CRs-Fixed: 2841584
2020-12-22 14:41:30 -08:00
Shiva Krishna Pittala
ee5f45a176 qcacmn: Read the Direct Buf Rx tail pointer in the Host order
Direct Buf Rx has a source ring to communicate with the target.
The target updates its tail pointer in little-endian format and this update
doesn't go through any byte-order conversion at the target. On a big-endian
Host platform, this tail pointer will be read in reverse order of bytes.
To fix this, convert the tail pointer to the Host order before using it.

Change-Id: Ibcaf3d7507910ea81eeb895772241ab9861ee45a
CRs-Fixed: 2843259
2020-12-22 10:44:16 -08:00
Shikha Bakshi
c1e00a21ba qcacmn: Modify logs for QDF_MODULE_ID_DP_PEER
Add macros dp_peer_info, dp_peer_info_low,
dp_peer_info_high, dp_peer_alert, dp_peer_err,
dp_tx_capture_debug to define logs.

Change-Id: Icf71595c10b1a4f0dca53f6953af4df19210e924
CRs-Fixed: 2832004
2020-12-22 06:40:31 -08:00
Shikha Bakshi
89662c1eeb qcacmn: Modify Logs for QDF_MODULE_ID_DP_INIT
Add macros like dp_init_debug, dp_init_err, dp_init_info, etc. to
define logs

Change-Id: I5b0f48b2f0b4b5d6be19850e2fff928672d09ad1
CRs-Fixed: 2837411
2020-12-22 06:40:26 -08:00
Shikha Bakshi
795eb11c9b qcacmn: Modify logs for QDF_MODULE_ID_DP_RX_ERROR
Add macros dp_rx_err_info, dp_rx_err_debug, dp_rx_err_err,etc.
to define logs

Change-Id: I0dc4810412f9ed238708850de12b5d5730e9fa4b
CRs-Fixed: 2830612
2020-12-22 04:43:55 -08:00
Shikha Bakshi
7cdc796f7e qcacmn: Modify logs for QDF_MODULE_ID_DP_RX_MON_DEST
Add macros dp_rx_mon_dest_info, dp_rx_mon_dest_debug,
dp_rx_mon_dest_err,etc. to define logs

Change-Id: I2a016ee8e3e74b745e776f1f7266d94bb9698892
CRs-Fixed: 2830629
2020-12-22 02:45:52 -08:00