Commit Graph

1012 Commits

Author SHA1 Message Date
Abhishek Ambure
e0fe68d2dd qcacld-3.0: Keep IBSS code under feature flag in SME
IBSS code is placed under QCA_IBSS_SUPPORT feature flag.

Change-Id: I501ad12155de2445824ca028295cfdec7940c6fd
CRs-Fixed: 2530205
2019-09-27 09:11:51 -07:00
Liangwei Dong
e2ac31beea qcacld-3.0: Use chan frequency for phy mode population
Use channel number will get invalid band.
Change csr_roam_get_phy_mode_band_for_bss API
and CSR_GET_BAND to use channel frequency as parameter.

Change-Id: I0c4d39f6b5689bc330e4e09302d84deaf209b9cb
CRs-Fixed: 2518428
2019-09-26 10:33:58 -07:00
Abhinav Kumar
523ca376a9 qcacld-3.0: Add support to dynamically enable roaming in STA+STA
Currently in STA+STA scenario roaming is enabled on the
first connected STA1 and is enabled on the other STA2 on
STA1 disconnection. This change adds support to dynamically
enable or disable roaming on any STA.

Change-Id: I34dc2730fb38193ea3dd0ec35c79df233f270913
CRs-Fixed: 2520827
2019-09-25 10:37:15 -07:00
Yeshwanth Sriram Guntuka
1669fc0508 qcacld-3.0: Add CSR APIs to maintain roam state machine
Add CSR APIs to maintain the roam state machine.

Change-Id: I68728cb657c5a492f141bea90b2da0d70cb61f08
CRs-Fixed: 2520826
2019-09-25 10:37:09 -07:00
Srinivas Dasari
240d327763 qcacld-3.0: Consider def roam scan periods only if not conf'd explicitly
Roam control enable sends default values for roam scan period and
full roam scan period to make sure undesirable values are not
used. But user might want to update values dynamically through
vendor cmd/DRIVER cmd before issuing roam control enable and
doesn't want to overwrite these values with default values.
So, consider default values sent only if user hasn't configured
already. This can be done by comparing configured value with
ini values.

Change-Id: I68ac6a9afbe4a45c1a1ade3286c57f36303c49e9
CRs-Fixed: 2530344
2019-09-23 09:26:00 -07:00
Srinivas Dasari
3a769ca362 qcacld-3.0: Reset inactivity params when roam control is enabled
When roam control is enabled, below inactivity params are expected
to be set 0,
1. roam_scan_inactivity_time
2. roam_inactive_data_packet_count
3. roam_scan_period_after_inactivity

Restore the same when roam scan control is disabled/CLEAR_ALL is
received.

Change-Id: Id9365895cdbccb3465b96ba6eec579da5014caa0
CRs-Fixed: 2529116
2019-09-23 09:25:53 -07:00
Srinivas Dasari
1ec7452b18 qcacld-3.0: Restore all control config params upon CLEAR_ALL
User might modify the roam control config params through
multiple commands as part of roam control config enable.
Currently, only the params which are modified as part of
SUBCMD_CONTROL_SET command are restored. Restore all of the roam
control config params from the default ini values when the
control config is disabled i.e when the CLEAR_ALL is received.

Change-Id: I59ebc2e3018b01889ffb2bcd19b72d6d20fd0517
CRs-Fixed: 2517854
2019-09-23 07:28:01 -07:00
Srinivas Dasari
a5a42fa0ce qcacld-3.0: Update scan_n_probes to neighbor roam info only
Currently, scan_n_probes is updated to global mac ctx when
it's changed through DRIVER command. But the update
should happen only to the neighbor roam info of the
corresponding vdev. Retrieval also should happen based on vdev.

Change-Id: I442eda44c6c0f6a66d86648bbe82bc0dc71422bd
CRs-Fixed: 2530341
2019-09-23 07:27:53 -07:00
Srinivas Dasari
7bedcd175d qcacld-3.0: Update home_away_time to neighbor roam info only
Currently, home scan away time is updated to global mac ctx
when it's updated through DRIVER command. But the update
should happen only to the neighbor roam info of the corresponding
vdev. Retrieval also should happen based on vdev.

