Commit Graph

55 Commits

Author SHA1 Message Date
Himanshu Batra
b9f1cd3492 qcacmn: Update mlo connected_links_bmap for self vdev
As part of mlo connect notification, connected_link_bmap is gatting
updated for partner links, but for assoc link also this needs to be set
Add fix to update mlo connected_links_bmap for self vdev

Change-Id: I4d64d97e67484dac2e96a3d22b5648ec2bc320d4
2021-12-02 07:15:21 -08:00
Lincoln Tran
da5f535c52 qcacmn: Free memory on connect failure
Currently, the check to free the original connect req when connection
fails is specific to MLO connection. Update the check to free on a
failed legacy connection as well.

Change-Id: I168d0555fecabf31c4702e382f2bd4bd63a15839
CRs-fixed: 3081248
2021-11-30 11:04:46 -08:00
Chaithanya Garrepalli
1cee4a643a qcacmn: Skip MLO setup if there are no ML capable SOCs
In MLO link setup and MLO soc setup return if num_tot_links
are zero

Change-Id: I2767c519cc19e47523c39f7ea32d0df4e053e4ea
2021-11-29 07:34:10 -08:00
Krishna Rao
39c0eb2153 qcacmn: Add API to get partner link info from Basic Variant ML element
Add API to get partner link information in the per-STA profiles
present in a Basic variant Multi-Link element. The partner link
information is returned only for those per-STA profiles which have a
MAC address in the STA Info field. Also note that the current
implementation does not have Multi-Link element fragmentation support
- this will be added in an upcoming change after shared helper
utilities for the same are available. Similarly, the current
implementation does not have support for per-STA profile fragmentation
- this may be added once it is introduced in the IEEE802.11be
standard.

Change-Id: Ied7092ba1366d39fa15adffc3737d4ad5c0adf59
CRs-Fixed: 3040491
2021-11-29 07:34:05 -08:00
Chaithanya Garrepalli
65137277e8 qcacmn: chages to save soc list in mlo setup
Changes to save SOC list in MLO setup

Change-Id: I185bf26b1dac6eced03931c213297564abe74747
2021-11-23 21:59:34 -08:00
Kiran Venkatappa
3e3ed9ca89 qcacmn: MLO setup, teardown sequence changes
MLO setup, teardown sequence changes

Change-Id: I76d14cd66c373b3b734a17e44f3655ffd17893c5
CRs-Fixed: 3059859
2021-11-23 16:57:00 -08:00
Himanshu Batra
cc99f5487f qcacmn: ML peer changes for STA
Add changes to support ML peer for STA vdev.

Change-Id: I173a2ad5441bbbf1c1185c677c6cc92c4f1a166f
2021-11-22 15:10:01 -08:00
Lincoln Tran
ddfe7df316 qcacmn: Update mlo_disconnect_no_lock to check for MLO cap
When a connection is requested but the client is unable to find the
candidate, connection will fail. In legacy case, legacy disconnection
path should be invoked. Update the mlo_disconnect_no_lock function to
match the mlo_disconnect logic when checking for MLO capabilities.
Also update the link connect notify function to prevent queuing
multiple disconnect requests.

Change-Id: I5ed4b213b1fe6b48d2d5631bf1625bea2864f606
CRs-fixed: 3069545
2021-11-17 23:17:11 -08:00
Krishna Rao
5f1d4dd7fb qcacmn: Add API to get link ID from Basic Variant ML element
Add API to get the link identifier from a given Basic variant
Multi-Link element or element fragment sequence, of the AP that
transmits the Multi-Link element/element fragment sequence or the
nontransmitted BSSID in the same multiple BSSID set as the AP that
transmits the Multi-Link element/element fragment sequence and that is
affiliated with the MLD that is described in the Multi-Link element.

Change-Id: I45039a6ed8ccd9403eae9514c60bcd8d694d2a31
CRs-Fixed: 3040407
2021-11-16 20:58:00 -08:00
Lincoln Tran
632f919086 qcacmn: Fix compilation issues related to MLO disconnect
When the WLAN_FEATURE_11BE_MLO_ADV_FEATURE macro is enabled,
some functions are not reachable or defined. Move the
definitions accordingly to fix compilation issues.

