blob: 98ae5a5faa3eb515ab3564285eda5f25591dea6b [file] [log] [blame]
Wu Gao55f21712018-09-17 10:57:49 +08001/*
Wu Gao6294afc2019-01-05 00:00:58 +08002 * Copyright (c) 2012-2019 The Linux Foundation. All rights reserved.
Wu Gao55f21712018-09-17 10:57:49 +08003 *
4 * Permission to use, copy, modify, and/or distribute this software for
5 * any purpose with or without fee is hereby granted, provided that the
6 * above copyright notice and this permission notice appear in all
7 * copies.
8 *
9 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
10 * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
11 * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
12 * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
13 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
14 * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
15 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
16 * PERFORMANCE OF THIS SOFTWARE.
17 */
18
19/**
20 * DOC: This file contains configuration definitions for MLME LFR.
21 */
22
23#ifndef CFG_MLME_LFR_H__
24#define CFG_MLME_LFR_H__
25
26/*
27 * <ini>
28 * mawc_roam_enabled - Enable/Disable MAWC during roaming
29 * @Min: 0 - Disabled
30 * @Max: 1 - Enabled
31 * @Default: 0
32 *
33 * This ini is used to control MAWC during roaming.
34 *
35 * Related: MAWCEnabled.
36 *
37 * Supported Feature: MAWC Roaming
38 *
39 * Usage: Internal/External
40 *
41 * </ini>
42 */
43#define CFG_LFR_MAWC_ROAM_ENABLED CFG_INI_BOOL( \
44 "mawc_roam_enabled", \
45 0, \
46 "Enable/Disable MAWC during roaming")
47
48/*
49 * <ini>
50 * mawc_roam_traffic_threshold - Configure traffic threshold
51 * @Min: 0
52 * @Max: 0xFFFFFFFF
53 * @Default: 300
54 *
55 * This ini is used to configure the data traffic load in kbps to
56 * register CMC.
57 *
58 * Related: mawc_roam_enabled.
59 *
60 * Supported Feature: MAWC Roaming
61 *
62 * Usage: Internal/External
63 *
64 * </ini>
65 */
66#define CFG_LFR_MAWC_ROAM_TRAFFIC_THRESHOLD CFG_INI_UINT( \
67 "mawc_roam_traffic_threshold", \
68 0, \
69 0xFFFFFFFF, \
70 300, \
71 CFG_VALUE_OR_DEFAULT, \
72 "Configure traffic threshold")
73
74/*
75 * <ini>
76 * mawc_roam_ap_rssi_threshold - Best AP RSSI threshold
77 * @Min: -120
78 * @Max: 0
79 * @Default: -66
80 *
81 * This ini is used to specify the RSSI threshold to scan for the AP.
82 *
83 * Related: mawc_roam_enabled.
84 *
85 * Supported Feature: MAWC Roaming
86 *
87 * Usage: Internal/External
88 *
89 * </ini>
90 */
91#define CFG_LFR_MAWC_ROAM_AP_RSSI_THRESHOLD CFG_INI_INT( \
92 "mawc_roam_ap_rssi_threshold", \
93 -120, \
94 0, \
95 -66, \
96 CFG_VALUE_OR_DEFAULT, \
97 "Best AP RSSI threshold")
98
99/*
100 * <ini>
101 * mawc_roam_rssi_high_adjust - Adjust MAWC roam high RSSI
102 * @Min: 3
103 * @Max: 5
104 * @Default: 5
105 *
106 * This ini is used for high RSSI threshold adjustment in stationary state
107 * to suppress the scan.
108 *
109 * Related: mawc_roam_enabled.
110 *
111 * Supported Feature: MAWC Roaming
112 *
113 * Usage: Internal/External
114 *
115 * </ini>
116 */
117#define CFG_LFR_MAWC_ROAM_RSSI_HIGH_ADJUST CFG_INI_UINT( \
118 "mawc_roam_ap_rssi_threshold", \
119 3, \
120 5, \
121 5, \
122 CFG_VALUE_OR_DEFAULT, \
123 "Adjust MAWC roam high RSSI")
124
125/*
126 * <ini>
127 * mawc_roam_rssi_low_adjust - Adjust MAWC roam low RSSI
128 * @Min: 3
129 * @Max: 5
130 * @Default: 5
131 *
132 * This ini is used for low RSSI threshold adjustment in stationary state
133 * to suppress the scan.
134 *
135 * Related: mawc_roam_enabled.
136 *
137 * Supported Feature: MAWC Roaming
138 *
139 * Usage: Internal/External
140 *
141 * </ini>
142 */
143#define CFG_LFR_MAWC_ROAM_RSSI_LOW_ADJUST CFG_INI_UINT( \
144 "mawc_roam_rssi_low_adjust", \
145 3, \
146 5, \
147 5, \
148 CFG_VALUE_OR_DEFAULT, \
149 "Adjust MAWC roam low RSSI")
150
151/*
152 * <ini>
153 * rssi_abs_thresh - The min RSSI of the candidate AP to consider roam
154 * @Min: -96
155 * @Max: 0
156 * @Default: 0
157 *
158 * The RSSI value of the candidate AP should be higher than rssi_abs_thresh
159 * to roam to the AP. 0 means no absolute minimum RSSI is required.
160 *
161 * Related: None
162 *
163 * Supported Feature: Roaming
164 *
165 * Usage: External
166 *
167 * </ini>
168 */
169#define CFG_LFR_ROAM_RSSI_ABS_THRESHOLD CFG_INI_INT( \
170 "rssi_abs_thresh", \
171 -96, \
172 0, \
173 0, \
174 CFG_VALUE_OR_DEFAULT, \
175 "The min RSSI of the candidate AP to consider roam")
176
177/*
178 * <ini>
179 * lookup_threshold_5g_offset - Lookup threshold offset for 5G band
180 * @Min: -120
181 * @Max: 120
182 * @Default: 0
183 *
184 * This ini is used to set the 5G band lookup threshold for roaming.
185 * It depends on another INI which is gNeighborLookupThreshold.
186 * gNeighborLookupThreshold is a legacy INI item which will be used to
187 * set the RSSI lookup threshold for both 2G and 5G bands. If the
188 * user wants to setup a different threshold for a 5G band, then user
189 * can use this offset value which will be summed up to the value of
190 * gNeighborLookupThreshold and used for 5G
191 * e.g: gNeighborLookupThreshold = -76dBm
192 * lookup_threshold_5g_offset = 6dBm
193 * Then the 5G band will be configured to -76+6 = -70dBm
194 * A default value of Zero to lookup_threshold_5g_offset will keep the
195 * thresholds same for both 2G and 5G bands
196 *
197 * Related: gNeighborLookupThreshold
198 *
199 * Supported Feature: Roaming
200 *
201 * Usage: Internal/External
202 *
203 * </ini>
204 */
205#define CFG_LFR_5G_RSSI_THRESHOLD_OFFSET CFG_INI_INT( \
206 "lookup_threshold_5g_offset", \
207 -120, \
208 120, \
209 0, \
210 CFG_VALUE_OR_DEFAULT, \
211 "Lookup threshold offset for 5G band")
212
213/*
214 * <ini>
215 * gEnableFastRoamInConcurrency - Enable LFR roaming on STA during concurrency
216 * @Min: 0
217 * @Max: 1
218 * @Default: 1
219 *
220 * This INI is used to enable Legacy fast roaming(LFR) on STA link during
221 * concurrent sessions.
222 *
223 * Related: None
224 *
225 * Supported Feature: Roaming
226 *
227 * Usage: External
228 *
229 * </ini>
230 */
231#define CFG_LFR_ENABLE_FAST_ROAM_IN_CONCURRENCY CFG_INI_BOOL( \
232 "gEnableFastRoamInConcurrency", \
233 1, \
234 "Enable LFR roaming on STA during concurrency")
235
236/*
237 * <ini>
Wu Gao55f21712018-09-17 10:57:49 +0800238 * gEnableEarlyStopScan - Set early stop scan
239 * @Min: 0
240 * @Max: 1
Tushnim Bhattacharyya1fdefe52018-09-25 11:50:42 -0700241 * @Default: 0
Wu Gao55f21712018-09-17 10:57:49 +0800242 *
243 * This ini is used to set early stop scan. Early stop
244 * scan is a feature for roaming to stop the scans at
245 * an early stage as soon as we find a better AP to roam.
246 * This would make the roaming happen quickly.
247 *
248 * Related: None
249 *
250 * Supported Feature: LFR Scan
251 *
252 * Usage: External
253 *
254 * </ini>
255 */
256#define CFG_LFR_EARLY_STOP_SCAN_ENABLE CFG_INI_BOOL( \
257 "gEnableEarlyStopScan", \
Tushnim Bhattacharyya1fdefe52018-09-25 11:50:42 -0700258 0, \
Wu Gao55f21712018-09-17 10:57:49 +0800259 "Set early stop scan")
260
261/*
262 * <ini>
263 * gEarlyStopScanMinThreshold - Set early stop scan min
264 * threshold
265 * @Min: -80
266 * @Max: -70
267 * @Default: -73
268 *
269 * This ini is used to set the early stop scan minimum
270 * threshold. Early stop scan minimum threshold is the
271 * minimum threshold to be considered for stopping the
272 * scan. The algorithm starts with a scan on the greedy
273 * channel list with the maximum threshold and steps down
274 * the threshold by 20% for each further channel. It can
275 * step down on each channel but cannot go lower than the
276 * minimum threshold.
277 *
278 * Related: None
279 *
280 * Supported Feature: Scan
281 *
282 * Usage: External
283 *
284 * </ini>
285 */
286#define CFG_LFR_EARLY_STOP_SCAN_MIN_THRESHOLD CFG_INI_INT( \
287 "gEarlyStopScanMinThreshold", \
288 -80, \
289 -70, \
290 -73, \
291 CFG_VALUE_OR_DEFAULT, \
292 "Set early stop scan min")
293
294/*
295 * <ini>
296 * gEarlyStopScanMaxThreshold - Set early stop scan max
297 * threshold
298 * @Min: -60
299 * @Max: -40
300 * @Default: -43
301 *
302 * This ini is used to set the the early stop scan maximum
303 * threshold at which the candidate AP should be to be
304 * qualified as a potential roam candidate and good enough
305 * to stop the roaming scan.
306 *
307 * Related: None
308 *
309 * Supported Feature: Scan
310 *
311 * Usage: External
312 *
313 * </ini>
314 */
315#define CFG_LFR_EARLY_STOP_SCAN_MAX_THRESHOLD CFG_INI_INT( \
316 "gEarlyStopScanMaxThreshold", \
317 -60, \
318 -40, \
319 -43, \
320 CFG_VALUE_OR_DEFAULT, \
321 "Set early stop scan max")
322
323/*
324 * <ini>
325 * gFirstScanBucketThreshold - Set first scan bucket
326 * threshold
327 * @Min: -50
328 * @Max: -30
329 * @Default: -30
330 *
331 * This ini will configure the first scan bucket
332 * threshold to the mentioned value and all the AP's which
333 * have RSSI under this threshold will fall under this
334 * bucket. This configuration item used to tweak and
335 * test the input for internal algorithm.
336 *
337 * Related: None
338 *
339 * Supported Feature: Scan
340 *
341 * Usage: Internal
342 *
343 * </ini>
344 */
345#define CFG_LFR_FIRST_SCAN_BUCKET_THRESHOLD CFG_INI_INT( \
346 "gFirstScanBucketThreshold", \
347 -50, \
348 -30, \
349 -30, \
350 CFG_VALUE_OR_DEFAULT, \
351 "Set first scan bucket")
352
353/*
354 * <ini>
Wu Gao55f21712018-09-17 10:57:49 +0800355 * gtraffic_threshold - Dense traffic threshold
356 * @Min: 0
357 * @Max: 0xffffffff
358 * @Default: 400
359 *
360 * Dense traffic threshold
361 * traffic threshold required for dense roam scan
362 * Measured in kbps
363 *
364 * Related: None
365 *
366 * Supported Feature: Roaming
367 *
368 * Usage: External
369 *
370 * </ini>
371 */
372#define CFG_LFR_ROAM_DENSE_TRAFFIC_THRESHOLD CFG_INI_UINT( \
373 "gtraffic_threshold", \
374 0, \
375 0xffffffff, \
376 400, \
377 CFG_VALUE_OR_DEFAULT, \
378 "Dense traffic threshold")
379
380/*
381 * <ini>
382 * groam_dense_rssi_thresh_offset - Sets dense roam RSSI threshold diff
383 * @Min: 0
384 * @Max: 20
385 * @Default: 10
386 *
387 * This INI is used to set offset value from normal RSSI threshold to dense
388 * RSSI threshold FW will optimize roaming based on new RSSI threshold once
389 * it detects dense environment.
390 *
391 * Related: None
392 *
393 * Supported Feature: Roaming
394 *
395 * Usage: External
396 *
397 * </ini>
398 */
399#define CFG_LFR_ROAM_DENSE_RSSI_THRE_OFFSET CFG_INI_UINT( \
400 "groam_dense_rssi_thresh_offset", \
401 0, \
402 20, \
403 10, \
404 CFG_VALUE_OR_DEFAULT, \
405 "Dense traffic threshold")
406
407/*
408 * <ini>
409 * groam_dense_min_aps - Sets minimum number of AP for dense roam
410 * @Min: 1
411 * @Max: 5
412 * @Default: 3
413 *
414 * Minimum number of APs required for dense roam. FW will consider
415 * environment as dense once it detects #APs operating is more than
416 * groam_dense_min_aps.
417 *
418 * Related: None
419 *
420 * Supported Feature: Roaming
421 *
422 * Usage: External
423 *
424 * </ini>
425 */
426#define CFG_LFR_ROAM_DENSE_MIN_APS CFG_INI_UINT( \
427 "groam_dense_min_aps", \
428 1, \
429 5, \
430 3, \
431 CFG_VALUE_OR_DEFAULT, \
432 "Sets minimum number of AP for dense roam")
433
434/*
435 * <ini>
436 * roam_bg_scan_bad_rssi_thresh - RSSI threshold for background roam
437 * @Min: -96
438 * @Max: 0
439 * @Default: -76
440 *
441 * If the DUT is connected to an AP with weak signal, then the bad RSSI
442 * threshold will be used as an opportunity to use the scan results
443 * from other scan clients and try to roam if there is a better AP
444 * available in the environment.
445 *
446 * Related: None
447 *
448 * Supported Feature: Roaming
449 *
450 * Usage: External
451 *
452 * </ini>
453 */
454#define CFG_LFR_ROAM_BG_SCAN_BAD_RSSI_THRESHOLD CFG_INI_INT( \
455 "roam_bg_scan_bad_rssi_thresh", \
456 -96, \
457 0, \
458 -76, \
459 CFG_VALUE_OR_DEFAULT, \
460 "RSSI threshold for background roam")
461
462/*
463 * <ini>
464 * roam_bg_scan_client_bitmap - Bitmap used to identify the scan clients
465 * @Min: 0
466 * @Max: 0x7FF
467 * @Default: 0x424
468 *
469 * This bitmap is used to define the client scans that need to be used
470 * by the roaming module to perform a background roaming.
471 * Currently supported bit positions are as follows:
472 * Bit 0 is reserved in the firmware.
473 * WMI_SCAN_CLIENT_NLO - 1
474 * WMI_SCAN_CLIENT_EXTSCAN - 2
475 * WMI_SCAN_CLIENT_ROAM - 3
476 * WMI_SCAN_CLIENT_P2P - 4
477 * WMI_SCAN_CLIENT_LPI - 5
478 * WMI_SCAN_CLIENT_NAN - 6
479 * WMI_SCAN_CLIENT_ANQP - 7
480 * WMI_SCAN_CLIENT_OBSS - 8
481 * WMI_SCAN_CLIENT_PLM - 9
482 * WMI_SCAN_CLIENT_HOST - 10
483 *
484 * Related: None
485 *
486 * Supported Feature: Roaming
487 *
488 * Usage: External
489 *
490 * </ini>
491 */
492#define CFG_LFR_ROAM_BG_SCAN_CLIENT_BITMAP CFG_INI_UINT( \
493 "roam_bg_scan_client_bitmap", \
494 0, \
495 0x7FF, \
496 0x424, \
497 CFG_VALUE_OR_DEFAULT, \
498 "Bitmap used to identify the scan clients")
499
500/*
501 * <ini>
502 * roam_bad_rssi_thresh_offset_2g - RSSI threshold offset for 2G to 5G roam
503 * @Min: 0
504 * @Max: 86
505 * @Default: 40
506 *
507 * If the DUT is connected to an AP with weak signal in 2G band, then the
508 * bad RSSI offset for 2g would be used as offset from the bad RSSI
509 * threshold configured and then use the resulting rssi for an opportunity
510 * to use the scan results from other scan clients and try to roam to
511 * 5G Band ONLY if there is a better AP available in the environment.
512 *
513 * For example if the roam_bg_scan_bad_rssi_thresh is -76 and
514 * roam_bad_rssi_thresh_offset_2g is 40 then the difference of -36 would be
515 * used as a trigger to roam to a 5G AP if DUT initially connected to a 2G AP
516 *
517 * Related: roam_bg_scan_bad_rssi_thresh
518 *
519 * Supported Feature: Roaming
520 *
521 * Usage: External
522 *
523 * </ini>
524 */
525#define CFG_LFR_ROAM_BG_SCAN_BAD_RSSI_OFFSET_2G CFG_INI_UINT( \
526 "roam_bad_rssi_thresh_offset_2g", \
527 0, \
528 86, \
529 40, \
530 CFG_VALUE_OR_DEFAULT, \
531 "RSSI threshold offset for 2G to 5G roam")
532
533/*
534 * <ini>
535 * roamscan_adaptive_dwell_mode - Sets dwell time adaptive mode
536 * @Min: 0
537 * @Max: 4
Jianmin Zhu0423e332019-04-21 14:26:28 +0800538 * @Default: 4
Wu Gao55f21712018-09-17 10:57:49 +0800539 *
540 * This parameter will set the algo used in dwell time optimization during
541 * roam scan. see enum scan_dwelltime_adaptive_mode.
542 * Acceptable values for this:
543 * 0: Default (Use firmware default mode)
544 * 1: Conservative optimization
545 * 2: Moderate optimization
546 * 3: Aggressive optimization
547 * 4: Static
548 *
549 * Related: None
550 *
551 * Supported Feature: Roaming
552 *
553 * Usage: External
554 *
555 * </ini>
556 */
557#define CFG_LFR_ADAPTIVE_ROAMSCAN_DWELL_MODE CFG_INI_UINT( \
558 "roamscan_adaptive_dwell_mode", \
559 0, \
560 4, \
Jianmin Zhu0423e332019-04-21 14:26:28 +0800561 4, \
Wu Gao55f21712018-09-17 10:57:49 +0800562 CFG_VALUE_OR_DEFAULT, \
563 "Sets dwell time adaptive mode")
564
565/*
566 * <ini>
567 * gper_roam_enabled - To enabled/disable PER based roaming in FW
568 * @Min: 0
569 * @Max: 3
570 * @Default: 3
571 *
572 * This ini is used to enable/disable Packet error based roaming, enabling this
573 * will cause DUT to monitor Tx and Rx traffic and roam to a better candidate
574 * if current is not good enough.
575 *
576 * Values supported:
577 * 0: disabled
578 * 1: enabled for Rx traffic
579 * 2: enabled for Tx traffic
580 * 3: enabled for Tx and Rx traffic
581 *
582 * Related: gper_roam_high_rate_th, gper_roam_low_rate_th,
583 * gper_roam_th_percent, gper_roam_rest_time
584 *
585 * Supported Feature: LFR-3.0
586 *
587 * Usage: Internal
588 *
589 * </ini>
590 */
591#define CFG_LFR_PER_ROAM_ENABLE CFG_INI_UINT( \
592 "gper_roam_enabled", \
593 0, \
594 3, \
595 3, \
596 CFG_VALUE_OR_DEFAULT, \
597 "To enabled/disable PER based roaming in FW")
598
599/*
600 * <ini>
601 * gper_roam_high_rate_th - Rate at which PER based roam will stop
602 * @Min: 1 Mbps
603 * @Max: 0xffffffff
604 * @Default: 40 Mbps
605 *
606 * This ini is used to define the data rate in mbps*10 at which FW will stop
607 * monitoring the traffic for PER based roam.
608 *
609 * Related: gper_roam_enabled, gper_roam_low_rate_th,
610 * gper_roam_th_percent, gper_roam_rest_time
611 *
612 * Supported Feature: LFR-3.0
613 *
614 * Usage: Internal
615 *
616 * </ini>
617 */
618#define CFG_LFR_PER_ROAM_CONFIG_HIGH_RATE_TH CFG_INI_UINT( \
619 "gper_roam_high_rate_th", \
620 10, \
621 0xffffffff, \
622 400, \
623 CFG_VALUE_OR_DEFAULT, \
624 "Rate at which PER based roam will stop")
625
626/*
627 * <ini>
628 * gper_roam_low_rate_th - Rate at which FW starts considering traffic for PER
629 * based roam.
630 *
631 * @Min: 1 Mbps
632 * @Max: 0xffffffff
633 * @Default: 20 Mbps
634 *
635 * This ini is used to define the rate in mbps*10 at which FW starts considering
636 * traffic for PER based roam, if gper_roam_th_percent of data is below this
637 * rate, FW will issue a roam scan.
638 *
639 * Related: gper_roam_enabled, gper_roam_high_rate_th,
640 * gper_roam_th_percent, gper_roam_rest_time
641 *
642 * Supported Feature: LFR-3.0
643 *
644 * Usage: Internal
645 *
646 * </ini>
647 */
648#define CFG_LFR_PER_ROAM_CONFIG_LOW_RATE_TH CFG_INI_UINT( \
649 "gper_roam_low_rate_th", \
650 10, \
651 0xffffffff, \
652 200, \
653 CFG_VALUE_OR_DEFAULT, \
654 "Rate at which FW starts considering traffic for PER")
655
656/*
657 * <ini>
658 * gper_roam_th_percent - Percentage at which FW will issue a roam scan if
659 * traffic is below gper_roam_low_rate_th rate.
660 *
661 * @Min: 10%
662 * @Max: 100%
663 * @Default: 60%
664 *
665 * This ini is used to define the percentage at which FW will issue a roam scan
666 * if traffic is below gper_roam_low_rate_th rate.
667 *
668 * Related: gper_roam_enabled, gper_roam_high_rate_th,
669 * gper_roam_high_rate_th, gper_roam_rest_time
670 *
671 * Supported Feature: LFR-3.0
672 *
673 * Usage: Internal
674 *
675 * </ini>
676 */
677#define CFG_LFR_PER_ROAM_CONFIG_RATE_TH_PERCENT CFG_INI_UINT( \
678 "gper_roam_th_percent", \
679 10, \
680 100, \
681 60, \
682 CFG_VALUE_OR_DEFAULT, \
683 "Percentage at which FW will issue a roam scan")
684
685/*
686 * <ini>
687 * gper_roam_rest_time - Time for which FW will wait once it issues a
688 * roam scan.
689 *
690 * @Min: 10 seconds
691 * @Max: 3600 seconds
692 * @Default: 300 seconds
693 *
694 * This ini is used to define the time for which FW will wait once it issues a
695 * PER based roam scan.
696 *
697 * Related: gper_roam_enabled, gper_roam_high_rate_th,
698 * gper_roam_high_rate_th, gper_roam_th_percent
699 *
700 * Supported Feature: LFR-3.0
701 *
702 * Usage: Internal
703 *
704 * </ini>
705 */
706#define CFG_LFR_PER_ROAM_REST_TIME CFG_INI_UINT( \
707 "gper_roam_rest_time", \
708 10, \
709 3600, \
710 300, \
711 CFG_VALUE_OR_DEFAULT, \
712 "Time for which FW will wait once it issues a roam scan")
713
714/*
715 * <ini>
716 * gper_roam_mon_time - Minimum time required in seconds to
717 * be considered as valid scenario for PER based roam
718 * @Min: 5
719 * @Max: 25
720 * @Default: 25
721 *
722 * This ini is used to define minimum time in seconds for which DUT has
723 * collected the PER stats before it can consider the stats hysteresis to be
724 * valid for PER based scan.
725 * DUT collects following information during this period:
726 * 1. % of packets below gper_roam_low_rate_th
727 * 2. # packets above gper_roam_high_rate_th
728 * if DUT gets (1) greater than gper_roam_th_percent and (2) is zero during
729 * this period, it triggers PER based roam scan.
730 *
731 * Related: gper_roam_enabled, gper_roam_high_rate_th, gper_roam_low_rate_th,
732 * gper_roam_th_percent, gper_roam_rest_time
733 *
734 * Supported Feature: LFR-3.0
735 *
736 * Usage: Internal
737 *
738 * </ini>
739 */
740#define CFG_LFR_PER_ROAM_MONITOR_TIME CFG_INI_UINT( \
741 "gper_roam_mon_time", \
742 5, \
743 25, \
744 25, \
745 CFG_VALUE_OR_DEFAULT, \
746 "Minimum time to be considered as valid scenario for PER based roam")
747
748/*
749 * <ini>
750 * gper_min_rssi_threshold_for_roam - Minimum roamable AP RSSI for
751 * candidate selection for PER based roam
752 * @Min: 0
753 * @Max: 96
754 * @Default: 83
755 *
756 * Minimum roamable AP RSSI for candidate selection for PER based roam
757 *
758 * Related: gper_roam_enabled, gper_roam_high_rate_th, gper_roam_low_rate_th,
759 * gper_roam_th_percent, gper_roam_rest_time
760 *
761 * Supported Feature: LFR-3.0
762 *
763 * Usage: Internal
764 *
765 * </ini>
766 */
767#define CFG_LFR_PER_ROAM_MIN_CANDIDATE_RSSI CFG_INI_UINT( \
768 "gper_min_rssi_threshold_for_roam", \
769 10, \
770 96, \
771 83, \
772 CFG_VALUE_OR_DEFAULT, \
773 "Minimum roamable AP RSSI for candidate selection for PER based roam")
774
775/*
776 * <ini>
777 * groam_disallow_duration - disallow duration before roaming
778 * @Min: 0
779 * @Max: 3600
780 * @Default: 30
781 *
782 * This ini is used to configure how long LCA[Last Connected AP] AP will
783 * be disallowed before it can be a roaming candidate again, in units of
784 * seconds.
785 *
786 * Related: LFR
787 *
788 * Usage: Internal
789 *
790 * </ini>
791 */
792#define CFG_LFR3_ROAM_DISALLOW_DURATION CFG_INI_UINT( \
793 "groam_disallow_duration", \
794 0, \
795 3600, \
796 30, \
797 CFG_VALUE_OR_DEFAULT, \
798 "disallow duration before roaming")
799
800/*
801 * <ini>
802 * grssi_channel_penalization - RSSI penalization
803 * @Min: 0
804 * @Max: 15
805 * @Default: 5
806 *
807 * This ini is used to configure RSSI that will be penalized if candidate(s)
808 * are found to be in the same channel as disallowed AP's, in units of db.
809 *
810 * Related: LFR
811 *
812 * Usage: Internal
813 *
814 * </ini>
815 */
816#define CFG_LFR3_ROAM_RSSI_CHANNEL_PENALIZATION CFG_INI_UINT( \
817 "grssi_channel_penalization", \
818 0, \
819 15, \
820 5, \
821 CFG_VALUE_OR_DEFAULT, \
822 "RSSI penalization")
823
824/*
825 * <ini>
826 * groam_num_disallowed_aps - Max number of AP's to maintain in LCA list
827 * @Min: 0
828 * @Max: 8
829 * @Default: 3
830 *
831 * This ini is used to set the maximum number of AP's to be maintained
832 * in LCA [Last Connected AP] list.
833 *
834 * Related: LFR
835 *
836 * Usage: Internal
837 *
838 * </ini>
839 */
840#define CFG_LFR3_ROAM_NUM_DISALLOWED_APS CFG_INI_UINT( \
841 "groam_num_disallowed_aps", \
842 0, \
843 8, \
844 3, \
845 CFG_VALUE_OR_DEFAULT, \
846 "Max number of AP's to maintain in LCA list")
847
848/*
849 * <ini>
850 * enable_5g_band_pref - Enable preference for 5G from INI.
851 * @Min: 0
852 * @Max: 1
853 * @Default: 0
854 * This ini is used to enable 5G preference parameters.
855 *
856 * Related: 5g_rssi_boost_threshold, 5g_rssi_boost_factor, 5g_max_rssi_boost
857 * 5g_rssi_penalize_threshold, 5g_rssi_penalize_factor, 5g_max_rssi_penalize
858 *
859 * Supported Feature: 5G band preference
860 *
861 * Usage: External
862 *
863 * </ini>
864 */
865#define CFG_LFR_ENABLE_5G_BAND_PREF CFG_INI_BOOL( \
866 "enable_5g_band_pref", \
867 0, \
868 "Enable preference for 5G from INI")
869
870/*
871 * <ini>
872 * 5g_rssi_boost_threshold - A_band_boost_threshold above which 5G is favored.
873 * @Min: -55
874 * @Max: -70
875 * @Default: -60
876 * This ini is used to set threshold for 5GHz band preference.
877 *
878 * Related: 5g_rssi_boost_factor, 5g_max_rssi_boost
879 * 5g_rssi_penalize_threshold, 5g_rssi_penalize_factor, 5g_max_rssi_penalize
880 *
881 * Supported Feature: 5G band preference
882 *
883 * Usage: External
884 *
885 * </ini>
886 */
887#define CFG_LFR_5G_RSSI_BOOST_THRESHOLD CFG_INI_INT( \
888 "5g_rssi_boost_threshold", \
889 -55, \
890 -70, \
891 -60, \
892 CFG_VALUE_OR_DEFAULT, \
893 "A_band_boost_threshold above which 5 GHz is favored")
894
895/*
896 * <ini>
897 * 5g_rssi_boost_factor - Factor by which 5GHz RSSI is boosted.
898 * @Min: 0
899 * @Max: 2
900 * @Default: 1
901 * This ini is used to set the 5Ghz boost factor.
902 *
903 * Related: 5g_rssi_boost_threshold, 5g_max_rssi_boost
904 * 5g_rssi_penalize_threshold, 5g_rssi_penalize_factor, 5g_max_rssi_penalize
905 *
906 * Supported Feature: 5G band preference
907 *
908 * Usage: External
909 *
910 * </ini>
911 */
912#define CFG_LFR_5G_RSSI_BOOST_FACTOR CFG_INI_UINT( \
913 "5g_rssi_boost_factor", \
914 0, \
915 2, \
916 1, \
917 CFG_VALUE_OR_DEFAULT, \
918 "Factor by which 5GHz RSSI is boosted")
919
920/*
921 * <ini>
922 * 5g_max_rssi_boost - Maximum boost that can be applied to 5GHz RSSI.
923 * @Min: 0
924 * @Max: 20
925 * @Default: 10
926 * This ini is used to set maximum boost which can be given to a 5Ghz network.
927 *
928 * Related: 5g_rssi_boost_threshold, 5g_rssi_boost_factor
929 * 5g_rssi_penalize_threshold, 5g_rssi_penalize_factor, 5g_max_rssi_penalize
930 *
931 * Supported Feature: 5G band preference
932 *
933 * Usage: External
934 *
935 * </ini>
936 */
937#define CFG_LFR_5G_MAX_RSSI_BOOST CFG_INI_UINT( \
938 "5g_max_rssi_boost", \
939 0, \
940 20, \
941 10, \
942 CFG_VALUE_OR_DEFAULT, \
943 "Maximum boost that can be applied to 5GHz RSSI")
944
945/*
946 * <ini>
947 * 5g_rssi_penalize_threshold - A_band_penalize_threshold above which
948 * 5 GHz is not favored.
949 * @Min: -65
950 * @Max: -80
951 * @Default: -70
952 * This ini is used to set threshold for 5GHz band preference.
953 *
954 * Related: 5g_rssi_penalize_factor, 5g_max_rssi_penalize
955 * 5g_rssi_boost_threshold, 5g_rssi_boost_factor, 5g_max_rssi_boost
956 *
957 * Supported Feature: 5G band preference
958 *
959 * Usage: External
960 *
961 * </ini>
962 */
963#define CFG_LFR_5G_RSSI_PENALIZE_THRESHOLD CFG_INI_INT( \
964 "5g_rssi_penalize_threshold", \
965 -65, \
966 -80, \
967 -70, \
968 CFG_VALUE_OR_DEFAULT, \
969 "A_band_penalize_threshold above which 5 GHz is not favored")
970
971/*
972 * <ini>
973 * 5g_rssi_penalize_factor - Factor by which 5GHz RSSI is penalizeed.
974 * @Min: 0
975 * @Max: 2
976 * @Default: 1
977 * This ini is used to set the 5Ghz penalize factor.
978 *
979 * Related: 5g_rssi_penalize_threshold, 5g_max_rssi_penalize
980 * 5g_rssi_boost_threshold, 5g_rssi_boost_factor, 5g_max_rssi_boost
981 *
982 * Supported Feature: 5G band preference
983 *
984 * Usage: External
985 *
986 * </ini>
987 */
988#define CFG_LFR_5G_RSSI_PENALIZE_FACTOR CFG_INI_UINT( \
989 "5g_rssi_penalize_factor", \
990 0, \
991 2, \
992 1, \
993 CFG_VALUE_OR_DEFAULT, \
994 "Factor by which 5GHz RSSI is penalizeed")
995
996/*
997 * <ini>
998 * 5g_max_rssi_penalize - Maximum penalty that can be applied to 5GHz RSSI.
999 * @Min: 0
1000 * @Max: 20
1001 * @Default: 10
1002 * This ini is used to set maximum penalty which can be given to a 5Ghz network.
1003 *
1004 * Related: 5g_rssi_penalize_threshold, 5g_rssi_penalize_factor
1005 * 5g_rssi_boost_threshold, 5g_rssi_boost_factor, 5g_max_rssi_boost
1006 *
1007 * Supported Feature: 5G band preference
1008 *
1009 * Usage: External
1010 *
1011 * </ini>
1012 */
1013#define CFG_LFR_5G_MAX_RSSI_PENALIZE CFG_INI_UINT( \
1014 "5g_max_rssi_penalize", \
1015 0, \
1016 20, \
1017 10, \
1018 CFG_VALUE_OR_DEFAULT, \
1019 "Maximum penalty that can be applied to 5GHz RSSI")
1020
1021/*
1022 * max_num_pre_auth - Configure max number of pre-auth
1023 * @Min: 0
1024 * @Max: 256
1025 * @Default: 64
1026 *
1027 * This ini is used to configure the data max number of pre-auth
1028 *
1029 * Usage: Internal
1030 *
1031 */
1032#define CFG_LFR_MAX_NUM_PRE_AUTH CFG_UINT( \
1033 "max_num_pre_auth", \
1034 0, \
1035 256, \
1036 64, \
1037 CFG_VALUE_OR_DEFAULT, \
1038 "")
1039
Sourav Mohapatra5ba8da32018-07-16 09:21:15 +05301040/*
1041 * roam_preauth_retry_count
1042 *
1043 * @Min: 1
1044 * @Max: 10
1045 * @Default: 5
1046 *
1047 * The maximum number of software retries for preauth or
1048 * reassoc made before picking up the next candidate for
1049 * connection during roaming.
1050 *
1051 * Related: N/A
1052 *
1053 * Supported Features: Roaming
1054 *
1055 * Usage: Internal/External
1056 *
1057 * </ini>
1058 */
1059#define CFG_LFR3_ROAM_PREAUTH_RETRY_COUNT CFG_INI_INT( \
1060 "roam_preauth_retry_count", \
1061 1, \
1062 10, \
1063 5, \
1064 CFG_VALUE_OR_DEFAULT, \
1065 "The maximum number of software retries for preauth")
1066
1067/*
1068 * <ini>
1069 * roam_preauth_no_ack_timeout
1070 *
1071 * @Min: 5
1072 * @Max: 50
1073 * @Default: 5
1074 *
1075 * Time to wait (in ms) after sending an preauth or reassoc
1076 * request which didn’t have an ack, before considering
1077 * it as a failure and making another software retry.
1078 *
1079 * Related: N/A
1080 *
1081 * Supported Features: Roaming
1082 *
1083 * Usage: Internal/External
1084 *
1085 * </ini>
1086 */
1087#define CFG_LFR3_ROAM_PREAUTH_NO_ACK_TIMEOUT CFG_INI_INT( \
1088 "roam_preauth_no_ack_timeout", \
1089 5, \
1090 50, \
1091 5, \
1092 CFG_VALUE_OR_DEFAULT, \
1093 "Time to wait after sending an preauth or reassoc")
1094
Wu Gao5d23d782018-11-08 16:09:47 +08001095/*
1096 * <ini>
1097 * FastRoamEnabled - Enable fast roaming
1098 * @Min: 0
1099 * @Max: 1
1100 * @Default: 0
1101 *
1102 * This ini is used to inform FW to enable fast roaming
1103 *
1104 * Related: None
1105 *
1106 * Supported Feature: Roaming
1107 *
1108 * Usage: External
1109 *
1110 * </ini>
1111 */
1112#define CFG_LFR_FEATURE_ENABLED CFG_INI_BOOL( \
1113 "FastRoamEnabled", \
1114 0, \
1115 "Enable fast roaming")
1116
1117/*
1118 * <ini>
1119 * MAWCEnabled - Enable/Disable Motion Aided Wireless Connectivity Global
1120 * @Min: 0 - Disabled
1121 * @Max: 1 - Enabled
1122 * @Default: 0
1123 *
1124 * This ini is used to controls the MAWC feature globally.
1125 * MAWC is Motion Aided Wireless Connectivity.
1126 *
1127 * Related: mawc_roam_enabled.
1128 *
1129 * Supported Feature: Roaming and PNO/NLO
1130 *
1131 * Usage: Internal/External
1132 *
1133 * </ini>
1134 */
1135#define CFG_LFR_MAWC_FEATURE_ENABLED CFG_INI_BOOL( \
1136 "MAWCEnabled", \
1137 0, \
1138 "Enable MAWC")
1139
1140/*
1141 * <ini>
1142 * FastTransitionEnabled - Enable fast transition in case of 11r and ese.
1143 * @Min: 0
1144 * @Max: 1
1145 * @Default: 1
1146 *
1147 * This ini is used to turn ON/OFF the whole neighbor roam, pre-auth, reassoc.
1148 * With this turned OFF 11r will completely not work. For 11r this flag has to
1149 * be ON. For ESE fastroam will not work.
1150 *
1151 * Related: None
1152 *
1153 * Supported Feature: Roaming
1154 *
1155 * Usage: External
1156 *
1157 * </ini>
1158 */
1159#define CFG_LFR_FAST_TRANSITION_ENABLED CFG_INI_BOOL( \
1160 "FastTransitionEnabled", \
1161 1, \
1162 "Enable fast transition")
1163
1164/*
1165 * <ini>
1166 * RoamRssiDiff - Enable roam based on rssi
1167 * @Min: 0
1168 * @Max: 30
1169 * @Default: 5
1170 *
1171 * This INI is used to decide whether to Roam or not based on RSSI. AP1 is the
1172 * currently associated AP and AP2 is chosen for roaming. The Roaming will
1173 * happen only if AP2 has better Signal Quality and it has a RSSI better than
1174 * AP2. RoamRssiDiff is the number of units (typically measured in dB) AP2
1175 * is better than AP1.
1176 *
1177 * Related: None
1178 *
1179 * Supported Feature: Roaming
1180 *
1181 * Usage: External
1182 *
1183 * </ini>
1184 */
1185#define CFG_LFR_ROAM_RSSI_DIFF CFG_INI_UINT( \
1186 "RoamRssiDiff", \
1187 0, \
1188 30, \
1189 5, \
1190 CFG_VALUE_OR_DEFAULT, \
1191 "Enable roam based on rssi")
1192
1193/*
1194 * <ini>
1195 * gWESModeEnabled - Enable WES mode
1196 * @Min: 0
1197 * @Max: 1
1198 * @Default: 0
1199 *
1200 * This ini is used to enable/disable Wireless Extended Security mode.
1201 *
1202 * Related: None
1203 *
1204 * Supported Feature: Roaming
1205 *
1206 * Usage: External
1207 *
1208 * </ini>
1209 */
1210#define CFG_LFR_ENABLE_WES_MODE CFG_INI_BOOL( \
1211 "gWESModeEnabled", \
1212 0, \
1213 "Enable WES mode")
1214
1215/*
1216 * <ini>
1217 * gRoamScanOffloadEnabled - Enable Roam Scan Offload
1218 * @Min: 0
1219 * @Max: 1
1220 * @Default: 1
1221 *
1222 * This INI is used to enable Roam Scan Offload in firmware
1223 *
1224 * Related: None
1225 *
1226 * Supported Feature: Roaming
1227 *
1228 * Usage: External
1229 *
1230 * </ini>
1231 */
1232#define CFG_LFR_ROAM_SCAN_OFFLOAD_ENABLED CFG_INI_BOOL( \
1233 "gRoamScanOffloadEnabled", \
1234 1, \
1235 "Enable Roam Scan Offload")
1236
1237/*
1238 * <ini>
1239 * gNeighborScanChannelList - Set channels to be scanned
1240 * by firmware for LFR scan
1241 * @Default: ""
1242 *
1243 * This ini is used to set the channels to be scanned
1244 * by firmware for LFR scan.
1245 *
1246 * Related: None
1247 *
1248 * Supported Feature: LFR Scan
1249 *
1250 * Usage: External
1251 *
1252 * </ini>
1253 */
1254
1255#define CFG_LFR_NEIGHBOR_SCAN_CHANNEL_LIST CFG_INI_STRING( \
1256 "gNeighborScanChanList", \
1257 0, \
1258 CFG_VALID_CHANNEL_LIST_STRING_LEN, \
1259 "", \
1260 "Set channels to be scanned")
1261
1262/*
1263 * <ini>
1264 * gNeighborScanTimerPeriod - Set neighbor scan timer period
1265 * @Min: 3
1266 * @Max: 300
1267 * @Default: 100
1268 *
1269 * This ini is used to set the timer period in secs after
1270 * which neighbor scan is trigerred.
1271 *
1272 * Related: None
1273 *
1274 * Supported Feature: LFR Scan
1275 *
1276 * Usage: External
1277 *
1278 * </ini>
1279 */
1280#define CFG_LFR_NEIGHBOR_SCAN_TIMER_PERIOD CFG_INI_UINT( \
1281 "gNeighborScanTimerPeriod", \
1282 3, \
1283 300, \
1284 100, \
1285 CFG_VALUE_OR_DEFAULT, \
1286 "Neighbor scan timer period")
1287
1288/*
1289 * <ini>
1290 * gRoamRestTimeMin - Set min neighbor scan timer period
1291 * @Min: 3
1292 * @Max: 300
1293 * @Default: 50
1294 *
1295 * This is the min rest time after which firmware will check for traffic
1296 * and if there no traffic it will move to a new channel to scan
1297 * else it will stay on the home channel till gNeighborScanTimerPeriod time
1298 * and then will move to a new channel to scan.
1299 *
1300 * Related: None
1301 *
1302 * Supported Feature: LFR Scan
1303 *
1304 * Usage: External
1305 *
1306 * </ini>
1307 */
1308#define CFG_LFR_NEIGHBOR_SCAN_MIN_TIMER_PERIOD CFG_INI_UINT( \
1309 "gRoamRestTimeMin", \
1310 3, \
1311 300, \
1312 50, \
1313 CFG_VALUE_OR_DEFAULT, \
1314 "Min neighbor scan timer period")
1315
1316/*
1317 * <ini>
1318 * gNeighborLookupThreshold - Set neighbor lookup rssi threshold
1319 * @Min: 10
1320 * @Max: 120
1321 * @Default: 78
1322 *
1323 * This is used to control the RSSI threshold for neighbor lookup.
1324 *
1325 * Related: None
1326 *
1327 * Supported Feature: LFR Scan
1328 *
1329 * Usage: External
1330 *
1331 * </ini>
1332 */
1333#define CFG_LFR_NEIGHBOR_LOOKUP_RSSI_THRESHOLD CFG_INI_UINT( \
1334 "gNeighborLookupThreshold", \
1335 10, \
1336 120, \
1337 78, \
1338 CFG_VALUE_OR_DEFAULT, \
1339 "Neighbor lookup rssi threshold")
1340
1341/*
1342 * <ini>
1343 * gOpportunisticThresholdDiff - Set oppurtunistic threshold diff
1344 * @Min: 0
1345 * @Max: 127
1346 * @Default: 0
1347 *
1348 * This ini is used to set opportunistic threshold diff.
1349 * This parameter is the RSSI diff above neighbor lookup
1350 * threshold, when opportunistic scan should be triggered.
1351 * MAX value is chosen so that this type of scan can be
1352 * always enabled by user.
1353 * MIN value will cause opportunistic scan to be triggered
1354 * in neighbor lookup RSSI range.
1355 *
1356 * Related: None
1357 *
1358 * Supported Feature: LFR Scan
1359 *
1360 * Usage: External
1361 *
1362 * </ini>
1363 */
1364#define CFG_LFR_OPPORTUNISTIC_SCAN_THRESHOLD_DIFF CFG_INI_UINT( \
1365 "gOpportunisticThresholdDiff", \
1366 0, \
1367 127, \
1368 0, \
1369 CFG_VALUE_OR_DEFAULT, \
1370 "Set oppurtunistic threshold diff")
1371
1372/*
1373 * <ini>
1374 * gRoamRescanRssiDiff - Sets RSSI for Scan trigger in firmware
1375 * @Min: 0
1376 * @Max: 100
1377 * @Default: 5
1378 *
1379 * This INI is the drop in RSSI value that will trigger a precautionary
1380 * scan by firmware. Max value is chosen in such a way that this type
1381 * of scan can be disabled by user.
1382 *
1383 * Related: None
1384 *
1385 * Supported Feature: Roaming
1386 *
1387 * Usage: External
1388 *
1389 * </ini>
1390 */
1391#define CFG_LFR_ROAM_RESCAN_RSSI_DIFF CFG_INI_UINT( \
1392 "gRoamRescanRssiDiff", \
1393 0, \
1394 100, \
1395 5, \
1396 CFG_VALUE_OR_DEFAULT, \
1397 "Sets RSSI for Scan trigger in firmware")
1398
1399/*
1400 * <ini>
1401 * gNeighborScanChannelMinTime - Set neighbor scan channel min time
1402 * @Min: 10
1403 * @Max: 40
1404 * @Default: 20
1405 *
1406 * This ini is used to set the minimum time in secs spent on each
1407 * channel in LFR scan inside firmware.
1408 *
1409 * Related: None
1410 *
1411 * Supported Feature: LFR Scan
1412 *
1413 * Usage: External
1414 *
1415 * </ini>
1416 */
1417#define CFG_LFR_NEIGHBOR_SCAN_MIN_CHAN_TIME CFG_INI_UINT( \
1418 "gNeighborScanChannelMinTime", \
1419 10, \
1420 40, \
1421 20, \
1422 CFG_VALUE_OR_DEFAULT, \
1423 "Neighbor scan channel min time")
1424
1425/*
1426 * <ini>
1427 * gNeighborScanChannelMaxTime - Set neighbor scan channel max time
1428 * @Min: 3
1429 * @Max: 300
1430 * @Default: 30
1431 *
1432 * This ini is used to set the maximum time in secs spent on each
1433 * channel in LFR scan inside firmware.
1434 *
1435 * Related: None
1436 *
1437 * Supported Feature: LFR Scan
1438 *
1439 * Usage: External
1440 *
1441 * </ini>
1442 */
1443#define CFG_LFR_NEIGHBOR_SCAN_MAX_CHAN_TIME CFG_INI_UINT( \
1444 "gNeighborScanChannelMaxTime", \
1445 3, \
1446 300, \
1447 30, \
1448 CFG_VALUE_OR_DEFAULT, \
1449 "Neighbor scan channel max time")
1450
1451/*
1452 * <ini>
1453 * gNeighborScanRefreshPeriod - Set neighbor scan refresh period
1454 * @Min: 1000
1455 * @Max: 60000
1456 * @Default: 20000
1457 *
1458 * This ini is used by firmware to set scan refresh period
1459 * in msecs for lfr scan.
1460 *
1461 * Related: None
1462 *
1463 * Supported Feature: LFR Scan
1464 *
1465 * Usage: External
1466 *
1467 * </ini>
1468 */
1469#define CFG_LFR_NEIGHBOR_SCAN_RESULTS_REFRESH_PERIOD CFG_INI_UINT( \
1470 "gNeighborScanRefreshPeriod", \
1471 1000, \
1472 60000, \
1473 20000, \
1474 CFG_VALUE_OR_DEFAULT, \
1475 "Neighbor scan refresh period")
1476
1477/*
1478 * <ini>
1479 * gEmptyScanRefreshPeriod - Set empty scan refresh period
1480 * @Min: 0
1481 * @Max: 60000
1482 * @Default: 0
1483 *
1484 * This ini is used by firmware to set scan period in msecs
1485 * following empty scan results.
1486 *
1487 * Related: None
1488 *
1489 * Supported Feature: LFR Scan
1490 *
1491 * Usage: External
1492 *
1493 * </ini>
1494 */
1495#define CFG_LFR_EMPTY_SCAN_REFRESH_PERIOD CFG_INI_UINT( \
1496 "gEmptyScanRefreshPeriod", \
1497 0, \
1498 60000, \
1499 0, \
1500 CFG_VALUE_OR_DEFAULT, \
1501 "Empty scan refresh period")
1502
1503/*
1504 * <ini>
1505 * gRoamBmissFirstBcnt - Beacon miss count to trigger 1st bmiss event
1506 * @Min: 5
1507 * @Max: 100
1508 * @Default: 10
1509 *
1510 * This ini used to control how many beacon miss will trigger first bmiss
1511 * event. First bmiss event will result in roaming scan.
1512 *
1513 * Related: None
1514 *
1515 * Usage: External
1516 *
1517 * </ini>
1518 */
1519#define CFG_LFR_ROAM_BMISS_FIRST_BCNT CFG_INI_UINT( \
1520 "gRoamBmissFirstBcnt", \
1521 5, \
1522 100, \
1523 10, \
1524 CFG_VALUE_OR_DEFAULT, \
1525 "First beacon miss count")
1526
1527/*
1528 * <ini>
1529 * gRoamBmissFinalBcnt - Beacon miss count to trigger final bmiss event
1530 * @Min: 5
1531 * @Max: 100
1532 * @Default: 20
1533 *
1534 * This ini used to control how many beacon miss will trigger final bmiss
1535 * event. Final bmiss event will make roaming take place or cause the
1536 * indication of final bmiss event.
1537 *
1538 * Related: None
1539 *
1540 * Usage: External
1541 *
1542 * </ini>
1543 */
1544#define CFG_LFR_ROAM_BMISS_FINAL_BCNT CFG_INI_UINT( \
1545 "gRoamBmissFinalBcnt", \
1546 5, \
1547 100, \
1548 20, \
1549 CFG_VALUE_OR_DEFAULT, \
1550 "Final beacon miss count")
1551
1552/*
1553 * <ini>
1554 * gRoamBeaconRssiWeight - Set beacon miss weight
1555 * @Min: 5
1556 * @Max: 16
1557 * @Default: 14
1558 *
1559 * This ini controls how many beacons' RSSI values will be used to calculate
1560 * the average value of RSSI.
1561 *
1562 * Related: None
1563 *
1564 * Usage: External
1565 *
1566 * </ini>
1567 */
1568#define CFG_LFR_ROAM_BEACON_RSSI_WEIGHT CFG_INI_UINT( \
1569 "gRoamBeaconRssiWeight", \
1570 0, \
1571 16, \
1572 14, \
1573 CFG_VALUE_OR_DEFAULT, \
1574 "Beacon miss weight")
1575
1576/*
1577 * <ini>
1578 * gAllowDFSChannelRoam - Allow dfs channel in roam
1579 * @Min: 0
1580 * @Max: 2
1581 * @Default: 0
1582 *
1583 * This ini is used to set default dfs channel
1584 *
1585 * Related: None
1586 *
1587 * Supported Feature: STA
1588 *
1589 * Usage: Internal/External
1590 *
1591 * </ini>
1592 */
1593#define CFG_LFR_ROAMING_DFS_CHANNEL CFG_INI_UINT( \
1594 "gAllowDFSChannelRoam", \
1595 0, \
1596 2, \
1597 0, \
1598 CFG_VALUE_OR_DEFAULT, \
1599 "Allow dfs channel in roam")
1600
1601/*
1602 * <ini>
1603 * gRoamScanHiRssiMaxCount - Sets 5GHz maximum scan count
1604 * @Min: 0
1605 * @Max: 10
1606 * @Default: 3
1607 *
1608 * This INI is used to set maximum scan count in 5GHz
1609 *
1610 * Related: None
1611 *
1612 * Supported Feature: Roaming
1613 *
1614 * Usage: External
1615 *
1616 * </ini>
1617 */
1618#define CFG_LFR_ROAM_SCAN_HI_RSSI_MAXCOUNT CFG_INI_UINT( \
1619 "gRoamScanHiRssiMaxCount", \
1620 0, \
1621 10, \
1622 3, \
1623 CFG_VALUE_OR_DEFAULT, \
1624 "5GHz maximum scan count")
1625
1626/*
1627 * <ini>
1628 * gRoamScanHiRssiDelta - Sets RSSI Delta for scan trigger
1629 * @Min: 0
1630 * @Max: 16
1631 * @Default: 10
1632 *
1633 * This INI is used to set change in RSSI at which scan is triggered
1634 * in 5GHz.
1635 *
1636 * Related: None
1637 *
1638 * Supported Feature: Roaming
1639 *
1640 * Usage: External
1641 *
1642 * </ini>
1643 */
1644#define CFG_LFR_ROAM_SCAN_HI_RSSI_DELTA CFG_INI_UINT( \
1645 "gRoamScanHiRssiDelta", \
1646 0, \
1647 16, \
1648 10, \
1649 CFG_VALUE_OR_DEFAULT, \
1650 "RSSI Delta for scan trigger")
1651
1652/*
1653 * <ini>
1654 * gRoamScanHiRssiDelay - Sets minimum delay between 5GHz scans
1655 * @Min: 5000
1656 * @Max: 0x7fffffff
1657 * @Default: 15000
1658 *
1659 * This INI is used to set the minimum delay between 5GHz scans.
1660 *
1661 * Related: None
1662 *
1663 * Supported Feature: Roaming
1664 *
1665 * Usage: External
1666 *
1667 * </ini>
1668 */
1669#define CFG_LFR_ROAM_SCAN_HI_RSSI_DELAY CFG_INI_UINT( \
1670 "gRoamScanHiRssiDelay", \
1671 5000, \
1672 0x7fffffff, \
1673 15000, \
1674 CFG_VALUE_OR_DEFAULT, \
1675 "Minimum delay between 5GHz scans")
1676
1677/*
1678 * <ini>
1679 * gRoamScanHiRssiUpperBound - Sets upper bound after which 5GHz scan
1680 * @Min: -66
1681 * @Max: 0
1682 * @Default: -30
1683 *
1684 * This INI is used to set the RSSI upper bound above which the 5GHz scan
1685 * will not be performed.
1686 *
1687 * Related: None
1688 *
1689 * Supported Feature: Roaming
1690 *
1691 * Usage: External
1692 *
1693 * </ini>
1694 */
1695#define CFG_LFR_ROAM_SCAN_HI_RSSI_UB CFG_INI_INT( \
1696 "gRoamScanHiRssiUpperBound", \
1697 -66, \
1698 0, \
1699 -30, \
1700 CFG_VALUE_OR_DEFAULT, \
1701 "Upper bound after which 5GHz scan")
1702
1703/*
1704 * <ini>
1705 * gRoamPrefer5GHz - Prefer roaming to 5GHz Bss
1706 * @Min: 0
1707 * @Max: 1
1708 * @Default: 1
1709 *
1710 * This ini is used to inform FW to prefer roaming to 5GHz BSS
1711 *
1712 * Related: None
1713 *
1714 * Supported Feature: Roaming
1715 *
1716 * Usage: External
1717 *
1718 * </ini>
1719 */
1720#define CFG_LFR_ROAM_PREFER_5GHZ CFG_INI_BOOL( \
1721 "gRoamPrefer5GHz", \
1722 1, \
1723 "Prefer roaming to 5GHz Bss")
1724
1725/*
1726 * <ini>
1727 * gRoamIntraBand - Prefer roaming within Band
1728 * @Min: 0
1729 * @Max: 1
1730 * @Default: 0
1731 *
1732 * This ini is used to inform FW to prefer roaming within band
1733 *
1734 * Related: None
1735 *
1736 * Supported Feature: Roaming
1737 *
1738 * Usage: External
1739 *
1740 * </ini>
1741 */
1742#define CFG_LFR_ROAM_INTRA_BAND CFG_INI_BOOL( \
1743 "gRoamIntraBand", \
1744 0, \
1745 "Prefer roaming within Band")
1746
1747/*
1748 * <ini>
1749 * gRoamScanNProbes - Sets the number of probes to be sent for firmware roaming
1750 * @Min: 1
1751 * @Max: 10
1752 * @Default: 2
1753 *
1754 * This INI is used to set the maximum number of probes the firmware can send
1755 * for firmware internal roaming cases.
1756 *
1757 * Related: None
1758 *
1759 * Supported Feature: Roaming
1760 *
1761 * Usage: External
1762 *
1763 * </ini>
1764 */
1765#define CFG_LFR_ROAM_SCAN_N_PROBES CFG_INI_UINT( \
1766 "gRoamScanNProbes", \
1767 1, \
1768 10, \
1769 2, \
1770 CFG_VALUE_OR_DEFAULT, \
1771 "The number of probes to be sent for firmware roaming")
1772
1773/*
1774 * <ini>
1775 * gRoamScanHomeAwayTime - Sets the Home Away Time to firmware
1776 * @Min: 0
1777 * @Max: 300
1778 * @Default: 0
1779 *
1780 * Home Away Time should be at least equal to (gNeighborScanChannelMaxTime
1781 * + (2*RFS)), where RFS is the RF Switching time(3). It is twice RFS
1782 * to consider the time to go off channel and return to the home channel.
1783 *
1784 * Related: gNeighborScanChannelMaxTime
1785 *
1786 * Supported Feature: Roaming
1787 *
1788 * Usage: External
1789 *
1790 * </ini>
1791 */
1792#define CFG_LFR_ROAM_SCAN_HOME_AWAY_TIME CFG_INI_UINT( \
1793 "gRoamScanHomeAwayTime", \
1794 0, \
1795 300, \
1796 0, \
1797 CFG_VALUE_OR_DEFAULT, \
1798 "the home away time to firmware")
1799
1800/*
1801 * <ini>
1802 * gDelayBeforeVdevStop - wait time for tx complete before vdev stop
1803 * @Min: 2
1804 * @Max: 200
1805 * @Default: 20
1806 *
1807 * This INI is used to set wait time for tx complete before vdev stop.
1808 *
1809 * Related: None
1810 *
1811 * Usage: External
1812 *
1813 * </ini>
1814 */
1815#define CFG_LFR_DELAY_BEFORE_VDEV_STOP CFG_INI_UINT( \
1816 "gDelayBeforeVdevStop", \
1817 2, \
1818 200, \
1819 20, \
1820 CFG_VALUE_OR_DEFAULT, \
1821 "wait time for tx complete before vdev stop")
Pragaspathi Thilagaraj69f0b692018-12-16 22:23:04 +05301822/*
1823 * <ini>
1824 * enable_bss_load_roam_trigger - enable/disable bss load based roam trigger
1825 * @Min: 0
1826 * @Max: 1
Pragaspathi Thilagaraj39d61602018-12-24 14:46:53 +05301827 * @Default: 0
Pragaspathi Thilagaraj69f0b692018-12-16 22:23:04 +05301828 *
1829 * This ini when enabled, allows the firmware to roam when bss load outpaces
1830 * the configured bss load threshold. When this ini is disabled, firmware
1831 * doesn't consider bss load values to trigger roam.
1832 *
1833 * Related: None
1834 *
1835 * Supported Feature: Roaming
1836 *
1837 * Usage: External
1838 *
1839 * </ini>
1840 */
1841#define CFG_ENABLE_BSS_LOAD_TRIGGERED_ROAM CFG_INI_BOOL( \
1842 "enable_bss_load_roam_trigger", \
Pragaspathi Thilagaraj39d61602018-12-24 14:46:53 +05301843 0, \
Pragaspathi Thilagaraj69f0b692018-12-16 22:23:04 +05301844 "enable bss load triggered roaming")
1845
1846/*
1847 * <ini>
1848 * bss_load_threshold - bss load above which the STA should trigger roaming
1849 * @Min: 0
1850 * @Max: 100
1851 * @Default: 70
1852 *
1853 * When the bss laod value that is sampled exceeds this threshold, firmware
1854 * will trigger roaming if bss load trigger is enabled.
1855 *
1856 * Related: None
1857 *
1858 * Supported Feature: Roaming
1859 *
1860 * Usage: External
1861 *
1862 * </ini>
1863 */
1864#define CFG_BSS_LOAD_THRESHOLD CFG_INI_UINT( \
1865 "bss_load_threshold", \
1866 0, \
1867 100, \
1868 70, \
1869 CFG_VALUE_OR_DEFAULT, \
1870 "bss load threshold")
1871
Pragaspathi Thilagaraj39d61602018-12-24 14:46:53 +05301872/*
1873 * <ini>
1874 * bss_load_sample_time - Time in milliseconds for which the bss load values
1875 * obtained from the beacons is sampled.
1876 * @Min: 0
1877 * @Max: 0xffffffff
1878 * @Default: 10000
1879 *
1880 * Related: None
1881 *
1882 * Supported Feature: Roaming
1883 *
1884 * Usage: External
1885 *
1886 * </ini>
1887 */
1888#define CFG_BSS_LOAD_SAMPLE_TIME CFG_INI_UINT( \
1889 "bss_load_sample_time", \
1890 0, \
1891 0xffffffff, \
1892 10000, \
1893 CFG_VALUE_OR_DEFAULT, \
1894 "bss load sampling time")
Wu Gao5d23d782018-11-08 16:09:47 +08001895
Wu Gao6294afc2019-01-05 00:00:58 +08001896/*
1897 * <ini>
Pragaspathi Thilagaraj2b8ea352019-04-12 02:23:50 +05301898 * bss_load_trigger_5g_rssi_threshold - Current AP minimum RSSI in dBm below
1899 * which roaming can be triggered if BSS load exceeds bss_load_threshold.
1900 * @Min: -120
1901 * @Max: 0
1902 * @Default: -70
1903 *
1904 * If connected AP is in 5Ghz, then consider bss load roam triggered only if
1905 * load % > bss_load_threshold && connected AP rssi is worse than
1906 * bss_load_trigger_5g_rssi_threshold
1907 *
1908 * Related: "bss_load_threshold"
1909 *
1910 * Supported Feature: Roaming
1911 *
1912 * Usage: Internal/External
1913 *
1914 * </ini>
1915 */
1916#define CFG_BSS_LOAD_TRIG_5G_RSSI_THRES CFG_INI_INT( \
1917 "bss_load_trigger_5g_rssi_threshold", \
1918 -120, \
1919 0, \
1920 -70, \
1921 CFG_VALUE_OR_DEFAULT, \
1922 "Minimum RSSI of current AP in 5GHz band for BSS load roam trigger")
1923
1924/*
1925 * <ini>
1926 * bss_load_trigger_2g_rssi_threshold - Current AP minimum RSSI in dBm below
1927 * which roaming can be triggered if BSS load exceeds bss_load_threshold.
1928 * @Min: -120
1929 * @Max: 0
1930 * @Default: -60
1931 *
1932 * If connected AP is in 2Ghz, then consider bss load roam triggered only if
1933 * load % > bss_load_threshold && connected AP rssi is worse than
1934 * bss_load_trigger_2g_rssi_threshold.
1935 *
1936 * Related: "bss_load_threshold"
1937 *
1938 * Supported Feature: Roaming
1939 *
1940 * Usage: Internal/External
1941 *
1942 * </ini>
1943 */
1944#define CFG_BSS_LOAD_TRIG_2G_RSSI_THRES CFG_INI_INT( \
1945 "bss_load_trigger_2g_rssi_threshold", \
1946 -120, \
1947 0, \
1948 -60, \
1949 CFG_VALUE_OR_DEFAULT, \
1950 "Minimum RSSI of current AP in 2.4GHz band for BSS load roam trigger")
1951
1952/*
1953 * <ini>
Wu Gao6294afc2019-01-05 00:00:58 +08001954 * ho_delay_for_rx - Delay hand-off (in msec) by this duration to receive
1955 * pending rx frames from current BSS
1956 * @Min: 0
1957 * @Max: 200
1958 * @Default: 0
1959 *
1960 * For LFR 3.0 roaming scenario, once roam candidate is found, firmware
1961 * waits for minimum this much duration to receive pending rx frames from
1962 * current BSS before switching to new channel for handoff to new AP.
1963 *
1964 * Related: None
1965 *
1966 * Supported Feature: Roaming
1967 *
1968 * Usage: External
1969 *
1970 * </ini>
1971 */
1972#define CFG_LFR3_ROAM_HO_DELAY_FOR_RX CFG_INI_UINT( \
1973 "ho_delay_for_rx", \
1974 0, \
1975 200, \
1976 0, \
1977 CFG_VALUE_OR_DEFAULT, \
1978 "Delay Hand-off by this duration to receive")
1979
1980/*
1981 * <ini>
1982 * min_delay_btw_roam_scans - Min duration (in sec) allowed btw two
1983 * consecutive roam scans
1984 * @Min: 0
1985 * @Max: 60
1986 * @Default: 10
1987 *
1988 * Roam scan is not allowed if duration between two consecutive
1989 * roam scans is less than this time.
1990 *
1991 * Related: None
1992 *
1993 * Supported Feature: Roaming
1994 *
1995 * Usage: External
1996 *
1997 * </ini>
1998 */
1999#define CFG_LFR_MIN_DELAY_BTW_ROAM_SCAN CFG_INI_UINT( \
2000 "min_delay_btw_roam_scans", \
2001 0, \
2002 60, \
2003 10, \
2004 CFG_VALUE_OR_DEFAULT, \
2005 "Min duration")
2006
2007/*
2008 * <ini>
2009 * roam_trigger_reason_bitmask - Contains roam_trigger_reasons
2010 * @Min: 0
2011 * @Max: 0xFFFFFFFF
2012 * @Default: 0x10DA
2013 *
2014 * Bitmask containing roam_trigger_reasons for which
2015 * min_delay_btw_roam_scans constraint should be applied.
2016 * Currently supported bit positions are as follows:
2017 * Bit 0 is reserved in the firmware.
2018 * WMI_ROAM_TRIGGER_REASON_PER - 1
2019 * WMI_ROAM_TRIGGER_REASON_BMISS - 2
2020 * WMI_ROAM_TRIGGER_REASON_LOW_RSSI - 3
2021 * WMI_ROAM_TRIGGER_REASON_HIGH_RSSI - 4
2022 * WMI_ROAM_TRIGGER_REASON_PERIODIC - 5
2023 * WMI_ROAM_TRIGGER_REASON_MAWC - 6
2024 * WMI_ROAM_TRIGGER_REASON_DENSE - 7
2025 * WMI_ROAM_TRIGGER_REASON_BACKGROUND - 8
2026 * WMI_ROAM_TRIGGER_REASON_FORCED - 9
2027 * WMI_ROAM_TRIGGER_REASON_BTM - 10
2028 * WMI_ROAM_TRIGGER_REASON_UNIT_TEST - 11
2029 * WMI_ROAM_TRIGGER_REASON_BSS_LOAD - 12
Pragaspathi Thilagaraj14f72de2019-03-28 23:12:51 +05302030 * WMI_ROAM_TRIGGER_REASON_DEAUTH - 13
2031 * WMI_ROAM_TRIGGER_REASON_IDLE - 14
2032 * WMI_ROAM_TRIGGER_REASON_MAX - 15
Wu Gao6294afc2019-01-05 00:00:58 +08002033 *
2034 * For Ex: 0xDA (PER, LOW_RSSI, HIGH_RSSI, MAWC, DENSE)
2035 *
2036 * Related: None
2037 *
2038 * Supported Feature: Roaming
2039 *
2040 * Usage: External
2041 *
2042 * </ini>
2043 */
2044#define CFG_LFR_ROAM_SCAN_TRIGGER_REASON_BITMASK CFG_INI_UINT( \
2045 "roam_trigger_reason_bitmask", \
2046 0, \
2047 0xFFFFFFFF, \
2048 0x10DA, \
2049 CFG_VALUE_OR_DEFAULT, \
2050 "Contains roam_trigger_reasons")
2051
2052/*
2053 * <ini>
2054 * enable_ftopen - enable/disable FT open feature
2055 * @Min: 0
2056 * @Max: 1
2057 * @Default: 1
2058 *
2059 * This INI is used to enable/disable FT open feature
2060 *
2061 * Related: None
2062 *
2063 * Supported Feature: Roaming
2064 *
2065 * Usage: External
2066 *
2067 * </ini>
2068 */
2069#define CFG_LFR_ROAM_FT_OPEN_ENABLE CFG_INI_BOOL( \
2070 "enable_ftopen", \
2071 1, \
2072 "enable/disable FT open feature")
2073
2074/*
2075 * <ini>
2076 * roam_force_rssi_trigger - To force RSSI trigger
2077 * irrespective of channel list type
2078 * @Min: 0
2079 * @Max: 1
2080 * @Default: 1
2081 *
2082 * This ini is used to set roam scan mode
2083 * WMI_ROAM_SCAN_MODE_RSSI_CHANGE, irrespective of whether
2084 * channel list type is CHANNEL_LIST_STATIC or not
2085 *
2086 * Related: None
2087 *
2088 * Supported Feature: Roaming
2089 *
2090 * Usage: External
2091 *
2092 * </ini>
2093 */
2094#define CFG_LFR_ROAM_FORCE_RSSI_TRIGGER CFG_INI_BOOL( \
2095 "roam_force_rssi_trigger", \
2096 1, \
2097 "To force RSSI trigger")
2098
Wu Gao5d23d782018-11-08 16:09:47 +08002099#ifdef WLAN_FEATURE_ROAM_OFFLOAD
2100/*
2101 * <ini>
2102 * gRoamOffloadEnabled - enable/disable roam offload feature
2103 * @Min: 0
2104 * @Max: 1
2105 * @Default: 1
2106 *
2107 * This INI is used to enable/disable roam offload feature
2108 *
2109 * Related: None
2110 *
2111 * Supported Feature: Roaming
2112 *
2113 * Usage: External
2114 *
2115 * </ini>
2116 */
2117#define CFG_LFR3_ROAMING_OFFLOAD CFG_INI_BOOL( \
2118 "gRoamOffloadEnabled", \
2119 1, \
2120 "enable roam offload")
2121
Pragaspathi Thilagaraj14f72de2019-03-28 23:12:51 +05302122/*
2123 * <ini>
2124 * enable_disconnect_roam_offload - Enable/Disable emergency roaming during
2125 * deauth/disassoc
2126 * @Min: 0 - Disabled
2127 * @Max: 1 - Enabled
2128 * @Default: 1
2129 *
2130 * When this ini is enabled firmware will trigger roam scan and roam to a new ap
2131 * if candidate is found and it will not send the deauth/disassoc frame to
2132 * the host driver.
2133 * If roaming fails after this deauth, then firmware will send
2134 * WMI_ROAM_REASON_DEAUTH event to the host. If roaming is successful, driver
2135 * follows the normal roam synch event path.
2136 *
2137 * Supported Feature: Roaming
2138 *
2139 * Usage: Internal/External
2140 *
2141 * </ini>
2142 */
2143#define CFG_LFR_ENABLE_DISCONNECT_ROAM CFG_INI_BOOL( \
2144 "enable_disconnect_roam_offload", \
2145 true, \
2146 "Enable/Disable roaming on deauth/disassoc from AP")
2147
2148/*
2149 * <ini>
2150 * enable_idle_roam - Enable/Disable idle roaming
2151 * @Min: 0 - Disabled
2152 * @Max: 1 - Enabled
2153 * @Default: 0
2154 *
2155 * When this ini is enabled firmware will trigger roam scan and roam to a new
2156 * ap if current connected AP rssi falls below the threshold. To consider the
2157 * connection as idle, the following conditions should be met if this ini
2158 * "enable_idle_roam" is enabled:
2159 * 1. User space sends "SET SUSPENDMODE" command with value 0.
2160 * 2. No TX/RX data for idle time configured via ini "idle_roam_inactive_time".
2161 * 3. Connected AP rssi change doesn't exceed a specific delta value.
2162 * (configured via ini idle_roam_rssi_delta)
2163 * 4. Connected AP rssi falls below minimum rssi (configured via ini
2164 * "idle_roam_min_rssi").
2165 *
2166 * Supported Feature: Roaming
2167 *
2168 * Usage: Internal/External
2169 *
2170 * </ini>
2171 */
2172#define CFG_LFR_ENABLE_IDLE_ROAM CFG_INI_BOOL( \
2173 "enable_idle_roam", \
2174 false, \
2175 "Enable/Disable idle roam")
2176
2177/*
2178 * <ini>
2179 * idle_roam_rssi_delta - This threshold is the criteria to decide whether DUT
2180 * is idle or moving. If rssi delta is more than configured thresold then its
2181 * considered as not idle. RSSI delta is entered in dBm. Idle roaming can be
2182 * triggered if the connected AP rssi change exceeds or falls below the
2183 * rssi delta and if other criteria of ini "enable_idle_roam" is met
2184 * @Min: 0
2185 * @Max: 50
2186 * @Default: 5
2187 *
2188 * Related: enable_idle_roam
2189 *
2190 * Supported Feature: Roaming
2191 *
2192 * Usage: Internal/External
2193 *
2194 * </ini>
2195 */
2196#define CFG_LFR_IDLE_ROAM_RSSI_DELTA CFG_INI_UINT( \
2197 "idle_roam_rssi_delta", \
2198 0, \
2199 50, \
2200 5, \
2201 CFG_VALUE_OR_DEFAULT, \
2202 "Configure RSSI delta to start idle roam")
2203
2204/*
2205 * <ini>
2206 * idle_roam_inactive_time - Time duration in millseconds for which the
2207 * connection is idle.
2208 * @Min: 0
2209 * @Max: 0xFFFFFFFF
2210 * @Default: 10000
2211 *
2212 * This ini is used to configure the time in seconds for which the connection
2213 * candidate is idle and after which idle roam scan can be triggered if
2214 * other criteria of ini "enable_idle_roam" is met.
2215 *
2216 * Related: enable_idle_roam
2217 *
2218 * Supported Feature: Roaming
2219 *
2220 * Usage: Internal/External
2221 *
2222 * </ini>
2223 */
2224#define CFG_LFR_IDLE_ROAM_INACTIVE_TIME CFG_INI_UINT( \
2225 "idle_roam_inactive_time", \
2226 0, \
2227 0xFFFFFFFF, \
2228 10000, \
2229 CFG_VALUE_OR_DEFAULT, \
2230 "Configure RSSI delta to start idle roam")
2231
2232/*
2233 * <ini>
2234 * idle_data_packet_count - No of tx/rx packets above which the connection is
2235 * not idle.
2236 * @Min: 0
2237 * @Max: 0xFFFFFFFF
2238 * @Default: 10
2239 *
2240 * This ini is used to configure the acceptable number of tx/rx packets below
2241 * which the connection is idle. Ex: If idle_data_packet_count is 10
2242 * and if the tx/rx packet count is less than 10, the connection is
2243 * idle. If there are more than 10 packets, the connection is active one.
2244 *
2245 * Related: enable_idle_roam
2246 *
2247 * Supported Feature: Roaming
2248 *
2249 * Usage: Internal/External
2250 *
2251 * </ini>
2252 */
2253#define CFG_LFR_IDLE_ROAM_PACKET_COUNT CFG_INI_UINT( \
2254 "idle_data_packet_count", \
2255 0, \
2256 0xFFFFFFFF, \
2257 10, \
2258 CFG_VALUE_OR_DEFAULT, \
2259 "Configure idle packet count")
2260
2261/*
2262 * <ini>
2263 * idle_roam_min_rssi - Minimum RSSI of connected AP, below which
2264 * idle roam scan can be triggered if other criteria of ini "enable_idle_roam"
2265 * is met.
2266 * @Min: -96
2267 * @Max: 0
2268 * @Default: -65
2269 *
2270 * Related: enable_idle_roam
2271 *
2272 * Supported Feature: Roaming
2273 *
2274 * Usage: Internal/External
2275 *
2276 * </ini>
2277 */
2278#define CFG_LFR_IDLE_ROAM_MIN_RSSI CFG_INI_INT( \
2279 "idle_roam_min_rssi", \
2280 -96, \
2281 0, \
2282 -65, \
2283 CFG_VALUE_OR_DEFAULT, \
2284 "Configure idle roam minimum RSSI")
2285
2286/*
2287 * <ini>
2288 * idle_roam_band - Band on which idle roam scan will be
2289 * enabled
2290 * @Min: 0
2291 * @Max: 2
2292 * @Default: 0
2293 *
2294 * Value 0 - Allow idle roam on both bands
2295 * Value 1 - Allow idle roam only on 2G band
2296 * Value 2 - Allow idle roam only on 5G band
2297 *
2298 * Related: enable_idle_roam
2299 *
2300 * Supported Feature: Roaming
2301 *
2302 * Usage: Internal/External
2303 *
2304 * </ini>
2305 */
2306#define CFG_LFR_IDLE_ROAM_BAND CFG_INI_UINT( \
2307 "idle_roam_band", \
2308 0, \
2309 2, \
2310 0, \
2311 CFG_VALUE_OR_DEFAULT, \
2312 "Band on which idle roam needs to be enabled")
2313
2314#define ROAM_OFFLOAD_ALL \
2315 CFG(CFG_LFR3_ROAMING_OFFLOAD) \
2316 CFG(CFG_LFR_ENABLE_DISCONNECT_ROAM) \
2317 CFG(CFG_LFR_ENABLE_IDLE_ROAM) \
2318 CFG(CFG_LFR_IDLE_ROAM_RSSI_DELTA) \
2319 CFG(CFG_LFR_IDLE_ROAM_INACTIVE_TIME) \
2320 CFG(CFG_LFR_IDLE_ROAM_PACKET_COUNT) \
2321 CFG(CFG_LFR_IDLE_ROAM_MIN_RSSI) \
2322 CFG(CFG_LFR_IDLE_ROAM_BAND) \
2323
Wu Gao5d23d782018-11-08 16:09:47 +08002324#else
2325#define ROAM_OFFLOAD_ALL
2326#endif
2327
2328#ifdef FEATURE_WLAN_ESE
2329/*
2330 * <ini>
2331 * EseEnabled - Enable ESE feature
2332 * @Min: 0
2333 * @Max: 1
2334 * @Default: 0
2335 *
2336 * This ini is used to enable/disable ESE feature
2337 *
2338 * Related: None
2339 *
2340 * Supported Feature: Roaming
2341 *
2342 * Usage: External
2343 *
2344 * </ini>
2345 */
2346#define CFG_LFR_ESE_FEATURE_ENABLED CFG_INI_BOOL( \
2347 "EseEnabled", \
2348 0, \
2349 "Enable ESE")
2350#define LFR_ESE_ALL CFG(CFG_LFR_ESE_FEATURE_ENABLED)
2351#else
2352#define LFR_ESE_ALL
2353#endif
2354
Wu Gao6294afc2019-01-05 00:00:58 +08002355#ifdef FEATURE_LFR_SUBNET_DETECTION
2356/*
2357 * <ini>
2358 * gLFRSubnetDetectionEnable - Enable LFR3 subnet detection
2359 * @Min: 0
2360 * @Max: 1
2361 * @Default: 1
2362 *
2363 * Enable IP subnet detection during legacy fast roming version 3. Legacy fast
2364 * roaming could roam across IP subnets without host processors' knowledge.
2365 * This feature enables firmware to wake up the host processor if it
2366 * successfully determines change in the IP subnet. Change in IP subnet could
2367 * potentially cause disruption in IP connnectivity if IP address is not
2368 * refreshed.
2369 *
2370 * Related: None
2371 *
2372 * Supported Feature: Roaming
2373 *
2374 * Usage: External
2375 *
2376 * </ini>
2377 */
2378#define CFG_LFR3_ENABLE_SUBNET_DETECTION CFG_INI_BOOL( \
2379 "gLFRSubnetDetectionEnable", \
2380 1, \
2381 "Enable LFR3 subnet detection")
2382
2383#define LFR_SUBNET_DETECTION_ALL CFG(CFG_LFR3_ENABLE_SUBNET_DETECTION)
2384#else
2385#define LFR_SUBNET_DETECTION_ALL
2386#endif
2387
Pragaspathi Thilagaraj1f3f99f2019-04-24 23:48:47 +05302388#ifdef WLAN_ADAPTIVE_11R
2389/*
2390 * <ini>
2391 * adaptive_11r - Enable/disable adaptive 11r feature.
2392 * @Min: 0
2393 * @Max: 1
2394 * @Default: 0
2395 *
2396 * Adaptive 11r feature enables the AP to support FT-AKM without
2397 * configuring the FT-AKM in the network. The AP will advertise non-FT akm
2398 * with a vendor specific IE having Adaptive 11r bit set to 1 in the IE data.
2399 * The AP also advertises the MDE in beacon/probe response.
2400 *
2401 * STA should check the adaptive 11r capability if the AP advertises MDE in
2402 * beacon/probe and adaptive 11r capability in vendor specific IE. If adaptive
2403 * 11r capability is found, STA can advertise the FT equivalent of the non-FT
2404 * AKM and connect with 11r protocol.
2405 *
2406 * Related: None.
2407 *
2408 * Supported Feature: Fast BSS Transition
2409 *
2410 * Usage: External
2411 *
2412 * </ini>
2413 */
2414#define CFG_ADAPTIVE_11R CFG_INI_BOOL( \
2415 "enable_adaptive_11r", \
2416 false, \
2417 "Enable/disable adaptive 11r support")
2418
2419#define ADAPTIVE_11R_ALL CFG(CFG_ADAPTIVE_11R)
2420#else
2421#define ADAPTIVE_11R_ALL
2422#endif
2423
Abhinav Kumar990fea62019-02-14 12:38:38 +05302424/*
2425 * <ini>
2426 * roaming_scan_policy - To config roaming scan policy
2427 * @Min: 0
2428 * @Max: 1
2429 * @Default: 0
2430 *
2431 * This ini is used to configure roaming scan behavior from HOST
2432 * 0 : DBS scan
2433 * 1 : Non-DBS scan
2434 *
2435 * Related: None
2436 *
2437 * Supported Feature: Roaming
2438 *
2439 * Usage: External
2440 *
2441 * </ini>
2442 */
2443#define CFG_ROAM_SCAN_SCAN_POLICY CFG_INI_BOOL( \
2444 "roaming_scan_policy", \
2445 0, \
2446 "Config roam scan policy")
2447
Pragaspathi Thilagaraj2b8ea352019-04-12 02:23:50 +05302448/*
2449 * <ini>
2450 * roam_scan_inactivity_time - Device inactivity monitoring time in
2451 * milliseconds for which the device is considered to be inactive with data
2452 * packets count is less than configured roam_inactive_data_count.
2453 *
2454 * @Min: 0
2455 * @Max: 0xFFFFFFFF
2456 * @Default: 0
2457 *
2458 * The below three ini values are used to control the roam scan after the
2459 * firmware gets empty roam scan results during periodic roam scans.
2460 * 1. roam_scan_inactivity_time
2461 * 2. roam_inactive_data_count
2462 * 3. roam_scan_period_after_inactivity
2463 * The first two ini "roam_scan_inactivity_time" and "roam_inactive_data_count"
2464 * is frames the criteria to detect if the DUT is inactive. If the device is
2465 * identified to be inactive based on the above two ini, then the value,
2466 * "roam_scan_period_after_inactivity" will be used as periodic roam scan
2467 * duration.
2468 *
2469 * Related: roam_inactive_data_count
2470 *
2471 * Supported Feature: Roaming
2472 *
2473 * Usage: External
2474 *
2475 * </ini>
2476 */
2477#define CFG_ROAM_SCAN_INACTIVITY_TIME CFG_INI_UINT( \
2478 "roam_scan_inactivity_time", \
2479 0, \
2480 0xFFFFFFFF, \
2481 0, \
2482 CFG_VALUE_OR_DEFAULT, \
2483 "Device inactivity monitoring time")
2484
2485/*
2486 * <ini>
2487 * roam_inactive_data_count - Maximum allowed data packets count during
2488 * roam_scan_inactivity_time.
2489 *
2490 * @Min: 0
2491 * @Max: 0xFFFFFFFF
2492 * @Default: 10
2493 *
2494 * The DUT is said to be inactive only if the data packets count
2495 * during this roam_scan_inactivity_time is less than the configured
2496 * roam_inactive_data_count.
2497 *
2498 * Related: roam_scan_inactivity_time
2499 *
2500 * Supported Feature: Roaming
2501 *
2502 * Usage: External
2503 *
2504 * </ini>
2505 */
2506#define CFG_ROAM_INACTIVE_COUNT CFG_INI_UINT( \
2507 "roam_inactive_data_count", \
2508 0, \
2509 0xFFFFFFFF, \
2510 10, \
2511 CFG_VALUE_OR_DEFAULT, \
2512 "Roam scan inactivity period data pkt count")
2513
2514/*
2515 * <ini>
2516 * roam_scan_period_after_inactivity - Roam scan duration in ms after device is
2517 * out of inactivity state.
2518 *
2519 * @Min: 0
2520 * @Max: 0xFFFFFFFF
2521 * @Default: 120000
2522 *
2523 * If there is empty scan results during roam scan, firmware will move to
2524 * roam scan inactive state if roam_scan_inactivity and
2525 * roam_inactive_data_count criteria are met.
2526 * This ini is used to configure the roam scan duration in ms once the
2527 * inactivity is finished and roam scan can be started.
2528 *
2529 * Related: roam_scan_inactivity_time, roam_inactive_data_count
2530 *
2531 * Supported Feature: Roaming
2532 *
2533 * Usage: External
2534 *
2535 * </ini>
2536 */
2537#define CFG_POST_INACTIVITY_ROAM_SCAN_PERIOD CFG_INI_UINT( \
2538 "roam_scan_period_after_inactivity", \
2539 0, \
2540 0xFFFFFFFF, \
2541 120000, \
2542 CFG_VALUE_OR_DEFAULT, \
2543 "Roam scan period post inactivity")
2544
Wu Gao55f21712018-09-17 10:57:49 +08002545#define CFG_LFR_ALL \
2546 CFG(CFG_LFR_MAWC_ROAM_ENABLED) \
2547 CFG(CFG_LFR_MAWC_ROAM_TRAFFIC_THRESHOLD) \
2548 CFG(CFG_LFR_MAWC_ROAM_AP_RSSI_THRESHOLD) \
2549 CFG(CFG_LFR_MAWC_ROAM_RSSI_HIGH_ADJUST) \
2550 CFG(CFG_LFR_MAWC_ROAM_RSSI_LOW_ADJUST) \
2551 CFG(CFG_LFR_ROAM_RSSI_ABS_THRESHOLD) \
2552 CFG(CFG_LFR_5G_RSSI_THRESHOLD_OFFSET) \
2553 CFG(CFG_LFR_ENABLE_FAST_ROAM_IN_CONCURRENCY) \
Wu Gao55f21712018-09-17 10:57:49 +08002554 CFG(CFG_LFR_EARLY_STOP_SCAN_ENABLE) \
2555 CFG(CFG_LFR_EARLY_STOP_SCAN_MIN_THRESHOLD) \
2556 CFG(CFG_LFR_EARLY_STOP_SCAN_MAX_THRESHOLD) \
2557 CFG(CFG_LFR_FIRST_SCAN_BUCKET_THRESHOLD) \
Wu Gao55f21712018-09-17 10:57:49 +08002558 CFG(CFG_LFR_ROAM_DENSE_TRAFFIC_THRESHOLD) \
2559 CFG(CFG_LFR_ROAM_DENSE_RSSI_THRE_OFFSET) \
2560 CFG(CFG_LFR_ROAM_DENSE_MIN_APS) \
2561 CFG(CFG_LFR_ROAM_BG_SCAN_BAD_RSSI_THRESHOLD) \
2562 CFG(CFG_LFR_ROAM_BG_SCAN_CLIENT_BITMAP) \
2563 CFG(CFG_LFR_ROAM_BG_SCAN_BAD_RSSI_OFFSET_2G) \
2564 CFG(CFG_LFR_ADAPTIVE_ROAMSCAN_DWELL_MODE) \
2565 CFG(CFG_LFR_PER_ROAM_ENABLE) \
2566 CFG(CFG_LFR_PER_ROAM_CONFIG_HIGH_RATE_TH) \
2567 CFG(CFG_LFR_PER_ROAM_CONFIG_LOW_RATE_TH) \
2568 CFG(CFG_LFR_PER_ROAM_CONFIG_RATE_TH_PERCENT) \
2569 CFG(CFG_LFR_PER_ROAM_REST_TIME) \
2570 CFG(CFG_LFR_PER_ROAM_MONITOR_TIME) \
2571 CFG(CFG_LFR_PER_ROAM_MIN_CANDIDATE_RSSI) \
2572 CFG(CFG_LFR3_ROAM_DISALLOW_DURATION) \
2573 CFG(CFG_LFR3_ROAM_RSSI_CHANNEL_PENALIZATION) \
2574 CFG(CFG_LFR3_ROAM_NUM_DISALLOWED_APS) \
2575 CFG(CFG_LFR_ENABLE_5G_BAND_PREF) \
2576 CFG(CFG_LFR_5G_RSSI_BOOST_THRESHOLD) \
2577 CFG(CFG_LFR_5G_RSSI_BOOST_FACTOR) \
2578 CFG(CFG_LFR_5G_MAX_RSSI_BOOST) \
2579 CFG(CFG_LFR_5G_RSSI_PENALIZE_THRESHOLD) \
2580 CFG(CFG_LFR_5G_RSSI_PENALIZE_FACTOR) \
2581 CFG(CFG_LFR_5G_MAX_RSSI_PENALIZE) \
Sourav Mohapatra5ba8da32018-07-16 09:21:15 +05302582 CFG(CFG_LFR_MAX_NUM_PRE_AUTH) \
2583 CFG(CFG_LFR3_ROAM_PREAUTH_RETRY_COUNT) \
Wu Gao5d23d782018-11-08 16:09:47 +08002584 CFG(CFG_LFR3_ROAM_PREAUTH_NO_ACK_TIMEOUT) \
2585 CFG(CFG_LFR_FEATURE_ENABLED) \
2586 CFG(CFG_LFR_MAWC_FEATURE_ENABLED) \
2587 CFG(CFG_LFR_FAST_TRANSITION_ENABLED) \
2588 CFG(CFG_LFR_ROAM_RSSI_DIFF) \
2589 CFG(CFG_LFR_ENABLE_WES_MODE) \
2590 CFG(CFG_LFR_ROAM_SCAN_OFFLOAD_ENABLED) \
2591 CFG(CFG_LFR_NEIGHBOR_SCAN_CHANNEL_LIST) \
2592 CFG(CFG_LFR_NEIGHBOR_SCAN_TIMER_PERIOD) \
2593 CFG(CFG_LFR_NEIGHBOR_SCAN_MIN_TIMER_PERIOD) \
2594 CFG(CFG_LFR_NEIGHBOR_LOOKUP_RSSI_THRESHOLD) \
2595 CFG(CFG_LFR_OPPORTUNISTIC_SCAN_THRESHOLD_DIFF) \
2596 CFG(CFG_LFR_ROAM_RESCAN_RSSI_DIFF) \
2597 CFG(CFG_LFR_NEIGHBOR_SCAN_MIN_CHAN_TIME) \
2598 CFG(CFG_LFR_NEIGHBOR_SCAN_MAX_CHAN_TIME) \
2599 CFG(CFG_LFR_NEIGHBOR_SCAN_RESULTS_REFRESH_PERIOD) \
2600 CFG(CFG_LFR_EMPTY_SCAN_REFRESH_PERIOD) \
2601 CFG(CFG_LFR_ROAM_BMISS_FIRST_BCNT) \
2602 CFG(CFG_LFR_ROAM_BMISS_FINAL_BCNT) \
2603 CFG(CFG_LFR_ROAM_BEACON_RSSI_WEIGHT) \
2604 CFG(CFG_LFR_ROAMING_DFS_CHANNEL) \
2605 CFG(CFG_LFR_ROAM_SCAN_HI_RSSI_MAXCOUNT) \
2606 CFG(CFG_LFR_ROAM_SCAN_HI_RSSI_DELTA) \
2607 CFG(CFG_LFR_ROAM_SCAN_HI_RSSI_DELAY) \
2608 CFG(CFG_LFR_ROAM_SCAN_HI_RSSI_UB) \
2609 CFG(CFG_LFR_ROAM_PREFER_5GHZ) \
2610 CFG(CFG_LFR_ROAM_INTRA_BAND) \
2611 CFG(CFG_LFR_ROAM_SCAN_N_PROBES) \
2612 CFG(CFG_LFR_ROAM_SCAN_HOME_AWAY_TIME) \
2613 CFG(CFG_LFR_DELAY_BEFORE_VDEV_STOP) \
Pragaspathi Thilagaraj69f0b692018-12-16 22:23:04 +05302614 CFG(CFG_ENABLE_BSS_LOAD_TRIGGERED_ROAM) \
2615 CFG(CFG_BSS_LOAD_THRESHOLD) \
Pragaspathi Thilagaraj39d61602018-12-24 14:46:53 +05302616 CFG(CFG_BSS_LOAD_SAMPLE_TIME) \
Wu Gao6294afc2019-01-05 00:00:58 +08002617 CFG(CFG_LFR3_ROAM_HO_DELAY_FOR_RX) \
2618 CFG(CFG_LFR_MIN_DELAY_BTW_ROAM_SCAN) \
2619 CFG(CFG_LFR_ROAM_SCAN_TRIGGER_REASON_BITMASK) \
2620 CFG(CFG_LFR_ROAM_FT_OPEN_ENABLE) \
2621 CFG(CFG_LFR_ROAM_FORCE_RSSI_TRIGGER) \
Abhinav Kumar990fea62019-02-14 12:38:38 +05302622 CFG(CFG_ROAM_SCAN_SCAN_POLICY) \
Pragaspathi Thilagaraj2b8ea352019-04-12 02:23:50 +05302623 CFG(CFG_ROAM_SCAN_INACTIVITY_TIME) \
2624 CFG(CFG_ROAM_INACTIVE_COUNT) \
2625 CFG(CFG_POST_INACTIVITY_ROAM_SCAN_PERIOD) \
2626 CFG(CFG_BSS_LOAD_TRIG_5G_RSSI_THRES) \
2627 CFG(CFG_BSS_LOAD_TRIG_2G_RSSI_THRES) \
Pragaspathi Thilagaraj1f3f99f2019-04-24 23:48:47 +05302628 ADAPTIVE_11R_ALL \
Wu Gao5d23d782018-11-08 16:09:47 +08002629 ROAM_OFFLOAD_ALL \
Wu Gao6294afc2019-01-05 00:00:58 +08002630 LFR_ESE_ALL \
2631 LFR_SUBNET_DETECTION_ALL
Wu Gao55f21712018-09-17 10:57:49 +08002632
2633#endif /* CFG_MLME_LFR_H__ */