Commit Graph

716 Commits

Author SHA1 Message Date
Asutosh Mohapatra
f1a5f8d3ab qcacmn: Enhance QCA vendor interface with new hang reason codes
Add more hang reason codes for the hang reason in the
qca_wlan_vendor_hang_reason enum.

Change-Id: Ia7f21c45d58c980219690cda390127f5d4004391
CRs-Fixed: 3380849
2023-01-19 16:42:34 -08:00
Sreeramya Soratkal
266f87715e qcacmn: Validate status of spectral control request processed
Validate the result of spectral specific ucfg control operation
after processing the control request to get the spectral system
capability information.
Throw error if it is an invalid operation.

CRs-Fixed: 3308464
Change-Id: I11bbd3a9a9ffc8462e420946d54f06a11fad558e
2022-12-29 15:41:00 -08:00
Surya Prakash Sivaraj
06469b874f qcacmn: Allocate TLV for KCK based on KCK length
For roam auth vendor event to userspace, currently
16bytes of static memory is allocated for KCK. However,
latest security AKMs have higher KCK length.

Allocate the TLV based on the KCK length received from
firmware.

Change-Id: I2a869989a263f141a9b24a1fb9a97eb34889ac19
CRs-Fixed: 3346092
2022-12-28 00:47:44 -08:00
Himanshu Batra
5ea3ebf775 qcacmn: Change to handle ML reconfig link delete
Change to handle ML reconfig link delete

Change-Id: Iaf743a1a61534f2f4bb12be7fccad48e67b81c12
CRs-Fixed: 3346537
2022-12-27 11:08:54 -08:00
Harsh Kumar Bijlani
299c4870e5 qcacmn: Add new attributes in SCS rule config QCA vendor subcommand
Add new attributes for the destination MAC address and netdev index in
SCS rule config subcommand.

Change-Id: I8298d9e0080440fce7401fb931e1af42672711cf
CRs-Fixed: 3359591
2022-12-27 07:12:38 -08:00
Vijay Raj
2413e83ebd qcacmn: Add event response for green ap low latency pwer save mode
Add low latency power save mode event response for xpan
profile.

Change-Id: If3271c8a0ed649cd04b9060060706de9ec5764c1
CRs-Fixed: 3267486
2022-12-26 03:24:24 -08:00
Will Huang
e2da240791 qcacmn: Add AFC vendor event index
Add QCA_NL80211_VENDOR_SUBCMD_AFC_EVENT_INDEX for AFC event index.

Change-Id: I6b8314d616027e33e09da0b9cdc451a5ca6246d3
CRs-Fixed: 3341706
2022-12-20 20:30:47 -08:00
Rhythm Patwa
07bee8ee4e qcacmn: Define AFC vendor commands and events
Wi-Fi Alliance specification for Automated Frequency Coordination (AFC)
system ensures that the Standard Power Wi-Fi devices can operate in 6
GHz spectrum under favorable conditions, without any interference with
the incumbent devices.

Add support for vendor command/events and corresponding
attributes to define the interface for exchanging AFC requests and
responses between the driver and a userspace application.

Change-Id: I8c894236cdb3a33f6eae5dd43879fc84f29a80dd
CRs-Fixed: 3337619
2022-12-19 11:38:44 -08:00
Deeksha Gupta
3b44cf0785 qcacmn: Introduce new macro for TX control port changes
Introduce new macro to support TX control port changes in
host driver with cfg80211.

Change-Id: I1f557c62e225ce019a6ce3174ad2d897b39e0147
CRs-Fixed: 3342945
2022-12-16 03:29:05 -08:00
Vijay Raj
cb5c29865e qcacmn: Add QCA vendor interface for AP doze mode configuration
Add a new subcommand QCA_NL80211_VENDOR_SUBCMD_DOZED_AP to configure
doze mode state on an AP interface. This is also used as an event to
indicate the updated configuration. In doze mode, AP transmits
beacons at higher beacon intervals and RX is disabled.

Uses attributes defined in enum qca_wlan_vendor_attr_dozed_ap.