Change-Id: I3e746f264c23454c1721a132d267b70157392894
CRs-Fixed: 2530338
2019-09-23 07:27:47 -07:00
Srinivas Dasari
456aa70f29 qcacld-3.0: Update empty scan refresh period to neighbor info only
Currently, roam empty scan refresh period is updated to global
mac ctx when it's updated through DRIVER command. But the update
should happen only to the neighbor roam info of the corresponding
vdev. Retrieval also should happen based on vdev.

Change-Id: Ic0496c326bca459c6ef6da1d84f1fd4645373cb9
CRs-Fixed: 2530335
2019-09-23 07:27:32 -07:00
Srinivas Dasari
7f48ac026d qcacld-3.0: Update roam delta to neighbor roam info only
Currently, roam delta is updated to global mac ctx when it's
updated through DRIVER command. But the update should
happen only to the neighbor roam info of the corresponding vdev.
Retrieval also should happen based on vdev.

Change-Id: I355b9db2e142d4205088627672c3fb27c32d7fbd
CRs-Fixed: 2530333
2019-09-23 07:27:24 -07:00
Srinivas Dasari
9249a98bfa qcacld-3.0: Update lookup rssi threshold to neighbor info only
Currently, neighbor lookup threshold is updated to global mac ctx
when it's updated through DRIVER command. But the update should
happen only to the neighbor roam info of the corresponding vdev.
Retrieval also should happen based on vdev.

Change-Id: If0ad4855726bdc42d82852f413f7915892d3dfd6
CRs-Fixed: 2530332
2019-09-23 01:43:53 -07:00
Ashish Kumar Dhanotiya
1a720e76ee qcacld-3.0: Decouple get channel command from extscan
Currently get valid channel vandor command is defined
under EXTSCAN feature and also depends on gExtScanEnable
ini. when Extscan feature is disabled by ini or by feature
flag this command doesn't work.

As this command is to get the valid channel list, this
should not depend on extscan feature.

To address above issue, decouple get valid channel command
from extscan feature.

Change-Id: I6496cb94e6330f071f8027607e7d55a8f5d3db8a
CRs-Fixed: 2518313
2019-09-19 10:54:56 -07:00
Kiran Kumar Lokere
229212a653 qcacld-3.0: Refactor SAP module to use channel frequency
Update SAP data structures to use channel frequency values instead
of using the channel id values to support 6GHz channels in SAP.

Change-Id: I9ef5857e8dcf3f7d879495d3f3c3ead083fe0bf0
CRs-Fixed: 2513083
2019-09-18 22:53:37 -07:00
gaurank kathpalia
88f78ec8d8 qcacld-3.0: Change chan to freq in csr structures
Change chan to freq in csr structures for 6ghz

Change-Id: I6dc962175d95b202e647f55cfcb1f3d849fef6e2
CRs-Fixed: 2522212
2019-09-13 04:33:17 -07:00
Tushnim Bhattacharyya
42299b8780 qcacld-3.0: Replace channel with frequency in csr_channel
Replace channel ID with frequency in struct csr_channel.

Change-Id: Id86aacfd6dc9b0c65184bf046a7ee27b9c1fb5e5
CRs-Fixed: 2519204
2019-09-04 18:53:48 -07:00
Tushnim Bhattacharyya
1b11154a62 qcacld-3.0: Replace channel with frequency in csr_channel_powerinfo
Replace channel ID with frequency in struct csr_channel_powerinfo.

Change-Id: Ibe6bb41345f01f7898e91d75f2c5730d88e33717
CRs-Fixed: 2519117
2019-09-04 18:53:43 -07:00
Kiran Kumar Lokere
89f01f0fac qcacld-3.0: Add support for VHT MCS 10&11
Add support to advertise the VHT MCS 10&11 support using vendor
specific IE to enable the MCS 10 and 11 support in VHT mode.

Change-Id: I2d197dcce20ab4aec617ca8a7f4a54b438fae635
CRs-Fixed: 2465662
2019-09-04 16:22:53 -07:00
Tushnim Bhattacharyya
9f94d78a66 qcacld-3.0: Replace channel with frequency in csr_roamstart_bssparams
Replace channel ID with frequency in struct csr_roamstart_bssparams.

