Commit Graph

8769 Commits

Author SHA1 Message Date
Neha Bisht
466c04dee9 qcacmn: remove dependency of public files from wlan_objmgr_psoc_obj.h
Remove dependency of wlan_lmac_if_def headerfile from
wlan_objmgr_psoc_obj.h

Change-Id: Ida8472e6f05a90b3930b5a13a2bf89ea8b3e938f
2020-05-15 10:41:46 -07:00
Neha Bisht
9e2bd0589d qcacmn: lmac header exclusion from wlan_objmgr_psoc_obj.h
Avoid inclusion of wlan_lmac_if_def headerfile in
wlan_objmgr_psoc_obj.h which led to inclusion of several
other components header files, so handling dependencies by
adding a forward declaration.

Change-Id: I9ad231152789a1d8d9c01fd772abe4a8b06ad0b4
2020-05-15 10:41:41 -07:00
Abhinav Kumar
395336f2f9 qcacmn: Add iface changes to enable/disable FT-IM in FW
With specific AP(s), FW needs to perform FT initial mobility
association instead of FT roaming for deauth roam trigger.

Add iface changes to configure "FT initial mobility roaming
for deauth roam trigger" behavior from the HOST.

Change-Id: I695a36b66a7a53e8d08526c065a9530196646184
CRs-fixed: 2665885
2020-05-15 06:56:19 -07:00
Alok Kumar
37307abc04 qcacmn: Add FISA support for qca6750
Add FISA feature support for chip 6750

Change-Id: I0ca082b7b4ca71e2b2d18678a0ce10b7b46bbc28
CRs-Fixed: 2667283
2020-05-15 06:56:15 -07:00
Yeshwanth Sriram Guntuka
6159db7efa qcacmn: Reset tx desc as part of flow pool delete
Tx desc flow pool for the vdev is not deleted as part
of disconnection due to tx_desc pending to be processed
in tx comp ring. Hdd_stop is triggered immediately after
this causing dp vdev detach. In parallel, the tx desc
from the tx comp ring is processed, wherein stale vdev
address is derefernced to get dp soc causing page fault.

Fix is to reset tx desc by setting the vdev to NULL as
part of dp_tx_delete_flow_pool and also reset count to
zero in dp_tx_comp_handler before ring desc process loop.

Change-Id: I66f718668ba84f89106d09e624d9593f89479e55
CRs-Fixed: 2683874
2020-05-15 00:36:54 -07:00
Jinwei Chen
e1c2e73b6c qcacmn: move vdev_id_map[vdev_id] null setting after dp_rx_vdev_detach
In dp_vdev_detach_wifi3(), the vdev_id_map[vdev_id] set to
null is happened before dp_rx_vdev_detach(). but the call back
done by dp_rx_vdev_detach still need to get the vdev pointer by
vdev_id, it will return NULL by current logic.
  Move vdev_id_map[vdev_id] null setting after dp_rx_vdev_detach().

Change-Id: Ibaf506cfef83d68a21033e67395c37f53aeb4489
CRs-Fixed: 2681712
2020-05-15 00:36:50 -07:00
Linux Build Service Account
e1b2780845 Merge "qcacmn: Add full monitor attach/detach API" 2020-05-14 15:39:10 -07:00
Gerrit - the friendly Code Review server
7ca5bbcd01 Merge changes into wlan-cmn.driver.lnx.2.0 2020-05-14 15:35:21 -07:00
Amir
61ea84b2cb qcacmn: Add full monitor attach/detach API
Add full monitor attach/detach API

Change-Id: I16b52d8ffe2949f43a18bb5d00c3997a1447dac4
CRs-Fixed: 2685408
2020-05-14 14:46:04 -07:00
Jinwei Chen
c1ab9eee8e qcacmn: add exception frame flag in qdf_nbuf_cb
add exception frame flag in qdf_nbuf_cb structure.