Change-Id: I183140f0466eb7400cc161afb8c2e295ec587f93
CRs-Fixed: 3267855
2022-12-15 12:40:33 -08:00
Chaoli Zhou
c0d40ef91a qcacmn: Fix 'struct wifi_pos_osif_ops' will not be visible issue
Fix the compile error: "declaration of 'struct wifi_pos_osif_ops'
will not be visible outside of wifi_pos_register_osif_callbacks"
when enable CONFIG_WIFI_POS_CONVERGED but disable the macro
WLAN_FEATURE_RTT_11AZ_SUPPORT.

Change-Id: Ib0043a109244d25368b7508b67b5b7b5c26cd3bf
CRs-Fixed: 3338198
2022-12-11 12:54:10 -08:00
Surya Prakash Sivaraj
dda3f7844b qcacmn: Add support for AKM 24
Add support for AKM 24

Change-Id: I7bd483afbe1659c56b6708085f0bfd1e1d5dd261
CRs-Fixed: 3299891
2022-12-09 07:32:52 -08:00
Srikanth Marepalli
93e8977721 qcacmn: Roam control configuration for 6 GHz in full scan only on prior discovery
During the roam scan, if there are no desired APs found in the partial
frequency list, an immediate full scan on all the supported frequencies
is initiated as a fallback. This would include the 6 GHz PSC
frequencies. Define an attribute to allow that behavior to be modified
to include PSCs only if 6 GHz use has been detected.

Change-Id: I81eb9b20c2953e6b0dbf4138b31547db82d7397f
CRs-Fixed: 3351706
2022-12-08 02:49:02 -08:00
Ashish Kumar Dhanotiya
0456b0a11e qcacmn: Add a new QCA vendor attribute to configure wifi calling (wfc) state
Add QCA_WLAN_VENDOR_ATTR_CONFIG_WFC_STATE vendor attribute,
Userspace uses this attribute to configure wfc state to
Driver/Firmware. Driver/Firmware uses this information to
optimize power savings, rate adaption, roaming, etc.

Change-Id: If58bd1e64216de81af6cf82eaabd740b85729eac
CRs-Fixed: 3343034
2022-12-07 05:50:37 -08:00
Srikanth Marepalli
8333f89c98 qcacmn: Add a vendor attribute for roam control configuration for full scan
During the roam scan, if there are no desired APs found in the partial
frequency list, an immediate full scan on all the supported frequencies
is initiated as a fallback. This flag controls the frequency list
creation for full scan on the following lines.
1 - Full scan to exclude the frequencies that were already scanned by
    the previous partial scan.
0 - Full scan to include all the supported frequencies irrespective of
    the ones already scanned by partial scan.

Change-Id: Id48ae28e6d0e719b9db9b2e73bd76f9be1ea0b3e
CRs-Fixed: 3343567
2022-12-02 12:29:22 -08:00
Krunalsinh Padhar
7ca1ab9e0f qcacmn: add vendor sub-command index for primary netdev notification event
Add vendor sub commands index
QCA_NL80211_VENDOR_SUBCMD_MLO_PEER_PRIM_NETDEV_EVENT_INDEX.

This index is used to identify the vendor event from the socket buffer.
This vendor event notifies the application layer about the primary
netdev after each MLO association.

Change-Id: Icccf0498412ee6831dcf61f9dd7c7e828848c2eb
CRs-Fixed: 3297028
2022-11-26 15:51:34 -08:00
Amit Mehta
46a5d43615 qcacmn: Vendor attribute to configure QoS/AC upgrade for UDP frames
Introduce a new attribute to configure access category
override for UDP frames of BE/BK category. Unlike, the
earlier attribute QCA_WLAN_VENDOR_ATTR_CONFIG_UDP_QOS_UPGRADE
which will override for all UDP frames, this attribute is
for overriding only for BE/BK based UDP frames.