Change-Id: I826db5eea09fd7b5789c4907168d30186e5d5435
CRs-Fixed: 2518017
2019-08-31 02:13:01 -07:00
Abhinav Kumar
18285936bc qcacld-3.0: Don't Issue disconnect on roaming timer expiry
Currently Host issue a disconnect and cleanup for current AP,
even if the offloaded roaming feature has started, but has not
completed for some reason. This results in connection loss with
the current AP.

Fix is to call abort event SIR_ROAMING_ABORT in case of roaming
offload timeout in order to maintain the connection with the
current AP.

Change-Id: I4168f8aeb7a759896a5d93e1918ce6542e61b37e
CRs-Fixed: 2508449
2019-08-26 12:26:44 -07:00
Abhishek Singh
5606ee0fca qcacld-3.0: Use vdev cmd resp timer from vdev target if
As part of vdev target if convergence the new vdev command
resp time are defined in target if layer.

So use the vdev timer values from target if.

Change-Id: Ib74f91331e4cb470233e678ded9159e17045467e
CRs-fixed: 2513794
2019-08-23 12:31:17 -07:00
Srinivas Dasari
a33fdd8376 qcacld-3.0: Send full roam scan period to userspace upon querying
Userspace may query for current configured full roam scan period
through the vendor cmd QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_GET
and the attribute QCA_ATTR_ROAM_CONTROL_FULL_SCAN_PERIOD.
Fill the full scan period in the same attribute and send as reply

Change-Id: I0ab8b3d7b469515244ce27accc852c6d93514b2d
CRs-Fixed: 2508804
2019-08-23 01:43:00 -07:00
Srinivas Dasari
9ad9e25ed6 qcacld-3.0: Send roam control status to userspace upon querying
Userspace may configure and enable roam control and query for
the status. Add provision to send the same as vendor cmd reply

Change-Id: I7b82f85fa560c974eedc5115276bd87a84f9d3a0
CRs-Fixed: 2508802
2019-08-23 01:42:55 -07:00
Srinivas Dasari
b6798ec303 qcacld-3.0: Restore the params upon roam control config disable
Userspace disables the roam control config once it's done with
the controlled roaming. Driver should restore the params changed
by roam control config enable and proceed with roaming as per
its default behavior.
Restore the below params which are getting modified as per
the current implementation,
1. Roam trigger bitmap
2. Scoring
3. Scan period
4. Full scan period

Change-Id: I1be699825bdd798f20a3432ebccb922ade67f89b
CRs-Fixed: 2508780
2019-08-22 12:34:47 -07:00
Srinivas Dasari
5fb8190eca qcacld-3.0: Enable/disable scoring based on vendor command
Userspace can disable/enable scoring for roam candidate
selection through roam subcmd and the attribute
QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_ENABLE.

Firmware supports the below configurations currently,
1. Default selection criteria where all selection criteria
   are enabled and different weightages/scores are given to
   different criteria.
   This will be enabled when userspace doesn't specify any
   candidate selection criteria.
2. Legacy candidate selection criteria where scoring
   algorithm is disabled and only RSSI is considered for
   roam candidate selection.
   this will be enabled when userspace specify 100% weightage
   for RSSI.
Rest of the combinations are not supported for now.

Update the RSO config whenever scoring is enabled/disabled

Change-Id: Ibb787ef5433eebbdd3633748135ba6e314c931b6
CRs-Fixed: 2508778
2019-08-22 12:34:42 -07:00
Srinivas Dasari
391692d2da qcacld-3.0: Cache the status of roam control enable/disable in CSR
Userspace enables the roam control config and may query for it
later. In order to indicate the current status to userspace,
cache the same in struct sCsrNeighborRoamControlInfo

Change-Id: Ib535d6940df48305bda74a624604217d1f968861
CRs-Fixed: 2508777
2019-08-22 12:34:38 -07:00
Srinivas Dasari
f4e1b1208c qcacld-3.0: Send roam triggers from vendor cmd to firmware
Userspace can configure different roam triggers as defined
in qca_vendor_roam_triggers through the roam subcmd
QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_SET and the
attribute QCA_ATTR_ROAM_CONTROL_TRIGGERS. Send the roam trigger
bitmap to firmware