Change-Id: I97f61973cc1c0d00fe66cc0e8aac0c7b4b16bb56
CRs-Fixed: 2680255
2020-05-14 13:04:23 -07:00
Jinwei Chen
800b1b181b qcacmn: add exception frame flag for non-regular RX delivery
FISA RX aggregation is not necessary for non-regular RX delivery
as it requires extra FISA flush and also may impact regular
dp_rx_process() RX FISA aggregation.
  Add exception frame flag for non-regular RX delivery, so that
FISA path can identify this frame and bypass FISA RX.

Change-Id: Ic06cb72b516221754b124a673ab6c4f392947897
CRs-Fixed: 2680255
2020-05-14 13:04:20 -07:00
Padma Raghunathan
d38acd0c2f qcacmn: Fix access to rx mpdu start tlv
MPDU start TLV structure is different across pine and hk/cyp. The
access to individual members of this structure is already taken care
in HAL APIs.

Tha addition of offset is redundant and wrongly defined offset values
led to wrong interpretation of mpdu start tlv fields like RSSI in
QCN9000.

Change-Id: I3c0daa1c9117eecd1566a1d52d794e92dc292fa4
CRs-Fixed: 2682570
2020-05-14 07:05:01 -07:00
Linux Build Service Account
ef5e85c3d9 Merge "qcacmn: Add debug info support for rx descriptors" 2020-05-13 13:39:57 -07:00
Gerrit - the friendly Code Review server
8049e94b75 Merge changes into wlan-cmn.driver.lnx.2.0 2020-05-13 13:33:56 -07:00
Yeshwanth Sriram Guntuka
8a2c60e8f5 qcacmn: Add debug info support for rx descriptors
Add debug info support for rx descriptors to log
the caller func name and timestamp in replenish
and free scenario.

Change-Id: I1d9b855d14f705094f241bae653f33a94d0e39b7
CRs-Fixed: 2677288
2020-05-13 12:39:51 -07:00
Jianmin Zhu
6f95b4aadb qcacmn: Force wake PCIe for hsp register write
make sure both PCIe and device are force woken for the register
writes for hsp, or write may fail.
Earlier WAR is not required as we have root caused it.

Change-Id: I350b810a6cef8eec46428e57f5b779f888552c1b
CRs-Fixed: 2677342
2020-05-13 08:37:42 -07:00
Basamma Yakkanahalli
0307ee6023 qcacmn: Add support to configure tso and reo desc for ipq5018 target
Added support to configure TSO and REO descriptors as part
of new datapath init-deint enhancement for ipq5018 target.

Change-Id: Ic6878dafa99cb09d6e45cf2d69de76cac0fe35c1
2020-05-13 08:37:38 -07:00
Surabhi Vishnoi
a994b57d2b qcacmn: Add support to provide higher range mem chunks in wmi init command
With the current implementation of wmi init command,
there is no provision for the host driver to provide mem
chunks addresses with more than 32-bit, to the firmware.
WCN3990 is a 35-bit target and can accept mem chunks addresses
which are above 32-bit.
If firmware supports address range more than 32 bit, it
advertises the support by setting the WMI_SERVICE_EXTEND_ADDRESS
service. Based on this service fill the upper bits of paddr while
providing the mem chunks in the wmi init command.

Change-Id: Id65eb03d8f5cec5b9f16e24287a45a86433ab970
CRs-Fixed: 2678069
2020-05-13 06:46:06 -07:00
Prathyusha Guduri
dcb2fc98f6 qcacmn: Add Tx desc limit check for exception packets
Soc level exception descriptors limit is sent from FW in WMI service
ready TLV. Using that to check for exception packets limit

Change-Id: I99d20ecbb6a5bfd61b5a8a205775d34749eae880
2020-05-13 06:46:01 -07:00
Chaithanya Garrepalli
4fb5635434 qcacmn: in dp peer teardown add check of AP bss peer
In dp_peer_teardown avoid setting the delete in progress
flag only for AP bss peer

For STA bss peer as CP always allocated new peer for peer_create
set delete in progress in teardown

Change-Id: Id769678895a0953e731ce040399af7bddd4c373d
2020-05-13 04:57:17 -07:00
Edayilliam Jayadev
abdb33bb00 qcacmn: Add start scan response WMI event
Add support for processing the start scan response
WMI event. FW provides the necessary information to
segregate FFT bins to pri80, 5 MHz and sec80 in
160/165 MHz. Also, cfreq2 and the channel width is
provided to FW via WMI command.

