cfg_mlme_sta.h 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479
  1. /*
  2. * Copyright (c) 2012-2019, The Linux Foundation. All rights reserved.
  3. *
  4. * Permission to use, copy, modify, and/or distribute this software for any
  5. * purpose with or without fee is hereby granted, provided that the above
  6. * copyright notice and this permission notice appear in all copies.
  7. *
  8. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  9. * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
  10. * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
  11. * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  12. * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
  13. * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  14. * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  15. */
  16. /**
  17. * DOC: This file contains configuration definitions for MLME STA.
  18. */
  19. #ifndef CFG_MLME_STA_H__
  20. #define CFG_MLME_STA_H__
  21. #include "wlan_mlme_public_struct.h"
  22. /*
  23. * <ini>
  24. * gStaKeepAlivePeriod - STA keep alive period
  25. *
  26. *
  27. * @Min: 0
  28. * @Max: 1000
  29. * @Default: 60
  30. *
  31. * This ini is used to control how frequently STA should send NULL frames to AP
  32. * (period in seconds) to notify AP of its existence.
  33. *
  34. * Related: None
  35. *
  36. * Supported Feature: STA
  37. *
  38. * Usage: Internal/External
  39. *
  40. * </ini>
  41. */
  42. #define CFG_INFRA_STA_KEEP_ALIVE_PERIOD CFG_INI_UINT( \
  43. "gStaKeepAlivePeriod", \
  44. 0, \
  45. 1000, \
  46. 60, \
  47. CFG_VALUE_OR_DEFAULT, \
  48. "send default NULL frame to AP")
  49. /*
  50. * <ini>
  51. * tgt_gtx_usr_cfg - target gtx user config
  52. * @Min: 0
  53. * @Max: 32
  54. * @Default: 32
  55. *
  56. * This ini is used to set target gtx user config.
  57. *
  58. * Related: None
  59. *
  60. * Usage: Internal/External
  61. *
  62. * </ini>
  63. */
  64. #define CFG_TGT_GTX_USR_CFG CFG_INI_UINT( \
  65. "tgt_gtx_usr_cfg", \
  66. 0, \
  67. 32, \
  68. 32, \
  69. CFG_VALUE_OR_DEFAULT, \
  70. "target gtx user config")
  71. /*
  72. * <ini>
  73. * pmkidModes - Enable PMKID modes
  74. * This INI is used to enable PMKID feature options
  75. * @Min: 0
  76. * @Max: 3
  77. * @Default: 3
  78. *
  79. * Related: None
  80. *
  81. * Supported Feature: Scan
  82. *
  83. * Usage: External
  84. *
  85. * </ini>
  86. */
  87. #define CFG_PMKID_MODES CFG_INI_UINT( \
  88. "pmkidModes", \
  89. 0, \
  90. 3, \
  91. 3, \
  92. CFG_VALUE_OR_DEFAULT, \
  93. "PMKID feature options")
  94. /*
  95. * <ini>
  96. * gIgnorePeerErpInfo - Ignore peer information
  97. * @Min: 0
  98. * @Max: 1
  99. * @Default: 0
  100. *
  101. * This ini is used to ignore default peer info
  102. *
  103. * Related: None
  104. *
  105. * Supported Feature: STA
  106. *
  107. * Usage: Internal/External
  108. *
  109. * </ini>
  110. */
  111. #define CFG_IGNORE_PEER_ERP_INFO CFG_INI_BOOL( \
  112. "gIgnorePeerErpInfo", \
  113. 0, \
  114. "ignore default peer info")
  115. /*
  116. * <ini>
  117. * gStaPrefer80MHzOver160MHz - set sta preference to connect in 80HZ/160HZ
  118. * @Min: 0
  119. * @Max: 1
  120. * @Default: 0
  121. *
  122. * This ini is used to set sta preference to connect in 80HZ/160HZ
  123. *
  124. * 0 - Connects in 160MHz 1x1 when AP is 160MHz 2x2
  125. * 1 - Connects in 80MHz 2x2 when AP is 160MHz 2x2
  126. *
  127. * Related: NA
  128. *
  129. * Supported Feature: 11AC
  130. *
  131. * Usage: External
  132. *
  133. * </ini>
  134. */
  135. #define CFG_STA_PREFER_80MHZ_OVER_160MHZ CFG_INI_BOOL( \
  136. "gStaPrefer80MHzOver160MHz", \
  137. 0, \
  138. "Sta preference to connect in 80HZ/160HZ")
  139. /*
  140. * <ini>
  141. * gEnable5gEBT - Enables/disables 5G early beacon termination. When enabled
  142. * terminate the reception of beacon if the TIM element is
  143. * clear for the power saving
  144. * @Min: 0
  145. * @Max: 1
  146. * @Default: 1
  147. *
  148. * This ini is used to set default 5G early beacon termination
  149. *
  150. * Related: None
  151. *
  152. * Supported Feature: STA
  153. *
  154. * Usage: Internal/External
  155. *
  156. * </ini>
  157. */
  158. #define CFG_PPS_ENABLE_5G_EBT CFG_INI_BOOL( \
  159. "gEnable5gEBT", \
  160. 1, \
  161. "5G early beacon termination")
  162. /*
  163. * <ini>
  164. * gSendDeauthBeforeCon - Send deauth before connection or not
  165. * @Min: 0
  166. * @Max: 1
  167. * @Default: 0
  168. *
  169. * This ini is used to set whether send deauth before connection or
  170. * not. If last disconnection was due to HB failure and we reconnect
  171. * to same AP next time, send deauth before starting connection.
  172. *
  173. * Related: None
  174. *
  175. * Supported Feature: STA
  176. *
  177. * Usage: Internal/External
  178. *
  179. * </ini>
  180. */
  181. #define CFG_ENABLE_DEAUTH_BEFORE_CONNECTION CFG_INI_BOOL( \
  182. "gSendDeauthBeforeCon", \
  183. 0, \
  184. "send deauth before connection")
  185. /*
  186. * <ini>
  187. * gDot11PMode - 802.11p mode
  188. * @Min: CFG_11P_DISABLED
  189. * @Max: CFG_11P_CONCURRENT
  190. * @Default: CFG_11P_DISABLED
  191. *
  192. * This ini used to set 802.11p mode.
  193. *
  194. *
  195. * Usage: Internal/External
  196. *
  197. * </ini>
  198. */
  199. #define CFG_DOT11P_MODE CFG_INI_UINT( \
  200. "gDot11PMode", \
  201. CFG_11P_DISABLED, \
  202. CFG_11P_CONCURRENT, \
  203. CFG_11P_DISABLED, \
  204. CFG_VALUE_OR_DEFAULT, \
  205. "802.11p mode")
  206. /*
  207. * <ini>
  208. * gEnable_go_cts2self_for_sta - Indicate firmware to stop NOA and
  209. * start using cts2self
  210. * @Min: 0
  211. * @Max: 1
  212. * @Default: 0
  213. *
  214. * When gEnable_go_cts2self_for_sta is enabled then if a legacy
  215. * client connects to P2P GO, Host will send a WMI VDEV command
  216. * to FW to stop using NOA for P2P GO
  217. * and start using CTS2SELF.
  218. *
  219. *
  220. * Supported Feature: P2P
  221. *
  222. *
  223. * Usage: Internal/External
  224. *
  225. * </ini>
  226. */
  227. #define CFG_ENABLE_GO_CTS2SELF_FOR_STA CFG_INI_BOOL( \
  228. "gEnable_go_cts2self_for_sta", \
  229. 0, \
  230. "firmware to stop NOA and start using cts2self")
  231. /*
  232. * <ini>
  233. * g_qcn_ie_support - QCN IE support
  234. * @Min: 0 (disabled)
  235. * @Max: 1 (enabled)
  236. * @Default: 1 (enabled)
  237. *
  238. * This config item is used to support QCN IE in probe/assoc/reassoc request
  239. * for STA mode. QCN IE support is not added for SAP mode.
  240. *
  241. * Related: N/A
  242. *
  243. * Supported Feature: N/A
  244. *
  245. * Usage: Internal/External
  246. *
  247. * </ini>
  248. */
  249. #define CFG_QCN_IE_SUPPORT CFG_INI_BOOL( \
  250. "g_qcn_ie_support", \
  251. 1, \
  252. "QCN IE support")
  253. /*
  254. * <ini>
  255. * g_fils_max_chan_guard_time - Set maximum channel guard time(ms)
  256. * @Min: 0
  257. * @Max: 10
  258. * @Default: 0
  259. *
  260. * This ini is used to set maximum channel guard time in milliseconds.
  261. *
  262. * Related: None
  263. *
  264. * Supported Feature: FILS
  265. *
  266. * Usage: External
  267. *
  268. * </ini>
  269. */
  270. #define CFG_FILS_MAX_CHAN_GUARD_TIME CFG_INI_UINT( \
  271. "g_fils_max_chan_guard_time", \
  272. 0, \
  273. 10, \
  274. 0, \
  275. CFG_VALUE_OR_DEFAULT, \
  276. "Set maximum channel guard time")
  277. /*
  278. * <ini>
  279. * force_rsne_override - force rsnie override from user
  280. * @Min: 0
  281. * @Max: 1
  282. * @Default: 0
  283. *
  284. * This ini is used to enable/disable test mode to force rsne override used in
  285. * security enhancement test cases to pass the RSNIE sent by user in
  286. * assoc request.
  287. *
  288. * Related: None
  289. *
  290. * Supported Feature: STA
  291. *
  292. * Usage: internal
  293. *
  294. * </ini>
  295. */
  296. #define CFG_FORCE_RSNE_OVERRIDE CFG_INI_BOOL( \
  297. "force_rsne_override", \
  298. 0, \
  299. "Set obss active dwelltime")
  300. /*
  301. * <ini>
  302. * SingleTIDRC - Set replay counter for all TID's
  303. * @Min: 0 Separate replay counter for all TID
  304. * @Max: 1 Single replay counter for all TID
  305. * @Default: 1
  306. *
  307. * This ini is used to set replay counter for all TID's
  308. *
  309. * 0 - Separate replay counter for all TID
  310. * 1 - Single replay counter for all TID
  311. *
  312. * Related: None.
  313. *
  314. * Supported Feature: WMM
  315. *
  316. * Usage: Internal/External
  317. *
  318. * </ini>
  319. */
  320. #define CFG_SINGLE_TID_RC CFG_INI_BOOL( \
  321. "SingleTIDRC", \
  322. 1, \
  323. "replay counter for all TID")
  324. /*
  325. * wait_cnf_timeout - Wait assoc cnf timeout
  326. * @Min: 10
  327. * @Max: 3000
  328. * @Default: 1000
  329. *
  330. * This is internal configure for waiting assoc cnf timeout
  331. *
  332. * Related: None
  333. *
  334. * Usage: Internal
  335. *
  336. */
  337. #define CFG_WT_CNF_TIMEOUT CFG_UINT( \
  338. "wait_cnf_timeout", \
  339. 10, \
  340. 3000, \
  341. 1000, \
  342. CFG_VALUE_OR_DEFAULT, \
  343. "Wait confirm timeout")
  344. /*
  345. * <ini>
  346. * gStaMiracastMccRestTimeVal - Rest time when Miracast is running.
  347. * @Min: 100
  348. * @Max: 500
  349. * @Default: 400
  350. *
  351. * This ini is used to set rest time for home channel for Miracast before
  352. * going for scan.
  353. *
  354. * Related: None.
  355. *
  356. * Supported Feature: Concurrency
  357. *
  358. * Usage: Internal/External
  359. *
  360. * </ini>
  361. */
  362. #define CFG_STA_MCAST_MCC_REST_TIME CFG_INI_UINT( \
  363. "gStaMiracastMccRestTimeVal", \
  364. 100, \
  365. 500, \
  366. 400, \
  367. CFG_VALUE_OR_DEFAULT, \
  368. "Rest time when Miracast is running")
  369. /*
  370. * current_rssi - current rssi
  371. * @Min: 0
  372. * @Max: 127
  373. * @Default: 0
  374. *
  375. * This is internal configure for current rssi
  376. *
  377. * Related: None
  378. *
  379. * Usage: Internal
  380. *
  381. */
  382. #define CFG_CURRENT_RSSI CFG_UINT( \
  383. "current_rssi", \
  384. 0, \
  385. 127, \
  386. 0, \
  387. CFG_VALUE_OR_DEFAULT, \
  388. "Current RSSI")
  389. /*
  390. * <ini>
  391. * gAllowTPCfromAP - Support for AP power constraint
  392. * @Min: 0
  393. * @Max: 1
  394. * @Default: 1
  395. *
  396. * This ini controls driver to honor/dishonor power constraint from AP.
  397. *
  398. * Related: None.
  399. *
  400. * Supported Feature: Concurrency
  401. *
  402. * Usage: Internal/External
  403. *
  404. * </ini>
  405. */
  406. #define CFG_TX_POWER_CTRL CFG_INI_BOOL( \
  407. "gAllowTPCfromAP", \
  408. 1, \
  409. "Support for AP power constraint")
  410. /*
  411. * <ini>
  412. * gStaKeepAliveMethod - Which keepalive method to use
  413. * @Min: 0
  414. * @Max: 1
  415. * @Default: 1
  416. *
  417. * This ini determines which keepalive method to use for station interfaces
  418. * 1) Use null data packets
  419. * 2) Use gratuitous ARP packets
  420. *
  421. * Related: gStaKeepAlivePeriod, gApKeepAlivePeriod, gGoKeepAlivePeriod
  422. *
  423. * Supported Feature: STA, Keepalive
  424. *
  425. * Usage: External
  426. *
  427. * </ini>
  428. */
  429. #define CFG_STA_KEEPALIVE_METHOD CFG_INI_INT( \
  430. "gStaKeepAliveMethod", \
  431. MLME_STA_KEEPALIVE_NULL_DATA, \
  432. MLME_STA_KEEPALIVE_COUNT - 1, \
  433. MLME_STA_KEEPALIVE_GRAT_ARP, \
  434. CFG_VALUE_OR_DEFAULT, \
  435. "Which keepalive method to use")
  436. #define CFG_STA_ALL \
  437. CFG(CFG_INFRA_STA_KEEP_ALIVE_PERIOD) \
  438. CFG(CFG_TGT_GTX_USR_CFG) \
  439. CFG(CFG_PMKID_MODES) \
  440. CFG(CFG_IGNORE_PEER_ERP_INFO) \
  441. CFG(CFG_STA_PREFER_80MHZ_OVER_160MHZ) \
  442. CFG(CFG_PPS_ENABLE_5G_EBT) \
  443. CFG(CFG_ENABLE_DEAUTH_BEFORE_CONNECTION) \
  444. CFG(CFG_DOT11P_MODE) \
  445. CFG(CFG_ENABLE_GO_CTS2SELF_FOR_STA) \
  446. CFG(CFG_QCN_IE_SUPPORT) \
  447. CFG(CFG_STA_MCAST_MCC_REST_TIME) \
  448. CFG(CFG_FILS_MAX_CHAN_GUARD_TIME) \
  449. CFG(CFG_FORCE_RSNE_OVERRIDE) \
  450. CFG(CFG_SINGLE_TID_RC) \
  451. CFG(CFG_STA_KEEPALIVE_METHOD) \
  452. CFG(CFG_WT_CNF_TIMEOUT) \
  453. CFG(CFG_CURRENT_RSSI) \
  454. CFG(CFG_TX_POWER_CTRL)
  455. #endif /* CFG_MLME_STA_H__ */