Change-Id: I692110a2ae1ee5a35bb248b9138080a7dfb02cf6
CRs-Fixed: 2508776
2019-08-22 12:34:34 -07:00
Srinivas Dasari
0628e84a29 qcacld-3.0: Configure full scan period from vendor cmd to firmware
Userspace can update the full scan period through the roam subcmd
QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_SET and the attribute
QCA_ATTR_ROAM_CONTROL_FULL_SCAN_PERIOD. Send the same to firmware
as part of roam scan offload command

Change-Id: I7c1046763d693faa3340b655848d3306ef92e06c
CRs-Fixed: 2508775
2019-08-22 12:34:29 -07:00
Srinivas Dasari
25d77b28e7 qcacld-3.0: Configure preferred freq list as dynamic chan list
Configure the preferred channel list received from vendor
roam subcmd command ROAMING_SUBCMD_CONTROL_SET as dynamic channel
list to firmware. Combine this channel list with the existing
occupied channel list and send to firmware. Flush this channel
list as part of csr_cleanup

Change-Id: Ibc45291f72844331096cb460257cab6f0b0095dc
CRs-Fixed: 2507159
2019-08-22 08:45:36 -07:00
Srinivas Dasari
b78334d5ef qcacld-3.0: Cleanup roam scan channels configuration
Currently roam channel list is directly accessed from
mac->roam.neighborRoamInfo[sessionId].cfgParams.channelInfo
in multiple APIs to set/clear.
This needs to be enhanced as as firmware supports two channel
lists(static and dynamic) for roam scan, userspace may configure
both the lists. Cleanup the APIs to accommodate both of the
channel lists. Rename the variable channelInfo of cfgParams to
specific_chan_info to suit the usage.

Change-Id: I67548bc040c2296b75b9429f5891a5251a2a88d6
CRs-Fixed: 2507157
2019-08-21 05:29:55 -07:00
Abhishek Singh
682cf6f843 qcacld-3.0: Fix WMI timeout for runtime PM
For runtime PM if the bus is suspended driver need to consider
extra 6 sec time for bus resume.
Thus add 6 sec extra in WMI timeouts if runtime PM is supported.

Change-Id: I5515cc889a0315382bac11a33ea6f901b7af1c46
CRs-Fixed: 2507029
2019-08-20 22:53:50 -07:00
Pragaspathi Thilagaraj
ba42a982b3 qcacld-3.0: Check SAE & OWE target capability to enable RSO
Currently the host driver blocks roam scan offload command to
the target if the connected akm is OWE or SAE.

Add changes to read the WMI_SERVICE_WPA3_SAE_ROAM_SUPPORT and
WMI_SERVICE_WPA3_OWE_ROAM_SUPPORT service capability advertised
by the target and set it to the mlme fw_akm_bitmap. Read this
bitmap in csr_roam_offload_scan() to allow RSO command.

Also the connected akm is sent to the target via the
WMI_AP_PROFILE command. Translate the CSR akm type for OWE and
SAE akm also.

Change-Id: I68527722ab099e0c8e1681ed64ea416b9a6e9936
CRs-Fixed: 2491021
2019-08-13 04:17:19 -07:00
Pragaspathi Thilagaraj
a97d498743 qcacld-3.0: Send preauth status for SAE hybrid roaming
For WPA3 SAE LFR-3.0 roaming, authentication is offloaded to the
wpa_supplicant via the host driver due to the target crypto
inavailability limitations. The target does candidate selection
and sends the WMI_ROAM_PREAUTH_START_CMDID to the driver.

Once the SAE authentication is done, the supplicant sends the
external auth NL command with the authentication status, PMKID
derived. On receiving this event, send the PMKID, bssid, auth
status to the target over WMI_ROAM_PREAUTH_STATUS_CMDID command.

The host driver decides if the external authentication event is
received for preauth candidate or for initial connection by
checking the connected state information of the csr session.

When the authentication fails with the first candidate, the
target triggers the preauth start for the next candidate. This
happens till there are no candidates available to roam.

There could be a situation where the firmware sends preauth
event for candidate1 and before the supplicant could send the
external auth command to the host driver, the candidate1 preauth
timer could have expired and firmware sends the preauth start for
second candidate. After SAE is done with second candidate also,
the supplicant sends external auth event for second candidate. So
in this situation the firmware should decide to choose the
latest candidate. The host driver here is a mere passthrough and
doesn't maintain timer for the preauth event for each BSSID to
drop the expired candidate preauth events.

