Commit Graph

864 Commits

Author SHA1 Message Date
Hariharan Basuthkar
9f2a6a4040 qcacmn: Add wmi_support to send AFC cmd to the FW
Add Host WMI APIs to send the WMI_AFC_CMDID to the FW.

Change-Id: I6849826ab4596f3c76b2dea3cb76116be46b4dd6
CRs-Fixed: 2985645
2021-07-08 04:50:04 -07:00
Alan Chen
a390375589 qcacmn: Add resource config flag to enable dynamic_pcie_gen_speed
Add resource config flag to enable dynamic_pcie_gen_speed.

Change-Id: Ieb61ca183b7544aa31dee08f047da1de8bfec21f
CRs-Fixed: 2977084
2021-07-07 06:41:49 -07:00
Aakanksha Doda
e175d5124c qcacmn: Add cmn_dev changes to get ANI status from FW
Add changes to send a command and in return, get an event
giving ANI status from FW.

Change-Id: I327e6134fef17bc4dc98b99d1ca4bc4d0a039625
2021-07-06 06:53:43 -07:00
Surya Prakash Raajen
86ea3e3a8f qcacmn: Add enum support for soft chainmask
TLV targets support updating tx chainmask(soft-set) using 
PDEV_PARAM_TX_CHAINMASK param. Update host enum accordingly to
use this for setting soft chainmask.

Change-Id: Ic5362fb8c79f07cbd83328b786b5930f75d2a084
CRs-Fixed: 2976914
2021-07-06 04:38:45 -07:00
abhinav kumar
96f19b772c qcacmn: Add support to print candidate rssi in kmsg
First Requirement:
In case of WTC_BTM roam trigger reason, if FW reports rssi
threshold for 5G and 6G AP via wmi_roam_trigger_reason,
Host should print it in kmsg.

If wtc_candi_rssi_ext_present is set (1), It means fw
reports 5g and 6g candidate rssi (new firmware case).
If wtc_candi_rssi_ext_present is clear (0), It means fw
doesn’t report 5g and 6g candidate rssi (old firmware case).

Host use flag "wtc_candi_rssi_ext_present" to keep backward
compatibility.

Second requirement:
As per user space, value for scan mode in WTC command, is
like below:
0: no Scan, 1: partial scan and 2: full scan.

For NO scan case, FW sends value
ROAM_TRIGGER_SCAN_MODE_NO_SCAN_DISCONNECTION (3)
in wmi_roam_trigger_reason-> wtc_scan_mode. When driver receives
WTC scan mode as ROAM_TRIGGER_SCAN_MODE_NO_SCAN_DISCONNECTION,
it should print value as 0 instead of 3.

Convert WTC scan mode comes from FW to
wmi_configure_roam_trigger_parameters->scan_mode to make it
compatible to WTC command.

Change-Id: I8266460aac1272d345e4349c2ca52b4f9a745d4c
CRs-Fixed: 2965362
2021-06-29 12:45:46 -07:00
Paul Zhang
fa7cf78ebf qcacmn: Rate limit wmi ext2 service null error log
For some platform, ext2 service bitmap is not supported. So rate
limit the wmi ext2 service bitmap NULL error log to avoid
excessive console logging.

Change-Id: I383632669e4e4a59dd9e6e3ce82626a7cd3e42b3
CRs-Fixed: 2949180
2021-06-29 03:54:33 -07:00
Balaji Pothunoori
ae2a90d9fc qcacmn: add wmi service for tx aggregation support
Add wmi service to differentiate max tx aggr support
from firmware.

Change-Id: I2f9a4101815b06b41d4a75d888e30ee42b9307ec
CRs-Fixed: 2959207
2021-06-25 11:56:36 -07:00
Surabhi Vishnoi
6663105f9b qcacmn: Add support to handle wmi smart monitor event
Add functions to parse and extract wmi smart monitor
event received from target.

Change-Id: Ic18e3134b684c5f8e12839e997d628909a7e27c9
CRs-Fixed: 2969247
2021-06-25 09:40:32 -07:00
Hariharan Basuthkar
2234d80a72 qcacmn: Make 6G edge channel APIs common
Currently the 6G edge channel feature is MCC specific.
Make the 6G edge channel feature common for WIN and MCC.

Change-Id: I723b6db1d74dca5a911eede4ec6e6167f6b3e6bc
CRs-Fixed: 2976871
2021-06-25 07:20:05 -07:00
Kiran Venkatappa
8b5f8ef911 qcacmn: Add WMI MLO params for peer assoc command
New TLVs for MLO flags are introduced in peer assoc WMI
command. Add WMI changes to add these TLV in the peer assoc
command.

