Commit Graph

133 Commits

Author SHA1 Message Date
Jeff Johnson
e4c11db22a qcacld-3.0: Fix camelCase in tsap_Config_t
Rename typedef tsap_Config_t and the underlying struct sap_Config to
align with the Linux coding standard.

Change-Id: I6e8f8b5ab9555c7781f1acf12a0475902866300c
CRs-Fixed: 2237721
2018-05-09 15:19:47 -07:00
Jeff Johnson
f8b4d424cf qcacld-3.0: sap: Remove legacy markings
Per current guidance remove legacy markings.

Change-Id: I05b2f8ed3e48de4347475d279d4de409d4eece42
CRs-Fixed: 2229655
2018-04-24 14:48:48 -07:00
Wen Gong
01a2c63468 qcacld-3.0: Add DFS master feature flag
Add config flag to enable / disable DFS master feature

Change-Id: Ibb0bc715c70b471b5e73626cf75ce9785a8eb567
CRs-Fixed: 2222562
2018-04-23 00:30:46 -07:00
Jeff Johnson
78772177b6 qcacld-3.0: Remove obsolete WLANTL_DEBUG code
Macro WLANTL_DEBUG is currently used to define some SAP debug
counters, but these counters are unused, so remove this obsolete code.

Change-Id: Ie7d976efcb5fb335b3f60a5af48a70dd214b3bd0
CRs-Fixed: 2220915
2018-04-11 03:37:24 -07:00
Jeff Johnson
66ee8a92fe qcacld-3.0: Replace typedef tCsrRoamProfile
The Linux Coding Style enumerates a few special cases where typedefs
are useful, but stresses "NEVER EVER use a typedef unless you can
clearly match one of those rules." The tCsrRoamProfile typedef does
not meet any of those criteria, so replace references to it with a
reference to the underlying struct.

Change-Id: Ie78bc34c5c39a56058d0daa0240047ec67392ab3
CRs-Fixed: 2207843
2018-03-19 19:57:58 -07:00
Vignesh Viswanathan
200f5c19b0 qcacld-3.0: Skip starting SAP after channel change if stop BSS in progress
When stop_bss from HDD is received when a SAP channel change request
is currently in progress and channel change response is not yet
received from the FW, the stop_bss would clear the SAP session and
when channel change response is received, we try to start BSS again.
The CSR roam state is also set to JOINING in this case.

As part of start BSS, we queue set key command to SME active command
list. Since the session has been cleared, eWNI_SME_SETCONTEXT_RSP
sent to lim would not be processed in CSR state JOINING leading to set
key command stuck in the active command list.

Do not restart BSS after channel change response if stop BSS is in
progress. Also handle eWNI_SME_SETCONTEXT_RSP and clear the command
queue in CSR Joining state.

Change-Id: I8dbab054746d26cc92fc2274d35ce76a694035fe
CRs-Fixed: 2193505
2018-02-27 14:07:02 -08:00
bings
1826d9cbd5 qcacld-3.0: Move dfs leakage from cld to cmn
Move dfs leakage from cld to dfs module of cmn.

Change-Id: I17276fedf575f1a4029265be58d8fd088c1d956d
CRs-Fixed: 2174457
2018-02-04 21:43:22 -08:00
bings
02297abea9 qcacld-3.0: Use new APIs to get and set DFS Non-Occupancy-List(NOL)
Current driver is using pld_wlan_set_dfs_nol() and pld_wlan_get_dfs_nol()
directly through eSAP_DFS_NOL_SET and eSAP_DFS_NOL_GET case statements
respectively within HDD module. These methods are obsoleted as per
new driver design.

Use DFS component's utils_dfs_init_nol() and utils_dfs_save_nol() APIs
instead to get and set DFS NOL respectively.

Change-Id: I63e8adac3f99c2052c26e6b01d19071f098e0a4f
CRs-Fixed: 2172024
2018-02-02 00:27:24 -08:00
bings
d79e606efb qcacld-3.0: Do not get nol since channel status of nol is disabled
Currently there is no need to get nol when removing nol from candidate
channel list, because status of nol is set to CHANNEL_STATE_DISABLE in
regulatory.

Remove channels whose status are CHANNEL_STATE_DISABLE when trying to
remove nol from candidate channel list.