Change-Id: I799a05e55a59677dfc2ddf5b55ebc888ccfea03e
CRs-Fixed: 2507003
2019-08-12 16:18:14 -07:00
Pragaspathi Thilagaraj
7a7163bac7 qcacld-3.0: Add support for wpa3 roaming authentication offload
Firmware offloads WPA3 SAE authentication to host due to the
crypto library availability limitation. Once the roam candidate
selection is done in the firmware, firmware sends the
WMI_ROAM_PREAUTH_START_EVENTID. Once this event is received, the
host driver triggers the SAE.

Add support to offload the SAE authentication from firmware to
wpa_supplicant.

Change-Id: Ie3a9e731194e1edfcd9f33ef0d601767b9485d46
CRs-Fixed: 2490201
2019-08-12 02:45:06 -07:00
Sourav Mohapatra
dcd8f8d1f8 qcacld-3.0: Remove usage of sta_id in TSM stats path
Currently driver passes sta_id through out the call for getting the TSM
stats. Although passed, the sta_id is not used anywhere in the call
stack. As part of removing the sta_id usage, this sta_id can also be
removed safely.

Remove the usage of sta_id in get TSM stats path.

Change-Id: I1efbb1bfdc8df84e9b6a71dcd5bd39ea93ced21a
CRs-Fixed: 2484701
2019-08-09 22:25:58 -07:00
Sourav Mohapatra
05a52ed111 qcacld-3.0: Remove usage of sta_id in get SNR path
Currently driver passes sta_id through out the call for getting the SNR
stats. Although passed, the sta_id is not used anywhere in the call
stack. As part of removing the sta_id usage, this sta_id can also be
removed safely.

Remove the usage of sta_id in get SNR stats path.

Change-Id: I39482d8f6d8e3bd32e940a85d5592dada8f0460b
CRs-Fixed: 2503956
2019-08-09 02:50:11 -07:00
hqu
030099b43f qcacld-3.0: Remove operationChannel from csr_roam_profile
Remove operationChannel from structure csr_roam_profile, remove
the code where value assigning to operationChannel take place.

Change-Id: If7cd64d4d7513000181f92faabd6c863341c71f9
CRs-Fixed: 2503043
2019-08-08 09:52:44 -07:00
Liangwei Dong
e9793891b9 qcacld-3.0: Remove ChannelList from tCsrChannelInfo
Remove all the code reference of ChannelList.
Use freq_list in new code.

Change-Id: I1972f58f07b451dd52ead5dfcabce258f130f1ca
CRs-Fixed: 2503099
2019-08-08 08:40:07 -07:00
gaurank kathpalia
7665a50dab qcacld-3.0: Extend force 1x1 ini
Currently the driver checks whether the device
supports antenna sharing, and if the AP is added
in the OUI framework, then the driver modifies the
nss value to 1 to avoid sending SMPS to the peer AP.
Now suppose the device does not support Antenna sharing,
but supports DBS and is helium HW, then going to DBS HW
mode would result in peer sending a SMPS frame to the peer
as the helium HW only has two antennas, and one is needed
by each MAC now.

Fix is to add a third param in force 1x1 ini which would
decide the driver should consider the antenna sharing as
mandatory or not.

Change-Id: I3ae00fcbd642c7780952d66ccbf1208335fcb077
CRs-Fixed: 2496831
2019-08-07 08:41:16 -07:00
Abhishek Ambure
cbef14404b qcacld-3.0: Refactor vdev delete code
Refactor vdev delete code for target_if conversion. Remove legacy
vdev delete code.

Change-Id: Ia95faa3a8eb561e19d439046a25bd7e452b98fb2
CRs-Fixed: 2471947
2019-08-05 16:45:48 -07:00
Abhishek Ambure
7470976006 qcacld-3.0: Refactor vdev create code
Refactor vdev create code to target_if common code. Remove legacy
code for vdev create.