CRs-Fixed: 3332609
Change-Id: Ife6104b97bca83653fdcac31f2c91007d1aa6f2a
2022-11-23 10:52:49 -08:00
Srikanth Marepalli
7c94f932be qcacmn: A vendor roam control configuration for delaying hand off for RX
Introduce a run time roam configuration for "hand off delay for RX".
This value, in milliseconds, will delay the hand off for the specified
time to receive pending RX frames from the current BSS.

Change-Id: I961109a2f9287a611ae8f4b38e2ea824ecf9c559
CRs-Fixed: 3329952
2022-11-23 04:42:57 -08:00
Amruta Kulkarni
b6ca1b3ff2 qcacmn: Add null check in osif roam api
Add null check in osif_roam_auth_mlo_links api.

Change-Id: Ia3290fe3b51d8913f212c732a6c53b0a159adfc3
CRs-Fixed: 3337588
2022-11-22 20:34:32 -08:00
Linux Build Service Account
b32b979e35 Merge "qcacmn: Add changes to support link_id param in cfg80211_disconnected" 2022-11-20 06:53:45 -08:00
Himanshu Batra
80db72a890 qcacmn: Add changes to support link_id param in cfg80211_disconnected
As part of MLO dynamic link deletion handling, cfg80211_disconnected is
taking link_id as an argument.
Add changes to support link_id param in cfg80211_disconnected.

Change-Id: Ia312b5e5768ba9abb11675839e912d4819a2fa86
CRs-Fixed: 3315102
2022-11-19 20:11:05 -08:00
Krunalsinh Padhar
97ea3b37d1 qcacmn: Add QCA vendor subcommand to notify about primary netdev
Add a new vendor subcommand
QCA_NL80211_VENDOR_SUBCMD_MLO_PEER_PRIM_NETDEV_EVENT to send notification
to application layer about primary netdev of an MLO peer association.

Also define the attributes present in this subcommand.

Change-Id: I84ba177c5d7155f627d4d3fa86c64c4f9b24951c
CRs-Fixed: 3280634
2022-11-18 13:38:22 -08:00
David Oladunjoye
a361d76cff qcacmn: QCA vendor attribute to configure periodic sounding
Add a new QCA vendor attribute to configure the periodic sounding for Tx
beamformer functionality.

Change-Id: I2f36f98b6665d448c07d676ff9a5fa907a980c5c
CRs-Fixed: 3328364
2022-11-16 15:36:58 -08:00
Vinod Kumar Pirla
10892b0f48 qcacmn: Introduce new macros to interface ML SAP changes
Introduce new macros to interface ML SAP capable
host driver with cfg80211.
SAP needs to provide additional information
about the clients when beaconing as ML SAP.

Change-Id: Ie673927d1f8617da38170d41e6aaedae13f4f5c8
CRs-Fixed: 3331264
2022-11-16 13:39:03 -08:00
Mohammed Ahmed
b36ae3c3aa qcacmn: add psoc null check before passing to wlan_objmgr_get_peer_by_mac
Current code directly passes the result of wlan_vdev_get_psoc(vdev) to
wlan_objmgr_get_peer_by_mac, without null pointer checking, which can
result in null pointer dereferencing.
To fix this issue, add checking of the psoc pointer before passing to
wlan_objmgr_get_peer_by_mac.

Change-Id: Ica5ebbc448a6da8b1e7c846f05773d95f995eaca
CRs-Fixed: 3327337
2022-11-10 16:43:43 -08:00
Jhalak Naik
8ed6f1a778 qcacmn: Add QCA vendor attributes for EHT support in external ACS
Add support for new vendor sub-command attributes for 320 MHz
channel width and puncturing information as part of the
external ACS.

Change-Id: Ic8181619949061794775bfe55f4afd0f408a7316
CRs-Fixed: 3323216
2022-11-07 13:11:26 -08:00
David Oladunjoye
25cb050e32 qcacmn: Add lock to Set/clear WLAN_VDEV_FEXT2_MLO_STA_LINK flag
Currently, this MLO flag is being set/clear without regard for
concurrency. We need to lock the vdev when updating these values to
prevent race condition.