Change-Id: I90722116814e837fca456de1b2ef88d8519e9aff
CRs-Fixed: 2180752
2018-01-30 23:55:08 -08:00
Ashish Kumar Dhanotiya
443d31f5f8 qcacld-3.0: Cache deleted station's information in case of SAP
During disconnection process, cache disconnecting STA information
so that the same information is updated to upper-layer on receiving
GET_STATION vendor command, after disconnection.

Change-Id: I2e5a0be42d81b86e6f4490de1bdf9d7e0797506d
CRs-Fixed: 2126182
2018-01-08 09:39:09 -08:00
wadesong
1795e14189 qcacld-3.0: Refine ACS fail-safe channel selection
1) Change some of the parameters for the following two functions
to reflect the right PHY mode definitions at different layers:

wlan_hdd_set_acs_ch_range
sap_select_default_oper_chan

2) Refine the kernel-doc for the above 2 functions due to their
parameter changes.

3) Use eCsrPhyMode instead of uint32_t to define hw_mode in
struct sap_acs_cfg to reflect the right PHY mode definition.

4) Refine the ACS code logic due to the changes introduced above.

Change-Id: I91b7814831a05265cfff456452eef0fe2ef97d1e
CRs-Fixed: 2167355
2018-01-08 02:07:16 -08:00
Krunal Soni
b5d18ae94b qcacld-3.0: (Part-2) Refactor open and close session logic in SAP module
Current open and close session APIs mainly defined in HDD, SME, and SAP
modules are not proper. They require some design changes to maintain the
consistency.

In order to achieve the goal of making symmetrical design for open and
close session logic, refactor existing API in SAP module.

CRs-Fixed: 2147969
Change-Id: Iccc5ddd2b14ec2b27e6746a211edd10ec06ad434
2017-11-22 17:41:23 -08:00
Krunal Soni
5943765644 qcacld-3.0: Rename few SAP APIs & introduce the new wrapper APIs
wlansap_open(), wlansap_close(), wlansap_start(), and wlansap_stop()
APIs are not doing what their names' suggest. Rename these APIs such
a way that they reflect the true meaning of it.

Introduce two new APIs to create and destroy the sap context.

CRs-Fixed: 2147974
Change-Id: Ie0475df480d1b19e796ddf3b639de3078a5a61a0
2017-11-22 17:41:17 -08:00
Nachiket Kukade
d915283486 qcacld-3.0: Correction in conditional logic in key operations
In set default key operation module, under SAP mode, there are
conditional checks on key type information derived from the
Station's context. Also in get/add key operations SAP or STA
context pointers are derived without knowing the device mode
first, which is incorrect.

Derive key type info from SAP context in set default key and
derive station or sap context pointers only after knowing the
device mode.

Change-Id: I09b0e6f8d6315677e7584c7c24f003daa3eca9a3
CRs-Fixed: 2127288
2017-11-15 23:36:57 -08:00
Jeff Johnson
c1e6278e02 qcacld-3.0: Use enum QDF_OPMODE
Change "qcacmn: Rename enum tQDF_ADAPTER_MODE" (qca-wifi-host-cmn
Change-Id I20f1b6d1a0ab4b8fe6a85cefdff96a49e2f4652c) renamed enum
tQDF_ADAPTER_MODE to QDF_OPMODE. Update all references to use the
new name.

Change-Id: Ic6f663dac11a100f168b2626c7c0fbcaccbfca4f
CRs-Fixed: 2141065
2017-11-10 00:27:42 -08:00
Jeff Johnson
e6bf719666 qcacld-3.0: Rename struct tagCsrDelStaParams
Per the Linux coding style "mixed-case names are frowned upon" so
rename struct tagCsrDelStaParams.

Change-Id: I60d6448f4bae15e604a8ea55e72a6070a6ebdfbe
CRs-Fixed: 2140346
2017-11-08 19:42:43 -08:00
lifeng
7c607dd603 qcacld-3.0: Add a timer to reduce and resume beacon interval
qcacld-2.0 to qcacld-3.0 propagation

Reduce the beacon interval just before the channel switch.
This would help in reducing the downtime on the STA side which
is waiting for beacons from the AP to resume back transmission.

Switch back the beacon_interval to its original value after
the channel switch based on the timeout. This would ensure
there are atleast some beacons sent with increased frequency.

Change-Id: I37db52713d9e2c78abbb97a7cd0274d9da35bfd2
CRs-Fixed: 1094958
2017-11-07 01:13:18 -08:00
lifeng
1c16b6b0ac qcacld-3.0: Enhance dfs beacon tx
qcacld-2.0 to qcacld-3.0 propagation