CRs-Fixed: 2672081
Change-Id: I666b6c18a63d5d01117aa9cbd611691c6f8b2793
2020-05-13 01:30:40 -07:00
Nandha Kishore Easwaran
18bbaf7484 qcacmn: Add unique irq name per pci slot
Added unique irq name per pci slot so that affinity settings
can be altered as needed. Pci id will be read from dts, and
when there is no entry in dts, default value 0 will be used.
Also for all other target types except qcn9000, default value
0 will be used.

If WLAN_MAX_PDEVS is defined to 1, then always return pci id as
0 since there is only one pdev present

Change-Id: I8159ec8d8daecae687fcc286d620bfe9861dff98
2020-05-13 01:30:37 -07:00
Vulupala Shashank Reddy
f3d1f2a4be qcacmn: Delete older PMK of all APs which have the same PMK
Currently when supplicant sends set_pmkid_cache (Either after
initial connection or after session timeout with AP) to host to
set the new pmkid derived after the EAP is done. Host deletes
PMK entry only if bssid/ssid matches.
For OKC, the PMK derived from the initially associated AP will
be used for deriving PMKID for all APs. In case of connection with OKC
supported APs, If STA receive session timeout from AP, HOST should
delete older PMK of all APs which have the same PMK. Else While
roaming HOST could send older PMK to OKC supported AP and this
results PMK flush in FW and leads to full EAP.

Change-Id: I83e8d4c0c8b3ad503aa5894ffdc4a14bc3aeec7a
CRs-Fixed: 2679749
2020-05-13 01:30:33 -07:00
Hariharan Basuthkar
d9ac920d7d qcacmn: Fetch phybitmap from regulatory
Add an API wlan_reg_get_phybitmap, to retrieve the phybitmap from the
regulatory pdev_priv_obj->phybitmap.

Change-Id: Ie03ab69b2378f7243bbacc15c71007cdf0386ef6
CRs-Fixed: 2675030
2020-05-12 23:37:06 -07:00
Hariharan Basuthkar
9076fa7386 qcacmn: Convert WMI_REGULATORY_PHYBITMAP to REGULATORY_PHYMODE
When Host receives the WMI_REG_CHAN_LIST_CC_EVENT from the target,
the regulatory phymode bitmap is of the type WMI_REGULATORY_PHYBITMAP.

Convert WMI_REGULATORY_PHYBITMAP values to REGULATORY_PHYMODE values
in extract_reg_chan_list_update_event_tlv, to use it internally in
the Host.

Change-Id: Id2e37989e13007f60cf92d02c282c84407501d5f
CRs-Fixed: 2679640
2020-05-12 23:37:02 -07:00
Hariharan Basuthkar
b38a8f8122 qcacmn: Update regdb based on database version 31
Update regdb with QCA regulatory database version 31 with following
changes:

1) Map Andorra to ETSI1_WORLD for WIN and DSRC, and ETSI13_WORLD for MCC.
2) Map Armenia to APL4_WORLD for WIN, and ETSI4_WORLD for DSRC and MCC.
3) Enable 40, 80 and 160 MHz BW support for Armenia.
4) Enable 40, 80 and 160 MHz BW support for Bahrain.
5) Add Indoor flag in lower bands for APL15.
6) Map Bolivia to FCC8_WORLD for WIN  and FCC3_WORLD for MCC.
7) Map Brunei to FCC8_WORLD for WIN and FCC3_WORLD for MCC.
8) Map Ecuador to FCC3_FCCA for WIN and MCC.
9) Enable 40, 80 and 160 MHz BW support for Ecuador.
10) Map El Salvador to FCC3_WORLD for WIN and MCC.
11) Enable 40, 80 and 160 MHz BW support for El Salvador.
12) Map Japan to MKK17_MKKC for MCC and DSRC.
13) Map Kuwait to ETSI1_WORLD for WIN and ETSI13_WORLD for MCC and DSRC.
14) Map Sri Lanka to FCC3_ETSIC for WIN, MCC and DSRC.
15) Enable 40, 80 and 160 MHz BW support for Sri Lanka.
16) Map Yemen to ETSI1_WORLD for WIN, MCC and DSRC.
17) Enable 40, 80 and 160 MHz BW support for Yemen.
18) Remove 40/80/160 MHz channels support in ETSI11.

