1 /*
2  * Copyright (c) 2018-2021 The Linux Foundation. All rights reserved.
3  * Copyright (c) 2021-2024 Qualcomm Innovation Center, Inc. All rights reserved.
4  *
5  * Permission to use, copy, modify, and/or distribute this software for
6  * any purpose with or without fee is hereby granted, provided that the
7  * above copyright notice and this permission notice appear in all
8  * copies.
9  *
10  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
11  * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
12  * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
13  * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
14  * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
15  * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
16  * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
17  * PERFORMANCE OF THIS SOFTWARE.
18  */
19 /**
20  * DOC: declare public APIs exposed by the mlme component
21  */
22 
23 #ifndef _WLAN_MLME_API_H_
24 #define _WLAN_MLME_API_H_
25 
26 #include <wlan_mlme_public_struct.h>
27 #include <wlan_objmgr_psoc_obj.h>
28 #include <wlan_cmn.h>
29 #include "sme_api.h"
30 
31 #define DISABLE_MCS_12_13_2G_40M 1
32 
33 #define ASSEMBLE_RATECODE_V1(_pream, _nss, _rate) \
34 		(((1) << 28) | ((_pream) << 8) | ((_nss) << 5) | (_rate))
35 
36 /* This macro is used to extract the rate from the rate_code as first four bits
37  * in rate_code represents the rate, next 3 bits represents the nss and
38  * next 2 bits represents preamble.
39  */
40 #define RATECODE_V1_RIX_MASK    0xf
41 
42 /* This macro is used to extract preamble from the rate_code as first 4 bits
43  * in rate_code represents the rate, next 3 bits represents the nss and
44  * next 2 bits represents preamble.
45  */
46 #define RATECODE_V1_PREAMBLE_OFFSET (4 + 3)
47 
48 /* This macro is used to extract NSS from the rate_code as first 4 bits
49  * in rate_code represents the rate, next 3 bits represents the NSS and
50  * next 2 bits represents preamble.
51  */
52 #define RATECODE_V1_NSS_OFFSET  0x4
53 #define RATECODE_V1_NSS_MASK    0x7
54 
55 #ifdef FEATURE_SET
56 /**
57  * wlan_mlme_get_feature_info() - Get mlme features
58  * @psoc: psoc context
59  * @mlme_feature_set: MLME feature set info structure
60  *
61  * Return: None
62  */
63 void wlan_mlme_get_feature_info(
64 				struct wlan_objmgr_psoc *psoc,
65 				struct wlan_mlme_features *mlme_feature_set);
66 #endif
67 
68 /**
69  * wlan_mlme_get_cfg_str() - Copy the uint8_t array for a particular CFG
70  * @dst:       pointer to the destination buffer.
71  * @cfg_str:   pointer to the cfg string structure
72  * @len:       length to be copied
73  *
74  * Return: QDF_STATUS_SUCCESS or QDF_STATUS_E_FAILURE
75  */
76 QDF_STATUS wlan_mlme_get_cfg_str(uint8_t *dst, struct mlme_cfg_str *cfg_str,
77 				 qdf_size_t *len);
78 
79 /**
80  * wlan_mlme_set_cfg_str() - Set values for a particular CFG
81  * @src:            pointer to the source buffer.
82  * @dst_cfg_str:    pointer to the cfg string structure to be modified
83  * @len:            length to be written
84  *
85  * Return: QDF_STATUS_SUCCESS or QDF_STATUS_E_FAILURE
86  */
87 QDF_STATUS wlan_mlme_set_cfg_str(uint8_t *src, struct mlme_cfg_str *dst_cfg_str,
88 				 qdf_size_t len);
89 
90 /**
91  * wlan_mlme_get_edca_params() - get the EDCA parameters corresponding to the
92  * edca profile access category
93  * @edca_params:   pointer to mlme edca parameters structure
94  * @data:          data to which the parameter is to be copied
95  * @edca_ac:       edca ac type enum passed to get the cfg value
96  *
97  * Return QDF_STATUS_SUCCESS or QDF_STATUS_E_FAILURE
98  *
99  */
100 QDF_STATUS wlan_mlme_get_edca_params(struct wlan_mlme_edca_params *edca_params,
101 				     uint8_t *data, enum e_edca_type edca_ac);
102 
103 /**
104  * wlan_mlme_update_cfg_with_tgt_caps() - Update mlme cfg with tgt caps
105  * @psoc: pointer to psoc object
106  * @tgt_caps:  Pointer to the mlme related capability structure
107  *
108  * Return: None
109  */
110 void
111 wlan_mlme_update_cfg_with_tgt_caps(struct wlan_objmgr_psoc *psoc,
112 				   struct mlme_tgt_caps *tgt_caps);
113 
114 /**
115  * wlan_mlme_update_aux_dev_caps() - Update mlme aux capability
116  * @psoc: pointer to psoc object
117  * @wlan_mlme_aux_dev_caps:  array for aux dev capability
118  *
119  * Return: None
120  */
121 
122 void
123 wlan_mlme_update_aux_dev_caps(struct wlan_objmgr_psoc *psoc,
124 			      struct wlan_mlme_aux_dev_caps
125 			      wlan_mlme_aux_dev_caps[]);
126 
127 /*
128  * mlme_get_wep_key() - get the wep key to process during auth frame
129  * @vdev: VDEV object for which the wep key is being requested
130  * @wep_params: cfg wep parameters structure
131  * @wep_key_id: default key number
132  * @default_key: default key to be copied
133  * @key_len: length of the key to copy
134  *
135  * Return QDF_STATUS
136  */
137 QDF_STATUS mlme_get_wep_key(struct wlan_objmgr_vdev *vdev,
138 			    struct wlan_mlme_wep_cfg *wep_params,
139 			    enum wep_key_id wep_keyid, uint8_t *default_key,
140 			    qdf_size_t *key_len);
141 
142 /**
143  * wlan_mlme_get_tx_power() - Get the max tx power in particular band
144  * @psoc: pointer to psoc object
145  * @band: 2ghz/5ghz band
146  *
147  * Return: value of tx power in the respective band
148  */
149 uint8_t wlan_mlme_get_tx_power(struct wlan_objmgr_psoc *psoc,
150 			       enum band_info band);
151 
152 /**
153  * wlan_mlme_get_power_usage() - Get the power usage info
154  * @psoc: pointer to psoc object
155  *
156  * Return: pointer to character array of power usage
157  */
158 char *wlan_mlme_get_power_usage(struct wlan_objmgr_psoc *psoc);
159 
160 /**
161  * wlan_mlme_get_enable_deauth_to_disassoc_map() - Get the deauth to disassoc
162  * map
163  * @psoc: pointer to psoc object
164  * @value: pointer to the value which will be filled for the caller
165  *
166  * Return: QDF Status
167  */
168 QDF_STATUS
169 wlan_mlme_get_enable_deauth_to_disassoc_map(struct wlan_objmgr_psoc *psoc,
170 					    bool *value);
171 
172 /**
173  * wlan_mlme_get_ht_cap_info() - Get the HT cap info config
174  * @psoc: pointer to psoc object
175  * @ht_cap_info: pointer to the value which will be filled for the caller
176  *
177  * Return: QDF Status
178  */
179 QDF_STATUS wlan_mlme_get_ht_cap_info(struct wlan_objmgr_psoc *psoc,
180 				     struct mlme_ht_capabilities_info
181 				     *ht_cap_info);
182 
183 /**
184  * wlan_mlme_get_manufacturer_name() - get manufacturer name
185  * @psoc: pointer to psoc object
186  * @pbuf: pointer of the buff which will be filled for the caller
187  * @plen: pointer of max buffer length
188  *        actual length will be returned at this address
189  * This function gets manufacturer name
190  *
191  * Return: QDF_STATUS_SUCCESS - in case of success
192  */
193 QDF_STATUS
194 wlan_mlme_get_manufacturer_name(struct wlan_objmgr_psoc *psoc,
195 				uint8_t *pbuf, uint32_t *plen);
196 
197 /**
198  * wlan_mlme_get_model_number() - get model number
199  * @psoc: pointer to psoc object
200  * @pbuf: pointer of the buff which will be filled for the caller
201  * @plen: pointer of max buffer length
202  *        actual length will be returned at this address
203  * This function gets model number
204  *
205  * Return: QDF_STATUS_SUCCESS - in case of success
206  */
207 QDF_STATUS
208 wlan_mlme_get_model_number(struct wlan_objmgr_psoc *psoc,
209 			   uint8_t *pbuf, uint32_t *plen);
210 
211 /**
212  * wlan_mlme_get_model_name() - get model name
213  * @psoc: pointer to psoc object
214  * @pbuf: pointer of the buff which will be filled for the caller
215  * @plen: pointer of max buffer length
216  *        actual length will be returned at this address
217  * This function gets model name
218  *
219  * Return: QDF_STATUS_SUCCESS - in case of success
220  */
221 QDF_STATUS
222 wlan_mlme_get_model_name(struct wlan_objmgr_psoc *psoc,
223 			 uint8_t *pbuf, uint32_t *plen);
224 
225 /**
226  * wlan_mlme_get_manufacture_product_name() - get manufacture product name
227  * @psoc: pointer to psoc object
228  * @pbuf: pointer of the buff which will be filled for the caller
229  * @plen: pointer of max buffer length
230  *        actual length will be returned at this address
231  * This function gets manufacture product name
232  *
233  * Return: QDF_STATUS_SUCCESS - in case of success
234  */
235 QDF_STATUS
236 wlan_mlme_get_manufacture_product_name(struct wlan_objmgr_psoc *psoc,
237 				       uint8_t *pbuf, uint32_t *plen);
238 
239 /**
240  * wlan_mlme_get_manufacture_product_version() - get manufacture product version
241  * @psoc: pointer to psoc object
242  * @pbuf: pointer of the buff which will be filled for the caller
243  * @plen: pointer of max buffer length
244  *        actual length will be returned at this address
245  * This function gets manufacture product version
246  *
247  * Return: QDF_STATUS_SUCCESS - in case of success
248  */
249 QDF_STATUS
250 wlan_mlme_get_manufacture_product_version(struct wlan_objmgr_psoc *psoc,
251 					  uint8_t *pbuf, uint32_t *plen);
252 
253 /**
254  * wlan_mlme_set_ht_cap_info() - Set the HT cap info config
255  * @psoc: pointer to psoc object
256  * @ht_cap_info: Value that needs to be set from the caller
257  *
258  * Return: QDF Status
259  */
260 QDF_STATUS wlan_mlme_set_ht_cap_info(struct wlan_objmgr_psoc *psoc,
261 				     struct mlme_ht_capabilities_info
262 				     ht_cap_info);
263 
264 /**
265  * wlan_mlme_get_max_amsdu_num() - get the max amsdu num
266  * @psoc: pointer to psoc object
267  * @value: pointer to the value where the max_amsdu num is to be filled
268  *
269  * Return: QDF_STATUS
270  */
271 QDF_STATUS wlan_mlme_get_max_amsdu_num(struct wlan_objmgr_psoc *psoc,
272 				       uint8_t *value);
273 
274 /**
275  * wlan_mlme_set_max_amsdu_num() - set the max amsdu num
276  * @psoc: pointer to psoc object
277  * @value: value to be set for max_amsdu_num
278  *
279  * Return: QDF_STATUS
280  */
281 QDF_STATUS wlan_mlme_set_max_amsdu_num(struct wlan_objmgr_psoc *psoc,
282 				       uint8_t value);
283 
284 /**
285  * wlan_mlme_get_ht_mpdu_density() - get the ht mpdu density
286  * @psoc: pointer to psoc object
287  * @value: pointer to the value where the ht mpdu density is to be filled
288  *
289  * Return: QDF_STATUS
290  */
291 QDF_STATUS wlan_mlme_get_ht_mpdu_density(struct wlan_objmgr_psoc *psoc,
292 					 uint8_t *value);
293 
294 /**
295  * wlan_mlme_set_ht_mpdu_density() - set the ht mpdu density
296  * @psoc: pointer to psoc object
297  * @value: value to be set for ht mpdu density
298  *
299  * Return: QDF_STATUS
300  */
301 QDF_STATUS wlan_mlme_set_ht_mpdu_density(struct wlan_objmgr_psoc *psoc,
302 					 uint8_t value);
303 
304 /**
305  * wlan_mlme_get_band_capability() - Get the Band capability config
306  * @psoc: pointer to psoc object
307  * @band_capability: Pointer to the variable from caller
308  *
309  * Return: QDF Status
310  */
311 QDF_STATUS wlan_mlme_get_band_capability(struct wlan_objmgr_psoc *psoc,
312 					 uint32_t *band_capability);
313 
314 #ifdef QCA_MULTIPASS_SUPPORT
315 /**
316  * wlan_mlme_peer_config_vlan() - send vlan id to FW for RX path
317  * @vdev: vdev pointer
318  * @mac_addr: mac address of the peer
319  *
320  * Return: QDF_STATUS
321  */
322 QDF_STATUS
323 wlan_mlme_peer_config_vlan(struct wlan_objmgr_vdev *vdev,
324 			   uint8_t *mac_addr);
325 #else
326 static inline QDF_STATUS
wlan_mlme_peer_config_vlan(struct wlan_objmgr_vdev * vdev,uint8_t * mac_addr)327 wlan_mlme_peer_config_vlan(struct wlan_objmgr_vdev *vdev,
328 			   uint8_t *mac_addr)
329 {
330 	return QDF_STATUS_SUCCESS;
331 }
332 #endif
333 #ifdef MULTI_CLIENT_LL_SUPPORT
334 /**
335  * wlan_mlme_get_wlm_multi_client_ll_caps() - Get the wlm multi client latency
336  * level capability flag
337  * @psoc: pointer to psoc object
338  *
339  * Return: True is multi client ll cap present
340  */
341 bool wlan_mlme_get_wlm_multi_client_ll_caps(struct wlan_objmgr_psoc *psoc);
342 #else
343 static inline bool
wlan_mlme_get_wlm_multi_client_ll_caps(struct wlan_objmgr_psoc * psoc)344 wlan_mlme_get_wlm_multi_client_ll_caps(struct wlan_objmgr_psoc *psoc)
345 {
346 	return false;
347 }
348 #endif
349 
350 #ifdef FEATURE_WLAN_CH_AVOID_EXT
351 /**
352  * wlan_mlme_get_coex_unsafe_chan_nb_user_prefer() - get coex unsafe nb
353  * support
354  * @psoc:   pointer to psoc object
355  *
356  * Return: coex_unsafe_chan_nb_user_prefer
357  */
358 uint32_t wlan_mlme_get_coex_unsafe_chan_nb_user_prefer(
359 		struct wlan_objmgr_psoc *psoc);
360 bool wlan_mlme_get_coex_unsafe_chan_nb_user_prefer_for_p2p_go(
361 		struct wlan_objmgr_psoc *psoc);
362 bool wlan_mlme_get_coex_unsafe_chan_nb_user_prefer_for_sap(
363 		struct wlan_objmgr_psoc *psoc);
364 #else
365 static inline
wlan_mlme_get_coex_unsafe_chan_nb_user_prefer(struct wlan_objmgr_psoc * psoc)366 uint32_t wlan_mlme_get_coex_unsafe_chan_nb_user_prefer(
367 		struct wlan_objmgr_psoc *psoc)
368 {
369 	return false;
370 }
371 
372 static inline
wlan_mlme_get_coex_unsafe_chan_nb_user_prefer_for_sap(struct wlan_objmgr_psoc * psoc)373 bool wlan_mlme_get_coex_unsafe_chan_nb_user_prefer_for_sap(
374 		struct wlan_objmgr_psoc *psoc)
375 {
376 	return false;
377 }
378 
379 static inline
wlan_mlme_get_coex_unsafe_chan_nb_user_prefer_for_p2p_go(struct wlan_objmgr_psoc * psoc)380 bool wlan_mlme_get_coex_unsafe_chan_nb_user_prefer_for_p2p_go(
381 		struct wlan_objmgr_psoc *psoc)
382 {
383 	return false;
384 }
385 #endif
386 
387 /**
388  * wlan_mlme_set_band_capability() - Set the Band capability config
389  * @psoc: pointer to psoc object
390  * @band_capability: Value to be set from the caller
391  *
392  * Return: QDF Status
393  */
394 QDF_STATUS wlan_mlme_set_band_capability(struct wlan_objmgr_psoc *psoc,
395 					 uint32_t band_capability);
396 
397 #ifdef WLAN_VENDOR_HANDOFF_CONTROL
398 /**
399  * wlan_mlme_get_vendor_handoff_control_caps() - Get the vendor handoff control
400  * capability flag
401  * @psoc: pointer to psoc object
402  *
403  * Return: True if vendor handoff control caps present
404  */
405 bool wlan_mlme_get_vendor_handoff_control_caps(struct wlan_objmgr_psoc *psoc);
406 #else
407 static inline bool
wlan_mlme_get_vendor_handoff_control_caps(struct wlan_objmgr_psoc * psoc)408 wlan_mlme_get_vendor_handoff_control_caps(struct wlan_objmgr_psoc *psoc)
409 {
410 	return false;
411 }
412 #endif
413 
414 /**
415  * wlan_mlme_set_dual_sta_policy() - Set the dual sta config
416  * @psoc: pointer to psoc object
417  * @dual_sta_config: Value to be set from the caller
418  *
419  * Return: QDF Status
420  */
421 QDF_STATUS wlan_mlme_set_dual_sta_policy(struct wlan_objmgr_psoc *psoc,
422 					 uint8_t dual_sta_config);
423 
424 /**
425  * wlan_mlme_get_dual_sta_policy() - Get the dual sta policy
426  * @psoc: pointer to psoc object
427  * @dual_sta_config: Value to be set from the caller
428  *
429  * Return: QDF Status
430  */
431 QDF_STATUS wlan_mlme_get_dual_sta_policy(struct wlan_objmgr_psoc *psoc,
432 					 uint8_t *dual_sta_config);
433 
434 /**
435  * wlan_mlme_convert_ap_policy_config() - Convert vendor attr ap policy
436  * config to host enum
437  * @ap_config: Value to convert
438  *
439  * Return: enum host_concurrent_ap_policy
440  */
441 enum host_concurrent_ap_policy
442 wlan_mlme_convert_ap_policy_config(
443 		enum qca_wlan_concurrent_ap_policy_config ap_config);
444 
445 /**
446  * wlan_mlme_set_ap_policy() - Set ap config policy value
447  * @vdev: pointer to vdev object
448  * @ap_cfg_policy: Value to be set from the caller
449  *
450  * Return: QDF Status
451  */
452 QDF_STATUS
453 wlan_mlme_set_ap_policy(struct wlan_objmgr_vdev *vdev,
454 			enum host_concurrent_ap_policy ap_cfg_policy);
455 
456 /**
457  * wlan_mlme_get_ap_policy() - Get ap config policy value
458  * @vdev: pointer to vdev object
459  *
460  * Return: enum host_concurrent_ap_policy
461  */
462 enum host_concurrent_ap_policy
463 wlan_mlme_get_ap_policy(struct wlan_objmgr_vdev *vdev);
464 
465 /**
466  * wlan_mlme_ll_lt_sap_send_oce_flags_fw() - Send the oce flags to FW for
467  * ll_lt_sap
468  * @vdev: pointer to vdev object
469  *
470  * Return: void
471  */
472 void wlan_mlme_ll_lt_sap_send_oce_flags_fw(struct wlan_objmgr_vdev *vdev);
473 
474 /**
475  * wlan_mlme_get_prevent_link_down() - Get the prevent link down config
476  * @psoc: pointer to psoc object
477  * @prevent_link_down: Pointer to the variable from caller
478  *
479  * Return: QDF Status
480  */
481 QDF_STATUS wlan_mlme_get_prevent_link_down(struct wlan_objmgr_psoc *psoc,
482 					   bool *prevent_link_down);
483 
484 /**
485  * wlan_mlme_get_select_5ghz_margin() - Get the select 5Ghz margin config
486  * @psoc: pointer to psoc object
487  * @select_5ghz_margin: Pointer to the variable from caller
488  *
489  * Return: QDF Status
490  */
491 QDF_STATUS wlan_mlme_get_select_5ghz_margin(struct wlan_objmgr_psoc *psoc,
492 					    uint8_t *select_5ghz_margin);
493 
494 /**
495  * wlan_mlme_get_rtt_mac_randomization() - Get the RTT MAC randomization config
496  * @psoc: pointer to psoc object
497  * @rtt_mac_randomization: Pointer to the variable from caller
498  *
499  * Return: QDF Status
500  */
501 QDF_STATUS wlan_mlme_get_rtt_mac_randomization(struct wlan_objmgr_psoc *psoc,
502 					       bool *rtt_mac_randomization);
503 
504 /**
505  * wlan_mlme_get_crash_inject() - Get the crash inject config
506  * @psoc: pointer to psoc object
507  * @crash_inject: Pointer to the variable from caller
508  *
509  * Return: QDF Status
510  */
511 QDF_STATUS wlan_mlme_get_crash_inject(struct wlan_objmgr_psoc *psoc,
512 				      bool *crash_inject);
513 
514 /**
515  * wlan_mlme_get_lpass_support() - Get the LPASS Support config
516  * @psoc: pointer to psoc object
517  * @lpass_support: Pointer to the variable from caller
518  *
519  * Return: QDF Status
520  */
521 QDF_STATUS wlan_mlme_get_lpass_support(struct wlan_objmgr_psoc *psoc,
522 				       bool *lpass_support);
523 
524 /**
525  * wlan_mlme_get_wls_6ghz_cap() - Get the wifi location service(WLS)
526  * 6ghz capability
527  * @psoc: pointer to psoc object
528  * @wls_6ghz_capable: Pointer to the variable from caller
529  *
530  * Return: void
531  */
532 void wlan_mlme_get_wls_6ghz_cap(struct wlan_objmgr_psoc *psoc,
533 				bool *wls_6ghz_capable);
534 
535 /**
536  * wlan_mlme_get_self_recovery() - Get the self recovery config
537  * @psoc: pointer to psoc object
538  * @self_recovery: Pointer to the variable from caller
539  *
540  * Return: QDF Status
541  */
542 QDF_STATUS wlan_mlme_get_self_recovery(struct wlan_objmgr_psoc *psoc,
543 				       bool *self_recovery);
544 
545 /**
546  * wlan_mlme_get_sub_20_chan_width() - Get the sub 20 chan width config
547  * @psoc: pointer to psoc object
548  * @sub_20_chan_width: Pointer to the variable from caller
549  *
550  * Return: QDF Status
551  */
552 QDF_STATUS wlan_mlme_get_sub_20_chan_width(struct wlan_objmgr_psoc *psoc,
553 					   uint8_t *sub_20_chan_width);
554 
555 /**
556  * wlan_mlme_get_fw_timeout_crash() - Get the fw timeout crash config
557  * @psoc: pointer to psoc object
558  * @fw_timeout_crash: Pointer to the variable from caller
559  *
560  * Return: QDF Status
561  */
562 QDF_STATUS wlan_mlme_get_fw_timeout_crash(struct wlan_objmgr_psoc *psoc,
563 					  bool *fw_timeout_crash);
564 
565 /**
566  * wlan_mlme_get_ito_repeat_count() - Get the fw timeout crash config
567  * @psoc: pointer to psoc object
568  * @ito_repeat_count: Pointer to the variable from caller
569  *
570  * Return: QDF Status
571  */
572 QDF_STATUS wlan_mlme_get_ito_repeat_count(struct wlan_objmgr_psoc *psoc,
573 					  uint8_t *ito_repeat_count);
574 
575 /**
576  * wlan_mlme_get_acs_with_more_param() - Get the acs_with_more_param flag
577  * @psoc: pointer to psoc object
578  * @value: Value that needs to be set from the caller
579  *
580  * Return: QDF Status
581  */
582 QDF_STATUS wlan_mlme_get_acs_with_more_param(struct wlan_objmgr_psoc *psoc,
583 					     bool *value);
584 
585 /**
586  * wlan_mlme_get_auto_channel_weight() - Get the auto channel weight
587  * @psoc: pointer to psoc object
588  * @value: Value that needs to be set from the caller
589  *
590  * Return: QDF Status
591  */
592 QDF_STATUS wlan_mlme_get_auto_channel_weight(struct wlan_objmgr_psoc *psoc,
593 					     uint32_t *value);
594 
595 /**
596  * wlan_mlme_get_vendor_acs_support() - Get the vendor based channel selece
597  * @psoc: pointer to psoc object
598  * @value: Value that needs to be set from the caller
599  *
600  * Return: QDF Status
601  */
602 
603 QDF_STATUS wlan_mlme_get_vendor_acs_support(struct wlan_objmgr_psoc *psoc,
604 					    bool *value);
605 
606 /**
607  * wlan_mlme_get_acs_support_for_dfs_ltecoex() - Get the flag for
608  *						 acs support for dfs ltecoex
609  * @psoc: pointer to psoc object
610  * @value: Value that needs to be set from the caller
611  *
612  * Return: QDF Status
613  */
614 QDF_STATUS
615 wlan_mlme_get_acs_support_for_dfs_ltecoex(struct wlan_objmgr_psoc *psoc,
616 					  bool *value);
617 
618 /**
619  * wlan_mlme_get_external_acs_policy() - Get the flag for external acs policy
620  * @psoc: pointer to psoc object
621  * @value: Value that needs to be set from the caller
622  *
623  * Return: QDF Status
624  */
625 QDF_STATUS
626 wlan_mlme_get_external_acs_policy(struct wlan_objmgr_psoc *psoc,
627 				  bool *value);
628 
629 /**
630  * wlan_mlme_get_sap_inactivity_override() - Check if sap max inactivity
631  * override flag is set.
632  * @psoc: pointer to psoc object
633  * @value: Value that needs to be set from the caller
634  *
635  * Return: QDF Status
636  */
637 void wlan_mlme_get_sap_inactivity_override(struct wlan_objmgr_psoc *psoc,
638 					   bool *value);
639 
640 /**
641  * wlan_mlme_get_ignore_peer_ht_mode() - Get the ignore peer ht opmode flag
642  * @psoc: pointer to psoc object
643  * @value: Value that needs to be set from the caller
644  *
645  * Return: QDF Status
646  */
647 QDF_STATUS wlan_mlme_get_ignore_peer_ht_mode(struct wlan_objmgr_psoc *psoc,
648 					bool *value);
649 /**
650  * wlan_mlme_get_tx_chainmask_cck() - Get the tx_chainmask_cfg value
651  * @psoc: pointer to psoc object
652  * @value: Value that needs to be set from the caller
653  *
654  * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
655  */
656 QDF_STATUS wlan_mlme_get_tx_chainmask_cck(struct wlan_objmgr_psoc *psoc,
657 					  bool *value);
658 
659 /**
660  * wlan_mlme_get_tx_chainmask_1ss() - Get the tx_chainmask_1ss value
661  * @psoc: pointer to psoc object
662  * @value: Value that caller needs to get
663  *
664  * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
665  */
666 QDF_STATUS wlan_mlme_get_tx_chainmask_1ss(struct wlan_objmgr_psoc *psoc,
667 					  uint8_t *value);
668 
669 /**
670  * wlan_mlme_get_num_11b_tx_chains() -  Get the number of 11b only tx chains
671  * @psoc: pointer to psoc object
672  * @value: Value that needs to be set from the caller
673  *
674  * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
675  */
676 QDF_STATUS wlan_mlme_get_num_11b_tx_chains(struct wlan_objmgr_psoc *psoc,
677 					   uint16_t *value);
678 
679 /**
680  * wlan_mlme_get_num_11ag_tx_chains() - get the total number of 11a/g tx chains
681  * @psoc: pointer to psoc object
682  * @value: Value that caller needs to get
683  *
684  * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
685  */
686 QDF_STATUS wlan_mlme_get_num_11ag_tx_chains(struct wlan_objmgr_psoc *psoc,
687 					    uint16_t *value);
688 
689 /**
690  * wlan_mlme_get_bt_chain_separation_flag() - get the enable_bt_chain_separation
691  * flag
692  * @psoc: pointer to psoc object
693  * @value: Value that needs to be set from the caller
694  *
695  * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
696  */
697 QDF_STATUS wlan_mlme_get_bt_chain_separation_flag(struct wlan_objmgr_psoc *psoc,
698 						  bool *value);
699 /**
700  * wlan_mlme_configure_chain_mask() - configure chainmask parameters
701  * @psoc: pointer to psoc object
702  * @session_id: vdev_id
703  *
704  * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
705  */
706 QDF_STATUS wlan_mlme_configure_chain_mask(struct wlan_objmgr_psoc *psoc,
707 					  uint8_t session_id);
708 
709 /**
710  * wlan_mlme_is_chain_mask_supported() - check if configure chainmask can
711  * be supported
712  * @psoc: pointer to psoc object
713  *
714  * Return: true if supported else false
715  */
716 bool wlan_mlme_is_chain_mask_supported(struct wlan_objmgr_psoc *psoc);
717 
718 /**
719  * wlan_mlme_get_listen_interval() - Get listen interval
720  * @psoc: pointer to psoc object
721  * @value: Pointer to value that needs to be filled by MLME
722  *
723  * Return: QDF Status
724  */
725 QDF_STATUS wlan_mlme_get_listen_interval(struct wlan_objmgr_psoc *psoc,
726 					     int *value);
727 
728 /**
729  * wlan_mlme_set_sap_listen_interval() - Set the sap listen interval
730  * @psoc: pointer to psoc object
731  * @value: Value that needs to be set from the caller
732  *
733  * Return: QDF Status
734  */
735 QDF_STATUS wlan_mlme_set_sap_listen_interval(struct wlan_objmgr_psoc *psoc,
736 					     int value);
737 
738 /**
739  * wlan_mlme_set_assoc_sta_limit() - Set the assoc sta limit
740  * @psoc: pointer to psoc object
741  * @value: Value that needs to be set from the caller
742  *
743  * Return: QDF Status
744  */
745 QDF_STATUS wlan_mlme_set_assoc_sta_limit(struct wlan_objmgr_psoc *psoc,
746 					 int value);
747 
748 /**
749  * wlan_mlme_get_assoc_sta_limit() - Get the assoc sta limit
750  * @psoc: pointer to psoc object
751  * @value: Pointer to value that needs to be filled by MLME
752  *
753  * Return: QDF Status
754  */
755 QDF_STATUS wlan_mlme_get_assoc_sta_limit(struct wlan_objmgr_psoc *psoc,
756 					 int *value);
757 
758 /**
759  * wlan_mlme_get_sap_get_peer_info() - get the sap get peer info
760  * @psoc: pointer to psoc object
761  * @value: Value that needs to be set from the caller
762  *
763  * Return: QDF Status
764  */
765 QDF_STATUS wlan_mlme_get_sap_get_peer_info(struct wlan_objmgr_psoc *psoc,
766 					   bool *value);
767 
768 /**
769  * wlan_mlme_set_sap_get_peer_info() - set the sap get peer info
770  * @psoc: pointer to psoc object
771  * @value: value to overwrite the sap get peer info
772  *
773  * Return: QDF Status
774  */
775 QDF_STATUS wlan_mlme_set_sap_get_peer_info(struct wlan_objmgr_psoc *psoc,
776 					   bool value);
777 
778 /**
779  * wlan_mlme_get_sap_bcast_deauth_enabled() - get the enable/disable value
780  *                                           for broadcast deauth in sap
781  * @psoc: pointer to psoc object
782  * @value: Value that needs to get from the caller
783  *
784  * Return: QDF Status
785  */
786 QDF_STATUS
787 wlan_mlme_get_sap_bcast_deauth_enabled(struct wlan_objmgr_psoc *psoc,
788 				       bool *value);
789 
790 /**
791  * wlan_mlme_get_sap_allow_all_channels() - get the value of sap allow all
792  * channels
793  * @psoc: pointer to psoc object
794  * @value: Value that needs to be set from the caller
795  *
796  * Return: QDF Status
797  */
798 QDF_STATUS wlan_mlme_get_sap_allow_all_channels(struct wlan_objmgr_psoc *psoc,
799 						bool *value);
800 
801 /**
802  * wlan_mlme_is_6g_sap_fd_enabled() - get the enable/disable value
803  *                                     for 6g sap fils discovery
804  * @psoc: pointer to psoc object
805  * @value: Value that needs to get from the caller
806  *
807  * Return: QDF Status
808  */
809 QDF_STATUS
810 wlan_mlme_is_6g_sap_fd_enabled(struct wlan_objmgr_psoc *psoc,
811 			       bool *value);
812 
813 /**
814  * wlan_mlme_get_sap_max_peers() - get the value sap max peers
815  * @psoc: pointer to psoc object
816  * @value: Value that needs to be set from the caller
817  *
818  * Return: QDF Status
819  */
820 QDF_STATUS wlan_mlme_get_sap_max_peers(struct wlan_objmgr_psoc *psoc,
821 				       int *value);
822 
823 /**
824  * wlan_mlme_set_sap_max_peers() - set the value sap max peers
825  * @psoc: pointer to psoc object
826  * @value: Value that needs to be set from the caller
827  *
828  * Return: QDF Status
829  */
830 QDF_STATUS wlan_mlme_set_sap_max_peers(struct wlan_objmgr_psoc *psoc,
831 				       int value);
832 
833 /**
834  * wlan_mlme_get_sap_max_offload_peers() - get the value sap max offload peers
835  * @psoc: pointer to psoc object
836  * @value: Value that needs to be set from the caller
837  *
838  * Return: QDF Status
839  */
840 QDF_STATUS wlan_mlme_get_sap_max_offload_peers(struct wlan_objmgr_psoc *psoc,
841 					       int *value);
842 
843 /**
844  * wlan_mlme_get_sap_max_offload_reorder_buffs() - get the value sap max offload
845  * reorder buffs.
846  * @psoc: pointer to psoc object
847  * @value: Value that needs to be set from the caller
848  *
849  * Return: QDF Status
850  */
851 QDF_STATUS wlan_mlme_get_sap_max_offload_reorder_buffs(struct wlan_objmgr_psoc
852 						       *psoc, int *value);
853 
854 /**
855  * wlan_mlme_get_sap_chn_switch_bcn_count() - get the value sap max channel
856  * switch beacon count
857  * @psoc: pointer to psoc object
858  * @value: Value that needs to be set from the caller
859  *
860  * Return: QDF Status
861  */
862 QDF_STATUS wlan_mlme_get_sap_chn_switch_bcn_count(struct wlan_objmgr_psoc *psoc,
863 						  int *value);
864 
865 /**
866  * wlan_mlme_get_sap_chn_switch_mode() - get the sap channel
867  * switch mode
868  * @psoc: pointer to psoc object
869  * @value: Value that needs to be set from the caller
870  *
871  * Return: QDF Status
872  */
873 QDF_STATUS wlan_mlme_get_sap_chn_switch_mode(struct wlan_objmgr_psoc *psoc,
874 					     bool *value);
875 
876 /**
877  * wlan_mlme_get_sap_internal_restart() - get the sap internal
878  * restart
879  * @psoc: pointer to psoc object
880  * @value: Value that needs to be set from the caller
881  *
882  * Return: QDF Status
883  */
884 QDF_STATUS wlan_mlme_get_sap_internal_restart(struct wlan_objmgr_psoc *psoc,
885 					      bool *value);
886 /**
887  * wlan_mlme_get_sap_max_modulated_dtim() - get the max modulated dtim
888  * restart
889  * @psoc: pointer to psoc object
890  * @value: Value that needs to be set from the caller
891  *
892  * Return: QDF Status
893  */
894 QDF_STATUS wlan_mlme_get_sap_max_modulated_dtim(struct wlan_objmgr_psoc *psoc,
895 						uint8_t *value);
896 
897 /**
898  * wlan_mlme_get_sap_chan_pref_location() - get the sap chan pref location
899  * restart
900  * @psoc: pointer to psoc object
901  * @value: Value that needs to be set from the caller
902  *
903  * Return: QDF Status
904  */
905 QDF_STATUS wlan_mlme_get_sap_chan_pref_location(struct wlan_objmgr_psoc *psoc,
906 						uint8_t *value);
907 
908 /**
909  * wlan_mlme_get_sap_country_priority() - get the sap country code priority
910  * restart
911  * @psoc: pointer to psoc object
912  * @value: Value that needs to be set from the caller
913  *
914  * Return: QDF Status
915  */
916 QDF_STATUS wlan_mlme_get_sap_country_priority(struct wlan_objmgr_psoc *psoc,
917 					      bool *value);
918 
919 /**
920  * wlan_mlme_get_sap_reduced_beacon_interval() - get the sap reduced
921  * beacon interval
922  * @psoc: pointer to psoc object
923  * @value: Value that needs to be set from the caller
924  *
925  * Return: QDF Status
926  */
927 QDF_STATUS wlan_mlme_get_sap_reduced_beacon_interval(struct wlan_objmgr_psoc
928 						     *psoc, int *value);
929 
930 /**
931  * wlan_mlme_get_sap_chan_switch_rate_enabled() - get the sap rate hostapd
932  * enabled beacon interval
933  * @psoc: pointer to psoc object
934  * @value: Value that needs to be set from the caller
935  *
936  * Return: QDF Status
937  */
938 QDF_STATUS wlan_mlme_get_sap_chan_switch_rate_enabled(struct wlan_objmgr_psoc
939 						      *psoc, bool *value);
940 
941 /**
942  * wlan_mlme_get_sap_force_11n_for_11ac() - get the sap 11n for 11ac
943  * @psoc: pointer to psoc object
944  * @value: Value that needs to be set from the caller
945  *
946  * Return: QDF Status
947  */
948 QDF_STATUS wlan_mlme_get_sap_force_11n_for_11ac(struct wlan_objmgr_psoc
949 						*psoc, bool *value);
950 
951 /**
952  * wlan_mlme_get_go_force_11n_for_11ac() - get the go 11n for 11ac
953  * @psoc: pointer to psoc object
954  * @value: Value that needs to be set from the caller
955  *
956  * Return: QDF Status
957  */
958 QDF_STATUS wlan_mlme_get_go_force_11n_for_11ac(struct wlan_objmgr_psoc
959 					       *psoc, bool *value);
960 
961 /**
962  * wlan_mlme_is_go_11ac_override() - Override 11ac bandwdith for P2P GO
963  * @psoc: pointer to psoc object
964  * @value: pointer to the value which will be filled for the caller
965  *
966  * Return: QDF Status
967  */
968 QDF_STATUS wlan_mlme_is_go_11ac_override(struct wlan_objmgr_psoc *psoc,
969 					 bool *value);
970 
971 /**
972  * wlan_mlme_is_sap_11ac_override() - Override 11ac bandwdith for SAP
973  * @psoc: pointer to psoc object
974  * @value: pointer to the value which will be filled for the caller
975  *
976  * Return: QDF Status
977  */
978 QDF_STATUS wlan_mlme_is_sap_11ac_override(struct wlan_objmgr_psoc *psoc,
979 					  bool *value);
980 
981 /**
982  * wlan_mlme_set_go_11ac_override() - set override 11ac bandwdith for P2P GO
983  * @psoc: pointer to psoc object
984  * @value: pointer to the value which will be filled for the caller
985  *
986  * Return: QDF Status
987  */
988 QDF_STATUS wlan_mlme_set_go_11ac_override(struct wlan_objmgr_psoc *psoc,
989 					  bool value);
990 
991 /**
992  * wlan_mlme_set_sap_11ac_override() - set override 11ac bandwdith for SAP
993  * @psoc: pointer to psoc object
994  * @value: pointer to the value which will be filled for the caller
995  *
996  * Return: QDF Status
997  */
998 QDF_STATUS wlan_mlme_set_sap_11ac_override(struct wlan_objmgr_psoc *psoc,
999 					   bool value);
1000 
1001 /**
1002  * wlan_mlme_get_oce_sta_enabled_info() - Get the OCE feature enable
1003  * info for STA
1004  * @psoc: pointer to psoc object
1005  * @value: pointer to the value which will be filled for the caller
1006  *
1007  * Return: QDF Status
1008  */
1009 QDF_STATUS wlan_mlme_get_oce_sta_enabled_info(struct wlan_objmgr_psoc *psoc,
1010 					      bool *value);
1011 
1012 /**
1013  * wlan_mlme_get_bigtk_support() - Get the BIGTK support
1014  * @psoc: pointer to psoc object
1015  * @value: pointer to the value which will be filled for the caller
1016  *
1017  * Return: QDF Status
1018  */
1019 QDF_STATUS wlan_mlme_get_bigtk_support(struct wlan_objmgr_psoc *psoc,
1020 				       bool *value);
1021 
1022 /**
1023  * wlan_mlme_get_ocv_support() - Get the OCV support
1024  * @psoc: pointer to psoc object
1025  * @value: pointer to the value which will be filled for the caller
1026  *
1027  * Return: QDF Status
1028  */
1029 QDF_STATUS wlan_mlme_get_ocv_support(struct wlan_objmgr_psoc *psoc,
1030 				     bool *value);
1031 
1032 /**
1033  * wlan_mlme_get_host_scan_abort_support() - Get support for stop all host
1034  * scans service capability.
1035  * @psoc: PSOC object pointer
1036  *
1037  * Return: True if capability is supported, else False
1038  */
1039 bool wlan_mlme_get_host_scan_abort_support(struct wlan_objmgr_psoc *psoc);
1040 
1041 /**
1042  * wlan_mlme_get_dual_sta_roam_support  - Get support for dual sta roaming
1043  * feature
1044  * @psoc: PSOC object pointer
1045  *
1046  * Return: True if capability is supported, else False
1047  */
1048 bool wlan_mlme_get_dual_sta_roam_support(struct wlan_objmgr_psoc *psoc);
1049 
1050 /**
1051  * wlan_mlme_get_oce_sap_enabled_info() - Get the OCE feature enable
1052  * info for SAP
1053  * @psoc: pointer to psoc object
1054  * @value: pointer to the value which will be filled for the caller
1055  *
1056  * Return: QDF Status
1057  */
1058 QDF_STATUS wlan_mlme_get_oce_sap_enabled_info(struct wlan_objmgr_psoc *psoc,
1059 					      bool *value);
1060 
1061 /**
1062  * wlan_mlme_update_oce_flags() - Update the oce flags to FW
1063  * @pdev: pointer to pdev object
1064  *
1065  * Return: void
1066  */
1067 void wlan_mlme_update_oce_flags(struct wlan_objmgr_pdev *pdev);
1068 
1069 /**
1070  * wlan_mlme_cfg_get_aux_supported_modes() - get supported mode of aux.
1071  *             definition of bitmap refer WMI_AUX_DEV_CAPS_SUPPORTED_MODE.
1072  *
1073  * @psoc: pointer to psoc object
1074  * @aux_index: aux index, current only support aux0.
1075  * @hw_mode_id: hw mode id
1076  * @supported_modes_bitmap: output for value
1077  *
1078  * Return: true for getting value. false for failure check.
1079  */
1080 bool wlan_mlme_cfg_get_aux_supported_modes(
1081 		struct wlan_objmgr_psoc *psoc,
1082 		uint32_t aux_index,
1083 		enum wlan_mlme_hw_mode_config_type hw_mode_id,
1084 		uint32_t *supported_modes_bitmap);
1085 
1086 /**
1087  * wlan_mlme_is_aux_scan_support() - check whether aux scan is supported.
1088  * @psoc: pointer to psoc object
1089  * @hw_mode_id: hw mode id
1090  *
1091  * Return: true if supporting, else false
1092  */
1093 bool
1094 wlan_mlme_is_aux_scan_support(struct wlan_objmgr_psoc *psoc,
1095 			      enum wlan_mlme_hw_mode_config_type hw_mode_id);
1096 
1097 /**
1098  * wlan_mlme_is_aux_listen_support() - check whether aux listen is supported.
1099  * @psoc: pointer to psoc object
1100  * @hw_mode_id: hw mode id
1101  *
1102  * Return: true if supporting, else false
1103  */
1104 bool
1105 wlan_mlme_is_aux_listen_support(struct wlan_objmgr_psoc *psoc,
1106 				enum wlan_mlme_hw_mode_config_type hw_mode_id);
1107 
1108 /**
1109  * wlan_mlme_is_aux_emlsr_support() - check whether aux emlsr is supported.
1110  * @psoc: pointer to psoc object
1111  * @hw_mode_id: hw mode id
1112  *
1113  * Return: true if supporting, else false
1114  */
1115 bool
1116 wlan_mlme_is_aux_emlsr_support(struct wlan_objmgr_psoc *psoc,
1117 			       enum wlan_mlme_hw_mode_config_type hw_mode_id);
1118 
1119 #ifdef WLAN_FEATURE_11AX
1120 /**
1121  * wlan_mlme_cfg_get_he_ul_mumimo() - Get the HE Ul Mumio
1122  * @psoc: pointer to psoc object
1123  * @value: Value that needs to be set from the caller
1124  *
1125  * Return: QDF Status
1126  */
1127 QDF_STATUS wlan_mlme_cfg_get_he_ul_mumimo(struct wlan_objmgr_psoc *psoc,
1128 					  uint32_t *value);
1129 
1130 /**
1131  * wlan_mlme_cfg_set_he_ul_mumimo() - Set the HE Ul Mumio
1132  * @psoc: pointer to psoc object
1133  * @value: Value that needs to be set from the caller
1134  *
1135  * Return: QDF Status
1136  */
1137 QDF_STATUS wlan_mlme_cfg_set_he_ul_mumimo(struct wlan_objmgr_psoc *psoc,
1138 					  uint32_t value);
1139 
1140 /**
1141  * mlme_cfg_get_he_caps() - Get the HE capability info
1142  * @psoc: pointer to psoc object
1143  * @he_cap: Caps that needs to be filled.
1144  *
1145  * Return: QDF Status
1146  */
1147 QDF_STATUS mlme_cfg_get_he_caps(struct wlan_objmgr_psoc *psoc,
1148 				tDot11fIEhe_cap *he_cap);
1149 
1150 /**
1151  * wlan_mlme_cfg_get_enable_ul_mimo() - Get the HE Ul mimo
1152  * @psoc: pointer to psoc object
1153  * @value: Value that needs to be set from the caller
1154  *
1155  * Return: QDF Status
1156  */
1157 QDF_STATUS wlan_mlme_cfg_get_enable_ul_mimo(struct wlan_objmgr_psoc *psoc,
1158 					    uint8_t *value);
1159 
1160 /**
1161  * wlan_mlme_cfg_get_enable_ul_ofdm() - Get enable ul ofdm
1162  * @psoc: pointer to psoc object
1163  * @value: Value that needs to be set from the caller
1164  *
1165  * Return: QDF Status
1166  */
1167 QDF_STATUS wlan_mlme_cfg_get_enable_ul_ofdm(struct wlan_objmgr_psoc *psoc,
1168 					    uint8_t *value);
1169 
1170 /**
1171  * mlme_update_tgt_he_caps_in_cfg() - Update tgt he cap in mlme component
1172  * @psoc: pointer to psoc object
1173  * @cfg: pointer to config params from target
1174  *
1175  * This api to be used by callers to update
1176  * he caps in mlme.
1177  *
1178  * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
1179  */
1180 QDF_STATUS mlme_update_tgt_he_caps_in_cfg(struct wlan_objmgr_psoc *psoc,
1181 					  struct wma_tgt_cfg *cfg);
1182 #endif
1183 
1184 /**
1185  * wlan_mlme_convert_vht_op_bw_to_phy_ch_width() - convert channel width in VHT
1186  *                                                 operation IE to phy_ch_width
1187  * @channel_width: channel width in VHT operation IE.
1188  * @chan_id: channel id
1189  * @ccfs0: channel center frequency segment 0
1190  * @ccfs1: channel center frequency segment 1
1191  *
1192  * Return: phy_ch_width
1193  */
1194 enum phy_ch_width
1195 wlan_mlme_convert_vht_op_bw_to_phy_ch_width(uint8_t channel_width,
1196 					    uint8_t chan_id,
1197 					    uint8_t ccfs0,
1198 					    uint8_t ccfs1);
1199 
1200 /**
1201  * wlan_mlme_convert_he_6ghz_op_bw_to_phy_ch_width() - convert channel width in
1202  *                                          he 6ghz peration IE to phy_ch_width
1203  * @channel_width: channel width in HE operation IE.
1204  * @chan_id: channel id
1205  * @ccfs0: channel center frequency segment 0
1206  * @ccfs1: channel center frequency segment 1
1207  *
1208  * Return: phy_ch_width
1209  */
1210 enum phy_ch_width
1211 wlan_mlme_convert_he_6ghz_op_bw_to_phy_ch_width(uint8_t channel_width,
1212 						uint8_t chan_id,
1213 						uint8_t ccfs0,
1214 						uint8_t ccfs1);
1215 
1216 /**
1217  * wlan_mlme_chan_stats_scan_event_cb() - process connected channel stats
1218  * scan event
1219  * @vdev: pointer to vdev object
1220  * @event: scan event definition
1221  * @arg: scan argument
1222  *
1223  * Return: none
1224  */
1225 void wlan_mlme_chan_stats_scan_event_cb(struct wlan_objmgr_vdev *vdev,
1226 					struct scan_event *event, void *arg);
1227 
1228 /**
1229  * wlan_mlme_send_ch_width_update_with_notify() - update connected VDEV
1230  * channel bandwidth
1231  * @psoc: pointer to psoc object
1232  * @vdev: pointer to vdev object
1233  * @link_id: mlo link id
1234  * @ch_width: channel width to update
1235  *
1236  * Return: none
1237  */
1238 QDF_STATUS
1239 wlan_mlme_send_ch_width_update_with_notify(struct wlan_objmgr_psoc *psoc,
1240 					   struct wlan_objmgr_vdev *vdev,
1241 					   uint8_t link_id,
1242 					   enum phy_ch_width ch_width);
1243 
1244 /**
1245  * wlan_mlme_update_bss_rate_flags() - update bss rate flag as per new channel
1246  * width
1247  * @psoc: pointer to psoc object
1248  * @vdev_id: Vdev id
1249  * @cw: channel width to update
1250  * @eht_present: connected bss is eht capable or not
1251  * @he_present: connected bss is he capable or not
1252  * @vht_present: connected bss is vht capable or not
1253  * @ht_present: connected bss is ht capable or not
1254  *
1255  * Return: QDF_STATUS
1256  */
1257 QDF_STATUS wlan_mlme_update_bss_rate_flags(struct wlan_objmgr_psoc *psoc,
1258 					   uint8_t vdev_id,
1259 					   enum phy_ch_width cw,
1260 					   uint8_t eht_present,
1261 					   uint8_t he_present,
1262 					   uint8_t vht_present,
1263 					   uint8_t ht_present);
1264 
1265 #ifdef WLAN_FEATURE_11BE
1266 /**
1267  * mlme_update_tgt_eht_caps_in_cfg() - Update tgt eht cap in mlme component
1268  * @psoc: pointer to psoc object
1269  * @cfg: pointer to config params from target
1270  *
1271  * This api to be used by callers to update EHT caps in mlme.
1272  *
1273  * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
1274  */
1275 QDF_STATUS mlme_update_tgt_eht_caps_in_cfg(struct wlan_objmgr_psoc *psoc,
1276 					  struct wma_tgt_cfg *cfg);
1277 
1278 /**
1279  * mlme_update_tgt_mlo_caps_in_cfg() - Update tgt MLO cap in mlme component
1280  * @psoc: pointer to psoc object
1281  *
1282  * This api to be used by callers to update MLO caps in mlme.
1283  *
1284  * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
1285  */
1286 QDF_STATUS mlme_update_tgt_mlo_caps_in_cfg(struct wlan_objmgr_psoc *psoc);
1287 
1288 /**
1289  * wlan_mlme_convert_eht_op_bw_to_phy_ch_width() - convert channel width in eht
1290  *                                                 operation IE to phy_ch_width
1291  * @channel_width: channel width in eht operation IE
1292  *
1293  * Return: phy_ch_width
1294  */
1295 enum phy_ch_width wlan_mlme_convert_eht_op_bw_to_phy_ch_width(
1296 						uint8_t channel_width);
1297 
1298 /**
1299  * wlan_mlme_convert_phy_ch_width_to_eht_op_bw() - convert channel width to eht
1300  *                                                 operation IE format
1301  * @ch_width: phy_ch_width
1302  *
1303  * Return: channel width in eht operation IE
1304  */
1305 uint8_t wlan_mlme_convert_phy_ch_width_to_eht_op_bw(enum phy_ch_width ch_width);
1306 
1307 /**
1308  * wlan_mlme_get_epcs_capability() - Get mlme epcs capability flag
1309  * @psoc: psoc object
1310  *
1311  * Return: true if epcs capability enabled
1312  */
1313 bool wlan_mlme_get_epcs_capability(struct wlan_objmgr_psoc *psoc);
1314 
1315 /**
1316  * wlan_mlme_set_epcs_capability() - Set mlme epcs capability flag
1317  * @psoc: psoc object
1318  * @flag: epcs capability flag
1319  *
1320  * Return: void
1321  */
1322 void wlan_mlme_set_epcs_capability(struct wlan_objmgr_psoc *psoc, bool flag);
1323 
1324 /**
1325  * wlan_mlme_get_usr_disable_sta_eht() - Get user disable sta eht flag
1326  * @psoc: psoc object
1327  *
1328  * Return: true if user has disabled eht in connect request
1329  */
1330 bool wlan_mlme_get_usr_disable_sta_eht(struct wlan_objmgr_psoc *psoc);
1331 
1332 /**
1333  * wlan_mlme_set_usr_disable_sta_eht() - Set user disable sta eht flag
1334  * @psoc: psoc object
1335  * @disable: eht disable flag
1336  *
1337  * Return: void
1338  */
1339 void wlan_mlme_set_usr_disable_sta_eht(struct wlan_objmgr_psoc *psoc,
1340 				       bool disable);
1341 
1342 /**
1343  * wlan_mlme_get_eht_disable_punct_in_us_lpi() - Get disable eht punct in us
1344  * lpi mode flag.
1345  * @psoc: psoc object
1346  *
1347  * Return: true if eht punct disabled in us lpi mode
1348  */
1349 bool wlan_mlme_get_eht_disable_punct_in_us_lpi(struct wlan_objmgr_psoc *psoc);
1350 
1351 /**
1352  * wlan_mlme_set_eht_disable_punct_in_us_lpi() - Set disable eht punct in us
1353  * lpi mode flag.
1354  * @psoc: psoc object
1355  * @flag: true if eht punct disabled in us lpi mode
1356  *
1357  * Return: void
1358  */
1359 void wlan_mlme_set_eht_disable_punct_in_us_lpi(struct wlan_objmgr_psoc *psoc,
1360 					       bool flag);
1361 /**
1362  * wlan_mlme_update_bw_no_punct() - update connected VDEV
1363  * channel bandwidth without puncture bitmap for FCC requirement
1364  * @psoc: pointer to SOC object
1365  * @vdev_id: vdev id
1366  *
1367  * Return: none
1368  */
1369 QDF_STATUS
1370 wlan_mlme_update_bw_no_punct(struct wlan_objmgr_psoc *psoc,
1371 			     uint8_t vdev_id);
1372 
1373 /**
1374  * wlan_mlme_get_bw_no_punct() - Get connected VDEV
1375  * channel bandwidth without puncture bitmap for FCC requirement
1376  * @psoc: pointer to SOC object
1377  * @vdev: pointer to vdev
1378  * @bss_chan: bss chan with puncture
1379  * @new_ch_width: pointer to new channel bandwidth without puncture
1380  * Return: none
1381  */
1382 QDF_STATUS
1383 wlan_mlme_get_bw_no_punct(struct wlan_objmgr_psoc *psoc,
1384 			  struct wlan_objmgr_vdev *vdev,
1385 			  struct wlan_channel *bss_chan,
1386 			  enum phy_ch_width *new_ch_width);
1387 #else
1388 static inline
wlan_mlme_get_epcs_capability(struct wlan_objmgr_psoc * psoc)1389 bool wlan_mlme_get_epcs_capability(struct wlan_objmgr_psoc *psoc)
1390 {
1391 	return false;
1392 }
1393 
1394 static inline
wlan_mlme_set_epcs_capability(struct wlan_objmgr_psoc * psoc,bool flag)1395 void wlan_mlme_set_epcs_capability(struct wlan_objmgr_psoc *psoc, bool flag)
1396 {
1397 }
1398 
1399 static inline
wlan_mlme_get_usr_disable_sta_eht(struct wlan_objmgr_psoc * psoc)1400 bool wlan_mlme_get_usr_disable_sta_eht(struct wlan_objmgr_psoc *psoc)
1401 {
1402 	return true;
1403 }
1404 
1405 static inline
wlan_mlme_set_usr_disable_sta_eht(struct wlan_objmgr_psoc * psoc,bool disable)1406 void wlan_mlme_set_usr_disable_sta_eht(struct wlan_objmgr_psoc *psoc,
1407 				       bool disable)
1408 {
1409 }
1410 
1411 static inline
wlan_mlme_get_eht_disable_punct_in_us_lpi(struct wlan_objmgr_psoc * psoc)1412 bool wlan_mlme_get_eht_disable_punct_in_us_lpi(struct wlan_objmgr_psoc *psoc)
1413 {
1414 	return false;
1415 }
1416 
1417 static inline
wlan_mlme_set_eht_disable_punct_in_us_lpi(struct wlan_objmgr_psoc * psoc,bool flag)1418 void wlan_mlme_set_eht_disable_punct_in_us_lpi(struct wlan_objmgr_psoc *psoc,
1419 					       bool flag)
1420 {
1421 }
1422 
1423 static inline QDF_STATUS
wlan_mlme_update_bw_no_punct(struct wlan_objmgr_psoc * psoc,uint8_t vdev_id)1424 wlan_mlme_update_bw_no_punct(struct wlan_objmgr_psoc *psoc,
1425 			     uint8_t vdev_id)
1426 {
1427 	return QDF_STATUS_E_INVAL;
1428 }
1429 
1430 static inline QDF_STATUS
wlan_mlme_get_bw_no_punct(struct wlan_objmgr_psoc * psoc,struct wlan_objmgr_vdev * vdev,struct wlan_channel * bss_chan,enum phy_ch_width * new_ch_width)1431 wlan_mlme_get_bw_no_punct(struct wlan_objmgr_psoc *psoc,
1432 			  struct wlan_objmgr_vdev *vdev,
1433 			  struct wlan_channel *bss_chan,
1434 			  enum phy_ch_width *new_ch_width)
1435 {
1436 	return QDF_STATUS_E_INVAL;
1437 }
1438 #endif
1439 
1440 /**
1441  * wlan_mlme_is_ap_prot_enabled() - check if sap protection is enabled
1442  * @psoc: pointer to psoc object
1443  *
1444  * Return: is_ap_prot_enabled flag
1445  */
1446 bool wlan_mlme_is_ap_prot_enabled(struct wlan_objmgr_psoc *psoc);
1447 
1448 /**
1449  * wlan_mlme_get_ap_protection_mode() - Get ap_protection_mode value
1450  * @psoc: pointer to psoc object
1451  * @value: pointer to the value which needs to be filled for the caller
1452  *
1453  * Return: QDF Status
1454  */
1455 QDF_STATUS wlan_mlme_get_ap_protection_mode(struct wlan_objmgr_psoc *psoc,
1456 					    uint16_t *value);
1457 
1458 /**
1459  * wlan_mlme_is_ap_obss_prot_enabled() - Get ap_obss_protection is
1460  * enabled/disabled
1461  * @psoc: pointer to psoc object
1462  * @value: pointer to the value which needs to be filled for the caller
1463  *
1464  * Return: QDF Status
1465  */
1466 QDF_STATUS wlan_mlme_is_ap_obss_prot_enabled(struct wlan_objmgr_psoc *psoc,
1467 					     bool *value);
1468 
1469 /**
1470  * wlan_mlme_get_rts_threshold() - Get the RTS threshold config
1471  * @psoc: pointer to psoc object
1472  * @value: pointer to the value which will be filled for the caller
1473  *
1474  * Return: QDF Status
1475  */
1476 QDF_STATUS wlan_mlme_get_rts_threshold(struct wlan_objmgr_psoc *psoc,
1477 				       uint32_t *value);
1478 
1479 /**
1480  * wlan_mlme_set_rts_threshold() - Set the RTS threshold config
1481  * @psoc: pointer to psoc object
1482  * @value: Value that needs to be set from the caller
1483  *
1484  * Return: QDF Status
1485  */
1486 QDF_STATUS wlan_mlme_set_rts_threshold(struct wlan_objmgr_psoc *psoc,
1487 				       uint32_t value);
1488 
1489 /**
1490  * wlan_mlme_get_frag_threshold() - Get the Fragmentation threshold
1491  *                                  config
1492  * @psoc: pointer to psoc object
1493  * @value: pointer to the value which will be filled for the caller
1494  *
1495  * Return: QDF Status
1496  */
1497 QDF_STATUS wlan_mlme_get_frag_threshold(struct wlan_objmgr_psoc *psoc,
1498 					uint32_t *value);
1499 
1500 /**
1501  * wlan_mlme_set_frag_threshold() - Set the Fragmentation threshold
1502  *                                  config
1503  * @psoc: pointer to psoc object
1504  * @value: Value that needs to be set from the caller
1505  *
1506  * Return: QDF Status
1507  */
1508 QDF_STATUS wlan_mlme_set_frag_threshold(struct wlan_objmgr_psoc *psoc,
1509 					uint32_t value);
1510 
1511 /**
1512  * wlan_mlme_get_fils_enabled_info() - Get the fils enable info for driver
1513  * @psoc: pointer to psoc object
1514  * @value: pointer to the value which will be filled for the caller
1515  *
1516  * Return: QDF Status
1517  */
1518 QDF_STATUS wlan_mlme_get_fils_enabled_info(struct wlan_objmgr_psoc *psoc,
1519 					   bool *value);
1520 /**
1521  * wlan_mlme_set_fils_enabled_info() - Set the fils enable info for driver
1522  * @psoc: pointer to psoc object
1523  * @value: value that needs to be set from the caller
1524  *
1525  * Return: QDF Status
1526  */
1527 QDF_STATUS wlan_mlme_set_fils_enabled_info(struct wlan_objmgr_psoc *psoc,
1528 					   bool value);
1529 
1530 /**
1531  * wlan_mlme_set_primary_interface() - Set the primary iface id for driver
1532  * @psoc: pointer to psoc object
1533  * @value: value that needs to be set from the caller
1534  *
1535  * When a vdev is set as primary then based on the dual sta policy
1536  * "qca_wlan_concurrent_sta_policy_config" mcc preference and roaming has
1537  * to be enabled on the primary vdev
1538  *
1539  * Return: QDF Status
1540  */
1541 QDF_STATUS wlan_mlme_set_primary_interface(struct wlan_objmgr_psoc *psoc,
1542 					   uint8_t value);
1543 
1544 /**
1545  * wlan_mlme_set_default_primary_iface() - Set the default primary iface id
1546  * for driver
1547  * @psoc: pointer to psoc object
1548  *
1549  * Return: QDF Status
1550  */
1551 QDF_STATUS wlan_mlme_set_default_primary_iface(struct wlan_objmgr_psoc *psoc);
1552 
1553 /**
1554  * wlan_mlme_is_primary_interface_configured() - Check if primary iface is set
1555  * @psoc: pointer to psoc object
1556  *
1557  * Check if primary iface is configured from userspace through vendor command.
1558  * Return true if it's configured. If it's not configured, default value would
1559  * be 0xFF and return false then.
1560  *
1561  * Return: True or False
1562  */
1563 bool wlan_mlme_is_primary_interface_configured(struct wlan_objmgr_psoc *psoc);
1564 
1565 /**
1566  * wlan_mlme_peer_get_assoc_rsp_ies() - Get the assoc response IEs of peer
1567  * @peer: WLAN peer objmgr
1568  * @ie_buf: Pointer to IE buffer
1569  * @ie_len: Length of the IE buffer
1570  *
1571  * Get the pointer to assoc response IEs of the peer from MLME
1572  * and length of the IE buffer.
1573  *
1574  * Return: QDF_STATUS
1575  */
1576 QDF_STATUS wlan_mlme_peer_get_assoc_rsp_ies(struct wlan_objmgr_peer *peer,
1577 					    const uint8_t **ie_buf,
1578 					    size_t *ie_len);
1579 
1580 /**
1581  * wlan_mlme_get_mcc_duty_cycle_percentage() - Get primary STA iface duty
1582  * cycle percentage
1583  * @pdev: pointer to pdev object
1584  *
1585  * API to get the MCC duty cycle for primary and secondary STA's
1586  *
1587  * Return: primary iface quota on success
1588  */
1589 int wlan_mlme_get_mcc_duty_cycle_percentage(struct wlan_objmgr_pdev *pdev);
1590 
1591 /**
1592  * wlan_mlme_get_tl_delayed_trgr_frm_int() - Get delay interval(in ms)
1593  * of UAPSD auto trigger
1594  * @psoc: pointer to psoc object
1595  * @value: Value that needs to be set from the caller
1596  *
1597  * Return: None
1598  */
1599 void wlan_mlme_get_tl_delayed_trgr_frm_int(struct wlan_objmgr_psoc *psoc,
1600 					   uint32_t *value);
1601 
1602 /**
1603  * wlan_mlme_get_wmm_dir_ac_vi() - Get TSPEC direction
1604  * for VI
1605  * @psoc: pointer to psoc object
1606  * @value: Value that needs to be set from the caller
1607  *
1608  * Return: QDF Status
1609  */
1610 QDF_STATUS
1611 wlan_mlme_get_wmm_dir_ac_vi(struct wlan_objmgr_psoc *psoc, uint8_t *value);
1612 
1613 /**
1614  * wlan_mlme_get_wmm_nom_msdu_size_ac_vi() - Get normal
1615  * MSDU size for VI
1616  * @psoc: pointer to psoc object
1617  * @value: Value that needs to be set from the caller
1618  *
1619  * Return: QDF Status
1620  */
1621 QDF_STATUS wlan_mlme_get_wmm_nom_msdu_size_ac_vi(struct wlan_objmgr_psoc *psoc,
1622 						 uint16_t *value);
1623 
1624 /**
1625  * wlan_mlme_get_wmm_mean_data_rate_ac_vi() - mean data
1626  * rate for VI
1627  * @psoc: pointer to psoc object
1628  * @value: Value that needs to be set from the caller
1629  *
1630  * Return: QDF Status
1631  */
1632 QDF_STATUS
1633 wlan_mlme_get_wmm_mean_data_rate_ac_vi(struct wlan_objmgr_psoc *psoc,
1634 					uint32_t *value);
1635 
1636 /**
1637  * wlan_mlme_get_wmm_min_phy_rate_ac_vi() - min PHY
1638  * rate for VI
1639  * @psoc: pointer to psoc object
1640  * @value: Value that needs to be set from the caller
1641  *
1642  * Return: QDF Status
1643  */
1644 QDF_STATUS wlan_mlme_get_wmm_min_phy_rate_ac_vi(struct wlan_objmgr_psoc *psoc,
1645 						uint32_t *value);
1646 
1647 /**
1648  * wlan_mlme_get_wmm_sba_ac_vi() - surplus bandwidth
1649  * allowance for VI
1650  * @psoc: pointer to psoc object
1651  * @value: Value that needs to be set from the caller
1652  *
1653  * Return: QDF Status
1654  */
1655 QDF_STATUS
1656 wlan_mlme_get_wmm_sba_ac_vi(struct wlan_objmgr_psoc *psoc, uint16_t *value);
1657 
1658 /**
1659  * wlan_mlme_get_wmm_uapsd_vi_srv_intv() - Get Uapsd service
1660  * interval for video
1661  * @psoc: pointer to psoc object
1662  * @value: pointer to the value which will be filled for the caller
1663  *
1664  * Return: QDF Status
1665  */
1666 QDF_STATUS
1667 wlan_mlme_get_wmm_uapsd_vi_srv_intv(struct wlan_objmgr_psoc *psoc,
1668 				    uint32_t *value);
1669 
1670 /**
1671  * wlan_mlme_get_wmm_uapsd_vi_sus_intv() - Get Uapsd suspension
1672  * interval for video
1673  * @psoc: pointer to psoc object
1674  * @value: pointer to the value which will be filled for the caller
1675  *
1676  * Return: QDF Status
1677  */
1678 QDF_STATUS
1679 wlan_mlme_get_wmm_uapsd_vi_sus_intv(struct wlan_objmgr_psoc *psoc,
1680 				    uint32_t *value);
1681 
1682 /**
1683  * wlan_mlme_get_wmm_dir_ac_be() - Get TSPEC direction
1684  * for BE
1685  * @psoc: pointer to psoc object
1686  * @value: Value that needs to be set from the caller
1687  *
1688  * Return: QDF Status
1689  */
1690 QDF_STATUS
1691 wlan_mlme_get_wmm_dir_ac_be(struct wlan_objmgr_psoc *psoc,
1692 			    uint8_t *value);
1693 
1694 /**
1695  * wlan_mlme_get_wmm_nom_msdu_size_ac_be() - Get normal
1696  * MSDU size for BE
1697  * @psoc: pointer to psoc object
1698  * @value: Value that needs to be set from the caller
1699  *
1700  * Return: QDF Status
1701  */
1702 QDF_STATUS wlan_mlme_get_wmm_nom_msdu_size_ac_be(struct wlan_objmgr_psoc *psoc,
1703 						 uint16_t *value);
1704 
1705 /**
1706  * wlan_mlme_get_wmm_mean_data_rate_ac_be() - mean data
1707  * rate for BE
1708  * @psoc: pointer to psoc object
1709  * @value: Value that needs to be set from the caller
1710  *
1711  * Return: QDF Status
1712  */
1713 QDF_STATUS wlan_mlme_get_wmm_mean_data_rate_ac_be(struct wlan_objmgr_psoc *psoc,
1714 						  uint32_t *value);
1715 
1716 /**
1717  * wlan_mlme_get_wmm_min_phy_rate_ac_be() - min PHY
1718  * rate for BE
1719  * @psoc: pointer to psoc object
1720  * @value: Value that needs to be set from the caller
1721  *
1722  * Return: QDF Status
1723  */
1724 QDF_STATUS wlan_mlme_get_wmm_min_phy_rate_ac_be(struct wlan_objmgr_psoc *psoc,
1725 						uint32_t *value);
1726 
1727 /**
1728  * wlan_mlme_get_wmm_sba_ac_be() - surplus bandwidth
1729  * allowance for BE
1730  * @psoc: pointer to psoc object
1731  * @value: Value that needs to be set from the caller
1732  *
1733  * Return: QDF Status
1734  */
1735 QDF_STATUS
1736 wlan_mlme_get_wmm_sba_ac_be(struct wlan_objmgr_psoc *psoc, uint16_t *value);
1737 
1738 /**
1739  * wlan_mlme_get_wmm_uapsd_be_srv_intv() - Get Uapsd service
1740  * interval for BE
1741  * @psoc: pointer to psoc object
1742  * @value: pointer to the value which will be filled for the caller
1743  *
1744  * Return: QDF Status
1745  */
1746 QDF_STATUS
1747 wlan_mlme_get_wmm_uapsd_be_srv_intv(struct wlan_objmgr_psoc *psoc,
1748 				    uint32_t *value);
1749 
1750 /**
1751  * wlan_mlme_get_wmm_uapsd_be_sus_intv() - Get Uapsd suspension
1752  * interval for BE
1753  * @psoc: pointer to psoc object
1754  * @value: pointer to the value which will be filled for the caller
1755  *
1756  * Return: QDF Status
1757  */
1758 QDF_STATUS
1759 wlan_mlme_get_wmm_uapsd_be_sus_intv(struct wlan_objmgr_psoc *psoc,
1760 				    uint32_t *value);
1761 
1762 /**
1763  * wlan_mlme_get_wmm_dir_ac_bk() - Get TSPEC direction
1764  * for BK
1765  * @psoc: pointer to psoc object
1766  * @value: Value that needs to be set from the caller
1767  *
1768  * Return: QDF Status
1769  */
1770 QDF_STATUS
1771 wlan_mlme_get_wmm_dir_ac_bk(struct wlan_objmgr_psoc *psoc, uint8_t *value);
1772 
1773 /**
1774  * wlan_mlme_get_wmm_nom_msdu_size_ac_bk() - Get normal
1775  * MSDU size for BK
1776  * @psoc: pointer to psoc object
1777  * @value: Value that needs to be set from the caller
1778  *
1779  * Return: QDF Status
1780  */
1781 QDF_STATUS wlan_mlme_get_wmm_nom_msdu_size_ac_bk(struct wlan_objmgr_psoc *psoc,
1782 						 uint16_t *value);
1783 
1784 /**
1785  * wlan_mlme_get_wmm_mean_data_rate_ac_bk() - mean data
1786  * rate for BK
1787  * @psoc: pointer to psoc object
1788  * @value: Value that needs to be set from the caller
1789  *
1790  * Return: QDF Status
1791  */
1792 QDF_STATUS wlan_mlme_get_wmm_mean_data_rate_ac_bk(struct wlan_objmgr_psoc *psoc,
1793 						  uint32_t *value);
1794 
1795 /**
1796  * wlan_mlme_get_wmm_min_phy_rate_ac_bk() - min PHY
1797  * rate for BK
1798  * @psoc: pointer to psoc object
1799  * @value: Value that needs to be set from the caller
1800  *
1801  * Return: QDF Status
1802  */
1803 QDF_STATUS wlan_mlme_get_wmm_min_phy_rate_ac_bk(struct wlan_objmgr_psoc *psoc,
1804 						uint32_t *value);
1805 
1806 /**
1807  * wlan_mlme_get_wmm_sba_ac_bk() - surplus bandwidth
1808  * allowance for BE
1809  * @psoc: pointer to psoc object
1810  * @value: Value that needs to be set from the caller
1811  *
1812  * Return: QDF Status
1813  */
1814 QDF_STATUS
1815 wlan_mlme_get_wmm_sba_ac_bk(struct wlan_objmgr_psoc *psoc, uint16_t *value);
1816 
1817 /**
1818  * wlan_mlme_get_wmm_uapsd_bk_srv_intv() - Get Uapsd service
1819  * interval for BK
1820  * @psoc: pointer to psoc object
1821  * @value: pointer to the value which will be filled for the caller
1822  *
1823  * Return: QDF Status
1824  */
1825 QDF_STATUS
1826 wlan_mlme_get_wmm_uapsd_bk_srv_intv(struct wlan_objmgr_psoc *psoc,
1827 				    uint32_t *value);
1828 
1829 /**
1830  * wlan_mlme_get_wmm_uapsd_bk_sus_intv() - Get Uapsd suspension
1831  * interval for BK
1832  * @psoc: pointer to psoc object
1833  * @value: pointer to the value which will be filled for the caller
1834  *
1835  * Return: QDF Status
1836  */
1837 QDF_STATUS
1838 wlan_mlme_get_wmm_uapsd_bk_sus_intv(struct wlan_objmgr_psoc *psoc,
1839 				    uint32_t *value);
1840 
1841 /**
1842  * wlan_mlme_get_wmm_mode() - Enable WMM feature
1843  * @psoc: pointer to psoc object
1844  * @value: pointer to the value which will be filled for the caller
1845  *
1846  * Return: QDF Status
1847  */
1848 QDF_STATUS
1849 wlan_mlme_get_wmm_mode(struct wlan_objmgr_psoc *psoc, uint8_t *value);
1850 
1851 /**
1852  * wlan_mlme_get_80211e_is_enabled() - Enable 802.11e feature
1853  * @psoc: pointer to psoc object
1854  * @value: pointer to the value which will be filled for the caller
1855  *
1856  * Return: QDF Status
1857  */
1858 QDF_STATUS
1859 wlan_mlme_get_80211e_is_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
1860 
1861 /**
1862  * wlan_mlme_get_wmm_uapsd_mask() - setup U-APSD mask for ACs
1863  * @psoc: pointer to psoc object
1864  * @value: pointer to the value which will be filled for the caller
1865  *
1866  * Return: QDF Status
1867  */
1868 QDF_STATUS
1869 wlan_mlme_get_wmm_uapsd_mask(struct wlan_objmgr_psoc *psoc, uint8_t *value);
1870 
1871 #ifdef FEATURE_WLAN_ESE
1872 /**
1873  * wlan_mlme_get_inactivity_interval() - Infra Inactivity Interval
1874  * @psoc: pointer to psoc object
1875  * @value: pointer to the value which will be filled for the caller
1876  *
1877  * Return: None
1878  */
1879 void
1880 wlan_mlme_get_inactivity_interval(struct wlan_objmgr_psoc *psoc,
1881 				  uint32_t *value);
1882 #endif
1883 
1884 /**
1885  * wlan_mlme_get_is_ts_burst_size_enable() - Get TS burst size flag
1886  * @psoc: pointer to psoc object
1887  * @value: pointer to the value which will be filled for the caller
1888  *
1889  * Return: None
1890  */
1891 void wlan_mlme_get_is_ts_burst_size_enable(struct wlan_objmgr_psoc *psoc,
1892 					   bool *value);
1893 
1894 /**
1895  * wlan_mlme_get_ts_info_ack_policy() - Get TS ack policy
1896  * @psoc: pointer to psoc object
1897  * @value: pointer to the value which will be filled for the caller
1898  *
1899  * Return: None
1900  */
1901 void wlan_mlme_get_ts_info_ack_policy(struct wlan_objmgr_psoc *psoc,
1902 				      enum mlme_ts_info_ack_policy *value);
1903 
1904 /**
1905  * wlan_mlme_get_ts_acm_value_for_ac() - Get ACM value for AC
1906  * @psoc: pointer to psoc object
1907  * @value: pointer to the value which will be filled for the caller
1908  *
1909  * Return: QDF Status
1910  */
1911 QDF_STATUS
1912 wlan_mlme_get_ts_acm_value_for_ac(struct wlan_objmgr_psoc *psoc, bool *value);
1913 
1914 /**
1915  * wlan_mlme_get_wmm_dir_ac_vo() - Get TSPEC direction
1916  * for VO
1917  * @psoc: pointer to psoc object
1918  * @value: Value that needs to be set from the caller
1919  *
1920  * Return: QDF Status
1921  */
1922 QDF_STATUS
1923 wlan_mlme_get_wmm_dir_ac_vo(struct wlan_objmgr_psoc *psoc, uint8_t *value);
1924 
1925 /**
1926  * wlan_mlme_get_wmm_nom_msdu_size_ac_vo() - Get normal
1927  * MSDU size for VO
1928  * @psoc: pointer to psoc object
1929  * @value: Value that needs to be set from the caller
1930  *
1931  * Return: QDF Status
1932  */
1933 QDF_STATUS wlan_mlme_get_wmm_nom_msdu_size_ac_vo(struct wlan_objmgr_psoc *psoc,
1934 						 uint16_t *value);
1935 
1936 /**
1937  * wlan_mlme_get_wmm_mean_data_rate_ac_vo() - mean data rate for VO
1938  * @psoc: pointer to psoc object
1939  * @value: Value that needs to be set from the caller
1940  *
1941  * Return: QDF Status
1942  */
1943 QDF_STATUS wlan_mlme_get_wmm_mean_data_rate_ac_vo(struct wlan_objmgr_psoc *psoc,
1944 						  uint32_t *value);
1945 /**
1946  * wlan_mlme_get_wmm_min_phy_rate_ac_vo() - min PHY
1947  * rate for VO
1948  * @psoc: pointer to psoc object
1949  * @value: Value that needs to be set from the caller
1950  *
1951  * Return: QDF Status
1952  */
1953 QDF_STATUS wlan_mlme_get_wmm_min_phy_rate_ac_vo(struct wlan_objmgr_psoc *psoc,
1954 						uint32_t *value);
1955 /**
1956  * wlan_mlme_get_wmm_sba_ac_vo() - surplus bandwidth allowance for VO
1957  * @psoc: pointer to psoc object
1958  * @value: Value that needs to be set from the caller
1959  *
1960  *  Return: QDF Status
1961  */
1962 QDF_STATUS
1963 wlan_mlme_get_wmm_sba_ac_vo(struct wlan_objmgr_psoc *psoc, uint16_t *value);
1964 
1965 /**
1966  * wlan_mlme_set_enable_bcast_probe_rsp() - Set enable bcast probe resp info
1967  * @psoc: pointer to psoc object
1968  * @value: value that needs to be set from the caller
1969  *
1970  * Return: QDF Status
1971  */
1972 QDF_STATUS wlan_mlme_set_enable_bcast_probe_rsp(struct wlan_objmgr_psoc *psoc,
1973 						bool value);
1974 
1975 /**
1976  * wlan_mlme_get_wmm_uapsd_vo_srv_intv() - Get Uapsd service
1977  * interval for voice
1978  * @psoc: pointer to psoc object
1979  * @value: pointer to the value which will be filled for the caller
1980  *
1981  * Return: QDF Status
1982  */
1983 QDF_STATUS
1984 wlan_mlme_get_wmm_uapsd_vo_srv_intv(struct wlan_objmgr_psoc *psoc,
1985 				    uint32_t *value);
1986 
1987 /**
1988  * wlan_mlme_get_wmm_uapsd_vo_sus_intv() - Get Uapsd suspension
1989  * interval for voice
1990  * @psoc: pointer to psoc object
1991  * @value: pointer to the value which will be filled for the caller
1992  *
1993  * Return: QDF Status
1994  */
1995 QDF_STATUS
1996 wlan_mlme_get_wmm_uapsd_vo_sus_intv(struct wlan_objmgr_psoc *psoc,
1997 				    uint32_t *value);
1998 
1999 /**
2000  * wlan_mlme_cfg_get_vht_max_mpdu_len() - gets vht max mpdu length from cfg item
2001  * @psoc: psoc context
2002  * @value: pointer to get required data
2003  *
2004  * Return: QDF_STATUS
2005  */
2006 QDF_STATUS
2007 wlan_mlme_cfg_get_vht_max_mpdu_len(struct wlan_objmgr_psoc *psoc,
2008 				   uint8_t *value);
2009 
2010 /**
2011  * wlan_mlme_cfg_set_vht_max_mpdu_len() - sets vht max mpdu length into cfg item
2012  * @psoc: psoc context
2013  * @value: data to be set
2014  *
2015  * Return: QDF_STATUS
2016  */
2017 QDF_STATUS
2018 wlan_mlme_cfg_set_vht_max_mpdu_len(struct wlan_objmgr_psoc *psoc,
2019 				   uint8_t value);
2020 
2021 /**
2022  * wlan_mlme_cfg_get_ht_smps() - gets HT SM Power Save mode from cfg item
2023  * @psoc: psoc context
2024  * @value: data to be set
2025  *
2026  * Return: QDF_STATUS
2027  */
2028 QDF_STATUS wlan_mlme_cfg_get_ht_smps(struct wlan_objmgr_psoc *psoc,
2029 				     uint8_t *value);
2030 
2031 /**
2032  * wlan_mlme_cfg_get_vht_chan_width() - gets vht supported channel width from
2033  * cfg item
2034  * @psoc: psoc context
2035  * @value: pointer to get required data
2036  *
2037  * Return: QDF_STATUS
2038  */
2039 QDF_STATUS wlan_mlme_cfg_get_vht_chan_width(struct wlan_objmgr_psoc *psoc,
2040 					    uint8_t *value);
2041 
2042 /**
2043  * wlan_mlme_cfg_set_vht_chan_width() - sets vht supported channel width into
2044  * cfg item
2045  * @psoc: psoc context
2046  * @value: data to be set
2047  *
2048  * Return: QDF_STATUS
2049  */
2050 QDF_STATUS wlan_mlme_cfg_set_vht_chan_width(struct wlan_objmgr_psoc *psoc,
2051 					    uint8_t value);
2052 
2053 /**
2054  * wlan_mlme_cfg_get_vht_chan_width() - sets vht supported channel width into
2055  * cfg item
2056  * @psoc: psoc context
2057  * @value: data to be set
2058  *
2059  * Return: QDF_STATUS
2060  */
2061 QDF_STATUS wlan_mlme_cfg_get_vht_chan_width(struct wlan_objmgr_psoc *psoc,
2062 					    uint8_t *value);
2063 
2064 /**
2065  * wlan_mlme_cfg_get_vht_ldpc_coding_cap() - gets vht ldpc coding cap from
2066  * cfg item
2067  * @psoc: psoc context
2068  * @value: pointer to get required data
2069  *
2070  * Return: QDF_STATUS
2071  */
2072 QDF_STATUS wlan_mlme_cfg_get_vht_ldpc_coding_cap(struct wlan_objmgr_psoc *psoc,
2073 						 bool *value);
2074 
2075 /**
2076  * wlan_mlme_cfg_set_vht_ldpc_coding_cap() - sets vht ldpc coding cap into
2077  * cfg item
2078  * @psoc: psoc context
2079  * @value: data to be set
2080  *
2081  * Return: QDF_STATUS
2082  */
2083 QDF_STATUS wlan_mlme_cfg_set_vht_ldpc_coding_cap(struct wlan_objmgr_psoc *psoc,
2084 						 bool value);
2085 
2086 /**
2087  * wlan_mlme_cfg_get_vht_short_gi_80mhz() - gets vht short gi 80MHz from
2088  * cfg item
2089  * @psoc: psoc context
2090  * @value: pointer to get required data
2091  *
2092  * Return: QDF_STATUS
2093  */
2094 QDF_STATUS wlan_mlme_cfg_get_vht_short_gi_80mhz(struct wlan_objmgr_psoc *psoc,
2095 						bool *value);
2096 
2097 /**
2098  * wlan_mlme_cfg_set_vht_short_gi_80mhz() - sets vht short gi 80MHz into
2099  * cfg item
2100  * @psoc: psoc context
2101  * @value: data to be set
2102  *
2103  * Return: QDF_STATUS
2104  */
2105 QDF_STATUS wlan_mlme_cfg_set_vht_short_gi_80mhz(struct wlan_objmgr_psoc *psoc,
2106 						bool value);
2107 
2108 /**
2109  * wlan_mlme_cfg_get_short_gi_160_mhz() - gets vht short gi 160MHz from
2110  * cfg item
2111  * @psoc: psoc context
2112  * @value: pointer to get required data
2113  *
2114  * Return: QDF_STATUS
2115  */
2116 QDF_STATUS
2117 wlan_mlme_cfg_get_short_gi_160_mhz(struct wlan_objmgr_psoc *psoc, bool *value);
2118 
2119 /**
2120  * wlan_mlme_cfg_set_short_gi_160_mhz() - sets vht short gi 160MHz into
2121  * cfg item
2122  * @psoc: psoc context
2123  * @value: data to be set
2124  *
2125  * Return: QDF_STATUS
2126  */
2127 QDF_STATUS
2128 wlan_mlme_cfg_set_short_gi_160_mhz(struct wlan_objmgr_psoc *psoc, bool value);
2129 
2130 /**
2131  * wlan_mlme_cfg_get_vht_tx_stbc() - gets vht tx stbc from
2132  * cfg item
2133  * @psoc: psoc context
2134  * @value: pointer to get required data
2135  *
2136  * Return: QDF_STATUS
2137  */
2138 QDF_STATUS
2139 wlan_mlme_cfg_get_vht_tx_stbc(struct wlan_objmgr_psoc *psoc, bool *value);
2140 
2141 /**
2142  * wlan_mlme_cfg_get_vht_rx_stbc() - gets vht rx stbc from
2143  * cfg item
2144  * @psoc: psoc context
2145  * @value: pointer to get required data
2146  *
2147  * Return: QDF_STATUS
2148  */
2149 QDF_STATUS
2150 wlan_mlme_cfg_get_vht_rx_stbc(struct wlan_objmgr_psoc *psoc, bool *value);
2151 
2152 /**
2153  * wlan_mlme_cfg_set_vht_tx_stbc() - sets vht tx stbc into
2154  * cfg item
2155  * @psoc: psoc context
2156  * @value: data to be set
2157  *
2158  * Return: QDF_STATUS
2159  */
2160 QDF_STATUS
2161 wlan_mlme_cfg_set_vht_tx_stbc(struct wlan_objmgr_psoc *psoc, bool value);
2162 
2163 /**
2164  * wlan_mlme_cfg_get_vht_rx_stbc() - gets vht rx stbc from
2165  * cfg item
2166  * @psoc: psoc context
2167  * @value: pointer to get required data
2168  *
2169  * Return: QDF_STATUS
2170  */
2171 QDF_STATUS
2172 wlan_mlme_cfg_get_vht_rx_stbc(struct wlan_objmgr_psoc *psoc, bool *value);
2173 
2174 /**
2175  * wlan_mlme_cfg_set_vht_rx_stbc() - sets vht rx stbc into
2176  * cfg item
2177  * @psoc: psoc context
2178  * @value: data to be set
2179  *
2180  * Return: QDF_STATUS
2181  */
2182 QDF_STATUS
2183 wlan_mlme_cfg_set_vht_rx_stbc(struct wlan_objmgr_psoc *psoc, bool value);
2184 
2185 /**
2186  * wlan_mlme_cfg_get_vht_su_bformer() - gets vht su beam former cap from
2187  * cfg item
2188  * @psoc: psoc context
2189  * @value: pointer to get required data
2190  *
2191  * Return: QDF_STATUS
2192  */
2193 QDF_STATUS
2194 wlan_mlme_cfg_get_vht_su_bformer(struct wlan_objmgr_psoc *psoc, bool *value);
2195 
2196 /**
2197  * wlan_mlme_cfg_set_vht_su_bformer() - sets vht su beam former cap into
2198  * cfg item
2199  * @psoc: psoc context
2200  * @value: data to be set
2201  *
2202  * Return: QDF_STATUS
2203  */
2204 QDF_STATUS
2205 wlan_mlme_cfg_set_vht_su_bformer(struct wlan_objmgr_psoc *psoc, bool value);
2206 
2207 /**
2208  * wlan_mlme_cfg_set_vht_su_bformee() - sets vht su beam formee cap into
2209  * cfg item
2210  * @psoc: psoc context
2211  * @value: data to be set
2212  *
2213  * Return: QDF_STATUS
2214  */
2215 QDF_STATUS
2216 wlan_mlme_cfg_set_vht_su_bformee(struct wlan_objmgr_psoc *psoc, bool value);
2217 
2218 /**
2219  * wlan_mlme_cfg_set_vht_tx_bfee_ant_supp() - sets vht Beamformee antenna
2220  * support cap
2221  * into cfg item
2222  * @psoc: psoc context
2223  * @value: data to be set
2224  *
2225  * Return: QDF_STATUS
2226  */
2227 QDF_STATUS wlan_mlme_cfg_set_vht_tx_bfee_ant_supp(struct wlan_objmgr_psoc *psoc,
2228 						  uint8_t value);
2229 
2230 /**
2231  * wlan_mlme_cfg_get_vht_tx_bfee_ant_supp() - Gets vht Beamformee antenna
2232  * support cap into cfg item
2233  *
2234  * @psoc: psoc context
2235  * @value: data to be set
2236  *
2237  * Return: QDF_STATUS
2238  */
2239 QDF_STATUS wlan_mlme_cfg_get_vht_tx_bfee_ant_supp(struct wlan_objmgr_psoc *psoc,
2240 						  uint8_t *value);
2241 
2242 /**
2243  * wlan_mlme_cfg_set_vht_num_sounding_dim() - sets vht no of sounding dimensions
2244  * into cfg item
2245  * @psoc: psoc context
2246  * @value: data to be set
2247  *
2248  * Return: QDF_STATUS
2249  */
2250 QDF_STATUS wlan_mlme_cfg_set_vht_num_sounding_dim(struct wlan_objmgr_psoc *psoc,
2251 						  uint8_t value);
2252 
2253 /**
2254  * wlan_mlme_cfg_get_vht_mu_bformer() - gets vht mu beam former cap from
2255  * cfg item
2256  * @psoc: psoc context
2257  * @value: pointer to get required data
2258  *
2259  * Return: QDF_STATUS
2260  */
2261 QDF_STATUS
2262 wlan_mlme_cfg_get_vht_mu_bformer(struct wlan_objmgr_psoc *psoc, bool *value);
2263 
2264 /**
2265  * wlan_mlme_cfg_set_vht_mu_bformer() - sets vht mu beam former cap into
2266  * cfg item
2267  * @psoc: psoc context
2268  * @value: data to be set
2269  *
2270  * Return: QDF_STATUS
2271  */
2272 QDF_STATUS
2273 wlan_mlme_cfg_set_vht_mu_bformer(struct wlan_objmgr_psoc *psoc, bool value);
2274 
2275 /**
2276  * wlan_mlme_cfg_get_vht_mu_bformee() - gets vht mu beam formee cap from
2277  * cfg item
2278  * @psoc: psoc context
2279  * @value: pointer to get required data
2280  *
2281  * Return: QDF_STATUS
2282  */
2283 QDF_STATUS
2284 wlan_mlme_cfg_get_vht_mu_bformee(struct wlan_objmgr_psoc *psoc, bool *value);
2285 
2286 /**
2287  * wlan_mlme_cfg_set_vht_mu_bformee() - sets vht mu beam formee cap into
2288  * cfg item
2289  * @psoc: psoc context
2290  * @value: data to be set
2291  *
2292  * Return: QDF_STATUS
2293  */
2294 QDF_STATUS
2295 wlan_mlme_cfg_set_vht_mu_bformee(struct wlan_objmgr_psoc *psoc, bool value);
2296 
2297 /**
2298  * wlan_mlme_cfg_get_vht_txop_ps() - gets vht tx ops ps cap from
2299  * cfg item
2300  * @psoc: psoc context
2301  * @value: pointer to get required data
2302  *
2303  * Return: QDF_STATUS
2304  */
2305 QDF_STATUS
2306 wlan_mlme_cfg_get_vht_txop_ps(struct wlan_objmgr_psoc *psoc, bool *value);
2307 
2308 /**
2309  * wlan_mlme_cfg_set_vht_txop_ps() - sets vht tx ops ps cap into
2310  * cfg item
2311  * @psoc: psoc context
2312  * @value: data to be set
2313  *
2314  * Return: QDF_STATUS
2315  */
2316 QDF_STATUS
2317 wlan_mlme_cfg_set_vht_txop_ps(struct wlan_objmgr_psoc *psoc, bool value);
2318 
2319 /**
2320  * wlan_mlme_cfg_get_vht_ampdu_len_exp() - gets vht max AMPDU length exponent from
2321  * cfg item
2322  * @psoc: psoc context
2323  * @value: pointer to get required data
2324  *
2325  * Return: QDF_STATUS
2326  */
2327 QDF_STATUS
2328 wlan_mlme_cfg_get_vht_ampdu_len_exp(struct wlan_objmgr_psoc *psoc,
2329 				    uint8_t *value);
2330 
2331 /**
2332  * wlan_mlme_cfg_set_vht_ampdu_len_exp() - sets vht max AMPDU length exponent into
2333  * cfg item
2334  * @psoc: psoc context
2335  * @value: data to be set
2336  *
2337  * Return: QDF_STATUS
2338  */
2339 QDF_STATUS
2340 wlan_mlme_cfg_set_vht_ampdu_len_exp(struct wlan_objmgr_psoc *psoc,
2341 				    uint8_t value);
2342 
2343 /**
2344  * wlan_mlme_cfg_get_vht_rx_mcs_map() - gets vht rx mcs map from
2345  * cfg item
2346  * @psoc: psoc context
2347  * @value: pointer to get required data
2348  *
2349  * Return: QDF_STATUS
2350  */
2351 QDF_STATUS wlan_mlme_cfg_get_vht_rx_mcs_map(struct wlan_objmgr_psoc *psoc,
2352 					    uint32_t *value);
2353 
2354 /**
2355  * wlan_mlme_cfg_set_vht_rx_mcs_map() - sets rx mcs map into
2356  * cfg item
2357  * @psoc: psoc context
2358  * @value: data to be set
2359  *
2360  * Return: QDF_STATUS
2361  */
2362 QDF_STATUS
2363 wlan_mlme_cfg_set_vht_rx_mcs_map(struct wlan_objmgr_psoc *psoc, uint32_t value);
2364 
2365 /**
2366  * wlan_mlme_cfg_get_vht_tx_mcs_map() - gets vht tx mcs map from
2367  * cfg item
2368  * @psoc: psoc context
2369  * @value: pointer to get required data
2370  *
2371  * Return: QDF_STATUS
2372  */
2373 QDF_STATUS wlan_mlme_cfg_get_vht_tx_mcs_map(struct wlan_objmgr_psoc *psoc,
2374 					    uint32_t *value);
2375 
2376 /**
2377  * wlan_mlme_cfg_set_vht_tx_mcs_map() - sets tx mcs map into
2378  * cfg item
2379  * @psoc: psoc context
2380  * @value: data to be set
2381  *
2382  * Return: QDF_STATUS
2383  */
2384 QDF_STATUS wlan_mlme_cfg_set_vht_tx_mcs_map(struct wlan_objmgr_psoc *psoc,
2385 					    uint32_t value);
2386 
2387 /**
2388  * wlan_mlme_cfg_set_vht_rx_supp_data_rate() - sets rx supported data rate into
2389  * cfg item
2390  * @psoc: psoc context
2391  * @value: data to be set
2392  *
2393  * Return: QDF_STATUS
2394  */
2395 QDF_STATUS
2396 wlan_mlme_cfg_set_vht_rx_supp_data_rate(struct wlan_objmgr_psoc *psoc,
2397 					uint32_t value);
2398 
2399 /**
2400  * wlan_mlme_cfg_set_vht_tx_supp_data_rate() - sets tx supported data rate into
2401  * cfg item
2402  * @psoc: psoc context
2403  * @value: data to be set
2404  *
2405  * Return: QDF_STATUS
2406  */
2407 QDF_STATUS
2408 wlan_mlme_cfg_set_vht_tx_supp_data_rate(struct wlan_objmgr_psoc *psoc,
2409 					uint32_t value);
2410 
2411 /**
2412  * wlan_mlme_cfg_get_vht_basic_mcs_set() - gets basic mcs set from
2413  * cfg item
2414  * @psoc: psoc context
2415  * @value: data to be set
2416  *
2417  * Return: QDF_STATUS
2418  */
2419 QDF_STATUS
2420 wlan_mlme_cfg_get_vht_basic_mcs_set(struct wlan_objmgr_psoc *psoc,
2421 				    uint32_t *value);
2422 
2423 /**
2424  * wlan_mlme_cfg_set_vht_basic_mcs_set() - sets basic mcs set into
2425  * cfg item
2426  * @psoc: psoc context
2427  * @value: data to be set
2428  *
2429  * Return: QDF_STATUS
2430  */
2431 QDF_STATUS
2432 wlan_mlme_cfg_set_vht_basic_mcs_set(struct wlan_objmgr_psoc *psoc,
2433 				    uint32_t value);
2434 
2435 /**
2436  * wlan_mlme_get_vht_enable_tx_bf() - Get vht enable tx bf
2437  * @psoc: psoc context
2438  * @value: data to be set
2439  *
2440  * Return: QDF_STATUS
2441  */
2442 QDF_STATUS
2443 wlan_mlme_get_vht_enable_tx_bf(struct wlan_objmgr_psoc *psoc, bool *value);
2444 
2445 /**
2446  * wlan_mlme_get_vht_tx_su_beamformer() - VHT enable tx su beamformer
2447  * @psoc: psoc context
2448  * @value: data to be set
2449  *
2450  * Return: QDF_STATUS
2451  */
2452 QDF_STATUS
2453 wlan_mlme_get_vht_tx_su_beamformer(struct wlan_objmgr_psoc *psoc, bool *value);
2454 
2455 /**
2456  * wlan_mlme_get_vht_channel_width() - gets Channel width capability
2457  * for 11ac
2458  * @psoc: psoc context
2459  * @value: data to be set
2460  *
2461  * Return: QDF_STATUS
2462  */
2463 QDF_STATUS wlan_mlme_get_vht_channel_width(struct wlan_objmgr_psoc *psoc,
2464 					   uint8_t *value);
2465 
2466 /**
2467  * wlan_mlme_get_vht_rx_mcs_8_9() - VHT Rx MCS capability for 1x1 mode
2468  * @psoc: psoc context
2469  * @value: data to be set
2470  *
2471  * Return: QDF_STATUS
2472  */
2473 QDF_STATUS wlan_mlme_get_vht_rx_mcs_8_9(struct wlan_objmgr_psoc *psoc,
2474 					uint8_t *value);
2475 
2476 /**
2477  * wlan_mlme_get_vht_tx_mcs_8_9() - VHT Tx MCS capability for 1x1 mode
2478  * @psoc: psoc context
2479  * @value: data to be set
2480  *
2481  * Return: QDF_STATUS
2482  */
2483 QDF_STATUS
2484 wlan_mlme_get_vht_tx_mcs_8_9(struct wlan_objmgr_psoc *psoc, uint8_t *value);
2485 
2486 /**
2487  * wlan_mlme_get_vht_rx_mcs_2x2() - VHT Rx MCS capability for 2x2 mode
2488  * @psoc: psoc context
2489  * @value: data to be set
2490  *
2491  * Return: QDF_STATUS
2492  */
2493 QDF_STATUS wlan_mlme_get_vht_rx_mcs_2x2(struct wlan_objmgr_psoc *psoc,
2494 					uint8_t *value);
2495 
2496 /**
2497  * wlan_mlme_get_vht_tx_mcs_2x2() - VHT Tx MCS capability for 2x2 mode
2498  * @psoc: psoc context
2499  * @value: data to be set
2500  *
2501  * Return: QDF_STATUS
2502  */
2503 QDF_STATUS wlan_mlme_get_vht_tx_mcs_2x2(struct wlan_objmgr_psoc *psoc,
2504 					uint8_t *value);
2505 
2506 /**
2507  * wlan_mlme_get_vht20_mcs9() - Enables VHT MCS9 in 20M BW operation
2508  * @psoc: psoc context
2509  * @value: data to be set
2510  *
2511  * Return: QDF_STATUS
2512  */
2513 QDF_STATUS
2514 wlan_mlme_get_vht20_mcs9(struct wlan_objmgr_psoc *psoc, bool *value);
2515 
2516 /**
2517  * wlan_mlme_get_srd_master_mode_for_vdev  - Get SRD master mode for vdev
2518  * @psoc:          pointer to psoc object
2519  * @vdev_opmode:   vdev operating mode
2520  * @value:  pointer to the value which will be filled for the caller
2521  *
2522  * Return: QDF Status
2523  */
2524 QDF_STATUS
2525 wlan_mlme_get_srd_master_mode_for_vdev(struct wlan_objmgr_psoc *psoc,
2526 				       enum QDF_OPMODE vdev_opmode,
2527 				       bool *value);
2528 
2529 /**
2530  * wlan_mlme_get_indoor_support_for_nan  - Get indoor channel support for NAN
2531  * @psoc: pointer to psoc object
2532  * @value: pointer to the value which will be filled for the caller
2533  *
2534  * Return: QDF Status
2535  */
2536 QDF_STATUS
2537 wlan_mlme_get_indoor_support_for_nan(struct wlan_objmgr_psoc *psoc,
2538 				     bool *value);
2539 
2540 /**
2541  * wlan_mlme_get_force_sap_enabled() - Get the value of force SAP enabled
2542  * @psoc: psoc context
2543  * @value: data to get
2544  *
2545  * Get the value of force SAP enabled
2546  *
2547  * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
2548  */
2549 QDF_STATUS
2550 wlan_mlme_get_force_sap_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
2551 
2552 /**
2553  * wlan_mlme_get_enable_dynamic_nss_chains_cfg() - API to get whether dynamic
2554  * nss and chain config is enabled or not
2555  * @psoc: psoc context
2556  * @value: data to be set
2557  *
2558  * API to get whether dynamic nss and chain config is enabled or not
2559  *
2560  * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
2561  */
2562 QDF_STATUS
2563 wlan_mlme_get_enable_dynamic_nss_chains_cfg(struct wlan_objmgr_psoc *psoc,
2564 					    bool *value);
2565 
2566 /**
2567  * wlan_mlme_get_restart_sap_on_dynamic_nss_chains_cfg() - API to get whether
2568  * SAP needs to be restarted or not on dynamic nss chain config
2569  * @psoc: psoc context
2570  * @value: data to be set
2571  *
2572  * API to get whether SAP needs to be restarted or not on dynamic nss chain
2573  * config
2574  *
2575  * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
2576  */
2577 QDF_STATUS
2578 wlan_mlme_get_restart_sap_on_dynamic_nss_chains_cfg(
2579 						struct wlan_objmgr_psoc *psoc,
2580 						bool *value);
2581 
2582 /**
2583  * wlan_mlme_cfg_set_dynamic_nss_chains_support() - API to update
2584  * dynamic_nss_chains_support
2585  *
2586  * @psoc: psoc context
2587  * @value: data to be set
2588  *
2589  * API to update dynamic_nss_chains_support in wlan_mlme_cfg object to
2590  * maintain this value in mlme context
2591  *
2592  * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
2593  */
2594 QDF_STATUS
2595 wlan_mlme_cfg_set_dynamic_nss_chains_support(struct wlan_objmgr_psoc *psoc,
2596 					     bool value);
2597 
2598 /**
2599  * wlan_mlme_cfg_get_dynamic_nss_chains_support() - API to get current value of
2600  * dynamic_nss_chains_support
2601  *
2602  * @psoc: psoc context
2603  * @value: data to be set
2604  *
2605  * API to get current value of dynamic_nss_chains_support
2606  *
2607  * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
2608  */
2609 QDF_STATUS
2610 wlan_mlme_cfg_get_dynamic_nss_chains_support(struct wlan_objmgr_psoc *psoc,
2611 					     bool *value);
2612 
2613 /**
2614  * wlan_mlme_get_vht_enable2x2() - Enables/disables VHT Tx/Rx MCS values for 2x2
2615  * @psoc: psoc context
2616  * @value: data to be set
2617  *
2618  * Return: QDF_STATUS
2619  */
2620 QDF_STATUS
2621 wlan_mlme_get_vht_enable2x2(struct wlan_objmgr_psoc *psoc, bool *value);
2622 
2623 /**
2624  * wlan_mlme_set_vht_enable2x2() - Enables/disables VHT Tx/Rx MCS values for 2x2
2625  * @psoc: psoc context
2626  * @value: data to be set
2627  *
2628  * Return: QDF_STATUS
2629  */
2630 QDF_STATUS
2631 wlan_mlme_set_vht_enable2x2(struct wlan_objmgr_psoc *psoc, bool value);
2632 
2633 /**
2634  * wlan_mlme_get_vht_enable_paid() - Enables/disables paid feature
2635  * @psoc: psoc context
2636  * @value: data to be set
2637  *
2638  * Return: QDF_STATUS
2639  */
2640 QDF_STATUS
2641 wlan_mlme_get_vht_enable_paid(struct wlan_objmgr_psoc *psoc, bool *value);
2642 
2643 /**
2644  * wlan_mlme_get_vht_enable_gid() - Enables/disables VHT GID feature
2645  * @psoc: psoc context
2646  * @value: data to be set
2647  *
2648  * Return: QDF_STATUS
2649  */
2650 QDF_STATUS
2651 wlan_mlme_get_vht_enable_gid(struct wlan_objmgr_psoc *psoc, bool *value);
2652 
2653 /**
2654  * wlan_mlme_get_vht_for_24ghz() - Enables/disables VHT for 24 ghz
2655  * @psoc: psoc context
2656  * @value: data to be set
2657  *
2658  * Return: QDF_STATUS
2659  */
2660 QDF_STATUS
2661 wlan_mlme_get_vht_for_24ghz(struct wlan_objmgr_psoc *psoc, bool *value);
2662 
2663 /**
2664  * wlan_mlme_set_vht_for_24ghz() - Enables/disables VHT for 24 ghz
2665  * @psoc: psoc context
2666  * @value: data to be set
2667  *
2668  * Return: QDF_STATUS
2669  */
2670 QDF_STATUS
2671 wlan_mlme_set_vht_for_24ghz(struct wlan_objmgr_psoc *psoc, bool value);
2672 
2673 /**
2674  * wlan_mlme_get_vendor_vht_for_24ghz() - nables/disables vendor VHT for 24 ghz
2675  * @psoc: psoc context
2676  * @value: data to be set
2677  *
2678  * Return: QDF_STATUS
2679  */
2680 QDF_STATUS
2681 wlan_mlme_get_vendor_vht_for_24ghz(struct wlan_objmgr_psoc *psoc, bool *value);
2682 
2683 /**
2684  * mlme_update_vht_cap() - update vht capabilities
2685  * @psoc: psoc context
2686  * @cfg: data to be set
2687  *
2688  * Return: QDF_STATUS
2689  */
2690 QDF_STATUS
2691 mlme_update_vht_cap(struct wlan_objmgr_psoc *psoc, struct wma_tgt_vht_cap *cfg);
2692 
2693 /**
2694  * mlme_update_nss_vht_cap() - Update the number of spatial
2695  * streams supported for vht
2696  * @psoc: psoc context
2697  *
2698  * Return: QDF_STATUS
2699  */
2700 QDF_STATUS mlme_update_nss_vht_cap(struct wlan_objmgr_psoc *psoc);
2701 
2702 #ifdef WLAN_FEATURE_11BE
2703 /**
2704  * mlme_get_bss_11be_allowed() - Check BSS allowed in 11be mode
2705  * @psoc: psoc context
2706  * @bssid: bssid
2707  * @ie_data: ie data
2708  * @ie_length: ie data length
2709  *
2710  * Return: true if AP in 11be oui allow list
2711  */
2712 bool mlme_get_bss_11be_allowed(struct wlan_objmgr_psoc *psoc,
2713 			       struct qdf_mac_addr *bssid,
2714 			       uint8_t *ie_data,
2715 			       uint32_t ie_length);
2716 
2717 /**
2718  * wlan_mlme_get_oem_eht_mlo_config() - Get the OEM EHT configuration.
2719  * @psoc: PSOC object manager.
2720  * @oem_eht_cfg: Pointer to fill OEM cfg
2721  *
2722  * Returns success of retrieving OEM cfg else failure.
2723  *
2724  * Return: QDF_STATUS.
2725  */
2726 QDF_STATUS wlan_mlme_get_oem_eht_mlo_config(struct wlan_objmgr_psoc *psoc,
2727 					    uint32_t *oem_eht_cfg);
2728 #else
2729 static inline
mlme_get_bss_11be_allowed(struct wlan_objmgr_psoc * psoc,struct qdf_mac_addr * bssid,uint8_t * ie_data,uint32_t ie_length)2730 bool mlme_get_bss_11be_allowed(struct wlan_objmgr_psoc *psoc,
2731 			       struct qdf_mac_addr *bssid,
2732 			       uint8_t *ie_data,
2733 			       uint32_t ie_length)
2734 {
2735 	return false;
2736 }
2737 
2738 static inline QDF_STATUS
wlan_mlme_get_oem_eht_mlo_config(struct wlan_objmgr_psoc * psoc,uint32_t * oem_eht_cfg)2739 wlan_mlme_get_oem_eht_mlo_config(struct wlan_objmgr_psoc *psoc,
2740 				 uint32_t *oem_eht_cfg)
2741 {
2742 	*oem_eht_cfg = 0x0;
2743 	return QDF_STATUS_SUCCESS;
2744 }
2745 #endif
2746 
2747 /**
2748  * wlan_mlme_is_sap_uapsd_enabled() - Get if SAP UAPSD is enabled/disabled
2749  * @psoc: psoc context
2750  * @value: value to be filled for caller
2751  *
2752  * Return: QDF_STATUS
2753  */
2754 QDF_STATUS wlan_mlme_is_sap_uapsd_enabled(struct wlan_objmgr_psoc *psoc,
2755 					  bool *value);
2756 
2757 /**
2758  * wlan_mlme_set_sap_uapsd_flag() - Enable/Disable SAP UAPSD
2759  * @psoc:  psoc context
2760  * @value: Enable/Disable control value for sap_uapsd_enabled field
2761  *
2762  * Return: QDF_STATUS
2763  */
2764 QDF_STATUS wlan_mlme_set_sap_uapsd_flag(struct wlan_objmgr_psoc *psoc,
2765 					bool value);
2766 /**
2767  * wlan_mlme_is_11h_enabled() - Get the 11h flag
2768  * @psoc: psoc context
2769  * @value: Enable/Disable value ptr.
2770  *
2771  * Return: QDF_STATUS
2772  */
2773 QDF_STATUS
2774 wlan_mlme_is_11h_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
2775 
2776 /**
2777  * wlan_mlme_set_11h_enabled() - Set the 11h flag
2778  * @psoc: psoc context
2779  * @value: Enable/Disable value
2780  *
2781  * Return: QDF_STATUS
2782  */
2783 QDF_STATUS
2784 wlan_mlme_set_11h_enabled(struct wlan_objmgr_psoc *psoc, bool value);
2785 
2786 /**
2787  * wlan_mlme_is_11d_enabled() - Get the 11d flag
2788  * @psoc: psoc context
2789  * @value: Enable/Disable value ptr.
2790  *
2791  * Return: QDF_STATUS
2792  */
2793 QDF_STATUS
2794 wlan_mlme_is_11d_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
2795 
2796 /**
2797  * wlan_mlme_set_11d_enabled() - Set the 11h flag
2798  * @psoc: psoc context
2799  * @value: Enable/Disable value
2800  *
2801  * Return: QDF_STATUS
2802  */
2803 QDF_STATUS
2804 wlan_mlme_set_11d_enabled(struct wlan_objmgr_psoc *psoc, bool value);
2805 
2806 /**
2807  * wlan_mlme_is_rf_test_mode_enabled() - Get the rf test mode flag
2808  * @psoc: psoc context
2809  * @value: Enable/Disable value ptr.
2810  *
2811  * Return: QDF_STATUS
2812  */
2813 QDF_STATUS
2814 wlan_mlme_is_rf_test_mode_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
2815 
2816 /**
2817  * wlan_mlme_set_rf_test_mode_enabled() - Set the rf test mode flag
2818  * @psoc: psoc context
2819  * @value: Enable/Disable value.
2820  *
2821  * Return: QDF_STATUS
2822  */
2823 QDF_STATUS
2824 wlan_mlme_set_rf_test_mode_enabled(struct wlan_objmgr_psoc *psoc, bool value);
2825 
2826 #ifdef CONFIG_BAND_6GHZ
2827 /**
2828  * wlan_mlme_is_disable_vlp_sta_conn_to_sp_ap_enabled() - Get the disable vlp
2829  *                                                       STA conn to SP AP flag
2830  * @psoc: psoc context
2831  * @value: Enable/Disable value ptr.
2832  *
2833  * Return: QDF_STATUS
2834  */
2835 QDF_STATUS
2836 wlan_mlme_is_disable_vlp_sta_conn_to_sp_ap_enabled(
2837 						struct wlan_objmgr_psoc *psoc,
2838 						bool *value);
2839 
2840 /**
2841  * wlan_mlme_is_standard_6ghz_conn_policy_enabled() - Get the 6 GHz standard
2842  *                                                    connection policy flag
2843  * @psoc: psoc context
2844  * @value: Enable/Disable value ptr.
2845  *
2846  * Return: QDF_STATUS
2847  */
2848 QDF_STATUS
2849 wlan_mlme_is_standard_6ghz_conn_policy_enabled(struct wlan_objmgr_psoc *psoc,
2850 					       bool *value);
2851 
2852 #else
2853 static inline QDF_STATUS
wlan_mlme_is_disable_vlp_sta_conn_to_sp_ap_enabled(struct wlan_objmgr_psoc * psoc,bool * value)2854 wlan_mlme_is_disable_vlp_sta_conn_to_sp_ap_enabled(
2855 						struct wlan_objmgr_psoc *psoc,
2856 						bool *value)
2857 {
2858 	*value = false;
2859 	return QDF_STATUS_SUCCESS;
2860 }
2861 
2862 static inline QDF_STATUS
wlan_mlme_is_standard_6ghz_conn_policy_enabled(struct wlan_objmgr_psoc * psoc,bool * value)2863 wlan_mlme_is_standard_6ghz_conn_policy_enabled(struct wlan_objmgr_psoc *psoc,
2864 					       bool *value)
2865 {
2866 	*value = false;
2867 	return QDF_STATUS_SUCCESS;
2868 }
2869 #endif
2870 
2871 #ifdef WLAN_FEATURE_11BE_MLO
2872 /**
2873  * wlan_mlme_get_eht_mode() - Get the EHT mode of operations
2874  * @psoc: psoc context
2875  * @value: EHT mode value ptr
2876  *
2877  * Return: QDF_STATUS
2878  */
2879 QDF_STATUS
2880 wlan_mlme_get_eht_mode(struct wlan_objmgr_psoc *psoc,
2881 		       enum wlan_eht_mode *value);
2882 
2883 /**
2884  * wlan_mlme_set_eht_mode() - Set the EHT mode of operation
2885  * @psoc: psoc context
2886  * @value: EHT mode value
2887  *
2888  * Return: QDF_STATUS
2889  */
2890 QDF_STATUS
2891 wlan_mlme_set_eht_mode(struct wlan_objmgr_psoc *psoc, enum wlan_eht_mode value);
2892 
2893 /**
2894  * wlan_mlme_get_emlsr_mode_enabled() - Get the eMLSR mode flag
2895  * @psoc: psoc context
2896  * @value: Enable/Disable value ptr.
2897  *
2898  * Return: QDF_STATUS
2899  */
2900 QDF_STATUS
2901 wlan_mlme_get_emlsr_mode_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
2902 
2903 /**
2904  * wlan_mlme_set_emlsr_mode_enabled() - Set the eMLSR mode flag
2905  * @psoc: psoc context
2906  * @value: Enable/Disable value.
2907  *
2908  * Return: QDF_STATUS
2909  */
2910 QDF_STATUS
2911 wlan_mlme_set_emlsr_mode_enabled(struct wlan_objmgr_psoc *psoc, bool value);
2912 
2913 /**
2914  * wlan_mlme_set_eml_params() - Set EML subfields in psoc mlme obj that
2915  * are received from FW
2916  * @psoc: psoc context
2917  * @cap: psoc mac/phy capability ptr
2918  *
2919  * Return: none
2920  */
2921 void
2922 wlan_mlme_set_eml_params(struct wlan_objmgr_psoc *psoc,
2923 			 struct wlan_psoc_host_mac_phy_caps_ext2 *cap);
2924 
2925 /**
2926  * wlan_mlme_get_eml_params() - Get EML subfields from psoc mlme obj
2927  * @psoc: psoc context
2928  * @cap: EML capability subfield ptr
2929  *
2930  * Return: none
2931  */
2932 void
2933 wlan_mlme_get_eml_params(struct wlan_objmgr_psoc *psoc,
2934 			 struct wlan_mlo_eml_cap *cap);
2935 
2936 /**
2937  * wlan_mlme_cfg_set_emlsr_pad_delay() - Configure EMLSR padding delay subfield
2938  * @psoc: psoc context
2939  * @val: EMLSR padding delay subfield value
2940  *
2941  * API to configure EMLSR padding delay subfield in psoc mlme obj with user
2942  * requested value if it greater than the value configured by FW during boot-up.
2943  *
2944  * Return: none
2945  */
2946 void
2947 wlan_mlme_cfg_set_emlsr_pad_delay(struct wlan_objmgr_psoc *psoc, uint8_t val);
2948 
2949 /**
2950  * wlan_mlme_get_t2lm_negotiation_supported() - Get the T2LM
2951  * negotiation supported value
2952  * @psoc: psoc context
2953  *
2954  * Return: t2lm negotiation supported value
2955  */
2956 enum t2lm_negotiation_support
2957 wlan_mlme_get_t2lm_negotiation_supported(struct wlan_objmgr_psoc *psoc);
2958 
2959 /**
2960  * wlan_mlme_set_t2lm_negotiation_supported() - Set the T2LM
2961  * negotiation supported value
2962  * @psoc: psoc context
2963  * @value: t2lm negotiation supported value
2964  *
2965  * Return: qdf status
2966  */
2967 QDF_STATUS
2968 wlan_mlme_set_t2lm_negotiation_supported(struct wlan_objmgr_psoc *psoc,
2969 					 uint8_t value);
2970 
2971 /**
2972  * wlan_mlme_get_eht_mld_id() - Get the MLD ID of the requested BSS
2973  * @psoc: psoc context
2974  *
2975  * Return: MLD ID of the requested BSS
2976  */
2977 uint8_t
2978 wlan_mlme_get_eht_mld_id(struct wlan_objmgr_psoc *psoc);
2979 
2980 /**
2981  * wlan_mlme_set_eht_mld_id() - Set MLD ID of the requested BSS information
2982  * within the ML probe request.
2983  * @psoc: psoc context
2984  * @value: MLD ID
2985  *
2986  * Return: qdf status
2987  */
2988 QDF_STATUS
2989 wlan_mlme_set_eht_mld_id(struct wlan_objmgr_psoc *psoc, uint8_t value);
2990 
2991 /*
2992  * wlan_mlme_get_mlo_prefer_percentage() - get MLO preference percentage
2993  * @psoc: pointer to psoc object
2994  *
2995  * Return: void
2996  */
2997 void
2998 wlan_mlme_get_mlo_prefer_percentage(
2999 				struct wlan_objmgr_psoc *psoc,
3000 				int8_t *mlo_prefer_percentage);
3001 #else
3002 static inline QDF_STATUS
wlan_mlme_get_eht_mode(struct wlan_objmgr_psoc * psoc,enum wlan_eht_mode * value)3003 wlan_mlme_get_eht_mode(struct wlan_objmgr_psoc *psoc, enum wlan_eht_mode *value)
3004 {
3005 	*value = WLAN_EHT_MODE_DISABLED;
3006 	return QDF_STATUS_SUCCESS;
3007 }
3008 
3009 static inline QDF_STATUS
wlan_mlme_set_eht_mode(struct wlan_objmgr_psoc * psoc,enum wlan_eht_mode value)3010 wlan_mlme_set_eht_mode(struct wlan_objmgr_psoc *psoc, enum wlan_eht_mode value)
3011 {
3012 	return QDF_STATUS_SUCCESS;
3013 }
3014 
3015 static inline QDF_STATUS
wlan_mlme_get_emlsr_mode_enabled(struct wlan_objmgr_psoc * psoc,bool * value)3016 wlan_mlme_get_emlsr_mode_enabled(struct wlan_objmgr_psoc *psoc, bool *value)
3017 {
3018 	*value = false;
3019 	return QDF_STATUS_SUCCESS;
3020 }
3021 
3022 static inline QDF_STATUS
wlan_mlme_set_emlsr_mode_enabled(struct wlan_objmgr_psoc * psoc,bool value)3023 wlan_mlme_set_emlsr_mode_enabled(struct wlan_objmgr_psoc *psoc, bool value)
3024 {
3025 	return QDF_STATUS_SUCCESS;
3026 }
3027 
3028 static inline void
wlan_mlme_set_eml_params(struct wlan_objmgr_psoc * psoc,struct wlan_psoc_host_mac_phy_caps_ext2 * cap)3029 wlan_mlme_set_eml_params(struct wlan_objmgr_psoc *psoc,
3030 			 struct wlan_psoc_host_mac_phy_caps_ext2 *cap)
3031 {
3032 }
3033 
3034 static inline void
wlan_mlme_get_eml_params(struct wlan_objmgr_psoc * psoc,struct wlan_mlo_eml_cap * cap)3035 wlan_mlme_get_eml_params(struct wlan_objmgr_psoc *psoc,
3036 			 struct wlan_mlo_eml_cap *cap)
3037 {
3038 }
3039 
3040 static inline void
wlan_mlme_cfg_set_emlsr_pad_delay(struct wlan_objmgr_psoc * psoc,uint8_t val)3041 wlan_mlme_cfg_set_emlsr_pad_delay(struct wlan_objmgr_psoc *psoc, uint8_t val)
3042 {
3043 }
3044 
3045 static inline enum t2lm_negotiation_support
wlan_mlme_get_t2lm_negotiation_supported(struct wlan_objmgr_psoc * psoc)3046 wlan_mlme_get_t2lm_negotiation_supported(struct wlan_objmgr_psoc *psoc)
3047 {
3048 	return T2LM_NEGOTIATION_DISABLED;
3049 }
3050 
3051 static inline QDF_STATUS
wlan_mlme_set_t2lm_negotiation_supported(struct wlan_objmgr_psoc * psoc,uint8_t value)3052 wlan_mlme_set_t2lm_negotiation_supported(struct wlan_objmgr_psoc *psoc,
3053 					 uint8_t value)
3054 {
3055 	return QDF_STATUS_E_NOSUPPORT;
3056 }
3057 
3058 static inline void
wlan_mlme_get_mlo_prefer_percentage(struct wlan_objmgr_psoc * psoc,int8_t * mlo_prefer_percentage)3059 wlan_mlme_get_mlo_prefer_percentage(
3060 				struct wlan_objmgr_psoc *psoc,
3061 				int8_t *mlo_prefer_percentage)
3062 {}
3063 #endif
3064 
3065 /**
3066  * wlan_mlme_set_btm_abridge_flag() - Set BTM abridge flag
3067  * @psoc: psoc context
3068  * @value: abridge flag
3069  *
3070  * Return: qdf status
3071  *
3072  * BTM abridge flag indicates whether to select candidates
3073  * for BTM roam based on score.
3074  */
3075 QDF_STATUS
3076 wlan_mlme_set_btm_abridge_flag(struct wlan_objmgr_psoc *psoc, bool value);
3077 
3078 /**
3079  * wlan_mlme_get_btm_abridge_flag() - Get BTM abridge flag
3080  * @psoc: psoc context
3081  *
3082  * Return: abridge flag
3083  *
3084  * BTM abridge flag indicates whether to select candidates
3085  * for BTM roam based on score.
3086  */
3087 bool
3088 wlan_mlme_get_btm_abridge_flag(struct wlan_objmgr_psoc *psoc);
3089 
3090 /**
3091  * wlan_mlme_get_sta_miracast_mcc_rest_time() - Get STA/MIRACAST MCC rest time
3092  * @psoc: pointer to psoc object
3093  * @value: value which needs to filled by API
3094  *
3095  * This API gives rest time to be used when STA and MIRACAST MCC conc happens
3096  *
3097  * Return: QDF_STATUS
3098  */
3099 QDF_STATUS
3100 wlan_mlme_get_sta_miracast_mcc_rest_time(struct wlan_objmgr_psoc *psoc,
3101 					 uint32_t *value);
3102 
3103 /**
3104  * wlan_mlme_get_max_modulated_dtim_ms() - get the max modulated dtim in ms
3105  * restart
3106  * @psoc: pointer to psoc object
3107  * @value: Value that needs to be set from the caller
3108  *
3109  * Return: QDF Status
3110  */
3111 QDF_STATUS
3112 wlan_mlme_get_max_modulated_dtim_ms(struct wlan_objmgr_psoc *psoc,
3113 				    uint16_t *value);
3114 
3115 /**
3116  * wlan_mlme_get_scan_probe_unicast_ra() - Get scan probe unicast RA cfg
3117  * @psoc: pointer to psoc object
3118  * @value: value which needs to filled by API
3119  *
3120  * This API gives scan probe request with unicast RA user config
3121  *
3122  * Return: QDF_STATUS
3123  */
3124 QDF_STATUS
3125 wlan_mlme_get_scan_probe_unicast_ra(struct wlan_objmgr_psoc *psoc,
3126 				    bool *value);
3127 
3128 /**
3129  * wlan_mlme_set_scan_probe_unicast_ra() - Set scan probe unicast RA cfg
3130  * @psoc: pointer to psoc object
3131  * @value: set value
3132  *
3133  * This API sets scan probe request with unicast RA user config
3134  *
3135  * Return: QDF_STATUS
3136  */
3137 QDF_STATUS
3138 wlan_mlme_set_scan_probe_unicast_ra(struct wlan_objmgr_psoc *psoc,
3139 				    bool value);
3140 
3141 /**
3142  * wlan_mlme_get_sap_mcc_chnl_avoid() - Check if SAP MCC needs to be avoided
3143  * @psoc: pointer to psoc object
3144  * @value: value which needs to filled by API
3145  *
3146  * This API fetches the user setting to determine if SAP MCC with other persona
3147  * to be avoided.
3148  *
3149  * Return: QDF_STATUS
3150  */
3151 QDF_STATUS
3152 wlan_mlme_get_sap_mcc_chnl_avoid(struct wlan_objmgr_psoc *psoc,
3153 				 uint8_t *value);
3154 /**
3155  * wlan_mlme_get_mcc_bcast_prob_resp() - Get broadcast probe rsp in MCC
3156  * @psoc: pointer to psoc object
3157  * @value: value which needs to filled by API
3158  *
3159  * To get INI value which helps to determe whether to enable/disable use of
3160  * broadcast probe response to increase the detectability of SAP in MCC mode.
3161  *
3162  *
3163  * Return: QDF_STATUS
3164  */
3165 QDF_STATUS
3166 wlan_mlme_get_mcc_bcast_prob_resp(struct wlan_objmgr_psoc *psoc,
3167 				  uint8_t *value);
3168 /**
3169  * wlan_mlme_get_mcc_rts_cts_prot() - To get RTS-CTS protection in MCC.
3170  * @psoc: pointer to psoc object
3171  * @value: value which needs to filled by API
3172  *
3173  * To get INI value which helps to determine whether to enable/disable
3174  * use of long duration RTS-CTS protection when SAP goes off
3175  * channel in MCC mode.
3176  *
3177  * Return: QDF_STATUS
3178  */
3179 QDF_STATUS
3180 wlan_mlme_get_mcc_rts_cts_prot(struct wlan_objmgr_psoc *psoc,
3181 			       uint8_t *value);
3182 /**
3183  * wlan_mlme_get_mcc_feature() - To find out to enable/disable MCC feature
3184  * @psoc: pointer to psoc object
3185  * @value: value which needs to filled by API
3186  *
3187  * To get INI value which helps to determine whether to enable MCC feature
3188  *
3189  * Return: QDF_STATUS
3190  */
3191 QDF_STATUS
3192 wlan_mlme_get_mcc_feature(struct wlan_objmgr_psoc *psoc,
3193 			  uint8_t *value);
3194 
3195 /**
3196  * wlan_mlme_get_rrm_enabled() - Get the RRM enabled ini
3197  * @psoc: pointer to psoc object
3198  * @value: pointer to the value which will be filled for the caller
3199  *
3200  * Return: QDF Status
3201  */
3202 QDF_STATUS wlan_mlme_get_rrm_enabled(struct wlan_objmgr_psoc *psoc,
3203 				     bool *value);
3204 
3205 /**
3206  * wlan_mlme_get_dtim_selection_diversity() - get dtim selection diversity
3207  * bitmap
3208  * @psoc: pointer to psoc object
3209  * @dtim_selection_div: value that is requested by the caller
3210  * This function gets the dtim selection diversity bitmap to be
3211  * sent to the firmware
3212  *
3213  * Return: QDF_STATUS_SUCCESS - in case of success
3214  */
3215 QDF_STATUS wlan_mlme_get_dtim_selection_diversity(struct wlan_objmgr_psoc *psoc,
3216 						  uint32_t *dtim_selection_div);
3217 
3218 /**
3219  * wlan_mlme_get_bmps_min_listen_interval() - get beacon mode powersave
3220  * minimum listen interval value
3221  * @psoc: pointer to psoc object
3222  * @value: value that is requested by the caller
3223  *
3224  * Return: QDF_STATUS_SUCCESS - in case of success
3225  */
3226 QDF_STATUS wlan_mlme_get_bmps_min_listen_interval(struct wlan_objmgr_psoc *psoc,
3227 						  uint32_t *value);
3228 
3229 /**
3230  * wlan_mlme_get_bmps_max_listen_interval() - get beacon mode powersave
3231  * maximum listen interval value
3232  * @psoc: pointer to psoc object
3233  * @value: value that is requested by the caller
3234  *
3235  * Return: QDF_STATUS_SUCCESS - in case of success
3236  */
3237 QDF_STATUS wlan_mlme_get_bmps_max_listen_interval(struct wlan_objmgr_psoc *psoc,
3238 						  uint32_t *value);
3239 
3240 /**
3241  * wlan_mlme_get_auto_bmps_timer_value() - get bmps timer value
3242  * @psoc: pointer to psoc object
3243  * @value: value that is requested by the caller
3244  *
3245  * Return: QDF_STATUS_SUCCESS - in case of success
3246  */
3247 QDF_STATUS wlan_mlme_get_auto_bmps_timer_value(struct wlan_objmgr_psoc *psoc,
3248 					       uint32_t *value);
3249 
3250 /**
3251  * wlan_mlme_is_bmps_enabled() - check if beacon mode powersave is
3252  * enabled/disabled
3253  * @psoc: pointer to psoc object
3254  * @value: value that is requested by the caller
3255  *
3256  * Return: QDF_STATUS_SUCCESS - in case of success
3257  */
3258 QDF_STATUS wlan_mlme_is_bmps_enabled(struct wlan_objmgr_psoc *psoc,
3259 				     bool *value);
3260 
3261 /**
3262  * wlan_mlme_override_bmps_imps() - disable imps/bmps
3263  * @psoc: pointer to psoc object
3264  *
3265  * Return: QDF_STATUS_SUCCESS - in case of success
3266  */
3267 QDF_STATUS wlan_mlme_override_bmps_imps(struct wlan_objmgr_psoc *psoc);
3268 
3269 /**
3270  * wlan_mlme_is_imps_enabled() - check if idle mode powersave is
3271  * enabled/disabled
3272  * @psoc: pointer to psoc object
3273  * @value: value that is requested by the caller
3274  *
3275  * Return: QDF_STATUS_SUCCESS - in case of success
3276  */
3277 QDF_STATUS wlan_mlme_is_imps_enabled(struct wlan_objmgr_psoc *psoc,
3278 				     bool *value);
3279 
3280 /**
3281  * wlan_mlme_get_wps_uuid() - get the wps uuid string
3282  * @wps_params:   pointer to mlme wps parameters structure
3283  * @data:          data to which the parameter is to be copied
3284  *
3285  * Return None
3286  *
3287  */
3288 void
3289 wlan_mlme_get_wps_uuid(struct wlan_mlme_wps_params *wps_params, uint8_t *data);
3290 
3291 /**
3292  * wlan_mlme_get_self_gen_frm_pwr() - get self gen frm pwr
3293  * @psoc: pointer to psoc object
3294  * @value:  Pointer to the value which will be filled for the caller
3295  *
3296  * Return: QDF Status
3297  */
3298 QDF_STATUS
3299 wlan_mlme_get_self_gen_frm_pwr(struct wlan_objmgr_psoc *psoc,
3300 			       uint32_t *value);
3301 
3302 /**
3303  * wlan_mlme_get_4way_hs_offload() - get 4-way hs offload to fw cfg
3304  * @psoc: pointer to psoc object
3305  * @value:  Pointer to the value which will be filled for the caller
3306  *
3307  * Return: QDF Status
3308  */
3309 QDF_STATUS
3310 wlan_mlme_get_4way_hs_offload(struct wlan_objmgr_psoc *psoc, uint32_t *value);
3311 
3312 /**
3313  * wlan_mlme_get_bmiss_skip_full_scan_value() - To get value of
3314  * bmiss_skip_full_scan ini
3315  * @psoc: pointer to psoc object
3316  * @value:  Pointer to the value which will be filled for the caller
3317  *
3318  * Return: QDF Status
3319  */
3320 QDF_STATUS
3321 wlan_mlme_get_bmiss_skip_full_scan_value(struct wlan_objmgr_psoc *psoc,
3322 					 bool *value);
3323 
3324 /**
3325  * mlme_get_peer_phymode() - get phymode of peer
3326  * @psoc: pointer to psoc object
3327  * @mac:  Pointer to the mac addr of the peer
3328  * @peer_phymode: phymode
3329  *
3330  * Return: QDF Status
3331  */
3332 QDF_STATUS
3333 mlme_get_peer_phymode(struct wlan_objmgr_psoc *psoc, uint8_t *mac,
3334 		      enum wlan_phymode *peer_phymode);
3335 
3336 /**
3337  * mlme_set_tgt_wpa3_roam_cap() - Set the target WPA3 roam support
3338  * to mlme
3339  * @psoc: pointer to PSOC object
3340  * @akm_bitmap: Bitmap of akm suites supported for roaming by the firmware
3341  *
3342  * Return: QDF Status
3343  */
3344 QDF_STATUS mlme_set_tgt_wpa3_roam_cap(struct wlan_objmgr_psoc *psoc,
3345 				      uint32_t akm_bitmap);
3346 /**
3347  * wlan_mlme_get_ignore_fw_reg_offload_ind() - Get the
3348  * ignore_fw_reg_offload_ind ini
3349  * @psoc: pointer to psoc object
3350  * @disabled: output pointer to hold user config
3351  *
3352  * Return: QDF Status
3353  */
3354 QDF_STATUS
3355 wlan_mlme_get_ignore_fw_reg_offload_ind(struct wlan_objmgr_psoc *psoc,
3356 					bool *disabled);
3357 
3358 /**
3359  * mlme_get_roam_trigger_str() - Get the string for enum
3360  * WMI_ROAM_TRIGGER_REASON_ID reason.
3361  * @roam_scan_trigger: roam scan trigger ID
3362  *
3363  *  Return: Meaningful string from enum WMI_ROAM_TRIGGER_REASON_ID
3364  */
3365 char *mlme_get_roam_trigger_str(uint32_t roam_scan_trigger);
3366 
3367 /**
3368  * mlme_get_roam_status_str() - Get the string for roam status
3369  * @roam_status: roam status coming from fw via
3370  * wmi_roam_scan_info tlv
3371  *
3372  *  Return: Meaningful string for roam status
3373  */
3374 char *mlme_get_roam_status_str(uint32_t roam_status);
3375 
3376 /**
3377  * mlme_get_converted_timestamp() - Return time of the day
3378  * from timestamp
3379  * @timestamp:    Timestamp value in milliseconds
3380  * @time:         Output buffer to fill time into
3381  *
3382  * Return: Time of the day in [HH:MM:SS.uS]
3383  */
3384 void mlme_get_converted_timestamp(uint32_t timestamp, char *time);
3385 
3386 #if defined(WLAN_SAE_SINGLE_PMK) && defined(WLAN_FEATURE_ROAM_OFFLOAD)
3387 /**
3388  * wlan_mlme_set_sae_single_pmk_bss_cap - API to set WPA3 single pmk AP IE
3389  * @psoc: Pointer to psoc object
3390  * @vdev_id: vdev id
3391  * @val: value to be set
3392  *
3393  * Return : None
3394  */
3395 void wlan_mlme_set_sae_single_pmk_bss_cap(struct wlan_objmgr_psoc *psoc,
3396 					  uint8_t vdev_id, bool val);
3397 
3398 /**
3399  * wlan_mlme_update_sae_single_pmk - API to update mlme_pmkid_info
3400  * @vdev: vdev object
3401  * @sae_single_pmk: pointer to sae_single_pmk_info struct
3402  *
3403  * Return : None
3404  */
3405 void
3406 wlan_mlme_update_sae_single_pmk(struct wlan_objmgr_vdev *vdev,
3407 				struct mlme_pmk_info *sae_single_pmk);
3408 
3409 /**
3410  * wlan_mlme_get_sae_single_pmk_info - API to get mlme_pmkid_info
3411  * @vdev: vdev object
3412  * @pmksa: pointer to PMKSA struct
3413  *
3414  * Return : None
3415  */
3416 void
3417 wlan_mlme_get_sae_single_pmk_info(struct wlan_objmgr_vdev *vdev,
3418 				  struct wlan_mlme_sae_single_pmk *pmksa);
3419 
3420 /**
3421  * wlan_mlme_is_sae_single_pmk_enabled() - Get is SAE single pmk feature enabled
3422  * @psoc: Pointer to Global psoc
3423  *
3424  * Return: True if SAE single PMK is enabled
3425  */
3426 bool wlan_mlme_is_sae_single_pmk_enabled(struct wlan_objmgr_psoc *psoc);
3427 
3428 /**
3429  * wlan_mlme_clear_sae_single_pmk_info - API to clear mlme_pmkid_info ap caps
3430  * @vdev: vdev object
3431  * @pmk : pmk info to clear
3432  *
3433  * Return : None
3434  */
3435 void wlan_mlme_clear_sae_single_pmk_info(struct wlan_objmgr_vdev *vdev,
3436 					 struct mlme_pmk_info *pmk);
3437 #else
3438 static inline void
wlan_mlme_set_sae_single_pmk_bss_cap(struct wlan_objmgr_psoc * psoc,uint8_t vdev_id,bool val)3439 wlan_mlme_set_sae_single_pmk_bss_cap(struct wlan_objmgr_psoc *psoc,
3440 				     uint8_t vdev_id, bool val)
3441 {
3442 }
3443 
3444 static inline
wlan_mlme_is_sae_single_pmk_enabled(struct wlan_objmgr_psoc * psoc)3445 bool wlan_mlme_is_sae_single_pmk_enabled(struct wlan_objmgr_psoc *psoc)
3446 {
3447 	return false;
3448 }
3449 
3450 static inline void
wlan_mlme_update_sae_single_pmk(struct wlan_objmgr_vdev * vdev,struct mlme_pmk_info * sae_single_pmk)3451 wlan_mlme_update_sae_single_pmk(struct wlan_objmgr_vdev *vdev,
3452 				struct mlme_pmk_info *sae_single_pmk)
3453 {
3454 }
3455 
3456 static inline void
wlan_mlme_get_sae_single_pmk_info(struct wlan_objmgr_vdev * vdev,struct wlan_mlme_sae_single_pmk * pmksa)3457 wlan_mlme_get_sae_single_pmk_info(struct wlan_objmgr_vdev *vdev,
3458 				  struct wlan_mlme_sae_single_pmk *pmksa)
3459 {
3460 }
3461 
3462 static inline
wlan_mlme_clear_sae_single_pmk_info(struct wlan_objmgr_vdev * vdev,struct mlme_pmk_info * pmk)3463 void wlan_mlme_clear_sae_single_pmk_info(struct wlan_objmgr_vdev *vdev,
3464 					 struct mlme_pmk_info *pmk)
3465 {
3466 }
3467 #endif
3468 
3469 /**
3470  * mlme_get_roam_fail_reason_str() - Get fail string from enum
3471  * WMI_ROAM_FAIL_REASON_ID
3472  * @result:   Roam fail reason
3473  *
3474  * Return: Meaningful string from enum
3475  */
3476 char *mlme_get_roam_fail_reason_str(uint32_t result);
3477 
3478 /**
3479  * mlme_get_sub_reason_str() - Get roam trigger sub reason from enum
3480  * WMI_ROAM_TRIGGER_SUB_REASON_ID
3481  * @sub_reason: Sub reason value
3482  *
3483  * Return: Meaningful string from enum WMI_ROAM_TRIGGER_SUB_REASON_ID
3484  */
3485 char *mlme_get_sub_reason_str(uint32_t sub_reason);
3486 
3487 /**
3488  * wlan_mlme_get_mgmt_max_retry() - Get the
3489  * max mgmt retry
3490  * @psoc: pointer to psoc object
3491  * @max_retry: output pointer to hold user config
3492  *
3493  * Return: QDF Status
3494  */
3495 QDF_STATUS
3496 wlan_mlme_get_mgmt_max_retry(struct wlan_objmgr_psoc *psoc,
3497 			     uint8_t *max_retry);
3498 
3499 /**
3500  * wlan_mlme_get_mgmt_6ghz_rate_support() - Get status of HE rates for
3501  * 6GHz mgmt frames
3502  * @psoc: pointer to psoc object
3503  * @enable_he_mcs0_for_6ghz_mgmt: pointer to check for HE rates support
3504  *
3505  * Return: QDF Status
3506  */
3507 QDF_STATUS
3508 wlan_mlme_get_mgmt_6ghz_rate_support(struct wlan_objmgr_psoc *psoc,
3509 				     bool *enable_he_mcs0_for_6ghz_mgmt);
3510 
3511 /**
3512  * wlan_mlme_get_status_ring_buffer() - Get the
3513  * status of ring buffer
3514  * @psoc: pointer to psoc object
3515  * @enable_ring_buffer: output pointer to point the configured value of
3516  * ring buffer
3517  *
3518  * Return: QDF_STATUS
3519  */
3520 QDF_STATUS
3521 wlan_mlme_get_status_ring_buffer(struct wlan_objmgr_psoc *psoc,
3522 				 bool *enable_ring_buffer);
3523 
3524 /**
3525  * wlan_mlme_get_peer_unmap_conf() - Indicate if peer unmap confirmation
3526  * support is enabled or disabled
3527  * @psoc: pointer to psoc object
3528  *
3529  * Return: true if peer unmap confirmation support is enabled, else false
3530  */
3531 bool wlan_mlme_get_peer_unmap_conf(struct wlan_objmgr_psoc *psoc);
3532 
3533 #ifdef WLAN_FEATURE_ROAM_OFFLOAD
3534 /**
3535  * wlan_mlme_get_roam_reason_vsie_status() - Indicate if roam reason
3536  * vsie is enabled or disabled
3537  * @psoc: pointer to psoc object
3538  * @roam_reason_vsie_enabled: pointer to hold value of roam reason
3539  * vsie
3540  *
3541  * Return: QDF_STATUS
3542  */
3543 QDF_STATUS
3544 wlan_mlme_get_roam_reason_vsie_status(struct wlan_objmgr_psoc *psoc,
3545 				      uint8_t *roam_reason_vsie_enabled);
3546 
3547 /**
3548  * wlan_mlme_set_roam_reason_vsie_status() - Update roam reason vsie status
3549  * @psoc: pointer to psoc object
3550  * @roam_reason_vsie_enabled: value of roam reason vsie
3551  *
3552  * Return: QDF_STATUS
3553  */
3554 QDF_STATUS
3555 wlan_mlme_set_roam_reason_vsie_status(struct wlan_objmgr_psoc *psoc,
3556 				      uint8_t roam_reason_vsie_enabled);
3557 
3558 /**
3559  * wlan_mlme_get_roaming_triggers  - Get the roaming triggers bitmap
3560  * @psoc: Pointer to PSOC object
3561  *
3562  * Return: Roaming triggers value
3563  */
3564 uint32_t wlan_mlme_get_roaming_triggers(struct wlan_objmgr_psoc *psoc);
3565 
3566 /**
3567  * wlan_mlme_set_roaming_triggers() - Set the roaming triggers bitmap
3568  * @psoc: Pointer to PSOC object
3569  * @trigger_bitmap: Roaming triggers bitmap to set
3570  *
3571  * Return: void
3572  */
3573 void wlan_mlme_set_roaming_triggers(struct wlan_objmgr_psoc *psoc,
3574 				    uint32_t trigger_bitmap);
3575 
3576 /**
3577  * wlan_mlme_get_roaming_offload() - Get roaming offload setting
3578  * @psoc: pointer to psoc object
3579  * @val:  Pointer to enable/disable roaming offload
3580  *
3581  * Return: QDF Status
3582  */
3583 QDF_STATUS
3584 wlan_mlme_get_roaming_offload(struct wlan_objmgr_psoc *psoc,
3585 			      bool *val);
3586 
3587 /**
3588  * wlan_mlme_get_enable_disconnect_roam_offload() - Get emergency roaming
3589  * Enable/Disable status during deauth/disassoc
3590  * @psoc: pointer to psoc object
3591  * @val:  Pointer to emergency roaming Enable/Disable status
3592  *        during deauth/disassoc
3593  *
3594  * Return: QDF Status
3595  */
3596 QDF_STATUS
3597 wlan_mlme_get_enable_disconnect_roam_offload(struct wlan_objmgr_psoc *psoc,
3598 					     bool *val);
3599 
3600 /**
3601  * wlan_mlme_get_enable_idle_roam() - Get Enable/Disable idle roaming status
3602  * @psoc: pointer to psoc object
3603  * @val:  Pointer to Enable/Disable idle roaming status
3604  *
3605  * Return: QDF Status
3606  */
3607 QDF_STATUS
3608 wlan_mlme_get_enable_idle_roam(struct wlan_objmgr_psoc *psoc, bool *val);
3609 
3610 /**
3611  * wlan_mlme_get_idle_roam_rssi_delta() - Get idle roam rssi delta
3612  * @psoc: pointer to psoc object
3613  * @val:  Pointer to idle roam rssi delta
3614  *
3615  * Return: QDF Status
3616  */
3617 QDF_STATUS
3618 wlan_mlme_get_idle_roam_rssi_delta(struct wlan_objmgr_psoc *psoc,
3619 				   uint32_t *val);
3620 
3621 /**
3622  * wlan_mlme_get_roam_info_stats_num() - Get roam information statistics number
3623  * @psoc: pointer to psoc object
3624  * @val:  Pointer to roam_info_stats_num
3625  *
3626  * Return: QDF Status
3627  */
3628 QDF_STATUS
3629 wlan_mlme_get_roam_info_stats_num(struct wlan_objmgr_psoc *psoc, uint32_t *val);
3630 
3631 /**
3632  * wlan_mlme_get_idle_roam_inactive_time() - Get idle roam inactive time
3633  * @psoc: pointer to psoc object
3634  * @val:  Pointer to idle roam inactive time
3635  *
3636  * Return: QDF Status
3637  */
3638 QDF_STATUS
3639 wlan_mlme_get_idle_roam_inactive_time(struct wlan_objmgr_psoc *psoc,
3640 				      uint32_t *val);
3641 /**
3642  * wlan_mlme_get_idle_data_packet_count() - Get idle data packet count
3643  * @psoc: pointer to psoc object
3644  * @val:  Pointer to idle data packet count
3645  *
3646  * Return: QDF Status
3647  */
3648 QDF_STATUS
3649 wlan_mlme_get_idle_data_packet_count(struct wlan_objmgr_psoc *psoc,
3650 				     uint32_t *val);
3651 
3652 /**
3653  * wlan_mlme_get_idle_roam_min_rssi() - Get idle roam min rssi
3654  * @psoc: pointer to psoc object
3655  * @val:  Pointer to idle roam min rssi
3656  *
3657  * Return: QDF Status
3658  */
3659 QDF_STATUS
3660 wlan_mlme_get_idle_roam_min_rssi(struct wlan_objmgr_psoc *psoc, uint32_t *val);
3661 
3662 /**
3663  * wlan_mlme_get_idle_roam_band() - Get idle roam band
3664  * @psoc: pointer to psoc object
3665  * @val:  Pointer to idle roam band
3666  *
3667  * Return: QDF Status
3668  */
3669 QDF_STATUS
3670 wlan_mlme_get_idle_roam_band(struct wlan_objmgr_psoc *psoc, uint32_t *val);
3671 
3672 /**
3673  * wlan_mlme_get_self_bss_roam() - Get self bss roam enable status
3674  * @psoc: pointer to psoc object
3675  * @enable_self_bss_roam:  Pointer to self bss roam enable status
3676  *
3677  * Return: QDF Status
3678  */
3679 QDF_STATUS
3680 wlan_mlme_get_self_bss_roam(struct wlan_objmgr_psoc *psoc,
3681 			    uint8_t *enable_self_bss_roam);
3682 #else
3683 static inline QDF_STATUS
wlan_mlme_get_roam_reason_vsie_status(struct wlan_objmgr_psoc * psoc,uint8_t * roam_reason_vsie_enable)3684 wlan_mlme_get_roam_reason_vsie_status(struct wlan_objmgr_psoc *psoc,
3685 				      uint8_t *roam_reason_vsie_enable)
3686 {
3687 	return QDF_STATUS_E_FAILURE;
3688 }
3689 
3690 static inline QDF_STATUS
wlan_mlme_set_roam_reason_vsie_status(struct wlan_objmgr_psoc * psoc,uint8_t roam_reason_vsie_enable)3691 wlan_mlme_set_roam_reason_vsie_status(struct wlan_objmgr_psoc *psoc,
3692 				      uint8_t roam_reason_vsie_enable)
3693 {
3694 	return QDF_STATUS_E_FAILURE;
3695 }
3696 
3697 static inline
wlan_mlme_get_roaming_triggers(struct wlan_objmgr_psoc * psoc)3698 uint32_t wlan_mlme_get_roaming_triggers(struct wlan_objmgr_psoc *psoc)
3699 {
3700 	return 0xFFFF;
3701 }
3702 
3703 static inline
wlan_mlme_set_roaming_triggers(struct wlan_objmgr_psoc * psoc,uint32_t trigger_bitmap)3704 void wlan_mlme_set_roaming_triggers(struct wlan_objmgr_psoc *psoc,
3705 				    uint32_t trigger_bitmap)
3706 {
3707 }
3708 
3709 static inline QDF_STATUS
wlan_mlme_get_roaming_offload(struct wlan_objmgr_psoc * psoc,bool * val)3710 wlan_mlme_get_roaming_offload(struct wlan_objmgr_psoc *psoc,
3711 			      bool *val)
3712 {
3713 	*val = false;
3714 
3715 	return QDF_STATUS_SUCCESS;
3716 }
3717 #endif
3718 
3719 /**
3720  * wlan_mlme_set_peer_indicated_ch_width() - Set peer indicated channel width
3721  * @psoc: pointer to psoc object
3722  * @data: Pointer to peer operating mode change event status
3723  *
3724  * Return: QDF Status
3725  */
3726 QDF_STATUS
3727 wlan_mlme_set_peer_indicated_ch_width(struct wlan_objmgr_psoc *psoc,
3728 				      struct peer_oper_mode_event *data);
3729 
3730 /**
3731  * wlan_mlme_get_peer_indicated_ch_width() - Get peer indicated channel width
3732  * @psoc: pointer to psoc object
3733  * @data: Pointer to peer operating mode change event status
3734  *
3735  * Return: QDF Status
3736  */
3737 QDF_STATUS
3738 wlan_mlme_get_peer_indicated_ch_width(struct wlan_objmgr_psoc *psoc,
3739 				      struct peer_oper_mode_event *data);
3740 
3741 /**
3742  * wlan_mlme_set_ft_over_ds() - Update ft_over_ds
3743  * @psoc: pointer to psoc object
3744  * @ft_over_ds_enable: value of ft_over_ds
3745  *
3746  * Return: QDF_STATUS
3747  */
3748 QDF_STATUS wlan_mlme_set_ft_over_ds(struct wlan_objmgr_psoc *psoc,
3749 				    uint8_t ft_over_ds_enable);
3750 /**
3751  * wlan_mlme_get_dfs_chan_ageout_time() - Get the DFS Channel ageout time
3752  * @psoc: pointer to psoc object
3753  * @dfs_chan_ageout_time: output pointer to hold configured value of DFS
3754  * Channel ageout time
3755  *
3756  * Return: QDF Status
3757  */
3758 QDF_STATUS
3759 wlan_mlme_get_dfs_chan_ageout_time(struct wlan_objmgr_psoc *psoc,
3760 				   uint8_t *dfs_chan_ageout_time);
3761 
3762 #ifdef WLAN_FEATURE_SAE
3763 /**
3764  * wlan_mlme_get_sae_assoc_retry_count() - Get the sae assoc retry count
3765  * @psoc: pointer to psoc object
3766  * @retry_count: assoc retry count
3767  *
3768  * Return: QDF Status
3769  */
3770 QDF_STATUS
3771 wlan_mlme_get_sae_assoc_retry_count(struct wlan_objmgr_psoc *psoc,
3772 				    uint8_t *retry_count);
3773 /**
3774  * wlan_mlme_get_sae_auth_retry_count() - Get the sae auth retry count
3775  * @psoc: pointer to psoc object
3776  * @retry_count: auth retry count
3777  *
3778  * Return: QDF Status
3779  */
3780 QDF_STATUS
3781 wlan_mlme_get_sae_auth_retry_count(struct wlan_objmgr_psoc *psoc,
3782 				   uint8_t *retry_count);
3783 
3784 /**
3785  * wlan_mlme_get_sae_roam_auth_retry_count() - Get the sae roam auth retry count
3786  * @psoc: pointer to psoc object
3787  * @retry_count: auth retry count
3788  *
3789  * Return: QDF Status
3790  */
3791 QDF_STATUS
3792 wlan_mlme_get_sae_roam_auth_retry_count(struct wlan_objmgr_psoc *psoc,
3793 					uint8_t *retry_count);
3794 
3795 #else
3796 static inline QDF_STATUS
wlan_mlme_get_sae_assoc_retry_count(struct wlan_objmgr_psoc * psoc,uint8_t * retry_count)3797 wlan_mlme_get_sae_assoc_retry_count(struct wlan_objmgr_psoc *psoc,
3798 				    uint8_t *retry_count)
3799 {
3800 	*retry_count = 0;
3801 	return QDF_STATUS_SUCCESS;
3802 }
3803 
3804 static inline QDF_STATUS
wlan_mlme_get_sae_auth_retry_count(struct wlan_objmgr_psoc * psoc,uint8_t * retry_count)3805 wlan_mlme_get_sae_auth_retry_count(struct wlan_objmgr_psoc *psoc,
3806 				    uint8_t *retry_count)
3807 {
3808 	*retry_count = 0;
3809 	return QDF_STATUS_SUCCESS;
3810 }
3811 
3812 static inline QDF_STATUS
wlan_mlme_get_sae_roam_auth_retry_count(struct wlan_objmgr_psoc * psoc,uint8_t * retry_count)3813 wlan_mlme_get_sae_roam_auth_retry_count(struct wlan_objmgr_psoc *psoc,
3814 					uint8_t *retry_count)
3815 {
3816 	*retry_count = 0;
3817 	return QDF_STATUS_SUCCESS;
3818 }
3819 #endif
3820 
3821 #ifdef WLAN_FEATURE_ROAM_OFFLOAD
3822 /**
3823  * wlan_mlme_get_dual_sta_roaming_enabled  - API to get if the dual sta
3824  * roaming support is enabled.
3825  * @psoc: Pointer to global psoc object
3826  *
3827  * Return: True if dual sta roaming feature is enabled else return false
3828  */
3829 bool
3830 wlan_mlme_get_dual_sta_roaming_enabled(struct wlan_objmgr_psoc *psoc);
3831 #else
3832 static inline bool
wlan_mlme_get_dual_sta_roaming_enabled(struct wlan_objmgr_psoc * psoc)3833 wlan_mlme_get_dual_sta_roaming_enabled(struct wlan_objmgr_psoc *psoc)
3834 {
3835 	return false;
3836 }
3837 #endif
3838 
3839 /**
3840  * mlme_store_fw_scan_channels - Update the valid channel list to mlme.
3841  * @psoc: Pointer to global psoc object
3842  * @chan_list: Source channel list pointer
3843  *
3844  * Currently the channel list is saved to wma_handle to be updated in the
3845  * PCL command. This cannot be accessed at target_if while sending vdev
3846  * set pcl command. So save the channel list to mlme.
3847  *
3848  * Return: QDF_STATUS
3849  */
3850 QDF_STATUS
3851 mlme_store_fw_scan_channels(struct wlan_objmgr_psoc *psoc,
3852 			    tSirUpdateChanList *chan_list);
3853 
3854 /**
3855  * mlme_get_fw_scan_channels  - Copy the saved valid channel
3856  * list to the provided buffer
3857  * @psoc: Pointer to global psoc object
3858  * @freq_list: Pointer to the frequency list buffer to be filled
3859  * @saved_num_chan: Number of channels filled
3860  *
3861  * Return: QDF_STATUS
3862  */
3863 QDF_STATUS mlme_get_fw_scan_channels(struct wlan_objmgr_psoc *psoc,
3864 				     uint32_t *freq_list,
3865 				     uint8_t *saved_num_chan);
3866 /**
3867  * wlan_mlme_get_roam_scan_offload_enabled() - Roam scan offload enable or not
3868  * @psoc: pointer to psoc object
3869  * @val:  Pointer to the value which will be filled for the caller
3870  *
3871  * Return: QDF Status
3872  */
3873 QDF_STATUS
3874 wlan_mlme_get_roam_scan_offload_enabled(struct wlan_objmgr_psoc *psoc,
3875 					bool *val);
3876 
3877 /**
3878  * wlan_mlme_get_roam_bmiss_final_bcnt() - Get roam bmiss final count
3879  * @psoc: pointer to psoc object
3880  * @val:  Pointer to the value which will be filled for the caller
3881  *
3882  * Return: QDF Status
3883  */
3884 QDF_STATUS
3885 wlan_mlme_get_roam_bmiss_final_bcnt(struct wlan_objmgr_psoc *psoc,
3886 				    uint8_t *val);
3887 
3888 /**
3889  * wlan_mlme_get_roam_bmiss_first_bcnt() - Get roam bmiss first count
3890  * @psoc: pointer to psoc object
3891  * @val:  Pointer to the value which will be filled for the caller
3892  *
3893  * Return: QDF Status
3894  */
3895 QDF_STATUS
3896 wlan_mlme_get_roam_bmiss_first_bcnt(struct wlan_objmgr_psoc *psoc,
3897 				    uint8_t *val);
3898 
3899 /**
3900  * wlan_mlme_get_bmiss_timeout_on_wakeup() - Get bmiss timeout
3901  * @psoc: pointer to psoc object
3902  * @val:  Pointer to the value which will be filled for the caller
3903  *
3904  * Return: QDF Status
3905  */
3906 QDF_STATUS
3907 wlan_mlme_get_bmiss_timeout_on_wakeup(struct wlan_objmgr_psoc *psoc,
3908 				      uint8_t *val);
3909 
3910 /**
3911  * wlan_mlme_get_bmiss_timeout_on_sleep() - Get roam conbmiss timeout
3912  * @psoc: pointer to psoc object
3913  * @val:  Pointer to the value which will be filled for the caller
3914  *
3915  * Return: QDF Status
3916  */
3917 QDF_STATUS
3918 wlan_mlme_get_bmiss_timeout_on_sleep(struct wlan_objmgr_psoc *psoc,
3919 				     uint8_t *val);
3920 
3921 /**
3922  * wlan_mlme_adaptive_11r_enabled() - check if adaptive 11r feature is enaled
3923  * or not
3924  * @psoc: pointer to psoc object
3925  *
3926  * Return: bool
3927  */
3928 #ifdef WLAN_ADAPTIVE_11R
3929 bool wlan_mlme_adaptive_11r_enabled(struct wlan_objmgr_psoc *psoc);
3930 #else
wlan_mlme_adaptive_11r_enabled(struct wlan_objmgr_psoc * psoc)3931 static inline bool wlan_mlme_adaptive_11r_enabled(struct wlan_objmgr_psoc *psoc)
3932 {
3933 	return false;
3934 }
3935 #endif
3936 
3937 /**
3938  * wlan_mlme_get_mawc_enabled() - Get mawc enabled status
3939  * @psoc: pointer to psoc object
3940  * @val:  Pointer to the value which will be filled for the caller
3941  *
3942  * Return: QDF Status
3943  */
3944 QDF_STATUS
3945 wlan_mlme_get_mawc_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
3946 
3947 /**
3948  * wlan_mlme_get_mawc_roam_enabled() - Get mawc roam enabled status
3949  * @psoc: pointer to psoc object
3950  * @val:  Pointer to the value which will be filled for the caller
3951  *
3952  * Return: QDF Status
3953  */
3954 QDF_STATUS
3955 wlan_mlme_get_mawc_roam_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
3956 
3957 /**
3958  * wlan_mlme_get_mawc_roam_traffic_threshold() - Get mawc traffic threshold
3959  * @psoc: pointer to psoc object
3960  * @val:  Pointer to the value which will be filled for the caller
3961  *
3962  * Return: QDF Status
3963  */
3964 QDF_STATUS
3965 wlan_mlme_get_mawc_roam_traffic_threshold(struct wlan_objmgr_psoc *psoc,
3966 					  uint32_t *val);
3967 
3968 /**
3969  * wlan_mlme_get_mawc_roam_ap_rssi_threshold() - Get AP RSSI threshold for
3970  * MAWC roaming
3971  * @psoc: pointer to psoc object
3972  * @val:  Pointer to the value which will be filled for the caller
3973  *
3974  * Return: QDF Status
3975  */
3976 QDF_STATUS
3977 wlan_mlme_get_mawc_roam_ap_rssi_threshold(struct wlan_objmgr_psoc *psoc,
3978 					  uint32_t *val);
3979 
3980 /**
3981  * wlan_mlme_get_mawc_roam_rssi_high_adjust() - Get high adjustment value
3982  * for suppressing scan
3983  * @psoc: pointer to psoc object
3984  * @val:  Pointer to the value which will be filled for the caller
3985  *
3986  * Return: QDF Status
3987  */
3988 QDF_STATUS
3989 wlan_mlme_get_mawc_roam_rssi_high_adjust(struct wlan_objmgr_psoc *psoc,
3990 					 uint8_t *val);
3991 
3992 /**
3993  * wlan_mlme_get_mawc_roam_rssi_low_adjust() - Get low adjustment value
3994  * for suppressing scan
3995  * @psoc: pointer to psoc object
3996  * @val:  Pointer to the value which will be filled for the caller
3997  *
3998  * Return: QDF Status
3999  */
4000 QDF_STATUS
4001 wlan_mlme_get_mawc_roam_rssi_low_adjust(struct wlan_objmgr_psoc *psoc,
4002 					uint8_t *val);
4003 
4004 /**
4005  * wlan_mlme_get_bss_load_enabled() - Get bss load based roam trigger
4006  * enabled status
4007  * @psoc: pointer to psoc object
4008  * @val:  Pointer to the value which will be filled for the caller
4009  *
4010  * Return: QDF Status
4011  */
4012 QDF_STATUS
4013 wlan_mlme_get_bss_load_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
4014 
4015 /**
4016  * wlan_mlme_get_bss_load_threshold() - Get bss load threshold
4017  * @psoc: pointer to psoc object
4018  * @val:  Pointer to the value which will be filled for the caller
4019  *
4020  * Return: QDF Status
4021  */
4022 QDF_STATUS
4023 wlan_mlme_get_bss_load_threshold(struct wlan_objmgr_psoc *psoc, uint32_t *val);
4024 
4025 /**
4026  * wlan_mlme_get_bss_load_sample_time() - Get bss load sample time
4027  * @psoc: pointer to psoc object
4028  * @val:  Pointer to the value which will be filled for the caller
4029  *
4030  * Return: QDF Status
4031  */
4032 QDF_STATUS
4033 wlan_mlme_get_bss_load_sample_time(struct wlan_objmgr_psoc *psoc,
4034 				   uint32_t *val);
4035 
4036 /**
4037  * wlan_mlme_get_bss_load_rssi_threshold_6ghz() - Get bss load RSSI
4038  * threshold on 6G
4039  * @psoc: pointer to psoc object
4040  * @val:  Pointer to the value which will be filled for the caller
4041  *
4042  * Return: QDF Status
4043  */
4044 QDF_STATUS
4045 wlan_mlme_get_bss_load_rssi_threshold_6ghz(struct wlan_objmgr_psoc *psoc,
4046 					   int32_t *val);
4047 
4048 /**
4049  * wlan_mlme_get_bss_load_rssi_threshold_5ghz() - Get bss load RSSI
4050  * threshold on 5G
4051  * @psoc: pointer to psoc object
4052  * @val:  Pointer to the value which will be filled for the caller
4053  *
4054  * Return: QDF Status
4055  */
4056 QDF_STATUS
4057 wlan_mlme_get_bss_load_rssi_threshold_5ghz(struct wlan_objmgr_psoc *psoc,
4058 					   int32_t *val);
4059 
4060 /**
4061  * wlan_mlme_get_bss_load_rssi_threshold_24ghz() - Get bss load RSSI
4062  * threshold on 2.4G
4063  * @psoc: pointer to psoc object
4064  * @val:  Pointer to the value which will be filled for the caller
4065  *
4066  * Return: QDF Status
4067  */
4068 QDF_STATUS
4069 wlan_mlme_get_bss_load_rssi_threshold_24ghz(struct wlan_objmgr_psoc *psoc,
4070 					    int32_t *val);
4071 /**
4072  * wlan_mlme_check_chan_param_has_dfs() - Get dfs flag based on
4073  * channel & channel parameters
4074  * @pdev: pdev object
4075  * @ch_params: channel parameters
4076  * @chan_freq: channel frequency in MHz
4077  *
4078  * Return: True for dfs
4079  */
4080 bool
4081 wlan_mlme_check_chan_param_has_dfs(struct wlan_objmgr_pdev *pdev,
4082 				   struct ch_params *ch_params,
4083 				   uint32_t chan_freq);
4084 
4085 /**
4086  * wlan_mlme_set_usr_disabled_roaming() - Set user config for roaming disable
4087  * @psoc: pointer to psoc object
4088  * @val: user config for roaming disable
4089  *
4090  * Return: QDF_STATUS
4091  */
4092 QDF_STATUS
4093 wlan_mlme_set_usr_disabled_roaming(struct wlan_objmgr_psoc *psoc, bool val);
4094 
4095 /**
4096  * wlan_mlme_get_usr_disabled_roaming() - Get user config for roaming disable
4097  * @psoc: pointer to psoc object
4098  * @val: user config for roaming disable
4099  *
4100  * Return: QDF_STATUS
4101  */
4102 QDF_STATUS
4103 wlan_mlme_get_usr_disabled_roaming(struct wlan_objmgr_psoc *psoc, bool *val);
4104 
4105 /**
4106  * mlme_get_opr_rate() - get operational rate
4107  * @vdev: vdev pointer
4108  * @dst: buffer to get rates set
4109  * @len: length of the buffer
4110  *
4111  * Return: length of the rates set
4112  */
4113 qdf_size_t mlme_get_opr_rate(struct wlan_objmgr_vdev *vdev, uint8_t *dst,
4114 			     qdf_size_t len);
4115 
4116 /**
4117  * mlme_set_opr_rate() - set operational rate
4118  * @vdev: vdev pointer
4119  * @src: pointer to set operational rate
4120  * @len: length of operational rate
4121  *
4122  * Return: QDF_SUCCESS if success
4123  */
4124 QDF_STATUS mlme_set_opr_rate(struct wlan_objmgr_vdev *vdev, uint8_t *src,
4125 			     qdf_size_t len);
4126 
4127 /**
4128  * mlme_get_ext_opr_rate() - get extended operational rate
4129  * @vdev: vdev pointer
4130  * @dst: buffer to get rates set
4131  * @len: length of the buffer
4132  *
4133  * Return: length of the rates set
4134  */
4135 qdf_size_t mlme_get_ext_opr_rate(struct wlan_objmgr_vdev *vdev, uint8_t *dst,
4136 				 qdf_size_t len);
4137 
4138 /**
4139  * mlme_set_ext_opr_rate() - set extended operational rate
4140  * @vdev: vdev pointer
4141  * @src: pointer to set extended operational rate
4142  * @len: length of extended operational rate
4143  *
4144  * Return: QDF_SUCCESS if success
4145  */
4146 QDF_STATUS mlme_set_ext_opr_rate(struct wlan_objmgr_vdev *vdev, uint8_t *src,
4147 				 qdf_size_t len);
4148 
4149 /**
4150  * mlme_clear_ext_opr_rate() - clear extended operational rate
4151  * @vdev: vdev pointer
4152  *
4153  * Return: QDF_SUCCESS if success
4154  */
4155 QDF_STATUS mlme_clear_ext_opr_rate(struct wlan_objmgr_vdev *vdev);
4156 
4157 /**
4158  * mlme_get_mcs_rate() - get MCS based rate
4159  * @vdev: vdev pointer
4160  * @dst: buffer to get rates set
4161  * @len: length of the buffer
4162  *
4163  * Return: length of the rates set
4164  */
4165 qdf_size_t mlme_get_mcs_rate(struct wlan_objmgr_vdev *vdev, uint8_t *dst,
4166 			     qdf_size_t len);
4167 
4168 /**
4169  * mlme_set_mcs_rate() - set MCS based rate
4170  * @vdev: vdev pointer
4171  * @src: pointer to set MCS based rate
4172  * @len: length of MCS based rate
4173  *
4174  * Return: QDF_SUCCESS if success
4175  */
4176 QDF_STATUS mlme_set_mcs_rate(struct wlan_objmgr_vdev *vdev, uint8_t *src,
4177 			     qdf_size_t len);
4178 
4179 /**
4180  * mlme_clear_mcs_rate() - clear MCS based rate
4181  * @vdev: vdev pointer
4182  *
4183  * Return: QDF_SUCCESS if success
4184  */
4185 QDF_STATUS mlme_clear_mcs_rate(struct wlan_objmgr_vdev *vdev);
4186 
4187 /**
4188  * wlan_mlme_is_sta_mon_conc_supported() - Check if STA + Monitor mode
4189  * concurrency is supported
4190  * @psoc: pointer to psoc object
4191  *
4192  * Return: True if supported
4193  */
4194 bool wlan_mlme_is_sta_mon_conc_supported(struct wlan_objmgr_psoc *psoc);
4195 
4196 /**
4197  * wlan_mlme_get_phy_max_freq_range() - Get phy supported max channel
4198  * frequency range
4199  * @psoc: psoc for country information
4200  * @low_2ghz_chan: 2.4 GHz low channel frequency
4201  * @high_2ghz_chan: 2.4 GHz high channel frequency
4202  * @low_5ghz_chan: 5 GHz low channel frequency
4203  * @high_5ghz_chan: 5 GHz high channel frequency
4204  *
4205  * Return: QDF status
4206  */
4207 QDF_STATUS wlan_mlme_get_phy_max_freq_range(struct wlan_objmgr_psoc *psoc,
4208 					    uint32_t *low_2ghz_chan,
4209 					    uint32_t *high_2ghz_chan,
4210 					    uint32_t *low_5ghz_chan,
4211 					    uint32_t *high_5ghz_chan);
4212 
4213 /**
4214  * wlan_mlme_is_multipass_sap() -Get multipass sap support
4215  * @psoc: psoc pointer
4216  *
4217  * Return: True, if FW support multipass support.
4218  */
4219 bool wlan_mlme_is_multipass_sap(struct wlan_objmgr_psoc *psoc);
4220 
4221 #ifdef FEATURE_WDS
4222 /**
4223  * wlan_mlme_get_wds_mode() - Check wds mode supported
4224  * @psoc: pointer to psoc object
4225  *
4226  * Return: supported wds mode
4227  */
4228 enum wlan_wds_mode
4229 wlan_mlme_get_wds_mode(struct wlan_objmgr_psoc *psoc);
4230 
4231 /**
4232  * wlan_mlme_set_wds_mode() - Set wds mode
4233  * @psoc: pointer to psoc object
4234  * @mode: wds mode to set
4235  *
4236  * Return: void
4237  */
4238 void wlan_mlme_set_wds_mode(struct wlan_objmgr_psoc *psoc,
4239 			    enum wlan_wds_mode mode);
4240 #else
4241 static inline enum wlan_wds_mode
wlan_mlme_get_wds_mode(struct wlan_objmgr_psoc * psoc)4242 wlan_mlme_get_wds_mode(struct wlan_objmgr_psoc *psoc)
4243 {
4244 	return WLAN_WDS_MODE_DISABLED;
4245 }
4246 
wlan_mlme_set_wds_mode(struct wlan_objmgr_psoc * psoc,enum wlan_wds_mode mode)4247 static inline void wlan_mlme_set_wds_mode(struct wlan_objmgr_psoc *psoc,
4248 					  enum wlan_wds_mode mode)
4249 {
4250 }
4251 #endif
4252 
4253 #ifdef WLAN_SUPPORT_TWT
4254 /**
4255  * mlme_is_twt_enabled() - Get if TWT is enabled via ini.
4256  * @psoc: pointer to psoc object
4257  *
4258  * Return: True if TWT is enabled else false.
4259  */
4260 bool
4261 mlme_is_twt_enabled(struct wlan_objmgr_psoc *psoc);
4262 #else
4263 static inline bool
mlme_is_twt_enabled(struct wlan_objmgr_psoc * psoc)4264 mlme_is_twt_enabled(struct wlan_objmgr_psoc *psoc)
4265 {
4266 	return false;
4267 }
4268 #endif /* WLAN_SUPPORT_TWT */
4269 
4270 /**
4271  * wlan_mlme_skip_tpe() - Get preference to not consider TPE in 2G/5G case
4272  *
4273  * @psoc: pointer to psoc object
4274  *
4275  * Return: True if host should not consider TPE IE in TX power calculation when
4276  * operating in 2G/5G bands, false if host should always consider TPE IE values
4277  */
4278 bool wlan_mlme_skip_tpe(struct wlan_objmgr_psoc *psoc);
4279 
4280 /**
4281  * wlan_mlme_is_data_stall_recovery_fw_supported() - Check if data stall
4282  * recovery is supported by fw
4283  * @psoc: pointer to psoc object
4284  *
4285  * Return: True if supported
4286  */
4287 bool
4288 wlan_mlme_is_data_stall_recovery_fw_supported(struct wlan_objmgr_psoc *psoc);
4289 
4290 /**
4291  * mlme_cfg_get_orig_eht_caps() - Get the original EHT capability info
4292  * @psoc: pointer to psoc object
4293  * @eht_cap: Caps that needs to be filled.
4294  *
4295  * Return: QDF Status
4296  */
4297 QDF_STATUS mlme_cfg_get_orig_eht_caps(struct wlan_objmgr_psoc *psoc,
4298 				      tDot11fIEeht_cap *eht_cap);
4299 
4300 /**
4301  * mlme_cfg_get_eht_caps() - Get the EHT capability info
4302  * @psoc: pointer to psoc object
4303  * @eht_cap: Caps that needs to be filled.
4304  *
4305  * Return: QDF Status
4306  */
4307 QDF_STATUS mlme_cfg_get_eht_caps(struct wlan_objmgr_psoc *psoc,
4308 				 tDot11fIEeht_cap *eht_cap);
4309 
4310 /**
4311  * wlan_mlme_set_bt_profile_con() - Set bluetooth connection profile
4312  * @psoc: pointer to psoc object
4313  * @bt_profile_con: Bluetooth connection profile bit
4314  *
4315  * Return: None
4316  */
4317 void
4318 wlan_mlme_set_bt_profile_con(struct wlan_objmgr_psoc *psoc,
4319 			     bool bt_profile_con);
4320 
4321 /**
4322  * wlan_mlme_get_bt_profile_con() - Get Bluetooth connection profile
4323  * @psoc: pointer to psoc object
4324  *
4325  * Return: Bluetooth connection profile
4326  */
4327 bool
4328 wlan_mlme_get_bt_profile_con(struct wlan_objmgr_psoc *psoc);
4329 
4330 #ifdef WLAN_FEATURE_11BE_MLO
4331 /**
4332  * wlan_mlme_get_sta_mlo_conn_max_num() - get max number of links that sta mlo
4333  *                                        connection can support
4334  * @psoc: pointer to psoc object
4335  *
4336  * Return: max number of links that sta mlo connection can support
4337  */
4338 uint8_t wlan_mlme_get_sta_mlo_conn_max_num(struct wlan_objmgr_psoc *psoc);
4339 
4340 /**
4341  * wlan_mlme_is_5gl_5gh_mlsr_supported() - check 5GH_5GL MLSR supported
4342  * @psoc: pointer to psoc object
4343  *
4344  * Return: true if 5GH_5GL MLSR supported otherwise false
4345  */
4346 bool wlan_mlme_is_5gl_5gh_mlsr_supported(struct wlan_objmgr_psoc *psoc);
4347 
4348 /**
4349  * wlan_mlme_set_sta_mlo_conn_max_num() - set max number of links that sta mlo
4350  *                                        connection can support
4351  * @psoc: pointer to psoc object
4352  * @value: value to set
4353  *
4354  * Return: QDF Status
4355  */
4356 QDF_STATUS wlan_mlme_set_sta_mlo_conn_max_num(struct wlan_objmgr_psoc *psoc,
4357 					      uint8_t value);
4358 
4359 /**
4360  * wlan_mlme_set_user_set_link_num() - set number of links that config by user
4361  * @psoc: pointer to psoc object
4362  * @value: value to set
4363  *
4364  * Return: QDF Status
4365  */
4366 QDF_STATUS wlan_mlme_set_user_set_link_num(struct wlan_objmgr_psoc *psoc,
4367 					   uint8_t value);
4368 
4369 /**
4370  * wlan_mlme_set_ml_link_control_mode() - set ml_link_control_mode
4371  * @psoc: pointer to psoc object
4372  * @vdev_id: vdev id
4373  * @value: value to set
4374  *
4375  * API get call when host receives vendor command
4376  * QCA_NL80211_VENDOR_SUBCMD_MLO_LINK_STATE to configure link control mode.
4377  *
4378  * Return: none
4379  */
4380 void wlan_mlme_set_ml_link_control_mode(struct wlan_objmgr_psoc *psoc,
4381 					uint8_t vdev_id, uint8_t value);
4382 
4383 /**
4384  * wlan_mlme_get_ml_link_control_mode() - get ml_link_control_mode
4385  * @psoc: pointer to psoc object
4386  * @vdev_id: vdev id
4387  *
4388  * Return: value of ml_link_control_mode in success
4389  */
4390 uint8_t wlan_mlme_get_ml_link_control_mode(struct wlan_objmgr_psoc *psoc,
4391 					   uint8_t vdev_id);
4392 
4393 /**
4394  * wlan_mlme_restore_user_set_link_num() - restore link num when SSR happens
4395  * @psoc: pointer to psoc object
4396  *
4397  * Return: void
4398  */
4399 void wlan_mlme_restore_user_set_link_num(struct wlan_objmgr_psoc *psoc);
4400 
4401 /**
4402  * wlan_mlme_clear_user_set_link_num() - clear user set link num
4403  * @psoc: pointer to psoc object
4404  *
4405  * Return: void
4406  */
4407 void wlan_mlme_clear_user_set_link_num(struct wlan_objmgr_psoc *psoc);
4408 
4409 /**
4410  * wlan_mlme_get_sta_mlo_conn_band_bmp() - get band bitmap that sta mlo
4411  *                                         connection can support
4412  * @psoc: pointer to psoc object
4413  *
4414  * Return: band bitmap that sta mlo connection can support
4415  */
4416 uint8_t wlan_mlme_get_sta_mlo_conn_band_bmp(struct wlan_objmgr_psoc *psoc);
4417 
4418 /**
4419  * wlan_mlme_set_sta_mlo_simultaneous_links() - set mlo simultaneous links
4420  * @psoc: pointer to psoc object
4421  * @value: value to set
4422  *
4423  * Return: QDF Status
4424  */
4425 QDF_STATUS
4426 wlan_mlme_set_sta_mlo_simultaneous_links(struct wlan_objmgr_psoc *psoc,
4427 					 uint8_t value);
4428 
4429 /**
4430  * wlan_mlme_get_sta_mlo_simultaneous_links() - get mlo simultaneous links
4431  * @psoc: pointer to psoc object
4432  *
4433  * Return: number of links
4434  */
4435 uint8_t wlan_mlme_get_sta_mlo_simultaneous_links(struct wlan_objmgr_psoc *psoc);
4436 
4437 /**
4438  * wlan_mlme_set_sta_mlo_conn_band_bmp() - set band bitmap that sta mlo
4439  *                                         connection can support
4440  * @psoc: pointer to psoc object
4441  * @value: value to set
4442  *
4443  * Return: QDF Status
4444  */
4445 QDF_STATUS wlan_mlme_set_sta_mlo_conn_band_bmp(struct wlan_objmgr_psoc *psoc,
4446 					       uint8_t value);
4447 
4448 /**
4449  * wlan_mlme_get_sta_same_link_mld_addr() - check if mld/link use same address
4450  * @psoc: pointer to psoc object
4451  *
4452  * Return: bool to check if the mld/link use same mac address
4453  */
4454 bool wlan_mlme_get_sta_same_link_mld_addr(struct wlan_objmgr_psoc *psoc);
4455 #else
4456 static inline
wlan_mlme_set_ml_link_control_mode(struct wlan_objmgr_psoc * psoc,uint8_t vdev_id,uint8_t value)4457 void wlan_mlme_set_ml_link_control_mode(struct wlan_objmgr_psoc *psoc,
4458 					uint8_t vdev_id, uint8_t value)
4459 {
4460 }
4461 
4462 static inline
wlan_mlme_get_ml_link_control_mode(struct wlan_objmgr_psoc * psoc,uint8_t vdev_id)4463 uint8_t wlan_mlme_get_ml_link_control_mode(struct wlan_objmgr_psoc *psoc,
4464 					   uint8_t vdev_id)
4465 {
4466 	return 0;
4467 }
4468 
4469 static inline QDF_STATUS
wlan_mlme_set_user_set_link_num(struct wlan_objmgr_psoc * psoc,uint8_t value)4470 wlan_mlme_set_user_set_link_num(struct wlan_objmgr_psoc *psoc,
4471 				uint8_t value)
4472 {
4473 	return QDF_STATUS_SUCCESS;
4474 }
4475 
4476 static inline
wlan_mlme_restore_user_set_link_num(struct wlan_objmgr_psoc * psoc)4477 void wlan_mlme_restore_user_set_link_num(struct wlan_objmgr_psoc *psoc)
4478 {
4479 }
4480 
4481 static inline
wlan_mlme_clear_user_set_link_num(struct wlan_objmgr_psoc * psoc)4482 void wlan_mlme_clear_user_set_link_num(struct wlan_objmgr_psoc *psoc)
4483 {
4484 }
4485 
4486 static inline QDF_STATUS
wlan_mlme_set_sta_mlo_conn_max_num(struct wlan_objmgr_psoc * psoc,uint8_t value)4487 wlan_mlme_set_sta_mlo_conn_max_num(struct wlan_objmgr_psoc *psoc,
4488 				   uint8_t value)
4489 {
4490 	return QDF_STATUS_SUCCESS;
4491 }
4492 
4493 static inline uint8_t
wlan_mlme_get_sta_mlo_conn_max_num(struct wlan_objmgr_psoc * psoc)4494 wlan_mlme_get_sta_mlo_conn_max_num(struct wlan_objmgr_psoc *psoc)
4495 {
4496 	return 0;
4497 }
4498 
4499 static inline bool
wlan_mlme_is_5gl_5gh_mlsr_supported(struct wlan_objmgr_psoc * psoc)4500 wlan_mlme_is_5gl_5gh_mlsr_supported(struct wlan_objmgr_psoc *psoc)
4501 {
4502 	return 0;
4503 }
4504 
4505 static inline QDF_STATUS
wlan_mlme_set_sta_mlo_simultaneous_links(struct wlan_objmgr_psoc * psoc,uint8_t value)4506 wlan_mlme_set_sta_mlo_simultaneous_links(struct wlan_objmgr_psoc *psoc,
4507 					 uint8_t value)
4508 {
4509 	return QDF_STATUS_SUCCESS;
4510 }
4511 
4512 static inline QDF_STATUS
wlan_mlme_set_sta_mlo_conn_band_bmp(struct wlan_objmgr_psoc * psoc,uint8_t value)4513 wlan_mlme_set_sta_mlo_conn_band_bmp(struct wlan_objmgr_psoc *psoc,
4514 				    uint8_t value)
4515 {
4516 	return QDF_STATUS_SUCCESS;
4517 }
4518 #endif
4519 
4520 /**
4521  * wlan_mlme_set_ba_2k_jump_iot_ap() - Set a flag if ba 2k jump IOT AP is found
4522  * @vdev: vdev pointer
4523  * @found: Carries the value true if ba 2k jump IOT AP is found
4524  *
4525  * Return: QDF Status
4526  */
4527 QDF_STATUS
4528 wlan_mlme_set_ba_2k_jump_iot_ap(struct wlan_objmgr_vdev *vdev, bool found);
4529 
4530 /**
4531  * wlan_mlme_is_ba_2k_jump_iot_ap() - Check if ba 2k jump IOT AP is found
4532  * @vdev: vdev pointer
4533  *
4534  * Return: true if ba 2k jump IOT AP is found
4535  */
4536 bool
4537 wlan_mlme_is_ba_2k_jump_iot_ap(struct wlan_objmgr_vdev *vdev);
4538 
4539 /**
4540  * wlan_mlme_set_last_delba_sent_time() - Cache the last delba sent ts
4541  * @vdev: vdev pointer
4542  * @delba_sent_time: Last delba sent timestamp
4543  *
4544  * Return: QDF Status
4545  */
4546 QDF_STATUS
4547 wlan_mlme_set_last_delba_sent_time(struct wlan_objmgr_vdev *vdev,
4548 				   qdf_time_t delba_sent_time);
4549 
4550 /**
4551  * wlan_mlme_get_last_delba_sent_time() - Get the last delba sent ts
4552  * @vdev: vdev pointer
4553  *
4554  * Return: Last delba timestamp if cached, 0 otherwise
4555  */
4556 qdf_time_t
4557 wlan_mlme_get_last_delba_sent_time(struct wlan_objmgr_vdev *vdev);
4558 
4559 /**
4560  * mlme_set_user_ps() - Set the PS user config
4561  * @psoc: Pointer to psoc object
4562  * @vdev_id: vdev id
4563  * @ps_enable: User PS enable
4564  *
4565  * Return: QDF_STATUS
4566  */
4567 QDF_STATUS mlme_set_user_ps(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
4568 			    bool ps_enable);
4569 
4570 /**
4571  * mlme_get_user_ps() - Set the user ps flag
4572  * @psoc: Pointer to psoc object
4573  * @vdev_id: vdev id
4574  *
4575  * Return: True if user_ps flag is set
4576  */
4577 bool mlme_get_user_ps(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id);
4578 
4579 #ifdef WLAN_FEATURE_P2P_P2P_STA
4580 /**
4581  * wlan_mlme_get_p2p_p2p_conc_support() - Get p2p+p2p conc support
4582  * @psoc: pointer to psoc object
4583  *
4584  * Return: Success/failure
4585  */
4586 bool
4587 wlan_mlme_get_p2p_p2p_conc_support(struct wlan_objmgr_psoc *psoc);
4588 #else
4589 static inline bool
wlan_mlme_get_p2p_p2p_conc_support(struct wlan_objmgr_psoc * psoc)4590 wlan_mlme_get_p2p_p2p_conc_support(struct wlan_objmgr_psoc *psoc)
4591 {
4592 	return false;
4593 }
4594 #endif
4595 
4596 /**
4597  * mlme_get_vht_ch_width() - get vht channel width of fw capability
4598  *
4599  * Return: vht channel width
4600  */
4601 enum phy_ch_width mlme_get_vht_ch_width(void);
4602 
4603 /**
4604  * wlan_mlme_get_mgmt_hw_tx_retry_count() - Get mgmt frame hw tx retry count
4605  * @psoc: pointer to psoc object
4606  * @frm_type: frame type of the query
4607  *
4608  * Return: hw tx retry count
4609  */
4610 uint8_t
4611 wlan_mlme_get_mgmt_hw_tx_retry_count(struct wlan_objmgr_psoc *psoc,
4612 				     enum mlme_cfg_frame_type frm_type);
4613 
4614 /**
4615  * wlan_mlme_get_tx_retry_multiplier() - Get the tx retry multiplier percentage
4616  * @psoc: pointer to psoc object
4617  * @tx_retry_multiplier: pointer to hold user config value of
4618  * tx_retry_multiplier
4619  *
4620  * Return: QDF Status
4621  */
4622 QDF_STATUS
4623 wlan_mlme_get_tx_retry_multiplier(struct wlan_objmgr_psoc *psoc,
4624 				  uint32_t *tx_retry_multiplier);
4625 
4626 /**
4627  * wlan_mlme_get_update_chan_width_allowed  - Get value of INI
4628  * is_update_chan_width_allowed
4629  * @psoc: pointer to psoc object
4630  * @value: pointer to the value which will be filled for the caller
4631  *
4632  * Return: QDF Status
4633  */
4634 QDF_STATUS
4635 wlan_mlme_get_update_chan_width_allowed(struct wlan_objmgr_psoc *psoc,
4636 					bool *value);
4637 
4638 /**
4639  * wlan_mlme_get_channel_bonding_5ghz  - Get the channel bonding
4640  * val for 5ghz freq
4641  * @psoc: pointer to psoc object
4642  * @value: pointer to the value which will be filled for the caller
4643  *
4644  * Return: QDF Status
4645  */
4646 QDF_STATUS
4647 wlan_mlme_get_channel_bonding_5ghz(struct wlan_objmgr_psoc *psoc,
4648 				   uint32_t *value);
4649 
4650 /**
4651  * wlan_mlme_update_ratemask_params() - Update ratemask params
4652  *
4653  * @vdev: pointer to vdev object
4654  * @num_ratemask: number of rate masks
4655  * @rate_params: pointer to ratemask structure
4656  *
4657  * Return: QDF Status
4658  */
4659 QDF_STATUS
4660 wlan_mlme_update_ratemask_params(struct wlan_objmgr_vdev *vdev,
4661 				 uint8_t num_ratemask,
4662 				 struct config_ratemask_params *rate_params);
4663 
4664 /**
4665  * wlan_mlme_is_channel_valid() - validate channel frequency
4666  * @psoc: psoc object manager
4667  * @chan_freq: channel frequency
4668  *
4669  * This function validates channel frequency present in valid channel
4670  * list or not.
4671  *
4672  * Return: true or false
4673  */
4674 bool wlan_mlme_is_channel_valid(struct wlan_objmgr_psoc *psoc,
4675 				uint32_t chan_freq);
4676 #ifdef WLAN_FEATURE_MCC_QUOTA
4677 /**
4678  * wlan_mlme_set_user_mcc_quota() - set the user mcc quota in mlme
4679  * @psoc: pointer to psoc object
4680  * @quota: pointer to user set mcc quota object
4681  *
4682  * Return: QDF Status
4683  */
4684 QDF_STATUS wlan_mlme_set_user_mcc_quota(struct wlan_objmgr_psoc *psoc,
4685 					struct wlan_user_mcc_quota *quota);
4686 
4687 /**
4688  * wlan_mlme_get_user_mcc_quota() - Get the user mcc quota from mlme
4689  * @psoc: pointer to psoc object
4690  * @quota: pointer to user set mcc quota object
4691  *
4692  * Return: QDF Status
4693  */
4694 QDF_STATUS wlan_mlme_get_user_mcc_quota(struct wlan_objmgr_psoc *psoc,
4695 					struct wlan_user_mcc_quota *quota);
4696 
4697 /**
4698  * wlan_mlme_get_user_mcc_duty_cycle_percentage() - Get user mcc duty cycle
4699  * @psoc: pointer to psoc object
4700  *
4701  * Return: MCC duty cycle if MCC exists for the user MCC quota, else 0
4702  */
4703 uint32_t
4704 wlan_mlme_get_user_mcc_duty_cycle_percentage(struct wlan_objmgr_psoc *psoc);
4705 #else
4706 static inline QDF_STATUS
wlan_mlme_set_user_mcc_quota(struct wlan_objmgr_psoc * psoc,struct wlan_user_mcc_quota * quota)4707 wlan_mlme_set_user_mcc_quota(struct wlan_objmgr_psoc *psoc,
4708 			     struct wlan_user_mcc_quota *quota)
4709 {
4710 	return QDF_STATUS_SUCCESS;
4711 }
4712 
4713 static inline QDF_STATUS
wlan_mlme_get_user_mcc_quota(struct wlan_objmgr_psoc * psoc,struct wlan_user_mcc_quota * quota)4714 wlan_mlme_get_user_mcc_quota(struct wlan_objmgr_psoc *psoc,
4715 			     struct wlan_user_mcc_quota *quota)
4716 {
4717 	return QDF_STATUS_E_NOSUPPORT;
4718 }
4719 
4720 static inline uint32_t
wlan_mlme_get_user_mcc_duty_cycle_percentage(struct wlan_objmgr_psoc * psoc)4721 wlan_mlme_get_user_mcc_duty_cycle_percentage(struct wlan_objmgr_psoc *psoc)
4722 {
4723 	return 0;
4724 }
4725 #endif /* WLAN_FEATURE_MCC_QUOTA */
4726 
4727 /**
4728  * mlme_get_max_he_mcs_idx() -  get max mcs index from he cap information
4729  * @mcs_ch_width: channel width
4730  * @hecap_rxmcsnssmap: rx mcs map from he cap
4731  * @hecap_txmcsnssmap: tx mcs map from he cap
4732  *
4733  * Return: the maximum MCS supported
4734  */
4735 uint8_t mlme_get_max_he_mcs_idx(enum phy_ch_width mcs_ch_width,
4736 				u_int16_t *hecap_rxmcsnssmap,
4737 				u_int16_t *hecap_txmcsnssmap);
4738 
4739 /**
4740  * mlme_get_max_vht_mcs_idx() -  get max mcs index from vht cap information
4741  * @rx_vht_mcs_map: rx mcs map from vht cap
4742  * @tx_vht_mcs_map: tx mcs map from vht cap
4743  *
4744  * Return: the maximum MCS supported
4745  */
4746 uint8_t mlme_get_max_vht_mcs_idx(u_int16_t rx_vht_mcs_map,
4747 				 u_int16_t tx_vht_mcs_map);
4748 
4749 #ifdef WLAN_FEATURE_SON
4750 /**
4751  * mlme_save_vdev_max_mcs_idx() - Save max mcs index of vdev
4752  * @vdev: pointer to vdev object
4753  * @max_mcs_idx: max_mcs_idx to save
4754  *
4755  * Return: QDF Status
4756  */
4757 QDF_STATUS mlme_save_vdev_max_mcs_idx(struct wlan_objmgr_vdev *vdev,
4758 				      uint8_t max_mcs_idx);
4759 
4760 /**
4761  * mlme_get_vdev_max_mcs_idx() - Get max mcs index of vdev
4762  * @vdev: pointer to vdev object
4763  *
4764  * Return max mcs index of vdev
4765  */
4766 uint8_t mlme_get_vdev_max_mcs_idx(struct wlan_objmgr_vdev *vdev);
4767 #endif /* WLAN_FEATURE_SON */
4768 /**
4769  * wlan_mlme_set_safe_mode_enable() - set safe_mode_enable flag
4770  * based on value set by user space.
4771  *
4772  * @psoc: psoc context
4773  * @safe_mode_enable: safe mode enabled or not
4774  *
4775  * Return: none
4776  */
4777 void wlan_mlme_set_safe_mode_enable(struct wlan_objmgr_psoc *psoc,
4778 				    bool safe_mode_enable);
4779 
4780 /**
4781  * wlan_mlme_get_safe_mode_enable() - get safe_mode_enable set by user
4782  * space
4783  *
4784  * @psoc: psoc context
4785  * @safe_mode_enable: safe mode enabled or not
4786  *
4787  * Return: none
4788  */
4789 void wlan_mlme_get_safe_mode_enable(struct wlan_objmgr_psoc *psoc,
4790 				    bool *safe_mode_enable);
4791 
4792 /**
4793  * wlan_mlme_get_6g_ap_power_type() - get the power type of the
4794  * vdev operating on 6GHz.
4795  *
4796  * @vdev: vdev context
4797  *
4798  * Return: 6g_power_type
4799  */
4800 uint32_t wlan_mlme_get_6g_ap_power_type(struct wlan_objmgr_vdev *vdev);
4801 
4802 QDF_STATUS wlan_connect_hw_mode_change_resp(struct wlan_objmgr_pdev *pdev,
4803 					    uint8_t vdev_id,
4804 					    wlan_cm_id cm_id,
4805 					    QDF_STATUS status);
4806 
4807 /**
4808  * wlan_mlme_get_ch_width_from_phymode() - Convert phymode to ch_width
4809  * @phy_mode: Phy mode
4810  *
4811  * Return: enum phy_ch_width
4812  */
4813 enum phy_ch_width
4814 wlan_mlme_get_ch_width_from_phymode(enum wlan_phymode phy_mode);
4815 
4816 /**
4817  * wlan_mlme_get_peer_ch_width() - get ch_width of the given peer
4818  * @psoc: psoc context
4819  * @mac: peer mac
4820  *
4821  * Return: enum phy_ch_width
4822  */
4823 enum phy_ch_width
4824 wlan_mlme_get_peer_ch_width(struct wlan_objmgr_psoc *psoc, uint8_t *mac);
4825 
4826 #if defined(WLAN_FEATURE_SR)
4827 /**
4828  * wlan_mlme_get_sr_enable_modes() - get mode for which SR is enabled
4829  *
4830  * @psoc: psoc context
4831  * @val: pointer to hold the value of SR(Spatial Reuse) enable modes
4832  *
4833  * Return: void
4834  */
4835 void
4836 wlan_mlme_get_sr_enable_modes(struct wlan_objmgr_psoc *psoc, uint8_t *val);
4837 #endif
4838 
4839 /**
4840  * wlan_mlme_set_edca_pifs_param() - set edca/pifs param for ll sap
4841  * @ep: pointer to wlan_edca_pifs_param_ie
4842  * @type: edca_param_type
4843  *
4844  * Return: None
4845  */
4846 void
4847 wlan_mlme_set_edca_pifs_param(struct wlan_edca_pifs_param_ie *ep,
4848 			      enum host_edca_param_type type);
4849 /**
4850  * wlan_mlme_stats_get_periodic_display_time() - get display time
4851  * @psoc: pointer to psoc object
4852  * @periodic_display_time: buffer to hold value
4853  *
4854  * Return: QDF Status
4855  */
4856 QDF_STATUS
4857 wlan_mlme_stats_get_periodic_display_time(struct wlan_objmgr_psoc *psoc,
4858 					  uint32_t *periodic_display_time);
4859 
4860 /**
4861  * wlan_mlme_is_bcn_prot_disabled_for_sap() - Is beacon protection config
4862  * disabled for SAP interface
4863  *
4864  * @psoc: pointer to psoc object
4865  *
4866  * Return: is beacon protection disabled
4867  */
4868 bool
4869 wlan_mlme_is_bcn_prot_disabled_for_sap(struct wlan_objmgr_psoc *psoc);
4870 
4871 /**
4872  * wlan_mlme_get_src_addr_from_frame() - Get source address of the frame
4873  * @frame: frame ptr
4874  *
4875  * Extract source mac address of the frame
4876  *
4877  * Return: Ptr for extracted src mac address
4878  *
4879  */
4880 uint8_t *
4881 wlan_mlme_get_src_addr_from_frame(struct element_info *frame);
4882 
4883 /*
4884  * wlan_mlme_get_sap_ps_with_twt() - power save with twt config enabled/disabled
4885  * for SAP interface
4886  *
4887  * @psoc: pointer to psoc object
4888  *
4889  * Return: power save enabled/disabled
4890  */
4891 bool
4892 wlan_mlme_get_sap_ps_with_twt(struct wlan_objmgr_psoc *psoc);
4893 
4894 /**
4895  * wlan_mlme_get_max_bw() - Get max supported bandwidth
4896  *
4897  * Extract max supported bandwidth
4898  *
4899  * Return: enum phy_ch_width
4900  *
4901  */
4902 enum phy_ch_width wlan_mlme_get_max_bw(void);
4903 
4904 /**
4905  * wlan_mlme_get_sta_ch_width() - Get current operating
4906  * channel width for STA / P2P-CLI mode
4907  *
4908  * @vdev: STA / P2P-CLI vdev
4909  * @ch_width: Returned channel width
4910  *
4911  * Return: QDF_STATUS_SUCCESS for success otherwise QDF_STATUS_E_INVAL
4912  *
4913  */
4914 QDF_STATUS wlan_mlme_get_sta_ch_width(struct wlan_objmgr_vdev *vdev,
4915 				      enum phy_ch_width *ch_width);
4916 
4917 /**
4918  * wlan_mlme_set_ul_mu_config() - set ul mu config
4919  *
4920  * @psoc: pointer to psoc object
4921  * @vdev_id : vdev_id
4922  * @ulmu_disable : ulmu_disable value
4923  *
4924  * Return: QDF Status
4925  */
4926 QDF_STATUS
4927 wlan_mlme_set_ul_mu_config(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
4928 			   uint8_t ulmu_disable);
4929 
4930 /**
4931  * wlan_mlme_assemble_rate_code() - assemble rate code to be sent to FW
4932  *
4933  * @preamble: rate preamble
4934  * @nss: number of spatial streams
4935  * @rate: rate index
4936  *
4937  * Rate code assembling is different for targets which are 11ax capable.
4938  * Check for the target support and assemble the rate code accordingly.
4939  *
4940  * Return: assembled rate code
4941  */
4942 uint32_t
4943 wlan_mlme_assemble_rate_code(uint8_t preamble, uint8_t nss, uint8_t rate);
4944 
4945 /**
4946  * wlan_mlme_set_ap_oper_ch_width() - set SAP current operating ch_width
4947  *
4948  * @vdev: SAP VDEV object
4949  * @ch_width: ch_width to be cached
4950  *
4951  * Return: QDF Status
4952  */
4953 QDF_STATUS
4954 wlan_mlme_set_ap_oper_ch_width(struct wlan_objmgr_vdev *vdev,
4955 			       enum phy_ch_width ch_width);
4956 
4957 /**
4958  * wlan_mlme_get_ap_oper_ch_width() - get SAP current operating ch_width
4959  *
4960  * @vdev: SAP VDEV object
4961  *
4962  * Return: Current SAP operating ch_width
4963  */
4964 enum phy_ch_width
4965 wlan_mlme_get_ap_oper_ch_width(struct wlan_objmgr_vdev *vdev);
4966 
4967 /**
4968  * wlan_mlme_send_csa_event_status_ind() - send csa event status ind
4969  * @vdev: vdev obj
4970  * @csa_status: csa status
4971  *
4972  * Return: QDF_STATUS
4973  */
4974 QDF_STATUS
4975 wlan_mlme_send_csa_event_status_ind(struct wlan_objmgr_vdev *vdev,
4976 				    uint8_t csa_status);
4977 
4978 /**
4979  * wlan_mlme_is_hs_20_btm_offload_disabled() - Get BTM offload is enable/disable
4980  * @psoc: pointer to psoc object
4981  * @val:  Pointer to the value which will be filled for the caller
4982  *
4983  * Return: QDF Status
4984  */
4985 QDF_STATUS
4986 wlan_mlme_is_hs_20_btm_offload_disabled(struct wlan_objmgr_psoc *psoc,
4987 					bool *val);
4988 /**
4989  * wlan_mlme_set_keepalive_period() - Save keep alive period
4990  * @vdev: VDEV object
4991  * @keep_alive_period: Keep alive period
4992  *
4993  * Return: None
4994  */
4995 void wlan_mlme_set_keepalive_period(struct wlan_objmgr_vdev *vdev,
4996 				    uint16_t keep_alive_period);
4997 
4998 /**
4999  * wlan_mlme_get_keepalive_period() - Get keep alive period
5000  * @vdev: VDEV object
5001  *
5002  * Return: Keep alive period.
5003  */
5004 uint16_t wlan_mlme_get_keepalive_period(struct wlan_objmgr_vdev *vdev);
5005 #endif /* _WLAN_MLME_API_H_ */
5006