Change-Id: I366a96c973c3bedda03e4c370099ff809e0bd83d
CRs-Fixed: 2958851
2021-06-22 01:38:37 -07:00
Kiran Venkatappa
9b1509ec99 qcacmn: Add WMI MLO params for peer create command
New TLVs for MLO flags are introduced in peer create WMI
command. Add WMI changes to add these TLV in the peer create
command.

Change-Id: I38a129b30b366b6e3939231699f210d1bac362a1
CRs-Fixed: 2958849
2021-06-22 01:38:32 -07:00
Yu Wang
dcd269c55a qcacmn: enhance crypto api to install key synchronously
Add parameter 'bool sync' for wlan_cfg80211_crypto_add_key()
to indicate whether or not to add key synchronously.
If it's set to true, wait until install key complete event
is received.

Change-Id: I9a69d486665fb3f65a5720ccfbfb638c09329418
CRs-Fixed: 2865832
2021-06-21 23:14:27 -07:00
Abhishek Singh
f162bb1a8a qcacmn: Don't send MLO params in vdev restart request
Current FW implementation is not expecting MLO and partner link params
in vdev restart request. But host is sending these params as part of
vdev restart request. This is resulting in TLV count mismatch for vdev
restart request.

To resolve this, Don't send MLO and partner link params in vdev
restart request command.

Change-Id: Ied4572722c701ad7f53ac12727228a383e570433
CRs-Fixed: 2973256
2021-06-21 23:14:11 -07:00
Kiran Venkatappa
18a1a3d4a5 qcacmn: Add WMI MLO params for vdev start
New TLVs for MLO flags and partner link info are introduced in vdev
start WMI command. Add WMI changes to add these TLV in the vdev start
command.

Change-Id: Ic7d54c406f69346a6eedb43b1ebcf7266c448bd8
CRs-Fixed: 2958843
2021-06-17 20:09:45 -07:00
Kiran Venkatappa
923cd4dea9 qcacmn: Add WMI vdev create params for MLO
WMI vdev create is changed to incude mlo macdress as one of TLV.
Add changes in WMI vdev create send API to include this new TLV.

Change-Id: Ia13bdb8fbfc9f68d1e4c0209201f9acc4f575387
CRs-Fixed: 2958839
2021-06-17 20:09:40 -07:00
Jia Ding
2f7b7dbabf qcacmn: Set max EHT rate set to 4
802.11BE D1.0 9.4.2.295c.4 Supported EHT-MCS And NSS Set
field specifies maximum 4 optional EHT MCS map, which are
20 MHz-Only STA, BW <= 80 MHz except 20 MHz-Only STA,
BW = 160MHz and BW = 320 MHz.

Therefore set WMI_HOST_MAX_EHT_RATE_SET to 4.

Also add a debug message to log peer_flags_ext.

Change-Id: I3d56998bf0de381ef147d6c0551dcdb7fd935f60
CRs-Fixed: 2963536
2021-06-14 06:28:20 -07:00
Venkateswara Swamy Bandaru
55279efffb qcacmn: Add 320MHz bandwidth chanimask extraction support
Add 320MHz bandwidth chanimask extraction support in WMI for
ext serveice ready event.

Change-Id: I84195ee559640c3747c56c49112de152796f0ded
CRs-Fixed: 2952302
2021-06-08 10:23:49 -07:00
Srikanth Marepalli
6a7cbdde53 qcacmn: Add the support for SAE EAPOL handshake offload
Set the SAE EAPOL offload support in resource config based on
WMI_SERVICE_SAE_EAPOL_OFFLOAD_SUPPORT bit received in service
bitmap from Firmware.

Change-Id: I878736105c070df514dfe8d989541227b3baad11
CRs-Fixed: 2957082
2021-06-07 22:54:50 -07:00
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
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
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
Venkateswara Swamy Bandaru
38f2c1baf2 qcacmn: WMI changes for setting eht op
Add WMI support for setting eht op in vdev start wmi command.

Change-Id: I7eb0e7e5ace9d78dd060e207c3227d86c3882bee
CRs-Fixed: 2858003
2021-05-11 08:03:27 -07:00
Utkarsh Bhatnagar
141c21c4a7 qcacmn: Add support for TDLS 11ax
Add support for TDLS 11ax

Change-Id: Iec8d9d7356390c6012269ae2840ff2185f61f9da
CRs-Fixed: 2925247
2021-05-10 09:03:12 -07:00
Guisen Yang
3516552a3c qcacmn: Disable obss scan before suspend
When obss scan is enabled, FW will trigger scan periodically by
a timer. If a scan was triggered, FW need to access host memory
for data transfer. Occasionally, suspend may happen during one
scan, then FW is unable to access host memory and fw will crash.
So disable the obss scan before suspend.