Change-Id: Ieba86cb99f6963432777cd6aaa6ffb6b3e72b657
CRs-Fixed: 2662186
2020-05-12 23:36:58 -07:00
Sourav Mohapatra
294b74babf qcacmn: Resolve compilation errors after disabling DEBUGFS
On disabling debugfs, there are various compilation issues
involving missing stub functions and incorrect declarations.

In this change, resolve those issues.

Change-Id: I7b3047dac2aaf4eb68c64505186ca51e22ab0928
CRs-Fixed: 2670460
2020-05-12 15:36:27 -07:00
Kiran Kumar Lokere
1413ea8e1e qcacmn: Add support to handle HE 6GHz duplicate beacon
Check HE 6GHz duplicate beacon in scan results and do not
drop the beacon due to channel mismatch.

Change-Id: If095c18e4ad377a5909c9460fceaa47a2a768ce0
CRs-Fixed: 2654483
2020-05-12 15:36:24 -07:00
Tallapragada Kalyan
c053dca35b qcacmn: change minimum buffers in rxdma monitor buffer ring
With the init/de-init FR we set the minimum buffers
needed in monitor buffer ring to be 8, because the low
threshold by FW is set to 32 the MPDU TLVs are not DMA'd
to monitor status ring, this resulted in NAC feature
regressed. hence changing it from 8 to 64

Change-Id: Id39dce59686b7416bdc6156798ff7f948dff8da6
CRs-Fixed: 2683633
2020-05-12 15:36:20 -07:00
Ananya Barat
4a127a8976 qcacmn: Get max 5G bandwidth from country code or regdomain pair
If the country code is present, from the country code get the country
index in g_all_countries. Then get the maximum 5G bandwidth supported
by the country. Otherwise, from the regdomain pair value, get the max
5G bandwidth that is supported by that regdomain.

One of the applications of the maximum 5Ghz bandwidth is the following:
Build the 80P80 channels only if 160 MHz bandwidth is supported by the
country

Change-Id: I9e09fdc3a9a276c75f3fc709ee041a47ec812516
CRs-Fixed: 2673083
2020-05-12 13:45:23 -07:00
Sandeep Puligilla
fa82264607 qcacmn: Fix array out of bound
The channel array is being over indexed by 1. Update the for loop
to stay within the array bounds, and make it more resilient in case
of future changes to the array size.

Change-Id: I09f140fdb6a25283db5d34d405bf030a67caefd5
CRs-Fixed: 2668363
2020-05-12 08:37:26 -07:00
nakul kachhwaha
7d9905ffd3 qcacmn: iot_sim add support for action frame
Adding support for action frame to identify category code and
action type and adding these rule to action frame specific data
structure

Change-Id: Ic1ca4e3d2f3d53502b3c9cca59b310b919a1f713
CRs-Fixed: 2669950
2020-05-12 08:37:11 -07:00
nakul kachhwaha
dc319f9559 qcacmn: add/del iot_sim content change rule to FW
Adding tgt API call from debugfs write handler
to add or delete content change rule in fw.

Change-Id: Ia77e008c4fa8f1b93bf3b93e0953bd29544a7d5c
CRs-Fixed: 2665476
2020-05-12 06:43:18 -07:00
Jayachandran Sreekumaran
77c068dda2 qcacmn: IOT SIM target interface
IOT SIM target interface updates

Change-Id: Ia9b048ecccd476df822e61f4ccb16e70352f630d
CRs-Fixed: 2665426
2020-05-12 06:43:14 -07:00
Jayachandran Sreekumaran
d281143698 qcacmn: IOT simulation module api
IOT simulation module api registration with umac.

