blob: 6dbd4aea3e28fd1ad3c89c31c956b651b3a527ab [file] [log] [blame]
Sandeep Puligillac5609d52018-05-17 19:23:41 -07001/*
Abhishek Singh7c1c7432019-04-04 12:11:57 +05302 * Copyright (c) 2018-2019 The Linux Foundation. All rights reserved.
Sandeep Puligillac5609d52018-05-17 19:23:41 -07003 *
4 * Permission to use, copy, modify, and/or distribute this software for
5 * any purpose with or without fee is hereby granted, provided that the
6 * above copyright notice and this permission notice appear in all
7 * copies.
8 *
9 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
10 * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
11 * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
12 * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
13 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
14 * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
15 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
16 * PERFORMANCE OF THIS SOFTWARE.
17 */
18/**
Vignesh Viswanathan21c58cb2018-05-24 15:53:58 +053019 * DOC: declare internal API related to the mlme component
Sandeep Puligillac5609d52018-05-17 19:23:41 -070020 */
21
22#ifndef _WLAN_MLME_MAIN_H_
23#define _WLAN_MLME_MAIN_H_
24
25#include <wlan_mlme_public_struct.h>
Sandeep Puligillac5609d52018-05-17 19:23:41 -070026#include <wlan_objmgr_psoc_obj.h>
27#include <wlan_objmgr_global_obj.h>
28#include <wlan_cmn.h>
gaurank kathpalia24ed0f42018-11-13 15:37:49 +053029#include <wlan_objmgr_vdev_obj.h>
Abhishek Singh7c1c7432019-04-04 12:11:57 +053030#include <wlan_objmgr_peer_obj.h>
Sandeep Puligillac5609d52018-05-17 19:23:41 -070031
Abhishek Ambureec000072019-05-03 12:38:42 +053032#define mlme_legacy_fatal(params...) QDF_TRACE_FATAL(QDF_MODULE_ID_MLME, params)
33#define mlme_legacy_err(params...) QDF_TRACE_ERROR(QDF_MODULE_ID_MLME, params)
34#define mlme_legacy_warn(params...) QDF_TRACE_WARN(QDF_MODULE_ID_MLME, params)
35#define mlme_legacy_info(params...) QDF_TRACE_INFO(QDF_MODULE_ID_MLME, params)
36#define mlme_legacy_debug(params...) QDF_TRACE_DEBUG(QDF_MODULE_ID_MLME, params)
Sandeep Puligillac5609d52018-05-17 19:23:41 -070037
38/**
Arun Kumar Khandavallia43590e2019-08-26 17:13:25 +053039 * struct wlan_mlme_psoc_ext_obj -MLME ext psoc priv object
Sandeep Puligillac5609d52018-05-17 19:23:41 -070040 * @cfg: cfg items
41 */
Arun Kumar Khandavallia43590e2019-08-26 17:13:25 +053042struct wlan_mlme_psoc_ext_obj {
Sandeep Puligillac5609d52018-05-17 19:23:41 -070043 struct wlan_mlme_cfg cfg;
44};
45
Abhishek Singh7c1c7432019-04-04 12:11:57 +053046/**
Srinivas Dasari37e37312019-06-30 23:50:24 +053047 * struct wlan_ies - Generic WLAN Information Element(s) format
48 * @len: Total length of the IEs
49 * @data: IE data
50 */
51struct wlan_ies {
52 uint16_t len;
53 uint8_t *data;
54};
55
56/**
Abhishek Singh7c1c7432019-04-04 12:11:57 +053057 * struct peer_mlme_priv_obj - peer MLME component object
58 * @ucast_key_cipher: unicast crypto type.
Srinivas Dasaricc863f02019-09-05 17:18:48 +053059 * @is_pmf_enabled: True if PMF is enabled
Abhishek Singh7c1c7432019-04-04 12:11:57 +053060 */
61struct peer_mlme_priv_obj {
62 uint32_t ucast_key_cipher;
Srinivas Dasaricc863f02019-09-05 17:18:48 +053063 bool is_pmf_enabled;
Abhishek Singh7c1c7432019-04-04 12:11:57 +053064};
65
gaurank kathpalia24ed0f42018-11-13 15:37:49 +053066/**
67 * enum vdev_assoc_type - VDEV associate/reassociate type
68 * @VDEV_ASSOC: associate
69 * @VDEV_REASSOC: reassociate
70 * @VDEV_FT_REASSOC: fast reassociate
71 */
72enum vdev_assoc_type {
73 VDEV_ASSOC,
74 VDEV_REASSOC,
75 VDEV_FT_REASSOC
76};
77
78/**
Yeshwanth Sriram Guntukaea2fb372019-08-28 12:21:16 +053079 * wlan_mlme_roam_state_info - Structure containing roaming
80 * state related details
81 * @state: Roaming module state.
82 * @mlme_operations_bitmap: Bitmap containing what mlme operations are in
83 * progress where roaming should not be allowed.
84 */
85struct wlan_mlme_roam_state_info {
86 enum roam_offload_state state;
87 uint8_t mlme_operations_bitmap;
88};
89
90/**
91 * struct wlan_mlme_roaming_config - Roaming configurations structure
92 * @roam_trigger_bitmap: Master bitmap of roaming triggers. If the bitmap is
93 * zero, roaming module will be deinitialized at firmware for this vdev.
94 * @supplicant_disabled_roaming: Enable/disable roam scan in firmware; will be
95 * used by supplicant to do roam invoke after disabling roam scan in firmware
96 */
97struct wlan_mlme_roaming_config {
98 uint32_t roam_trigger_bitmap;
99 bool supplicant_disabled_roaming;
100};
101
102/**
103 * struct wlan_mlme_roam - Roam structure containing roam state and
104 * roam config info
105 * @roam_sm: Structure containing roaming state related details
106 * @roam_config: Roaming configurations structure
107 */
108struct wlan_mlme_roam {
109 struct wlan_mlme_roam_state_info roam_sm;
110 struct wlan_mlme_roaming_config roam_cfg;
111};
112
113/**
gaurank kathpalia24ed0f42018-11-13 15:37:49 +0530114 * struct mlme_legacy_priv - VDEV MLME legacy priv object
115 * @chan_switch_in_progress: flag to indicate that channel switch is in progress
116 * @hidden_ssid_restart_in_progress: flag to indicate hidden ssid restart is
117 * in progress
118 * @vdev_start_failed: flag to indicate that vdev start failed.
119 * @connection_fail: flag to indicate connection failed
Abhishek Singh06522c52019-05-08 12:13:42 +0530120 * @cac_required_for_new_channel: if CAC is required for new channel
Paul Zhangd34b5752019-10-09 11:22:32 +0800121 * @follow_ap_edca: if true, it is forced to follow the AP's edca.
gaurank kathpalia24ed0f42018-11-13 15:37:49 +0530122 * @assoc_type: vdev associate/reassociate type
123 * @dynamic_cfg: current configuration of nss, chains for vdev.
124 * @ini_cfg: Max configuration of nss, chains supported for vdev.
Bala Venkateshaccb9ddb2019-04-04 17:41:58 +0530125 * @sta_dynamic_oce_value: Dyanmic oce flags value for sta
gaurank kathpalia7ef72182019-05-29 19:41:25 +0530126 * @roam_invoke_params: Roam invoke params
Srinivas Dasari37e37312019-06-30 23:50:24 +0530127 * @self_disconnect_ies: Disconnect IEs to be sent in deauth/disassoc frames
128 * originated from driver
Srinivas Dasarid4e87252019-07-01 15:35:52 +0530129 * @peer_disconnect_ies: Disconnect IEs received in deauth/disassoc frames
130 * from peer
Abhishek Ambure968f1512019-08-28 18:33:57 +0530131 * @vdev_stop_type: vdev stop type request
Yeshwanth Sriram Guntukaea2fb372019-08-28 12:21:16 +0530132 * @roam_off_state: Roam offload state
gaurank kathpalia24ed0f42018-11-13 15:37:49 +0530133 */
134struct mlme_legacy_priv {
135 bool chan_switch_in_progress;
136 bool hidden_ssid_restart_in_progress;
137 bool vdev_start_failed;
138 bool connection_fail;
Abhishek Singh06522c52019-05-08 12:13:42 +0530139 bool cac_required_for_new_channel;
Paul Zhangd34b5752019-10-09 11:22:32 +0800140 bool follow_ap_edca;
gaurank kathpalia24ed0f42018-11-13 15:37:49 +0530141 enum vdev_assoc_type assoc_type;
142 struct wlan_mlme_nss_chains dynamic_cfg;
143 struct wlan_mlme_nss_chains ini_cfg;
Bala Venkateshaccb9ddb2019-04-04 17:41:58 +0530144 uint8_t sta_dynamic_oce_value;
gaurank kathpalia7ef72182019-05-29 19:41:25 +0530145 struct mlme_roam_after_data_stall roam_invoke_params;
Srinivas Dasari37e37312019-06-30 23:50:24 +0530146 struct wlan_ies self_disconnect_ies;
Srinivas Dasarid4e87252019-07-01 15:35:52 +0530147 struct wlan_ies peer_disconnect_ies;
Abhishek Ambure968f1512019-08-28 18:33:57 +0530148 uint32_t vdev_stop_type;
Yeshwanth Sriram Guntukaea2fb372019-08-28 12:21:16 +0530149 struct wlan_mlme_roam mlme_roam;
gaurank kathpalia24ed0f42018-11-13 15:37:49 +0530150};
151
Abhishek Singhf880a7d2019-04-29 14:51:11 +0530152#ifndef CRYPTO_SET_KEY_CONVERGED
Sandeep Puligillac5609d52018-05-17 19:23:41 -0700153/**
Abhishek Singh7c1c7432019-04-04 12:11:57 +0530154 * wlan_peer_set_unicast_cipher() - set unicast cipher
155 * @peer: PEER object
156 * @value: value to be set
157 *
158 * Return: void
159 */
160static inline
161void wlan_peer_set_unicast_cipher(struct wlan_objmgr_peer *peer, uint32_t value)
162{
163 struct peer_mlme_priv_obj *peer_priv;
164
165 peer_priv = wlan_objmgr_peer_get_comp_private_obj(peer,
166 WLAN_UMAC_COMP_MLME);
167 if (!peer_priv) {
Abhishek Ambureec000072019-05-03 12:38:42 +0530168 mlme_legacy_err(" peer mlme component object is NULL");
Abhishek Singh7c1c7432019-04-04 12:11:57 +0530169 return;
170 }
171 peer_priv->ucast_key_cipher = value;
172}
173
174/**
175 * wlan_peer_get_unicast_cipher() - get unicast cipher
176 * @peer: PEER object
177 *
178 * Return: ucast_key_cipher value
179 */
180static inline
181uint32_t wlan_peer_get_unicast_cipher(struct wlan_objmgr_peer *peer)
182{
183 struct peer_mlme_priv_obj *peer_priv;
184
185 peer_priv = wlan_objmgr_peer_get_comp_private_obj(peer,
186 WLAN_UMAC_COMP_MLME);
187 if (!peer_priv) {
Abhishek Ambureec000072019-05-03 12:38:42 +0530188 mlme_legacy_err("peer mlme component object is NULL");
Abhishek Singh7c1c7432019-04-04 12:11:57 +0530189 return 0;
190 }
191
192 return peer_priv->ucast_key_cipher;
193}
Abhishek Singhf880a7d2019-04-29 14:51:11 +0530194#endif
Abhishek Singh7c1c7432019-04-04 12:11:57 +0530195/**
196 * wma_get_peer_mic_len() - get mic hdr len and mic length for peer
197 * @psoc: psoc
198 * @pdev_id: pdev id for the peer
199 * @peer_mac: peer mac
200 * @mic_len: mic length for peer
201 * @mic_hdr_len: mic header length for peer
202 *
203 * Return: Success or Failure status
204 */
205QDF_STATUS mlme_get_peer_mic_len(struct wlan_objmgr_psoc *psoc, uint8_t pdev_id,
206 uint8_t *peer_mac, uint8_t *mic_len,
207 uint8_t *mic_hdr_len);
208
209/**
210 * mlme_peer_object_created_notification(): mlme peer create handler
211 * @peer: peer which is going to created by objmgr
212 * @arg: argument for vdev create handler
213 *
214 * Register this api with objmgr to detect peer is created
215 *
216 * Return: QDF_STATUS status in case of success else return error
217 */
218
219QDF_STATUS
220mlme_peer_object_created_notification(struct wlan_objmgr_peer *peer,
221 void *arg);
222
223/**
224 * mlme_peer_object_destroyed_notification(): mlme peer delete handler
225 * @peer: peer which is going to delete by objmgr
226 * @arg: argument for vdev delete handler
227 *
228 * Register this api with objmgr to detect peer is deleted
229 *
230 * Return: QDF_STATUS status in case of success else return error
231 */
232QDF_STATUS
233mlme_peer_object_destroyed_notification(struct wlan_objmgr_peer *peer,
234 void *arg);
235
236/**
Bala Venkateshaccb9ddb2019-04-04 17:41:58 +0530237 * mlme_get_dynamic_oce_flags(): mlme get dynamic oce flags
238 * @vdev: pointer to vdev object
239 *
240 * This api is used to get the dynamic oce flags pointer
241 *
242 * Return: QDF_STATUS status in case of success else return error
243 */
244uint8_t *mlme_get_dynamic_oce_flags(struct wlan_objmgr_vdev *vdev);
245
246/**
gaurank kathpalia991e2fa2018-11-12 21:48:06 +0530247 * mlme_get_dynamic_vdev_config() - get the vdev dynamic config params
248 * @vdev: vdev pointer
249 *
250 * Return: pointer to the dynamic vdev config structure
251 */
252struct wlan_mlme_nss_chains *mlme_get_dynamic_vdev_config(
253 struct wlan_objmgr_vdev *vdev);
254
255/**
256 * mlme_get_ini_vdev_config() - get the vdev ini config params
257 * @vdev: vdev pointer
258 *
259 * Return: pointer to the ini vdev config structure
260 */
261struct wlan_mlme_nss_chains *mlme_get_ini_vdev_config(
262 struct wlan_objmgr_vdev *vdev);
263
264/**
gaurank kathpalia7ef72182019-05-29 19:41:25 +0530265 * mlme_get_roam_invoke_params() - get the roam invoke params
266 * @vdev: vdev pointer
267 *
268 * Return: pointer to the vdev roam invoke config structure
269 */
270struct mlme_roam_after_data_stall *
271mlme_get_roam_invoke_params(struct wlan_objmgr_vdev *vdev);
272
273/**
Vignesh Viswanathan21c58cb2018-05-24 15:53:58 +0530274 * mlme_cfg_on_psoc_enable() - Populate MLME structure from CFG and INI
275 * @psoc: pointer to the psoc object
276 *
277 * Populate the MLME CFG structure from CFG and INI values using CFG APIs
278 *
279 * Return: QDF_STATUS
280 */
281QDF_STATUS mlme_cfg_on_psoc_enable(struct wlan_objmgr_psoc *psoc);
282
283/**
Arun Kumar Khandavallia43590e2019-08-26 17:13:25 +0530284 * mlme_get_psoc_ext_obj() - Get MLME object from psoc
Vignesh Viswanathan21c58cb2018-05-24 15:53:58 +0530285 * @psoc: pointer to the psoc object
286 *
287 * Get the MLME object pointer from the psoc
288 *
289 * Return: pointer to MLME object
290 */
Arun Kumar Khandavallia43590e2019-08-26 17:13:25 +0530291#define mlme_get_psoc_ext_obj(psoc) \
292 mlme_get_psoc_ext_obj_fl(psoc, __func__, __LINE__)
293struct wlan_mlme_psoc_ext_obj *mlme_get_psoc_ext_obj_fl(struct wlan_objmgr_psoc
294 *psoc,
295 const char *func,
296 uint32_t line);
Vignesh Viswanathan21c58cb2018-05-24 15:53:58 +0530297
Manikandan Mohan2bd09772018-11-28 18:27:32 -0800298/**
299 * mlme_init_ibss_cfg() - Init IBSS config data structure with default CFG value
300 * @psoc: pointer to the psoc object
301 * @ibss_cfg: Pointer to IBSS cfg data structure to return values
302 *
303 * Return: QDF_STATUS
304 */
305QDF_STATUS mlme_init_ibss_cfg(struct wlan_objmgr_psoc *psoc,
306 struct wlan_mlme_ibss_cfg *ibss_cfg);
307
Srinivas Dasari37e37312019-06-30 23:50:24 +0530308/**
309 * mlme_set_self_disconnect_ies() - Set diconnect IEs configured from userspace
310 * @vdev: vdev pointer
311 * @ie: pointer for disconnect IEs
312 *
313 * Return: None
314 */
315void mlme_set_self_disconnect_ies(struct wlan_objmgr_vdev *vdev,
316 struct wlan_ies *ie);
317
318/**
319 * mlme_free_self_disconnect_ies() - Free the self diconnect IEs
320 * @vdev: vdev pointer
321 *
322 * Return: None
323 */
324void mlme_free_self_disconnect_ies(struct wlan_objmgr_vdev *vdev);
Srinivas Dasarie2ee0942019-06-29 14:34:50 +0530325
326/**
327 * mlme_get_self_disconnect_ies() - Get diconnect IEs from vdev object
328 * @vdev: vdev pointer
329 *
330 * Return: Returns a pointer to the self disconnect IEs present in vdev object
331 */
332struct wlan_ies *mlme_get_self_disconnect_ies(struct wlan_objmgr_vdev *vdev);
Srinivas Dasarid4e87252019-07-01 15:35:52 +0530333
334/**
335 * mlme_set_peer_disconnect_ies() - Cache disconnect IEs received from peer
336 * @vdev: vdev pointer
337 * @ie: pointer for disconnect IEs
338 *
339 * Return: None
340 */
341void mlme_set_peer_disconnect_ies(struct wlan_objmgr_vdev *vdev,
342 struct wlan_ies *ie);
343
344/**
345 * mlme_free_peer_disconnect_ies() - Free the peer diconnect IEs
346 * @vdev: vdev pointer
347 *
348 * Return: None
349 */
350void mlme_free_peer_disconnect_ies(struct wlan_objmgr_vdev *vdev);
351
352/**
Paul Zhangd34b5752019-10-09 11:22:32 +0800353 * mlme_set_follow_ap_edca_flag() - Set follow ap's edca flag
354 * @vdev: vdev pointer
355 * @flag: carries if following ap's edca is true or not.
356 *
357 * Return: None
358 */
359void mlme_set_follow_ap_edca_flag(struct wlan_objmgr_vdev *vdev, bool flag);
360
361/**
362 * mlme_get_follow_ap_edca_flag() - Get follow ap's edca flag
363 * @vdev: vdev pointer
364 *
365 * Return: value of follow_ap_edca
366 */
367bool mlme_get_follow_ap_edca_flag(struct wlan_objmgr_vdev *vdev);
368
369/**
Srinivas Dasarid4e87252019-07-01 15:35:52 +0530370 * mlme_get_peer_disconnect_ies() - Get diconnect IEs from vdev object
371 * @vdev: vdev pointer
372 *
373 * Return: Returns a pointer to the peer disconnect IEs present in vdev object
374 */
375struct wlan_ies *mlme_get_peer_disconnect_ies(struct wlan_objmgr_vdev *vdev);
Srinivas Dasaricc863f02019-09-05 17:18:48 +0530376
377/**
378 * mlme_set_peer_pmf_status() - set pmf status of peer
379 * @peer: PEER object
380 * @is_pmf_enabled: Carries if PMF is enabled or not
381 *
382 * is_pmf_enabled will be set to true if PMF is enabled by peer
383 *
384 * Return: void
385 */
386void mlme_set_peer_pmf_status(struct wlan_objmgr_peer *peer,
387 bool is_pmf_enabled);
388/**
389 * mlme_get_peer_pmf_status() - get if peer is of pmf capable
390 * @peer: PEER object
391 *
392 * Return: Value of is_pmf_enabled; True if PMF is enabled by peer
393 */
394bool mlme_get_peer_pmf_status(struct wlan_objmgr_peer *peer);
Yeshwanth Sriram Guntukaea2fb372019-08-28 12:21:16 +0530395
396#if defined(WLAN_FEATURE_HOST_ROAM) || defined(WLAN_FEATURE_ROAM_OFFLOAD)
397/**
398 * mlme_get_supplicant_disabled_roaming() - Get supplicant disabled roaming
399 * value for a given vdev.
400 * @psoc: PSOC pointer
401 * @vdev_id: Vdev for which the supplicant disabled roaming value is being
402 * requested
403 *
404 * Return: True if supplicant disabled roaming else false
405 */
406bool
407mlme_get_supplicant_disabled_roaming(struct wlan_objmgr_psoc *psoc,
408 uint8_t vdev_id);
409
410/**
411 * mlme_set_supplicant_disabled_roaming - Set the supplicant disabled
412 * roaming flag.
413 * @psoc: PSOC pointer
414 * @vdev_id: Vdev for which the supplicant disabled roaming needs to
415 * be set
416 * @val: value true is to disable RSO and false to enable RSO
417 *
418 * Return: None
419 */
420void mlme_set_supplicant_disabled_roaming(struct wlan_objmgr_psoc *psoc,
421 uint8_t vdev_id, bool val);
422
423/**
424 * mlme_get_roam_trigger_bitmap() - Get roaming trigger bitmap value for a given
425 * vdev.
426 * @psoc: PSOC pointer
427 * @vdev_id: Vdev for which the roam trigger bitmap is being requested
428 *
429 * Return: roaming trigger bitmap
430 */
431uint32_t
432mlme_get_roam_trigger_bitmap(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id);
433
434/**
435 * mlme_set_roam_trigger_bitmap() - Set the roaming trigger bitmap value for
436 * the given vdev. If the bitmap is zero then roaming is completely disabled
437 * on the vdev which means roam structure in firmware is not allocated and no
438 * RSO start/stop commands can be sent
439 * @psoc: PSOC pointer
440 * @vdev_id: Vdev for which the roam trigger bitmap is to be set
441 * @val: bitmap value to set
442 *
443 * Return: None
444 */
445void mlme_set_roam_trigger_bitmap(struct wlan_objmgr_psoc *psoc,
446 uint8_t vdev_id, uint32_t val);
447
448/**
449 * mlme_get_roam_state() - Get roam state from vdev object
450 * @psoc: psoc pointer
451 * @vdev_id: vdev id
452 *
453 * Return: Returns roam offload state
454 */
455enum roam_offload_state
456mlme_get_roam_state(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id);
457
458/**
459 * mlme_set_roam_state() - Set roam state in vdev object
460 * @psoc: psoc pointer
461 * @vdev_id: vdev id
462 * @val: roam offload state
463 *
464 * Return: None
465 */
466void mlme_set_roam_state(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
467 enum roam_offload_state val);
468
469/**
470 * mlme_get_operations_bitmap() - Get the mlme operations bitmap which
471 * contains the bitmap of mlme operations which have disabled roaming
472 * temporarily
473 * @psoc: PSOC pointer
474 * @vdev_id: vdev for which the mlme operation bitmap is requested
475 *
476 * Return: bitmap value
477 */
478uint8_t
479mlme_get_operations_bitmap(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id);
480
481/**
482 * mlme_set_operations_bitmap() - Set the mlme operations bitmap which
483 * indicates what mlme operations are in progress
484 * @psoc: PSOC pointer
485 * @vdev_id: vdev for which the mlme operation bitmap is requested
486 * @reqs: RSO stop requestor
487 * @clear: clear bit if true else set bit
488 *
489 * Return: bitmap value
490 */
491void
492mlme_set_operations_bitmap(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
493 enum roam_control_requestor reqs, bool clear);
494
495#define MLME_IS_ROAM_STATE_RSO_STARTED(psoc, vdev_id) \
496 (mlme_get_roam_state(psoc, vdev_id) == ROAM_RSO_STARTED)
497
498#define MLME_IS_ROAM_STATE_DEINIT(psoc, vdev_id) \
499 (mlme_get_roam_state(psoc, vdev_id) == ROAM_DEINIT)
500
501#define MLME_IS_ROAM_STATE_INIT(psoc, vdev_id) \
502 (mlme_get_roam_state(psoc, vdev_id) == ROAM_INIT)
503
504#define MLME_IS_ROAM_STATE_STOPPED(psoc, vdev_id) \
505 (mlme_get_roam_state(psoc, vdev_id) == ROAM_RSO_STOPPED)
506
507#define MLME_IS_ROAM_INITIALIZED(psoc, vdev_id) \
508 (mlme_get_roam_state(psoc, vdev_id) >= ROAM_INIT)
509#endif
Srinivas Dasari1ec74522019-09-19 14:16:29 +0530510
511/**
512 * mlme_reinit_control_config_lfr_params() - Reinitialize roam control config
513 * @psoc: PSOC pointer
514 * @lfr: Pointer of an lfr_cfg buffer to fill.
515 *
516 * Reinitialize/restore the param related control roam config lfr params with
517 * default values of corresponding ini params.
518 *
519 * Return: None
520 */
521void mlme_reinit_control_config_lfr_params(struct wlan_objmgr_psoc *psoc,
522 struct wlan_mlme_lfr_cfg *lfr);
Sandeep Puligillac5609d52018-05-17 19:23:41 -0700523#endif