Send one action frame along with each beacon tx to reduce failure
of channel switching on sta side.

Change-Id: Idbbe1a4bcb4976101680974214fe85d9886ba7d1
CRs-Fixed: 1094958
2017-11-07 01:13:15 -08:00
Jeff Johnson
2ec495d3c9 qcacld-3.0: Remove eSAP_GET_WPSPBC_SESSION_EVENT
"qcacld-3.0: Remove support for eWNI_SME_GET_WPSPBC_SESSION_REQ"
(Change-Id: Ia95c4911600a45d1004b9e6148b1b04f414e2475) removed the
only function which sends eSAP_GET_WPSPBC_SESSION_EVENT. Since this
event is obsolete, remove it.

Change-Id: I9d83f66bce4ec66bc131747254a45d8b6afb5cbb
CRs-Fixed: 2134951
2017-11-02 12:59:15 -07:00
Krunal Soni
f6a367bf53 qcacld-3.0: Make SAP open()-close() & start()-stop() symmetrical
Current driver is not having wlansap_open() and wlansap_close()
symmetrical and same goes for wlansap_start() and wlansap_stop()
which may create confusion in understanding.

Create a symmetry and clean-up any unnecessary data-structure.

CRs-Fixed: 2135995
Change-Id: I2c3b96e1f2ee44c9f1158108d4b5e48495222080
2017-11-01 17:39:02 -07:00
Srinivas Girigowda
ea4d806da9 qcacld-3.0: Fix checkpatch warnings (SPACING)
Fix checkpatch warnings (SPACING).

Change-Id: I966fe641b4722cc15584defc42c90921090687fb
CRs-Fixed: 2126814
2017-10-24 16:40:54 -07:00
Wu Gao
aa5e3f7476 qcacld-3.0: Remove legacy P2P codes in SAP
To reduce code size, remove legacy P2P codes in SAP layer. Remove
P2P files from Kbuild.

Change-Id: I83a704d3f03e9cb9e6a7420f32d609a323799a12
CRs-Fixed: 2111575
2017-10-18 23:50:55 -07:00
Krunal Soni
22208393bb qcacld-3.0: Remove SAP connection from policy manager upon stopbss
If SAP has no channel left to move then it will issue stop bss. In this
scenario, SAP is not cleaning up its entry from policy manager table
which causes stale entry left over in table.

Fix this situation by stopping the bss successfully and deleting entry
from policy manager table.

Change-Id: I7c7d305936fe16b0deebb9b7a67f7753cbf243e6
CRs-Fixed: 2112932
2017-10-16 16:44:13 -07:00
Jeff Johnson
e13d806b89 qcacld-3.0: Rename pSapCtx to sap_ctx
The Linux Coding Style frowns upon mixed-case names and so-called
Hungarian notation, so rename pSapCtx to sap_ctx to align with the
Coding Style.

Change-Id: I9402132fc20cbb7e9041ec9f112eaa2af258a0d4
CRs-Fixed: 2118452
2017-09-28 21:59:32 -07:00
Jeff Johnson
164b3bb59f qcacld-3.0: Refine API wlansap_channel_change_request()
See change "qcacld-3.0: Refine API wlansap_open()" for the API
history.  Update wlansap_channel_change_request() to use the
true struct pointer type.

Change-Id: I829d33be89e319d6e81b99b94badb023109c29b2
CRs-Fixed: 2116267
2017-09-28 03:49:03 -07:00
Jeff Johnson
3abdd24af4 qcacld-3.0: Refine API wlansap_start_beacon_req()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_start_beacon_req() to use the true struct pointer type.

Change-Id: I92bb5538425b7f9c8d366854e59bdb57eb8c19aa
CRs-Fixed: 2116267
2017-09-28 03:49:01 -07:00
Jeff Johnson
bfeafc6ba7 qcacld-3.0: Refine API wlansap_dfs_send_csa_ie_request()
See change "qcacld-3.0: Refine API wlansap_open()" for the API
history.  Update wlansap_dfs_send_csa_ie_request() to use the
true struct pointer type.

Change-Id: I7abb2cdefab70e6c7997f438221a7f0aa4c8e3af
CRs-Fixed: 2116267
2017-09-28 03:48:58 -07:00
Jeff Johnson
ed4ed172fc qcacld-3.0: Refine API wlan_sap_set_vendor_acs()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlan_sap_set_vendor_acs() to use the true struct pointer type.