Change-Id: Ied90d62f10f6f12a35eeac3060dd0fae7d0c6cfd
CRs-Fixed: 3305558
2022-10-21 21:31:17 -07:00
Jyoti Kumari
5ba9521bfb qcacmn: Add a vendor attribute to configure concurrency policy for AP interface
Add a new QCA vendor attribute
QCA_WLAN_VENDOR_ATTR_CONCURRENT_POLICY_AP_CONFIG to
QCA_NL80211_VENDOR_SUBCMD_CONCURRENT_POLICY sub command to set
the concurrency policy for AP interface.
QCA_WLAN_VENDOR_ATTR_CONCURRENT_POLICY_AP_CONFIG uses the values
defined in enum qca_wlan_concurrent_ap_policy_config to specify
concurrency policy.

Change-Id: I73931e41e469b3696f80fe8897428d4fc796ec95
CRs-Fixed: 3302865
2022-10-19 22:30:46 -07:00
Jyoti Kumari
115f04aa57 qcacmn: Rename QCA_NL80211_VENDOR_SUBCMD_CONCURRENT_MULTI_STA_POLICY
Rename QCA_NL80211_VENDOR_SUBCMD_CONCURRENT_MULTI_STA_POLICY to
QCA_NL80211_VENDOR_SUBCMD_CONCURRENT_POLICY to allow extension
for other interface type(s). A subsequent commit will extend the
renamed definitions in a manner that is inconsistent with the
current naming.

This is a precursor for AP/P2P concurrency policy configuration
support via updated vendor command
QCA_NL80211_VENDOR_SUBCMD_CONCURRENT_POLICY.

Change-Id: I1df8e7b289a8d7f1982f5daab732a36ad013d9ca
CRs-Fixed: 3302835
2022-10-19 22:30:39 -07:00
Yu Wang
093c816d05 qcacmn: print SSID with QDF_SSID_FMT and QDF_SSID_REF
To protect user privacy, print SSID with QDF_SSID_FMT
and QDF_SSID_REF, then SSID will be hide in logs if
anonymization is enabled.

Change-Id: Ifad0ccd76bd1184a9b1d20f3d7fa4455df924843
CRs-Fixed: 3291826
2022-10-18 11:57:53 -07:00
Harsh Kumar Bijlani
53f89d318b qcacmn: Add service class id attribute in SCS rule config vendor subcommand
Add service class id attribute
QCA_WLAN_VENDOR_ATTR_SCS_RULE_CONFIG_SERVICE_CLASS_ID in SCS rule
configuration vendor subcommand
QCA_NL80211_VENDOR_SUBCMD_SCS_RULE_CONFIG.

Change-Id: I1a1be0a1a5c65be488e36c0d078dbc6aef47838a
CRs-Fixed: 3314058
2022-10-18 05:22:40 -07:00
Rachit Kankane
8f76bf1455 qcacmn: Add Spatial Reuse event index
Add async event index for Spatial Reuse

Change-Id: I486e45e074fca857670876e51ca5878a5a60906c
CRs-Fixed: 3307824
2022-10-17 06:48:55 -07:00
Sheenam Monga
6e707dac35 qcacmn: Add QCA vendor interface support for Spatial Reuse (SR) feature
Add a new vendor sub-command to implement Spatial Reuse feature.
Userspace enables SR feature with specific configuration parameters. The
driver/firmware upon receiving the command, enables the SR feature if it
is supported by the currently connected AP. The driver may reject the
command if it cannot enable the SR with the configured parameters. The
driver sends events to userspace to indicate when SR feature is enabled
or disabled internally. Userspace can also query SR feature related
parameters and statistics from the driver/firmware as needed.

Change-Id: Ie203576d4ace691e37a1c5eea379f562bf416835
CRs-Fixed: 3298975
2022-10-15 05:18:57 -07:00
Amruta Kulkarni
319456fee7 qcacmn: Add callback api to send stored keys
For STA MLO connection, the AP can send M1 right after assoc
response on assoc link, which will trigger sending keys to FW
for mlo links, but it can happen that wmi_peer_assoc is not
sent for mlo link until this time.
Current code does not have handling for this case.