Change-Id: Ie507da929a3701473cb57888e96e702e34d4c95a
CRs-Fixed: 2927239
2021-05-10 04:06:03 -07:00
Bapiraju Alla
17f12e5b39 qcacmn: Fill peer assoc mlo params in peer assoc request
Fill peer assoc mlo params in peer assoc request command.
Also add definitions to the WMI_SERVICE_11BE.

Change-Id: Ied7959e022ee27f3bd698b84dc801491175f85b3
CRs-Fixed: 2934417
2021-05-05 04:47:01 -07:00
Srinivas Girigowda
216b52af2f qcacmn: Add debug logs in cp_stats event path
In the issue reported, the clear stats request from the
user space is timing out because event id from firmware is not received.
From the logs it is not clear whether host driver received it or dropped
it in the error path.

Add debug logs, to make sure cp_stats event id is received in the host
driver and also in error cases.

Change-Id: I634714281db4a82826791725ec38fd589334cde8
CRs-Fixed: 2926978
2021-04-20 17:05:51 -07:00
Shwetha G K
23d574115e qcacmn: Support to get dpd status from FW
WMI changes to rerieve current dpd status from target.

CRs-Fixed: 2885488
Change-Id: Iddfcbf63fccac87b52d3ac242ba078f8210cb6d0
2021-04-19 05:06:55 -07:00
Vulupala Shashank Reddy
0e7182e1ca qcacmn: Extract TSF time stamp for mgmt rx packets
Extract TSF time stamp for mgmt rx packets.

Change-Id: Id76048d79ea1937c002479314e83b40da807771b
CRs-Fixed: 2916738
2021-04-14 00:52:25 -07:00
Priyadarshnee Srinivasan
2b51168ba8 qcacmn: Add 11BE wireless mode and NO11BE phybitmap
Extract the 11BE flags advertised by FW in WMI_SERVICE_READY_EXT2_EVENTID
and update the regulatory pdev wireless modes. The wireless mode is
currently represented as 'uint32_t' and all the 32 bits are exhausted.
To accommodate the new 11BE flags, change the data type of wireless_modes
from 'uint32_t' to 'uint64_t'.

Add a regulatory phymode 'REG_PHYMODE_11BE' in enum reg_phymode.

If the chip does not support 11BE phymode, FW advertises it via
WMI_REGULATORY_PHYBITMAP enum with a value of REGULATORY_PHYMODE_NO11BE.
Extract the phybitmap and store it in the regualtory
as 'REGULATORY_PHYMODE_NO11BE' bitmap.

CRs-Fixed: 2901260
Change-Id: I4ed3fc7c907b1f76e59efb347c747acea2a163b0
2021-04-12 05:42:52 -07:00
Venkateswara Swamy Bandaru
216478aaae qcacmn: EHT changes as per latest fw cmn headers
Updated the EHT related variables as per latest fw cmn headers.
Address review comments from previous EHT gerrits.

Change-Id: I67cd58a4efcf3e06d2ca3b5570432593b1d80825
CRs-Fixed: 2902607
2021-04-05 04:45:25 -07:00
Venkateswara Swamy Bandaru
a8e24fd6c0 qcacmn: Add 11be support WMI peer assoc command
Add 320Mhz band width support and EHT capabilities information in
WMI peer assoc command.

Change-Id: Ie4ee95fb1790c828275e90b384b2bdc04efb3f29
CRs-Fixed: 2882054
2021-04-04 04:55:43 -07:00
Venkateswara Swamy Bandaru
11f4850bfd qcacmn: Initialization changes for 11be
EHT capapilities will be received as part of ext2 service ready message.
Update the structure as per firmware common header file and extract the
EHT capabilities field.

Change-Id: Id2dd170db4de588008742f95493d4d06a6431f1c
CRs-Fixed: 2857802
2021-04-01 06:11:30 -07:00
sheenam monga
937c5c5af7 qcacmn: Read fw capability to offload igmp
Read fw capability to support igmp offload

Change-Id: I87ff7b07a5add99d8e9f8234912b656e5b866569
CRs-Fixed: 2904971
2021-03-31 12:06:55 -07:00
Aditya Sathish
e15153c092 qcacmn: Add WMI service support for DCS AWGN
Add support to read the WMI service bit describing support
for the DCS AWGN interference detection mechanism.