Change-Id: Iba77a686dc08251dbaee74554ee7de3080ad8b64
CRs-Fixed: 2116267
2017-09-28 03:48:56 -07:00
Jeff Johnson
b26e270d4e qcacld-3.0: Refine API wlansap_get_dfs_nol()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_get_dfs_nol() to use the true struct pointer type.

Change-Id: I4a430915f8e1cb5378f80e5d6cb34690e33160ea
CRs-Fixed: 2116267
2017-09-28 03:48:54 -07:00
Jeff Johnson
b3c4f7e460 qcacld-3.0: Refine API wlansap_set_dfs_nol()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_set_dfs_nol() to use the true struct pointer type.

Change-Id: I762ef985ee5ec40c79d4cdaafc4e89710edb2366
CRs-Fixed: 2116267
2017-09-28 03:48:52 -07:00
Jeff Johnson
14ec0689da qcacld-3.0: Refine API wlansap_cleanup_cac_timer()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_cleanup_cac_timer() to use the true struct pointer type.
And since this removes that last usage of CDS_GET_SAP_CB(), remove the
now obsolete macro.

Change-Id: I35338df7dc8cf74cb491d5c901200d685b40a55e
CRs-Fixed: 2116267
2017-09-28 03:48:48 -07:00
Jeff Johnson
104433afa3 qcacld-3.0: Refine API wlansap_set_invalid_session()
See change "qcacld-3.0: Refine API wlansap_open()" for the API
history.  Update wlansap_set_invalid_session() to use the true
struct pointer type.

Change-Id: Ib7c56dd9b04ececdb7518648f6ba9cc3e3ed7428
CRs-Fixed: 2116267
2017-09-28 03:48:39 -07:00
Jeff Johnson
92675a5d15 qcacld-3.0: Refine API wlansap_get_chan_width()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_get_chan_width() to use the true struct pointer type.

Change-Id: Iec86249524c042ae6dba818bb5983fd91d9e61fd
CRs-Fixed: 2116267
2017-09-28 03:48:37 -07:00
Jeff Johnson
630fd6a3c3 qcacld-3.0: Refine API wlansap_acs_chselect()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_acs_chselect() to use the true struct pointer type.

Change-Id: I954c519954207c5cc487296dd42b8b2b46c08173
CRs-Fixed: 2116267
2017-09-28 03:48:35 -07:00
Jeff Johnson
bc110a7828 qcacld-3.0: Refine API sap_is_auto_channel_select()
See change "qcacld-3.0: Refine API wlansap_open()" for the API
history.  Update sap_is_auto_channel_select() to use the true
struct pointer type.

Change-Id: I9a233ba67f773edce6a866dc0664f92cf3610c81
CRs-Fixed: 2116267
2017-09-28 03:48:33 -07:00
Jeff Johnson
a68cc538cd qcacld-3.0: Refine API wlan_sap_set_pre_cac_complete_status()
See change "qcacld-3.0: Refine API wlansap_open()" for the API
history.  Update wlan_sap_set_pre_cac_complete_status() to use
the true struct pointer type.

Change-Id: I814af33f02c847e542bb3c1b87d1f8da3cd82ff1
CRs-Fixed: 2116267
2017-09-28 03:48:31 -07:00
Jeff Johnson
2cdcfdcd69 qcacld-3.0: Refine API wlan_sap_set_chan_before_pre_cac()
See change "qcacld-3.0: Refine API wlansap_open()" for the API
history.  Update wlan_sap_set_chan_before_pre_cac() to use the
true struct pointer type.

Change-Id: I4dd1a526645317560a2929ddc4fed496d71867d1
CRs-Fixed: 2116267
2017-09-28 03:48:29 -07:00
Jeff Johnson
108566e1e1 qcacld-3.0: Refine API wlan_sap_set_pre_cac_status()
See change "qcacld-3.0: Refine API wlansap_open()" for the API
history.  Update wlan_sap_set_pre_cac_status() to use the true
struct pointer type.

Change-Id: Ic9ee7bfa01eb01c7c8c6b665c25300611fb7edde
CRs-Fixed: 2116267
2017-09-28 03:48:26 -07:00
Jeff Johnson
cd1ee1eedd qcacld-3.0: Refine API wlan_sap_update_next_channel()
See change "qcacld-3.0: Refine API wlansap_open()" for the API
history.  Update wlan_sap_update_next_channel() to use the true
struct pointer type.