To solve this, store the link vdev keys and send them once
link vdev is connected.

Change-Id: I882da96280711ca9cfa4d6ba852fda4a8b6d7a77
CRs-Fixed: 3293692
2022-10-12 23:22:44 -07:00
Jeff Johnson
8aa059674f qcacmn: os_if: Fix misspellings
Fix misspellings in os_if/...

Change-Id: I15604af98007e6ed4a7bc91abc9c07dfed1276fc
CRs-Fixed: 3304690
2022-10-11 14:23:11 -07:00
nakul kachhwaha
af02ec866a qcacmn: Add a new QCA vendor attribute to support flexible TWT
Add a new attribute QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_SP_START_OFFSET to
configure offset to shift start of the service period. This attribute
will be used when device supports flexible TWT. If provided, this
attribute will override QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_WAKE_TIME.

Change-Id: I1f066f328c6d0f3ca4d4bf4a94e63647d639f49d
CRs-Fixed: 3299714
2022-10-08 05:12:50 -07:00
Amruta Kulkarni
f1da02acc9 qcacmn: Release vdev reference to avoid leak
Currently vdev reference is not released in api
osif_send_roam_auth_mlo_links_events().

To solve this release vdev reference to avoid leak.

Change-Id: Idc766925f5cd71cbdd577ee7b67abffc35130dd9
CRs-Fixed: 3305547
2022-10-06 16:53:03 -07:00
Pragaspathi Thilagaraj
d95e7863cd qcacmn: Add support to enable/disable responder 11az ranging
Enable/Disable responder 11az ranging based on the below ini:
"enable_responder_11az_support"

With "enable_responder_11az_support" disabled, the below ext
cap advertisement will be disabled:
Non-TB Ranging Responder
TB Ranging Responder

and below vendor capabilities advertisment will be disabled:
QCA_WLAN_VENDOR_FEATURE_PROT_RANGE_NEGO_AND_MEASURE_AP
QCA_WLAN_VENDOR_FEATURE_SECURE_LTF_AP

Change-Id: I82eb70615f8daf82e98e7600418e07fad0672b76
CRs-Fixed: 3296410
2022-09-29 04:22:45 -07:00
Amruta Kulkarni
c3051031c5 qcacmn: Send roam auth mlo links event
After mlo roaming is complete send roam auth mlo links
event to kernel.
Also populate cfg roam info structure with mlo link info.

Change-Id: I8710e3a53f05c50b7b276d87a39411cb43d0983f
CRs-Fixed: 3279967
2022-09-27 16:23:16 -07:00
Chaoli Zhou
400309d015 qcacmn: Fix compiler warning on shift overflow in QCA vendor definitions
Fx the following compiler error:
qca-vendor.h:5892:54: error: result of ‘1 << 31’ requires 33 bits to represent, but ‘int’ only has 32 bits [-Werror=shift-overflow=]
 5892 |  QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HE40INTOL     = 1 << 31,

This "1" needs to be marked unsigned for this case of MSB=1.

Change-Id: I27daebd07d0cbf314459254cfc5906f5e56dd4be
CRs-Fixed: 3299457
2022-09-27 13:22:24 -07:00
Jianmin Zhu
fb43cc12b8 qcacmn: Fix scan with random address failed since wdev is connected
Reproduce steps:
1.	Connect from OSIF success, wdev->connected = true;
2.	Disconnect from target if and reassoc from OSIF happens back to
	back.
3.	Disconnect event is not sent to kernel, wdev->connected keeps
	true, isn't cleared.
4.	Connect from OSIF failed too, wdev->connected keeps true,  isn't
	cleared.
5.	Scan with random address failed since wdev->connected is true.

To fix it, if connect req was a reassoc req and received in not connected
state for race between disconnect from target if and reassoc connect from
OSIF, set reassoc_in_non_connected to send disconnect instead of
connect rsp to kernel to cleanup kernel flags like: wdev->connected.