Change-Id: I6f11781f79d5fc9ea28be02470ba288cdcbaa257
CRs-Fixed: 2659680
2020-05-12 06:43:11 -07:00
nakul kachhwaha
d20fe7aad4 qcacmn: Add debugfs support for iot_sim module
Following changes were done:
1. Adding debugfs functionality for iot_sim module
2. Changing the iot_sim context from psoc to pdev
3. Currently iot_sim support only bcast peer
4. Adding write handler to store user configured rules.

Change-Id: I4319bae3986874434f2a2e2397b1a8698c48d936
CRs-Fixed: 2657929
2020-05-12 06:43:07 -07:00
nakul kachhwaha
861af9fad3 qcacmn: Add files for IOT Simulation module
Adding files to support IOT Simulation module

Change-Id: I3c145f43e846ae5db032df748943c4d0ff531585
CRs-Fixed: 2657904
2020-05-12 06:43:02 -07:00
Vevek Venkatesan
516abea104 qcacmn: add HW version and name support for Hastings
Add support for HW version soc id and HW name string
for Hastings and HastingsPrime platform.

Change-Id: I1ba57339b2f9afd425e1ecc9f312ad484340d226
CRs-Fixed: 2681134
2020-05-11 11:44:11 -07:00
Sourav Mohapatra
3b4cb57737 qcacmn: Use wakeup_source_register when WAKEUP_SOURCE_DEV is def
Currently, the kernel APIs wakeup_source_register are used for kernel
version 4.19.110 and higher in sync with the upstream kernel. But in
downstream kernel, the same has been introduced from 4.19.80.

To accommodate compatibility with both, use a downstream compiler flag to
indicate when to use the kernel APIs.

Change-Id: I7c2d439aa8c859d92b4bbdbdd5034861c0c98e75
CRs-Fixed: 2679523
2020-05-11 05:24:36 -07:00
hqu
a4b218d195 qcacmn: Reset im stats and freq ctrl params when enable dcs wlan im
In the process of dcs disable delay, do restart(start/stop) SAP
operation, when SAP is started, it will send dcs cmd to enable
dcs wlan im again, but dcs_disable_timer is still running and
disable_delay_process is still true, dcs interference detection won't
work in time, after dcs_disable_timer timeout, it will set
disable_delay_process to false and dcs interference detection will
work again, but it will delay for some time from SAP started.

Fix is to reset im stats and freq ctrl params when enable dcs
wlan im.

Change-Id: I5be96b65037088c2797135a2b4c685c2826b2b57
CRs-Fixed: 2676033
2020-05-11 05:24:33 -07:00
Srinivas Dasari
e092863fce qcacmn: Configure burst duration as 0 when NDP is active
Currently, burst duration is configured as 240ms when NDI has
active NDPs. Firmware can go off-channel for scanning for this
duration which blocks data transfer. But some NDP based
applications(e.g. audio transfer) can tolerate a latency of
a maximum 120ms. So firmware can't go off-channel for
more than 120ms.
Configure burst duration as 0 when an NDP is active
to make sure firmware does non-burst scan and returns to NDP
channel within 120ms after scanning.

Change-Id: I33ca3a9d11c54b1173a3abd3ed7aa19c9c5662e5
CRs-Fixed: 2679038
2020-05-11 03:40:20 -07:00
Pavankumar Nandeshwar
788e43bfbd qcacmn: Assign appropriate size for hw_macid_pdev_id_map
Use appropriate size value MAX_NUM_LMAC_HW to make sure
that we have right size for hw_macid_pdev_id_map.

Change-Id: I3cbb1f83be54252c995e777392bb1c86a95239c1
2020-05-11 01:58:03 -07:00
Anirban Sirkhell
d7f7842cbe qcacmn: Fix compilation when HOST_OPCLASS is not defined
Match the type of the first parameter of the function
definition with the type of the first argument of function call.

