cfg_mlme_reg.h 8.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350
  1. /*
  2. * Copyright (c) 2012-2021 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. * DOC: This file contains configuration definitions for MLME REG.
  20. */
  21. #ifndef CFG_MLME_REG_H__
  22. #define CFG_MLME_REG_H__
  23. /*
  24. * <ini>
  25. * gSelfGenFrmPwr - self-generated frame power in tx chain mask
  26. * for CCK rates
  27. * @Min: 0
  28. * @Max: 0xffff
  29. * @Default: 0
  30. *
  31. * gSelfGenFrmPwr is to set self-generated frame power in tx chain mask
  32. * for CCK rates
  33. *
  34. * Related: None
  35. *
  36. * Supported Feature: STA
  37. *
  38. * Usage: Internal/External
  39. *
  40. * </ini>
  41. */
  42. #define CFG_SELF_GEN_FRM_PWR CFG_INI_UINT( \
  43. "gSelfGenFrmPwr", \
  44. 0, \
  45. 0xffff, \
  46. 0, \
  47. CFG_VALUE_OR_DEFAULT, \
  48. "set the self gen power value")
  49. /*
  50. * <ini>
  51. * enable_11d_in_world_mode - enable 11d in world mode
  52. * @Min: 0
  53. * @Max: 1
  54. * @Default: 0
  55. *
  56. * This ini enables 11d in world mode, irrespective of value of
  57. * g11dSupportEnabled
  58. *
  59. * Usage: External
  60. *
  61. * </ini>
  62. */
  63. #define CFG_ENABLE_11D_IN_WORLD_MODE CFG_INI_BOOL( \
  64. "enable_11d_in_world_mode", \
  65. 0, \
  66. "enable 11d in world mode")
  67. /*
  68. * <ini>
  69. * etsi_srd_chan_in_master_mode - Enable/disable ETSI SRD channels in
  70. * master mode PCL and ACS functionality
  71. * @Min: 0
  72. * @Max: 0xFF
  73. * @Default: 6
  74. *
  75. * etsi_srd_chan_in_master_mode is to enable/disable ETSI SRD channels in
  76. * master mode PCL and ACS functionality
  77. * Bit map for enabling the SRD mode in various modes are as follows:-
  78. * BIT 0:- Enable/Disable SRD channels for SAP.
  79. * BIT 1:- Enable/Disable SRD channels for P2P-GO.
  80. * BIT 2:- Enable/Disable SRD channels for NAN.
  81. * Rest of the bits are currently reserved for future SRD channel support for
  82. * other vdevs.
  83. *
  84. * Related: None
  85. *
  86. * Supported Feature: SAP/P2P-GO
  87. *
  88. * Usage: Internal/External
  89. *
  90. * </ini>
  91. */
  92. #define CFG_ETSI_SRD_CHAN_IN_MASTER_MODE CFG_INI_UINT( \
  93. "etsi13_srd_chan_in_master_mode", \
  94. 0, \
  95. 0xff, \
  96. 6, \
  97. CFG_VALUE_OR_DEFAULT, \
  98. "enable/disable ETSI SRD channels in master mode")
  99. /*
  100. * <ini>
  101. * enable_nan_indoor_channel - Enable Indoor channels for NAN
  102. * @Min: 0
  103. * @Max: 1
  104. * @Default: 0
  105. *
  106. * This ini is used to support to indoor channels for NAN interface
  107. * Customer can config this item to enable/disable NAN in indoor channel
  108. *
  109. * Related: None
  110. *
  111. * Supported Feature: NAN
  112. *
  113. * Usage: External
  114. *
  115. * </ini>
  116. */
  117. #define CFG_INDOOR_CHANNEL_SUPPORT_FOR_NAN CFG_INI_BOOL( \
  118. "enable_nan_indoor_channel", \
  119. 0, \
  120. "enable/disable indoor channels for NAN")
  121. /*
  122. * <ini>
  123. * fcc_5dot9_ghz_chan_in_master_mode - Enable/disable 5.9 GHz channels in
  124. * master mode for US
  125. * @Min: 0
  126. * @Max: 1
  127. * @Default: 0
  128. *
  129. * fcc_5dot9_ghz_chan_in_master_mode is to enable/disable 5.9 GHz channels
  130. * in master mode for FCC reg domain
  131. *
  132. * Related: None
  133. *
  134. * Supported Feature: SAP/P2P-GO
  135. *
  136. * Usage: Internal/External
  137. *
  138. * </ini>
  139. */
  140. #define CFG_FCC_5DOT9_GHZ_CHAN_IN_MASTER_MODE CFG_INI_BOOL( \
  141. "fcc_5dot9_ghz_chan_in_master_mode", \
  142. 0, \
  143. "enable/disable FCC 5.9 GHz channels in master mode")
  144. #ifdef SAP_AVOID_ACS_FREQ_LIST
  145. #define SAP_AVOID_ACS_FREQ_LIST_DEFAULT ""
  146. /*
  147. * <ini>
  148. * sap_avoid_acs_freq_list - Avoid configured frequencies from acs
  149. * @Default: No frequencies are configured, it means consider all
  150. * the frequencies for acs
  151. *
  152. * This ini is to configure the frequencies which needs to be
  153. * avoided during acs and sap will not come up on these channels
  154. * Ex: sap_avoid_acs_freq_list=2412,2417,2422,2427,2467,2472
  155. *
  156. * Related: Feature flag SAP_AVOID_ACS_FREQ_LIST
  157. *
  158. * Supported Feature: SAP
  159. *
  160. * Usage: External
  161. *
  162. * </ini>
  163. */
  164. #define CFG_SAP_AVOID_ACS_FREQ_LIST CFG_INI_STRING( \
  165. "sap_avoid_acs_freq_list", \
  166. 0, \
  167. CFG_VALID_CHANNEL_LIST_STRING_LEN, \
  168. SAP_AVOID_ACS_FREQ_LIST_DEFAULT, \
  169. "Avoid configured frequencies during acs")
  170. #define CFG_SAP_AVOID_ACS_FREQ_LIST_ALL CFG(CFG_SAP_AVOID_ACS_FREQ_LIST)
  171. #else
  172. #define CFG_SAP_AVOID_ACS_FREQ_LIST_ALL
  173. #endif
  174. /*
  175. * <ini>
  176. * restart_beaconing_on_chan_avoid_event - control the beaconing entity to move
  177. * away from active LTE channels
  178. * @Min: 0
  179. * @Max: 2
  180. * @Default: 1
  181. *
  182. * This ini is used to control the beaconing entity (SAP/GO) to move away from
  183. * active LTE channels when channel avoidance event is received
  184. * restart_beaconing_on_chan_avoid_event=0: Don't allow beaconing entity move
  185. * from active LTE channels
  186. * restart_beaconing_on_chan_avoid_event=1: Allow beaconing entity move from
  187. * active LTE channels
  188. * restart_beaconing_on_chan_avoid_event=2: Allow beaconing entity move from
  189. * 2.4G active LTE channels only
  190. *
  191. * Related: None
  192. *
  193. * Supported Feature: channel avoidance
  194. *
  195. * Usage: Internal/External
  196. *
  197. * </ini>
  198. */
  199. #define CFG_RESTART_BEACONING_ON_CH_AVOID CFG_INI_UINT( \
  200. "restart_beaconing_on_chan_avoid_event", \
  201. 0, \
  202. 2, \
  203. 1, \
  204. CFG_VALUE_OR_DEFAULT, \
  205. "control the beaconing entity to move away from active LTE channels")
  206. /*
  207. * <ini>
  208. * gindoor_channel_support - support to start sap in indoor channel
  209. * @Min: 0
  210. * @Max: 1
  211. * @Default: 0
  212. *
  213. * This ini is to support to start sap in indoor channel.
  214. * Customer can config this item to enable/disable sap in indoor channel
  215. *
  216. * Related: None
  217. *
  218. * Supported Feature: SAP
  219. *
  220. * Usage: External
  221. *
  222. * </ini>
  223. */
  224. #define CFG_INDOOR_CHANNEL_SUPPORT CFG_INI_BOOL( \
  225. "gindoor_channel_support", \
  226. 0, \
  227. "enable/disable sap in indoor channel")
  228. /*
  229. * <ini>
  230. * scan_11d_interval - 11d scan interval in ms
  231. * @Min: 1 sec
  232. * @Max: 10 hr
  233. * @Default: 1 hr
  234. *
  235. * This ini sets the 11d scan interval in FW
  236. *
  237. * Related: None
  238. *
  239. * Supported Feature: STA
  240. *
  241. * Usage: External
  242. *
  243. * </ini>
  244. */
  245. #define CFG_SCAN_11D_INTERVAL CFG_INI_UINT( \
  246. "scan_11d_interval", \
  247. 1000, \
  248. 36000000, \
  249. 3600000, \
  250. CFG_VALUE_OR_DEFAULT, \
  251. "set the 11d scan interval in FW")
  252. /*
  253. * <ini>
  254. * ignore_fw_reg_offload_ind - If set, Ignore the FW offload indication
  255. * @Min: 0
  256. * @Max: 1
  257. * @Default: 0
  258. *
  259. * This ini is used to ignore regdb offload indication from FW and
  260. * regulatory will be treated as non offload.
  261. *
  262. * Related: None
  263. *
  264. * Supported Feature: STA/AP
  265. *
  266. * Usage: External
  267. *
  268. * </ini>
  269. */
  270. #define CFG_IGNORE_FW_REG_OFFLOAD_IND CFG_INI_BOOL( \
  271. "ignore_fw_reg_offload_ind", \
  272. 0, \
  273. "Ignore Regulatory offloads Indication from FW")
  274. /*
  275. * <ini>
  276. * enable_pending_list_req - Sets Pending channel List Req.
  277. * @Min: 0
  278. * @Max: 1
  279. * @Default: 0
  280. *
  281. * This option enables/disables SCAN_CHAN_LIST_CMDID channel list command to FW
  282. * till the current scan is complete.
  283. *
  284. * Related: None
  285. *
  286. * Supported Feature: STA
  287. *
  288. * Usage: External
  289. *
  290. * </ini>
  291. */
  292. #define CFG_ENABLE_PENDING_CHAN_LIST_REQ CFG_INI_BOOL( \
  293. "enable_pending_list_req", \
  294. 0, \
  295. "Enable Pending list req")
  296. /*
  297. * <ini>
  298. * retain_nol_across_regdmn - Retain NOL across reg domain
  299. * @Min: 0
  300. * @Max: 1
  301. * @Default: 1
  302. *
  303. * This ini is used to set if NOL needs to be retained
  304. * on the reg domain change.
  305. *
  306. * Related: None
  307. *
  308. * Supported Feature: SAP
  309. *
  310. * Usage: External
  311. *
  312. * </ini>
  313. */
  314. #define CFG_RETAIN_NOL_ACROSS_REG_DOMAIN CFG_INI_BOOL( \
  315. "retain_nol_across_regdmn", \
  316. 1, \
  317. "Retain NOL even if the regdomain changes")
  318. #define CFG_REG_ALL \
  319. CFG(CFG_SELF_GEN_FRM_PWR) \
  320. CFG(CFG_ENABLE_PENDING_CHAN_LIST_REQ) \
  321. CFG(CFG_ENABLE_11D_IN_WORLD_MODE) \
  322. CFG(CFG_ETSI_SRD_CHAN_IN_MASTER_MODE) \
  323. CFG(CFG_INDOOR_CHANNEL_SUPPORT_FOR_NAN) \
  324. CFG(CFG_FCC_5DOT9_GHZ_CHAN_IN_MASTER_MODE) \
  325. CFG(CFG_RESTART_BEACONING_ON_CH_AVOID) \
  326. CFG(CFG_INDOOR_CHANNEL_SUPPORT) \
  327. CFG(CFG_SCAN_11D_INTERVAL) \
  328. CFG(CFG_IGNORE_FW_REG_OFFLOAD_IND) \
  329. CFG(CFG_RETAIN_NOL_ACROSS_REG_DOMAIN) \
  330. CFG_SAP_AVOID_ACS_FREQ_LIST_ALL
  331. #endif /* CFG_MLME_REG_H__ */