CRs-Fixed: 2906768
Change-Id: Id062b9d63a09f522ac1efdbaf6731665fa438630
2021-03-30 01:46:56 -07:00
Gururaj Pandurangi
08148f21fa qcacmn: Enable/Disable 6G edge channels ch2 and ch233
Enable lower 6G edge channel ch2 (5935MHz) for APL2 6G regdmn
using a service bit WMI_SERVICE_ENABLE_LOWER_6G_EDGE_CH_SUPP,
which is not enabled by default.
Also, disable upper 6G edge channel (7115MHz) using another
service bit WMI_SERVICE_DISABLE_UPPER_6G_EDGE_CH_SUPP, that
is enabled by default.

Change-Id: Ia7cb7f7d3165375178adbe70adb19b8671496b6d
CRs-Fixed: 2885623
2021-03-12 02:52:25 -08:00
Priyadarshnee Srinivasan
d617a3a77f qcacmn: FW-Host Handshake for REG_CHAN_LIST_CC_EVENT
In order to support different power levels of 6G AP and client,
the channel list event from FW namely "REG_CHAN_LIST_CC_EVENTID"
is modified to add few parameters specific to 6GHZ devices.
Hence the existing event is replaced by REG_CHAN_LIST_CC_EVENT_EXT for
all 2G/5G/6G pdevs in FW. Therefore, after the service ready event, FW
sends the channel list for the configured country/regdomain via
REG_CHAN_LIST_CC_EVENT_EXT. This mandates that all host software need
to have the processing capability of REG_CHAN_LIST_CC_EVENT_EXT to bring
up the AP.

As there can be host software which has not yet implemented the
version of "REG_CHAN_LIST_CC_EVENT_EXT", backward compatibility is lost
if "ONLY REG_CHAN_LIST_CC_EVENT_EXT" is sent by FW.
Hence a 3 way handshake between host and FW is established.

1. FW advertises its capability of processing REG_CHAN_LIST_CC_EVENT_EXT
id via wmi service bit 'wmi_service_reg_cc_ext_event_support'.
2. If the host is capable of processing the "REG_CHAN_LIST_CC_EVENT_EXT"
event id (which is done based on registration of this event), host
sends the capability in WMI_INIT_CMDID setting a bit in host_service_flags.
3. Based on host capability advertised in WMI_INIT_CMDID, FW decides to
send the old event ("REG_CHAN_LIST_CC_EVENTID") or the new event
("REG_CHAN_LIST_CC_EVENT_EXT").
4. If there is no flag indicated by host to FW in WMI_INIT_CMDID, FW
by default sends the old event ("REG_CHAN_LIST_CC_EVENTID").

CRs-Fixed: 2876360
Change-Id: Ibe95f414ad9fff0e5641bcc6e60450ef9afe245b
2021-03-11 19:43:58 +05:30
Bapiraju Alla
7f0008db3f qcacmn: Add service bit support for LL_GET_STA command over QMI
For some targets, FW expects WMI_REQUEST_UNIFIED_LL_GET_STA command
always over QMI irrespective of WOW state. FW will crash if this request
is sent over WMI on those targets. Currently there is no direct way for
the host to identify this requirement by FW. So FW may crash when this
WMI_REQUEST_UNIFIED_LL_GET_STA stats request is sent over WMI.

To resolve this, add service bit support for LL_GET_STA request over QMI.
With this change the INI parameter send_ll_and_get_station_stats_over_qmi
becomes obsolete and corresponding code will be removed.

Change-Id: I43f2827a0b1cae6e75f1224f452f8277d53736b2
CRs-Fixed: 2847483
2021-02-23 05:31:18 -08:00
Hariharan Basuthkar
5af6064a0c Revert "qcacmn: Fix reg rule parsing order"
This reverts commit I5bb22a1dcd3f1c95d8f4498b03d6cc6eedcfe44c.

Change-Id: Ib7bf273a53f382da36106eab0a1b26af33d35a65
CRs-Fixed: 2880944
2021-02-20 23:34:56 -08:00
Abhishek Ambure
cd38c6bd4e qcacmn: Add host support for OCV service supported by FW
FW advertises WMI_SERVICE_OCV_SUPPORT bit in service ready event if
firmware supports Operating Channel Validation feature.

Change-Id: Ida1ee9874f9cd32a684ceee728e3323306137c64
CRs-Fixed: 2880794
2021-02-19 05:40:14 -08:00
Lincoln Tran
98c5d1eef3 qcacmn: Register NDI tx beamform support bit
Add WMI service bit handling for NDI beamforming support.