CRs-Fixed: 2670065
Change-Id: Ifd9bd138caf5b3e0a547bc9a8bd2da38f0f8f675
2020-05-10 04:39:08 -07:00
Rakesh Pillai
37cc4255e2 qcacmn: Drain group tasklets and reg write work for runtime PM
Currently as part of runtime PM, only the active
tasklets are being drained. For chips eg. QCA6390,
QCA6490 etc, there are grp_tasklets and delayed reg
write work which has to be drained before entering
runtime PM.

Add the logic to drain all the possible tasks
before entering runtime PM.

Change-Id: Ieb486f00fffd7346dcdc1faea6fed5850ef6daf7
CRs-Fixed: 2676000
2020-05-08 20:27:43 -07:00
Christopher Chopp
5cf3d57f4e qcacmn: Move ppdu_user_desc peer check in tx cap tlvs
Move the ppdu_user_desc assignments in all tx capture
before peer checks. FW sends the peer_id which is not
valid in host, so this check is needed to not
miss the sequence number in this scenario.

Change-Id: I24305ae8f8f1964157ca61b8687fe72e76cde5ca
CRs-Fixed: 2626247
2020-05-08 16:10:50 -07:00
Ananya Gupta
4ef9913568 qcacmn: Cancel reap timer during driver unload
In case of driver unload, there can be a race condition
since the timer for processing monitor status ring can run
in parallel to the unload time wow ack response handler,
which is also flushing all the monitor status ring entries.
To avoid this race condition, stop the monitor reap timer
as a part of target suspend, and process all the outstanding
entries in the montior status ring.
This will make sure that the monitor status ring is
processed from only one context at any given time.

Change-Id: If61327c73fdddc414b3957b69ae986f2a26bb803
CRs-Fixed: 2677812
2020-05-08 14:25:48 -07:00
Sumedh Baikady
c86e8f9340 qcacmn: Replace legacy pdev id conversion with newer API
Remove the existing legacy pdev id conversion with
newer pdev id conversion used for lithium.

Change-Id: I3edbe5dd4e3964d8779efa54393f82da5a02ee6c
2020-05-08 14:25:44 -07:00
Priyadarshnee S
78bb108d7c qcacmn: Add a dispatcher API to determine if RCAC is supported
Add a dispatcher API ucfg_dfs_is_agile_rcac_enabled() to determine
if RCAC is supported for the given pdev.
Change the prototype of dfs_get_rcac_enable() to store rcac
config in a bool datatype.
Also, do a structure copy of ch_params of RCAC channel in
utils_dfs_get_rcac_channel().

CRs-Fixed: 2679975
Change-Id: I4b033463fc8111144bfffd3bb7e7d2bef6568c46
2020-05-08 09:07:13 -07:00
Gyanranjan Hazarika
edab7cf824 qcacmn: Define WMI_BEACON_TX_BUFFER_SIZE distinctly for WIN AP
The current value of WMI_BEACON_TX_BUFFER_SIZE imposes a limita-
tion on the size of the probe-response template that host can
send to target. This limit is good for offloading probe response
to target in case of soft-ap

WIN AP requires to support up to 16 VAPs in a single WIFI radio.
Also, 20TU probe response requirement for 6Ghz AP now requires
WIN AP to offload probe response

The current limit of 500 bytes is sufficient for soft-ap but does
not fulfill 16 6Ghz WIN AP requirement

Define WMI_BEACON_TX_BUFFER_SIZE for WIN AP as 1500 bytes

CRs-fixed: 2681235
Change-Id: I6251ee049451aa0c4a0482d772842a4f688b2f89
2020-05-08 07:33:47 -07:00
Adwait Nayak
270771642b qcacmn: CFR: Rectify the maximum capture length
In some scenarios, where cfr data is being captured
for maximum supported bandwidth case, memory allocated
in case of streamfs for all 255 buffers is not enough.

Corrections are made for maximum capture length.
Maximum capture length for a single CFR capture should be
(max bandwidth case) 16240B (112 bytes(csi header)
 + 64 bytes(cfr header) + 16064 bytes(cfr payload))

Remove debug logs under spin lock

Change-Id: I7cdc25350f3d85ecb7d0d69431c3c66dbc9b2bed
CRs-Fixed: 2678750
2020-05-07 13:03:50 -07:00