Change-Id: I57caf0c5fa2da7b6ba640a9d2edb72363959c585
CRs-Fixed: 2460786
2019-08-05 10:55:23 -07:00
hqu
5af7254cec qcacld-3.0: Remove operationChannel from tagCsrRoamConnectedProfile
Remove operationChannel from structure tagCsrRoamConnectedProfile,
remove the code where value assigning to operationChannel take place.

Change-Id: If6c034e39c63fd78e6f08ff3daa85e0432438cff
CRs-Fixed: 2499775
2019-08-02 00:43:36 -07:00
wadesong
24c869aa97 qcacld-3.0: Replace channel list with freq list
1) freq_list value population:

   Allocate memory for freq_list within tagCsrChannelInfo
   whenever ChannelList is allocated for the same struct.

   Populate channel frequencies into freq_list whenever
   ChannelList is populated for the same struct.

   Free the memory used by freq_list whenever ChannelList's
   memory is to be freed for the same struct.

2) Special treatment for sme_rrm_send_scan_result:

   To ease the freq_list population within function
   sme_rrm_send_scan_result, a parameter(freq_list) has
   been added into the parameter list of it.

   Meanwhile, all callers of the same function have been
   modified to pass freq_list to it.

3) Fix a number of camel cases detected by checkpatch.

Change-Id: I732b084d3e1edfc4f26e7ed44be1c6e826be8602
CRs-Fixed: 2496716
2019-07-30 16:22:52 -07:00
Arun Kumar Khandavalli
6ba1569220 Revert "qcacld-3.0: Create lim session for monitor mode for legacy targets"
The change 2812433 needs revert it got merged with still some
pending comments.

Change-Id: I4555d60bf0c8cea1b3a812063ee24956b07c0d8b
CRs-Fixed: 2499426
2019-07-30 10:55:40 -07:00
Arun Kumar Khandavalli
88709de4cb qcacld-3.0: Create lim session for monitor mode for legacy targets
For the latest chipsets because of architecture change the
lim session for monitor mode is not required but for the
older chipsets using the mainline the lim session has to be created.
If the session is not created the channel setting to capture
the packets on the monitor interface fails.

Create the monitor session in lim for older targets.

Change-Id: Ide44201e91c2d92cddff66f563898015f9e28ca7
CRs-Fixed: 2498775
2019-07-29 11:23:06 -07:00
Jianmin Zhu
5ce64f48cd qcacld-3.0: Replace channel list with freq list
Add freq_list in tagCsrChannelInfo to replace ChannelList
Add APIs to translate between channel list and freq list

Change-Id: I2f086d9371e2ec928bbb47aa2be91d65a206f4d6
CRs-Fixed: 2492624
2019-07-26 06:12:21 -07:00
hqu
c7075af31c qcacld-3.0: Add op_freq in tagCsrRoamConnectedProfile
Add op_freq in tagCsrRoamConnectedProfile. Finally remove
operationChannel from tagCsrRoamConnectedProfile in next
few changes.

Change-Id: Ie9be4b59483412866d915448b33f8cb6cc9e2d7c
CRs-Fixed: 2489893
2019-07-22 09:17:35 -07:00
hqu
7b2aef50f2 qcacld-3.0: Add op_freq in csr_roam_profile
Add op_freq in csr_roam_profile. Finally remove
operationChannel from csr_roam_profile in next
few changes.

Change-Id: I7a3d7fe7e77b18424f487429aaa19ca1a97b8aba
CRs-Fixed: 2489914
2019-07-21 22:04:46 -07:00
Paul Zhang
da2970b777 qcacld-3.0: Add OEM DATA vendor command support
This command is used to send OEM data binary blobs
from application/service to firmware.

Change-Id: I0b5d7dd5a030b70e59c8581fb51d99079b38385f
CRs-Fixed: 2477332
2019-07-11 00:52:04 -07:00
Ashish Kumar Dhanotiya
1ac4188eb5 qcacld-3.0: Remove legacy implementation of stats event handler
Driver has a stats infrastructure and all the stats related
commands are using this infrastructure and for this
target_if_mc_cp_stats_stats_event_handler is getting used.

Remove legacy implementation of stats event handler
wma_stats_event_handler and related APIs.
With this change remove unused structures also.

Change-Id: I9a892b5f7486a406654256fc2cc8177f2fafe790
CRs-Fixed: 2481937
2019-07-08 14:16:50 -07:00