Change-Id: I698f290e69f0acc9b72d60081849bce093d05741
CRs-fixed: 3075650
2021-11-16 14:53:29 -08:00
Krishna Rao
77e686b250 qcacmn: Add API to get MLD address from Basic Variant ML element
Add API to get the MLD MAC address from a given Basic variant
Multi-Link element or element fragment sequence.

CRs-Fixed: 3053521
Change-Id: I96cf893ae4a089c20bd2d8b783c4e3d1d4eb3e4a
2021-11-16 12:21:57 -08:00
Krishna Rao
b5253e0f65 qcacmn: Add API to get the variant of the given ML element
Add API to get the variant of the given Multi-Link element or element
fragment sequence.

Change-Id: I09b10c8e14e1a7e7b500116782f07d9fde7a78e1
CRs-Fixed: 3040403
2021-11-14 07:07:39 -08:00
Krishna Rao
f0b40c96d7 qcacmn: Add API to find Multi-Link element
Add API to find the first Multi-Link element or the start of the first
Multi-Link element fragment sequence in a given buffer containing
elements, if a Multi-Link element or element fragment sequence exists
in the given buffer.

Change-Id: I3dbd0f9053e3a1e20b47c182b5258f49b1e2c409
CRs-Fixed: 3040400
2021-11-12 18:06:25 -08:00
Yu Wang
0c8f452ae6 qcacmn: move API for getting ML vdev list out of WLAN_MLO_MULTI_CHIP
mlo_get_ml_vdev_list() is a common API, it should not be
embraced by macro WLAN_MLO_MULTI_CHIP.

Change-Id: Icf22de20fdeca374d674109d10b4887b833fa346
CRs-Fixed: 3073916
2021-11-12 15:07:14 -08:00
Srinivas Pitla
cc7d98b794 qcacmn: MLO Peer changes
This change implements timer based msgq processing to defer
the context for MLO peer. It also fixes some of the issues in
MLO peer path, It adds utils APIs for MLO params

Change-Id: I94384c91adfb8785d833bff1ba5541dc98cfc383
CRs-Fixed: 3059837
2021-11-12 11:32:39 -08:00
Himanshu Batra
b21d96305e qcacmn: Modify MLO disconnect handling
Modify MLO disconnect handling to issue disconnect on all links in
parallel
Also modify connect resp to accommodate ml info in connect resp

Change-Id: I57575c6ce7c8ebff7770f862dc81e7dfd20aa42d
2021-11-11 00:37:03 -08:00
Lincoln Tran
a89e4f0c78 qcacmn: Fix MLO peer manager compilation issue
Fix MLO compilation issue while exporting the symbol
wlan_mlo_link_peer_delete.

Change-Id: I911917ab7f142fdc49ea99e9613ddb6fb86b5ab3
CRs-Fixed: 3067718
2021-11-02 16:32:03 -07:00
Himanshu Batra
5a4b4ec7ca qcacmn: Ignore ml sta connect notification when connect req is flushed
If vdev is not in disconnected or connected state,
then the event is received due to connect req being flushed.
Hence, ignore this event

Change-Id: If7f51496fcca283cb6559b027a21df82ae9ec7d2
2021-11-01 01:42:27 -07:00
Himanshu Batra
b981e05832 qcacmn: Add API to get link peer assoc req buffer
Add API to get link peer assoc req buffer

Change-Id: I293a86f8eaaaf5a2e02802388960386848201a2c
2021-10-26 04:44:06 -07:00
Himanshu Batra
2100a410a5 qcacmn: Add APIs to modify connect_req/connected vdevs bmap for ML STA
Add APIs to modify connect_req/connected vdevs bmap for ML STA

Change-Id: I3c68f2f7a87db49eb72ddf0d9e85ae7387974c85
2021-10-19 09:49:48 -07:00
Arun Kumar Khandavalli
666ab22622 qcacmn: fix the memory leak in the connect failure path
There is a memory leak in the mlo connect failure the connect req
and the connect, ies are not getting freed because of the mlo is vdev
check. During the allocation there is no condition as such, so remove
the same during the connect failure path to resolve the memory leak.

Change-Id: I9076761cd3b918435af9929fcf888996d2129e98
CRs-Fixed: 3057979
2021-10-18 18:47:00 -07:00
Lincoln Tran
3cbefea6d0 qcacmn: Set MLO cap bit for subsequent links
When sending the connect for subsequent links in MLO, make sure to set
the capability bit, otherwise it will be marked as assoc link.

