xref: /wlan-driver/qcacld-3.0/components/mlme/dispatcher/inc/cfg_mlme_dot11mode.h (revision 5113495b16420b49004c444715d2daae2066e7dc)
1 /*
2  * Copyright (c) 2012-2020 The Linux Foundation. All rights reserved.
3  *
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 centralized definitions of converged configuration.
21  */
22 
23 #ifndef __CFG_MLME_DOT11MODE_H
24 #define __CFG_MLME_DOT11MODE_H
25 
26 #define CFG_DOT11_MODE CFG_UINT( \
27 		"dot11_mode", \
28 		0, \
29 		10, \
30 		0, \
31 		CFG_VALUE_OR_DEFAULT, \
32 		"dot 11 mode")
33 
34 /*
35  * <ini>
36  * vdev_dot11_mode- Bit mask to set the dot11 mode for different vdev types
37  * @Min: 0x0
38  * @Max: 0x333333
39  * @Default: 0
40  *
41  * This ini is used to set the dot11mode different vdev types.
42  * dot11_mode ini value (CFG_DOT11_MODE) is the master configuration
43  * Min configuration of INI dot11_mode and vdev_dot11_mode is used for that
44  * vdev type.
45  * dot11_mode vdev_dot11_mode dot11_mode_used
46  * 11AX        11AC              11AC
47  * 11AC        11AX              11AC
48  *
49  * Dot11 mode value is 4 bit length for each vdev. Below is the bit definition
50  * for different vdev types dot11 mode value bit index.
51  *
52  * Bits used for dot11mode        Vdev Type
53  * BIT[3:0]                       STA mode
54  * BIT[7:4]                       P2P_CLI/P2P_DEVICE mode
55  * BIT[11:8]                      NAN DISCOVERY
56  * BIT[15:12]                     OCB
57  * BIT[19:16]                     TDLS
58  * BIT[23:20]                     NDI mode
59  *
60  * Dot11 mode value to be set in the above bit definition:
61  * 0 - Auto, Uses CFG_DOT11_MODE setting
62  * 1 - HT mode(11N)
63  * 2 - VHT mode(11AC)
64  * 3 - HE mode(11AX)
65  *
66  * E.g: vdev_dot11_mode=0x013220
67  *
68  * 0          1        3       2             2        0
69  * NDI(auto)  TDLS HT  OCB_HE  VHT NAN_DISC  VHT P2P  STA_AUTO
70  *
71  * Usage: Internal/External
72  *
73  * </ini>
74  */
75 #define CFG_VDEV_DOT11_MODE CFG_INI_UINT( \
76 		"vdev_dot11_mode", \
77 		0, \
78 		0x333333, \
79 		0, \
80 		CFG_VALUE_OR_DEFAULT, \
81 		"vdev dot 11 mode")
82 
83 #define CFG_DOT11_MODE_ALL \
84 	CFG(CFG_DOT11_MODE) \
85 	CFG(CFG_VDEV_DOT11_MODE) \
86 
87 #endif /* __CFG_MLME_DOT11MODE_H */
88 
89