Change-Id: I10226f1bc7d4e47fb363de54b4bc0bc7784416ef
CRs-Fixed: 2116267
2017-09-28 03:48:24 -07:00
Jeff Johnson
d4ca1e5b46 qcacld-3.0: Refine API wlansap_cancel_remain_on_channel()
See change "qcacld-3.0: Refine API wlansap_open()" for the API
history.  Update wlansap_cancel_remain_on_channel() to use the
true struct pointer type.

Change-Id: Ibaa79aa4edd9c60915319e2b8f507e70acc0d774
CRs-Fixed: 2116267
2017-09-28 03:48:21 -07:00
Jeff Johnson
eea4e304b6 qcacld-3.0: Refine API wlansap_remain_on_channel()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_remain_on_channel() to use the true struct pointer type.

Change-Id: Iaa8be32f34e61da652b74e67c36d1cf27f13d961
CRs-Fixed: 2116267
2017-09-28 03:48:19 -07:00
Jeff Johnson
730c250ce5 qcacld-3.0: Refine API wlansap_send_action()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_send_action() to use the true struct pointer type.

Change-Id: I122b84fd9156558789b1b9d87120804d5598f3a4
CRs-Fixed: 2116267
2017-09-28 03:48:17 -07:00
Jeff Johnson
e6b25d9878 qcacld-3.0: Refine API wlansap_set_key_sta()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_set_key_sta() to use the true struct pointer type.

Change-Id: I401f5dcf04547b263daf89b75cd17a6768d9f1d5
CRs-Fixed: 2116267
2017-09-28 03:48:14 -07:00
Jeff Johnson
52a2ce3d16 qcacld-3.0: Refine API wlansap_set_channel_change_with_csa()
See change "qcacld-3.0: Refine API wlansap_open()" for the API
history.  Update wlansap_set_channel_change_with_csa() to use
the true struct pointer type.

Change-Id: Ia4b31f9f726528e9c76f60d4fc314fc87b892555
CRs-Fixed: 2116267
2017-09-28 03:48:12 -07:00
Jeff Johnson
e7ff1d07db qcacld-3.0: Refine API wlansap_deauth_sta()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_deauth_sta() to use the true struct pointer type.

Change-Id: Ia58822ad42d2a36333c4c085f6a4f4498d70e5f8
CRs-Fixed: 2116267
2017-09-28 03:48:10 -07:00
Jeff Johnson
92e867c568 qcacld-3.0: Refine API wlansap_disassoc_sta()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_disassoc_sta() to use the true struct pointer type.

Change-Id: I20209f92b7313026aee712a639f3605619255079
CRs-Fixed: 2116267
2017-09-28 03:48:08 -07:00
Jeff Johnson
31d1a74d61 qcacld-3.0: Refine API wlansap_clear_acl()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_clear_acl() to use the true struct pointer type.

Change-Id: I7ffab7e01a107ad476c2a02ffb60bad4d9b62a97
CRs-Fixed: 2116267
2017-09-28 03:48:06 -07:00
Jeff Johnson
49c819f9a0 qcacld-3.0: Refine API wlansap_get_acl_deny_list()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_get_acl_deny_list() to use the true struct pointer type.

Change-Id: I8d0981b6a11d854fc3f4b228703271608367bcab
CRs-Fixed: 2116267
2017-09-28 03:48:03 -07:00
Jeff Johnson
878f6d5cff qcacld-3.0: Refine API wlansap_get_acl_accept_list()
See change "qcacld-3.0: Refine API wlansap_open()" for the API
history.  Update wlansap_get_acl_accept_list() to use the true
struct pointer type.

Change-Id: I6dd326745fee2769753afb71f64bbf6ef3023a22
CRs-Fixed: 2116267
2017-09-28 03:48:01 -07:00
Jeff Johnson
1030f8c403 qcacld-3.0: Refine API wlansap_get_acl_mode()
See change "qcacld-3.0: Refine API wlansap_open()" for the API history.
Update wlansap_get_acl_mode() to use the true struct pointer type.

Change-Id: I4eb660074e58ce7cf6d74b755a12ec10961766b4
CRs-Fixed: 2116267
2017-09-28 03:47:59 -07:00