Change-Id: Ic0145b40e84ea440ea389200356d1f916a1ba530
CRs-fixed: 3055892
2021-10-15 15:32:14 -07:00
Bapiraju Alla
eadfb45b23 qcacmn: Fix MLO connection issues
Add minor fixes to allow MLO connection.

Change-Id: Ic9e464b6e5c948676d5ad0e2519c096a9e1b1964
CRs-fixed: 3021328
2021-10-15 15:32:04 -07:00
Lincoln Tran
82ee197386 qcacmn: Store original connect req in connection types
When performing an MLO connection, the subsequent links need data
from the original connection request. There is no easy way to
determine if the connection is MLO or not at this point, so
store the original connect request regardless of the connection
type. Also make sure all instances are freed properly.

Change-Id: Iccce376ba36a8c49127b177fc4a1bac54aafb315
CRs-fixed: 3051842
2021-10-14 17:11:06 -07:00
Himanshu Batra
069f37b825 qcacmn: Use osif_cfg as disconnect source for ML internal disconnect
In case when connect req is received while ML connect is in progress,
disconnect is issued with SB_disconnect as source but sb disconnect is
not handler in join active. So, send osif_cfg_disconnect as a source

Change-Id: I9604e23193ba3aef334f0873d2460a992b1914ea
2021-10-06 13:06:04 -07:00
Bapiraju Alla
8c5f682d9d qcacmn: Reset auth type for partner link connect request
Currently ML secure connection is failing for second link at STA.
This is because, auth type is not proper in connect request crypto
params. Hence failed to get the partner scan entry with matching
auth type.

To resolve this, reset auth type while preparing partner link connect
request.

Change-Id: Ic291ad4e4405ea2f625c1e47d052166eba21036b
CRs-Fixed: 3040789
2021-09-30 15:15:14 -07:00
Lincoln Tran
92f93cb246 qcacmn: Add MLO as disconnect source
When processing a peer or southbound disconnect on the non assoc link,
there is a vdev stop issue due to the correct state not being set. For
this link, set the disconnect source as MLO instead of passing it down
from the caller.

Change-Id: I8db444e7c80659a1a1026a53326e99c96ef631f0
CRs-fixed: 3040658
2021-09-29 15:05:32 -07:00
Lincoln Tran
bb30b105cf qcacmn: Fix MLO compilation issues
Fix compilation issues in MLO related code.
Add debug prints when generating link assoc response.
Add NULL value check.

Change-Id: Ie5951816ee39428c086ec91eaa6fc9cf598072b6
CRs-fixed: 3038725
2021-09-27 17:57:59 -07:00
Himanshu Batra
dff5855dd9 qcacmn: Add API to get ML vdev list
Add API to get ML vdev list

Change-Id: Ie4a001dc5b1906f2236f54335e3867727fd25e02
2021-09-24 20:45:03 -07:00
Himanshu Batra
60d195db92 qcacmn: Reset chan info for ML partner link connect req
Reset chan info for ML partner link connect req

Change-Id: Ib6c456bde8b5e023ae13dd34bf2f3d8d48cc365f
2021-09-15 08:40:33 -07:00
Lincoln Tran
50e7e5c6ae qcacmn: Copy assoc IE for MLO link connect
When associating the partner link in an MLO connecting, reuse the
association IEs from the original connection. To do this, store the
connection manager connection request to query later, since this
holds the assoc IE data.

Change-Id: I100351a4c9cd439222af202ca3e80ef50554e1e3
CRs-fixed: 3016095
2021-09-10 20:09: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
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
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
Lincoln Tran
ce48d77998 qcacmn: Add debug MLO changes
-Add debug logs to MLO manager code.
-Add ml_dev validation checks for ML peer operations.
-Add pointer checks to avoid NULL pointer dereference

Change-Id: I8e9ddf177a999a43e8612f8c6acedd08ffce63d5
CRs-fixed: 2998964
2021-08-25 19:45:02 -07:00
Krishna Rao
9503c2a865 qcacmn: Rectify format specifier for qdf_size_t in MLO utility
Resolve compilation error seen on some platforms by rectifying print
format specifier for qdf_size_t to "zu" in MLO utility functions.