change-Id: Ibbe38da14e9339b49589216250453b76c7387b57
CRs-Fixed: 3290496
2022-09-22 02:21:43 -07:00
Sreeramya Soratkal
fd8b102007 qcacmn: Validate status of spectral control request processed
Validate the result of spectral specific ucfg control operation
after processing the control request to get the spectral system
capability information and the spectral diag status.

Throw error if it is an invalid operation.

CRs-Fixed: 3272699
Change-Id: Iba1b165caa41a7b4a133e9d9f3df7203a60a2b75
2022-09-21 09:34:44 -07:00
David Oladunjoye
8be4fef5d9 qcacmn: QCA vendor attribute to configure periodic sounding
Add a new QCA vendor attribute to configure the periodic sounding for Tx
beamformer functionality.

Change-Id: Id4b75e992e22facdc58b467aaed29d9b00901fad
CRs-Fixed: 3290371
2022-09-19 14:54:16 -07:00
Adwait Nayak
321fa3cb5f Revert "qcacmn: Do not send the scan entry for nontx profile to cfg80211 layer"
This reverts refer to the Commit-Id
f60c8e57d3.

Change-Id: I4d004ecad6fffd654ee3e90db765acd6cde242c1
CRs-Fixed: 3291428
2022-09-19 00:29:06 -07:00
Ashish Kumar Dhanotiya
09220f783e qcacmn: Process tx and rx rate count from peer stats
Based on the new requirement process tx and rx rate counts
from peer stats response and send these stats to user space
as part of big data stats.

Change-Id: I988f0d6cf6a3537f31433d4f57280336ab58bc38
CRs-Fixed: 3289789
2022-09-17 01:11:22 -07:00
Pragaspathi Thilagaraj
89f5e532f3 qcacmn: Add support for AP secure-LTF capability
Add support to advertise AP secure-LTF capability based
on ini configuration

Change-Id: I8aebbd683694e36d8d16215c0358f5bfb18d5443
CRs-Fixed: 3283114
2022-09-14 09:36:20 -07:00
Adwait Nayak
f60c8e57d3 qcacmn: Do not send the scan entry for nontx profile to cfg80211 layer
Send only the scan entry for Tx profile to upper layer. As in cfg80211,
it goes through every nontx profile to from a new frame.

Change-Id: I4f01a1a5ed61bfd2a2b8a541c8d3be14ffa2e3c9
CRs-Fixed: 3251364
2022-09-08 12:24:20 -07:00
Asutosh Mohapatra
81d86f0f99 qcacmn: Add QCA vendor interface to get SAR capabilities to userspace
Add QCA_NL80211_VENDOR_SUBCMD_GET_SAR_CAPABILITY to get various SAR
capabilities supported by the WLAN firmware to userspace. These
capabilities are usually reported by the firmware during the initial
bootup handshake with the driver. Based on these capabilities, user
space can choose proper SAR indexes.

Change-Id: I31be4bd58dc02fe82ae57f703f7db54f5a3c027e
CRs-Fixed: 3274703
2022-09-05 04:49:09 -07:00
Jianmin Zhu
d012f9e86f qcacmn: Fix OOB when add 6 GHz channels for pno scan
If there are more than 1 preferred network list in schedule scan, after
6 GHz channels added to pno channel list of 1st network list, channel
num is updated and set for 2nd network list wrongly, then OOB happens when
6 GHz channels are added to 2nd network list.

Change-Id: I2658620ce4e6e8dcf93e810c7bc10364e4de7a73
CRs-Fixed: 3280705
2022-09-02 14:32:32 -07:00
Jianmin Zhu
b67ab65175 qcacmn: Enhance QCA vendor roam event to indicate MLO links after reassociation
Enhance QCA_NL80211_VENDOR_SUBCMD_KEY_MGMT_ROAM_AUTH event for the
driver to indicate the information of the associated links of MLO
roaming.

Change-Id: I5cede840ec42bb45ec13e35a1f5caa0c0674047a
CRs-Fixed: 3278009
2022-08-31 21:10:24 -07:00