Change-Id: Ib1a4dc0042510137412f3ad4ded61ea680596978
CRs-fixed: 2876723
2021-02-18 05:35:10 -08:00
Gururaj Pandurangi
8492c0f971 qcacmn: Add service bit to support backward compatibility
The host will send TPC power to FW via the new WMI cmd
WMI_VDEV_SET_TPC_POWER_CMDID going forward instead of
WMI_VDEV_PARAM_TX_PWRLIMIT to accommodate 6GHz channels.
But, to support backward compatibility for New Host+old FW
the TPC power will be sent to FW via legacy WMI cmds
WMI_VDEV_SET_PARAM_CMDID (during initial connection) or
WMI_VDEV_PARAM_TX_PWRLIMIT (power value change during RRM
req/bcn processing from connected AP) with the help of a
service bit WMI_SERVICE_EXT_TPC_REG_SUPPORT.

Change-Id: Iea1ecb62841c539c13a804ae9c475831b2d4c89c
CRs-Fixed: 2874250
2021-02-16 23:52:09 -08:00
Lincoln Tran
b16b4608c3 qcacmn: Fix reg rule parsing order
Currently, reg rules are processed in the order of LPI, SP, VLP. The
order from halphy is SP, LPI, VLP. Update the processing order so
correct reg rules are passed north.

Change-Id: I5bb22a1dcd3f1c95d8f4498b03d6cc6eedcfe44c
CRs-fixed: 2874752
2021-02-16 17:02:38 -08:00
Kai Chen
2667f112d8 qcacmn: Add CBF support for pktlog
Fix issue on enabling packet log.
Fix issue on logging CBF pkt in AP/STA mode.
Fix issue on setting data length 4 bytes aligned in pktlog header
, htt stats indication message header and Rx management TLV header.
Add CBF support for pktlog WMI enable command for firmware to enable
CBF receive.

Change-Id: Ib0067f32d7414be96503c4c67846c1312a59586e
2021-02-10 20:27:29 -08:00
Srinivas Girigowda
14bfc9057c qcacmn: Move ctrl_path_twt_stats functions to appropriate files
Move ctrl_path_twt_stats related functions to appropriate source
and header files.

CRs-Fixed:  2871393
Change-Id: I7043259c102e5aee6cbb13260ce2bb0c53c17853
2021-02-05 14:11:10 -08:00
Rajeev Kumar
5f5eda6e0e qcacmn: Set SAP and P2P GO D3 wow host WMI resource config
Set SAP and P2P GO D3 wow host WMI resource config such that
FW is aware of host capability and can allocate memory for
sufficient remote peers.

Change-Id: I05499f98bd6bc080a9aefb302be12873bf19ac35
CRs-Fixed: 2869055
2021-02-05 02:50:36 -08:00
Rajeev Kumar
afdf38701e qcacmn: Add WMI service handling for SAP and GO D3 wow
Add WMI service bit handlign for SAP and GO D3 wow mode
feature support.

Change-Id: I88efbf51d4cb0005f81ad86068f3278457f4eb05
CRs-Fixed: 2869065
2021-02-05 00:30:59 -08:00
Nandha Kishore Easwaran
a10cd5facf qcacmn: Swap bytes of ftm data in BE platform
Swap each word of ftm data before sending to FW.
This is needed since copy engine swap is enabled for big endian platform
and ftm data needs to be given to FW in network byte order.

Change-Id: I90b90adf77d92d254478605668efd94972c4129c
2021-01-31 00:48:48 -08:00
Abdul Muqtadeer Ahmed
96f3c808f1 qcacmn: Add pci gen switch in wmi resource config
Add a pci gen switch flag in the wmi resource config to send
to FW in the init command.

Change-Id: If3a50d80103387a8f1f77ecb43a16c7b41ce5a11
CRs-Fixed: 2865866
2021-01-29 20:57:19 -08:00
Mainak Sen
16c8160755 qcacmn: Mesh TID latency configuration for Pdev/Vdev/Peer
WMI changes for Mesh low latency support for pdev/vdev/peer

Change-Id: Id2bf0a9b5f121ca6e91f47c209a4b5271952147f
2021-01-25 02:18:03 -08:00
Srinivas Dasari
c69a4facac qcacmn: Get WAPI concurrency capability from firmware
Firmware advertises service capability WAPI_CONCURRENCY_SUPPORTED
if it supports other security modes when WAPI is active. Get the
same from service capabilities to decide whether to accept a
new concurrent connection or not.

Change-Id: I718503e52be2dda8ebd440f5a68b496d846b6ffc
CRs-Fixed: 2858770
2021-01-25 00:06:19 -08:00