Change-Id: I68b0696fea1c54578631e731a3cc48ec0eb84c97
CRs-Fixed: 3017056
2021-08-19 07:07:09 -07:00
Srinivas Pitla
7469335fa4 qcacmn: MLO peer implementation
This change adds MLO support to Peer.
It implements,
1) MLO peer list management
2) AID allocation
3) MLO Peer creation/deletion
4) Notifying partner links on peer creation/deletion/assoc

Change-Id: Ie1b675dccdf0de1d79f6f32d9255cf3cca53fdf2
CRs-Fixed: 2967057
2021-08-15 01:53:04 -07:00
Amruta Kulkarni
83e0741bf9 qcacmn: Fix compilation issue
Changes to fix compilation error seen on WIN side.

Change-Id: I28461a1950912700c9ce41d025197980b37c4b3a
CRs-Fixed: 3012157
2021-08-12 05:32:42 -07:00
Himanshu Batra
5f871547d8 qcacmn: Call correct API to validate mlo connect
Call correct API to validate mlo connect

Change-Id: I2f998e9cac66f8503fd42bb51d6fe5d436e2a495
2021-08-09 17:46:40 -07:00
Himanshu Batra
159972081f qcacmn: Remove redundant API mlo_is_mld_ap
Remove redundant API mlo_is_mld_ap

Change-Id: I78996b639439efb3e4f81bf42a2437bca935c8a9
CRs-Fixed: 3005510
2021-08-04 10:39:13 -07:00
Amruta Kulkarni
f6032d1c4a qcacmn: Generate Link Specific Assoc Response
Generate link specific association response for
MLO partner links.

CRs-Fixed: 2970626
Change-Id: I48520290c09f48ce356d166e1cd2ef24938e8fb2
2021-08-03 06:55:23 -07:00
Santosh Anbu
1c91398f51 qcacmn: Fix event dispatch for MLO_SYNC_WAIT
Add count to hold number of vdevs in a MLD link and fix sending
WLAN_VDEV_SM_EV_MLO_SYNC_COMPLETE in sync context to vdev SM.

Change-Id: Ie07c3e541ed5926ac08ae5a9d50e4365fefb1d52
CRs-Fixed: 2982475
2021-07-27 14:34:24 -07:00
Santosh Anbu
34be27c9fb qcacmn: Add API to set mlo context at umac global object
Replace global mlo manager context variable with the mlo_mgr context
already defined at global umac object.
Add API to set mlo context at umac global object.

Change-Id: Iad8d534b761aa93e124a721d3d6e01a81ef69b15
2021-07-22 23:38:34 -07:00
Amruta Kulkarni
84f88dd33f qcacmn: Get partner link channel freq
Get partner link channel freq from bssid

CRs-Fixed: 2969251
Change-Id: Iab14768d7b51f0114ca40a3ec5bc942ac8ea4f1c
2021-07-20 08:28:37 -07:00
Himanshu Batra
7d92d3dd78 qcacmn: Add MLO STA disconnect API definitions
Add MLO STA disconnect API definitions.

Change-Id: I7da336d7c634cc1408f7e92a0276ee950eed6ed6
2021-07-20 08:28:33 -07:00
Himanshu Batra
e9f5df7e52 qcacmn: Add MLO STA connect API definitions
Add MLO STA connect API definitions

Change-Id: I36c89a85c8ac5146fa718545fad3d619272fabe4
2021-07-20 08:28:28 -07:00
Sandeep Puligilla
1d0ef56609 qcacmn: Add validation check for MLD address
-Add validation check for MLD address as part of ML dev context
creation.
-Modify some function descriptions to clearly state the purpose.

Change-Id: Id049145351bdd790126e0ab522d24e4c399c0ad2
CRs-Fixed: 2976130
2021-07-14 13:12:31 -07:00
Himanshu Batra
8f056fe40e qcacmn: Free ML dev context memory in case of failure
Free ML dev context memory in case of failure

Change-Id: I2564cc5a3140f26e5b70c684879150debe009a29
CRs-Fixed: 2989084
2021-07-14 07:25:35 -07:00
Sandeep Puligilla
9c652b4d8b qcacmn: Implement AP start/stop API in mlo mgr
Implement AP start/stop API in mlo manager.

Change-Id: Ib9fcc4a678ebfe1ad57043891b12fc98998cf931
CRs-Fixed: 2970650
2021-07-10 02:58:34 -07:00