nl80211.h 33 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914
  1. #ifndef __LINUX_NL80211_H
  2. #define __LINUX_NL80211_H
  3. /*
  4. * 802.11 netlink interface public header
  5. *
  6. * Copyright 2006, 2007, 2008 Johannes Berg <johannes@sipsolutions.net>
  7. * Copyright 2008 Michael Wu <flamingice@sourmilk.net>
  8. * Copyright 2008 Luis Carlos Cobo <luisca@cozybit.com>
  9. * Copyright 2008 Michael Buesch <mb@bu3sch.de>
  10. * Copyright 2008 Luis R. Rodriguez <lrodriguez@atheros.com>
  11. * Copyright 2008 Jouni Malinen <jouni.malinen@atheros.com>
  12. * Copyright 2008 Colin McCabe <colin@cozybit.com>
  13. *
  14. * Permission to use, copy, modify, and/or distribute this software for any
  15. * purpose with or without fee is hereby granted, provided that the above
  16. * copyright notice and this permission notice appear in all copies.
  17. *
  18. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  19. * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
  20. * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
  21. * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  22. * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
  23. * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  24. * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  25. *
  26. */
  27. /**
  28. * DOC: Station handling
  29. *
  30. * Stations are added per interface, but a special case exists with VLAN
  31. * interfaces. When a station is bound to an AP interface, it may be moved
  32. * into a VLAN identified by a VLAN interface index (%NL80211_ATTR_STA_VLAN).
  33. * The station is still assumed to belong to the AP interface it was added
  34. * to.
  35. *
  36. * TODO: need more info?
  37. */
  38. /**
  39. * enum nl80211_commands - supported nl80211 commands
  40. *
  41. * @NL80211_CMD_UNSPEC: unspecified command to catch errors
  42. *
  43. * @NL80211_CMD_GET_WIPHY: request information about a wiphy or dump request
  44. * to get a list of all present wiphys.
  45. * @NL80211_CMD_SET_WIPHY: set wiphy parameters, needs %NL80211_ATTR_WIPHY or
  46. * %NL80211_ATTR_IFINDEX; can be used to set %NL80211_ATTR_WIPHY_NAME,
  47. * %NL80211_ATTR_WIPHY_TXQ_PARAMS, %NL80211_ATTR_WIPHY_FREQ, and/or
  48. * %NL80211_ATTR_WIPHY_CHANNEL_TYPE.
  49. * @NL80211_CMD_NEW_WIPHY: Newly created wiphy, response to get request
  50. * or rename notification. Has attributes %NL80211_ATTR_WIPHY and
  51. * %NL80211_ATTR_WIPHY_NAME.
  52. * @NL80211_CMD_DEL_WIPHY: Wiphy deleted. Has attributes
  53. * %NL80211_ATTR_WIPHY and %NL80211_ATTR_WIPHY_NAME.
  54. *
  55. * @NL80211_CMD_GET_INTERFACE: Request an interface's configuration;
  56. * either a dump request on a %NL80211_ATTR_WIPHY or a specific get
  57. * on an %NL80211_ATTR_IFINDEX is supported.
  58. * @NL80211_CMD_SET_INTERFACE: Set type of a virtual interface, requires
  59. * %NL80211_ATTR_IFINDEX and %NL80211_ATTR_IFTYPE.
  60. * @NL80211_CMD_NEW_INTERFACE: Newly created virtual interface or response
  61. * to %NL80211_CMD_GET_INTERFACE. Has %NL80211_ATTR_IFINDEX,
  62. * %NL80211_ATTR_WIPHY and %NL80211_ATTR_IFTYPE attributes. Can also
  63. * be sent from userspace to request creation of a new virtual interface,
  64. * then requires attributes %NL80211_ATTR_WIPHY, %NL80211_ATTR_IFTYPE and
  65. * %NL80211_ATTR_IFNAME.
  66. * @NL80211_CMD_DEL_INTERFACE: Virtual interface was deleted, has attributes
  67. * %NL80211_ATTR_IFINDEX and %NL80211_ATTR_WIPHY. Can also be sent from
  68. * userspace to request deletion of a virtual interface, then requires
  69. * attribute %NL80211_ATTR_IFINDEX.
  70. *
  71. * @NL80211_CMD_GET_KEY: Get sequence counter information for a key specified
  72. * by %NL80211_ATTR_KEY_IDX and/or %NL80211_ATTR_MAC.
  73. * @NL80211_CMD_SET_KEY: Set key attributes %NL80211_ATTR_KEY_DEFAULT,
  74. * %NL80211_ATTR_KEY_DEFAULT_MGMT, or %NL80211_ATTR_KEY_THRESHOLD.
  75. * @NL80211_CMD_NEW_KEY: add a key with given %NL80211_ATTR_KEY_DATA,
  76. * %NL80211_ATTR_KEY_IDX, %NL80211_ATTR_MAC and %NL80211_ATTR_KEY_CIPHER
  77. * attributes.
  78. * @NL80211_CMD_DEL_KEY: delete a key identified by %NL80211_ATTR_KEY_IDX
  79. * or %NL80211_ATTR_MAC.
  80. *
  81. * @NL80211_CMD_GET_BEACON: retrieve beacon information (returned in a
  82. * %NL80222_CMD_NEW_BEACON message)
  83. * @NL80211_CMD_SET_BEACON: set the beacon on an access point interface
  84. * using the %NL80211_ATTR_BEACON_INTERVAL, %NL80211_ATTR_DTIM_PERIOD,
  85. * %NL80211_ATTR_BEACON_HEAD and %NL80211_ATTR_BEACON_TAIL attributes.
  86. * @NL80211_CMD_NEW_BEACON: add a new beacon to an access point interface,
  87. * parameters are like for %NL80211_CMD_SET_BEACON.
  88. * @NL80211_CMD_DEL_BEACON: remove the beacon, stop sending it
  89. *
  90. * @NL80211_CMD_GET_STATION: Get station attributes for station identified by
  91. * %NL80211_ATTR_MAC on the interface identified by %NL80211_ATTR_IFINDEX.
  92. * @NL80211_CMD_SET_STATION: Set station attributes for station identified by
  93. * %NL80211_ATTR_MAC on the interface identified by %NL80211_ATTR_IFINDEX.
  94. * @NL80211_CMD_NEW_STATION: Add a station with given attributes to the
  95. * the interface identified by %NL80211_ATTR_IFINDEX.
  96. * @NL80211_CMD_DEL_STATION: Remove a station identified by %NL80211_ATTR_MAC
  97. * or, if no MAC address given, all stations, on the interface identified
  98. * by %NL80211_ATTR_IFINDEX.
  99. *
  100. * @NL80211_CMD_GET_MPATH: Get mesh path attributes for mesh path to
  101. * destination %NL80211_ATTR_MAC on the interface identified by
  102. * %NL80211_ATTR_IFINDEX.
  103. * @NL80211_CMD_SET_MPATH: Set mesh path attributes for mesh path to
  104. * destination %NL80211_ATTR_MAC on the interface identified by
  105. * %NL80211_ATTR_IFINDEX.
  106. * @NL80211_CMD_NEW_PATH: Add a mesh path with given attributes to the
  107. * the interface identified by %NL80211_ATTR_IFINDEX.
  108. * @NL80211_CMD_DEL_PATH: Remove a mesh path identified by %NL80211_ATTR_MAC
  109. * or, if no MAC address given, all mesh paths, on the interface identified
  110. * by %NL80211_ATTR_IFINDEX.
  111. * @NL80211_CMD_SET_BSS: Set BSS attributes for BSS identified by
  112. * %NL80211_ATTR_IFINDEX.
  113. *
  114. * @NL80211_CMD_GET_REG: ask the wireless core to send us its currently set
  115. * regulatory domain.
  116. * @NL80211_CMD_SET_REG: Set current regulatory domain. CRDA sends this command
  117. * after being queried by the kernel. CRDA replies by sending a regulatory
  118. * domain structure which consists of %NL80211_ATTR_REG_ALPHA set to our
  119. * current alpha2 if it found a match. It also provides
  120. * NL80211_ATTR_REG_RULE_FLAGS, and a set of regulatory rules. Each
  121. * regulatory rule is a nested set of attributes given by
  122. * %NL80211_ATTR_REG_RULE_FREQ_[START|END] and
  123. * %NL80211_ATTR_FREQ_RANGE_MAX_BW with an attached power rule given by
  124. * %NL80211_ATTR_REG_RULE_POWER_MAX_ANT_GAIN and
  125. * %NL80211_ATTR_REG_RULE_POWER_MAX_EIRP.
  126. * @NL80211_CMD_REQ_SET_REG: ask the wireless core to set the regulatory domain
  127. * to the the specified ISO/IEC 3166-1 alpha2 country code. The core will
  128. * store this as a valid request and then query userspace for it.
  129. *
  130. * @NL80211_CMD_GET_MESH_PARAMS: Get mesh networking properties for the
  131. * interface identified by %NL80211_ATTR_IFINDEX
  132. *
  133. * @NL80211_CMD_SET_MESH_PARAMS: Set mesh networking properties for the
  134. * interface identified by %NL80211_ATTR_IFINDEX
  135. *
  136. * @NL80211_CMD_SET_MGMT_EXTRA_IE: Set extra IEs for management frames. The
  137. * interface is identified with %NL80211_ATTR_IFINDEX and the management
  138. * frame subtype with %NL80211_ATTR_MGMT_SUBTYPE. The extra IE data to be
  139. * added to the end of the specified management frame is specified with
  140. * %NL80211_ATTR_IE. If the command succeeds, the requested data will be
  141. * added to all specified management frames generated by
  142. * kernel/firmware/driver.
  143. *
  144. * @NL80211_CMD_GET_SCAN: get scan results
  145. * @NL80211_CMD_TRIGGER_SCAN: trigger a new scan with the given parameters
  146. * @NL80211_CMD_NEW_SCAN_RESULTS: scan notification (as a reply to
  147. * NL80211_CMD_GET_SCAN and on the "scan" multicast group)
  148. * @NL80211_CMD_SCAN_ABORTED: scan was aborted, for unspecified reasons,
  149. * partial scan results may be available
  150. *
  151. * @NL80211_CMD_MAX: highest used command number
  152. * @__NL80211_CMD_AFTER_LAST: internal use
  153. */
  154. enum nl80211_commands {
  155. /* don't change the order or add anything inbetween, this is ABI! */
  156. NL80211_CMD_UNSPEC,
  157. NL80211_CMD_GET_WIPHY, /* can dump */
  158. NL80211_CMD_SET_WIPHY,
  159. NL80211_CMD_NEW_WIPHY,
  160. NL80211_CMD_DEL_WIPHY,
  161. NL80211_CMD_GET_INTERFACE, /* can dump */
  162. NL80211_CMD_SET_INTERFACE,
  163. NL80211_CMD_NEW_INTERFACE,
  164. NL80211_CMD_DEL_INTERFACE,
  165. NL80211_CMD_GET_KEY,
  166. NL80211_CMD_SET_KEY,
  167. NL80211_CMD_NEW_KEY,
  168. NL80211_CMD_DEL_KEY,
  169. NL80211_CMD_GET_BEACON,
  170. NL80211_CMD_SET_BEACON,
  171. NL80211_CMD_NEW_BEACON,
  172. NL80211_CMD_DEL_BEACON,
  173. NL80211_CMD_GET_STATION,
  174. NL80211_CMD_SET_STATION,
  175. NL80211_CMD_NEW_STATION,
  176. NL80211_CMD_DEL_STATION,
  177. NL80211_CMD_GET_MPATH,
  178. NL80211_CMD_SET_MPATH,
  179. NL80211_CMD_NEW_MPATH,
  180. NL80211_CMD_DEL_MPATH,
  181. NL80211_CMD_SET_BSS,
  182. NL80211_CMD_SET_REG,
  183. NL80211_CMD_REQ_SET_REG,
  184. NL80211_CMD_GET_MESH_PARAMS,
  185. NL80211_CMD_SET_MESH_PARAMS,
  186. NL80211_CMD_SET_MGMT_EXTRA_IE,
  187. NL80211_CMD_GET_REG,
  188. NL80211_CMD_GET_SCAN,
  189. NL80211_CMD_TRIGGER_SCAN,
  190. NL80211_CMD_NEW_SCAN_RESULTS,
  191. NL80211_CMD_SCAN_ABORTED,
  192. /* add new commands above here */
  193. /* used to define NL80211_CMD_MAX below */
  194. __NL80211_CMD_AFTER_LAST,
  195. NL80211_CMD_MAX = __NL80211_CMD_AFTER_LAST - 1
  196. };
  197. /*
  198. * Allow user space programs to use #ifdef on new commands by defining them
  199. * here
  200. */
  201. #define NL80211_CMD_SET_BSS NL80211_CMD_SET_BSS
  202. #define NL80211_CMD_SET_MGMT_EXTRA_IE NL80211_CMD_SET_MGMT_EXTRA_IE
  203. /**
  204. * enum nl80211_attrs - nl80211 netlink attributes
  205. *
  206. * @NL80211_ATTR_UNSPEC: unspecified attribute to catch errors
  207. *
  208. * @NL80211_ATTR_WIPHY: index of wiphy to operate on, cf.
  209. * /sys/class/ieee80211/<phyname>/index
  210. * @NL80211_ATTR_WIPHY_NAME: wiphy name (used for renaming)
  211. * @NL80211_ATTR_WIPHY_TXQ_PARAMS: a nested array of TX queue parameters
  212. * @NL80211_ATTR_WIPHY_FREQ: frequency of the selected channel in MHz
  213. * @NL80211_ATTR_WIPHY_CHANNEL_TYPE: included with NL80211_ATTR_WIPHY_FREQ
  214. * if HT20 or HT40 are allowed (i.e., 802.11n disabled if not included):
  215. * NL80211_CHAN_NO_HT = HT not allowed (i.e., same as not including
  216. * this attribute)
  217. * NL80211_CHAN_HT20 = HT20 only
  218. * NL80211_CHAN_HT40MINUS = secondary channel is below the primary channel
  219. * NL80211_CHAN_HT40PLUS = secondary channel is above the primary channel
  220. *
  221. * @NL80211_ATTR_IFINDEX: network interface index of the device to operate on
  222. * @NL80211_ATTR_IFNAME: network interface name
  223. * @NL80211_ATTR_IFTYPE: type of virtual interface, see &enum nl80211_iftype
  224. *
  225. * @NL80211_ATTR_MAC: MAC address (various uses)
  226. *
  227. * @NL80211_ATTR_KEY_DATA: (temporal) key data; for TKIP this consists of
  228. * 16 bytes encryption key followed by 8 bytes each for TX and RX MIC
  229. * keys
  230. * @NL80211_ATTR_KEY_IDX: key ID (u8, 0-3)
  231. * @NL80211_ATTR_KEY_CIPHER: key cipher suite (u32, as defined by IEEE 802.11
  232. * section 7.3.2.25.1, e.g. 0x000FAC04)
  233. * @NL80211_ATTR_KEY_SEQ: transmit key sequence number (IV/PN) for TKIP and
  234. * CCMP keys, each six bytes in little endian
  235. *
  236. * @NL80211_ATTR_BEACON_INTERVAL: beacon interval in TU
  237. * @NL80211_ATTR_DTIM_PERIOD: DTIM period for beaconing
  238. * @NL80211_ATTR_BEACON_HEAD: portion of the beacon before the TIM IE
  239. * @NL80211_ATTR_BEACON_TAIL: portion of the beacon after the TIM IE
  240. *
  241. * @NL80211_ATTR_STA_AID: Association ID for the station (u16)
  242. * @NL80211_ATTR_STA_FLAGS: flags, nested element with NLA_FLAG attributes of
  243. * &enum nl80211_sta_flags.
  244. * @NL80211_ATTR_STA_LISTEN_INTERVAL: listen interval as defined by
  245. * IEEE 802.11 7.3.1.6 (u16).
  246. * @NL80211_ATTR_STA_SUPPORTED_RATES: supported rates, array of supported
  247. * rates as defined by IEEE 802.11 7.3.2.2 but without the length
  248. * restriction (at most %NL80211_MAX_SUPP_RATES).
  249. * @NL80211_ATTR_STA_VLAN: interface index of VLAN interface to move station
  250. * to, or the AP interface the station was originally added to to.
  251. * @NL80211_ATTR_STA_INFO: information about a station, part of station info
  252. * given for %NL80211_CMD_GET_STATION, nested attribute containing
  253. * info as possible, see &enum nl80211_sta_info.
  254. *
  255. * @NL80211_ATTR_WIPHY_BANDS: Information about an operating bands,
  256. * consisting of a nested array.
  257. *
  258. * @NL80211_ATTR_MESH_ID: mesh id (1-32 bytes).
  259. * @NL80211_ATTR_PLINK_ACTION: action to perform on the mesh peer link.
  260. * @NL80211_ATTR_MPATH_NEXT_HOP: MAC address of the next hop for a mesh path.
  261. * @NL80211_ATTR_MPATH_INFO: information about a mesh_path, part of mesh path
  262. * info given for %NL80211_CMD_GET_MPATH, nested attribute described at
  263. * &enum nl80211_mpath_info.
  264. *
  265. * @NL80211_ATTR_MNTR_FLAGS: flags, nested element with NLA_FLAG attributes of
  266. * &enum nl80211_mntr_flags.
  267. *
  268. * @NL80211_ATTR_REG_ALPHA2: an ISO-3166-alpha2 country code for which the
  269. * current regulatory domain should be set to or is already set to.
  270. * For example, 'CR', for Costa Rica. This attribute is used by the kernel
  271. * to query the CRDA to retrieve one regulatory domain. This attribute can
  272. * also be used by userspace to query the kernel for the currently set
  273. * regulatory domain. We chose an alpha2 as that is also used by the
  274. * IEEE-802.11d country information element to identify a country.
  275. * Users can also simply ask the wireless core to set regulatory domain
  276. * to a specific alpha2.
  277. * @NL80211_ATTR_REG_RULES: a nested array of regulatory domain regulatory
  278. * rules.
  279. *
  280. * @NL80211_ATTR_BSS_CTS_PROT: whether CTS protection is enabled (u8, 0 or 1)
  281. * @NL80211_ATTR_BSS_SHORT_PREAMBLE: whether short preamble is enabled
  282. * (u8, 0 or 1)
  283. * @NL80211_ATTR_BSS_SHORT_SLOT_TIME: whether short slot time enabled
  284. * (u8, 0 or 1)
  285. * @NL80211_ATTR_BSS_BASIC_RATES: basic rates, array of basic
  286. * rates in format defined by IEEE 802.11 7.3.2.2 but without the length
  287. * restriction (at most %NL80211_MAX_SUPP_RATES).
  288. *
  289. * @NL80211_ATTR_HT_CAPABILITY: HT Capability information element (from
  290. * association request when used with NL80211_CMD_NEW_STATION)
  291. *
  292. * @NL80211_ATTR_SUPPORTED_IFTYPES: nested attribute containing all
  293. * supported interface types, each a flag attribute with the number
  294. * of the interface mode.
  295. *
  296. * @NL80211_ATTR_MGMT_SUBTYPE: Management frame subtype for
  297. * %NL80211_CMD_SET_MGMT_EXTRA_IE.
  298. *
  299. * @NL80211_ATTR_IE: Information element(s) data (used, e.g., with
  300. * %NL80211_CMD_SET_MGMT_EXTRA_IE).
  301. *
  302. * @NL80211_ATTR_MAX_NUM_SCAN_SSIDS: number of SSIDs you can scan with
  303. * a single scan request, a wiphy attribute.
  304. *
  305. * @NL80211_ATTR_SCAN_FREQUENCIES: nested attribute with frequencies (in MHz)
  306. * @NL80211_ATTR_SCAN_SSIDS: nested attribute with SSIDs, leave out for passive
  307. * scanning and include a zero-length SSID (wildcard) for wildcard scan
  308. * @NL80211_ATTR_SCAN_GENERATION: the scan generation increases whenever the
  309. * scan result list changes (BSS expired or added) so that applications
  310. * can verify that they got a single, consistent snapshot (when all dump
  311. * messages carried the same generation number)
  312. * @NL80211_ATTR_BSS: scan result BSS
  313. *
  314. * @NL80211_ATTR_MAX: highest attribute number currently defined
  315. * @__NL80211_ATTR_AFTER_LAST: internal use
  316. */
  317. enum nl80211_attrs {
  318. /* don't change the order or add anything inbetween, this is ABI! */
  319. NL80211_ATTR_UNSPEC,
  320. NL80211_ATTR_WIPHY,
  321. NL80211_ATTR_WIPHY_NAME,
  322. NL80211_ATTR_IFINDEX,
  323. NL80211_ATTR_IFNAME,
  324. NL80211_ATTR_IFTYPE,
  325. NL80211_ATTR_MAC,
  326. NL80211_ATTR_KEY_DATA,
  327. NL80211_ATTR_KEY_IDX,
  328. NL80211_ATTR_KEY_CIPHER,
  329. NL80211_ATTR_KEY_SEQ,
  330. NL80211_ATTR_KEY_DEFAULT,
  331. NL80211_ATTR_BEACON_INTERVAL,
  332. NL80211_ATTR_DTIM_PERIOD,
  333. NL80211_ATTR_BEACON_HEAD,
  334. NL80211_ATTR_BEACON_TAIL,
  335. NL80211_ATTR_STA_AID,
  336. NL80211_ATTR_STA_FLAGS,
  337. NL80211_ATTR_STA_LISTEN_INTERVAL,
  338. NL80211_ATTR_STA_SUPPORTED_RATES,
  339. NL80211_ATTR_STA_VLAN,
  340. NL80211_ATTR_STA_INFO,
  341. NL80211_ATTR_WIPHY_BANDS,
  342. NL80211_ATTR_MNTR_FLAGS,
  343. NL80211_ATTR_MESH_ID,
  344. NL80211_ATTR_STA_PLINK_ACTION,
  345. NL80211_ATTR_MPATH_NEXT_HOP,
  346. NL80211_ATTR_MPATH_INFO,
  347. NL80211_ATTR_BSS_CTS_PROT,
  348. NL80211_ATTR_BSS_SHORT_PREAMBLE,
  349. NL80211_ATTR_BSS_SHORT_SLOT_TIME,
  350. NL80211_ATTR_HT_CAPABILITY,
  351. NL80211_ATTR_SUPPORTED_IFTYPES,
  352. NL80211_ATTR_REG_ALPHA2,
  353. NL80211_ATTR_REG_RULES,
  354. NL80211_ATTR_MESH_PARAMS,
  355. NL80211_ATTR_BSS_BASIC_RATES,
  356. NL80211_ATTR_WIPHY_TXQ_PARAMS,
  357. NL80211_ATTR_WIPHY_FREQ,
  358. NL80211_ATTR_WIPHY_CHANNEL_TYPE,
  359. NL80211_ATTR_KEY_DEFAULT_MGMT,
  360. NL80211_ATTR_MGMT_SUBTYPE,
  361. NL80211_ATTR_IE,
  362. NL80211_ATTR_MAX_NUM_SCAN_SSIDS,
  363. NL80211_ATTR_SCAN_FREQUENCIES,
  364. NL80211_ATTR_SCAN_SSIDS,
  365. NL80211_ATTR_SCAN_GENERATION,
  366. NL80211_ATTR_BSS,
  367. /* add attributes here, update the policy in nl80211.c */
  368. __NL80211_ATTR_AFTER_LAST,
  369. NL80211_ATTR_MAX = __NL80211_ATTR_AFTER_LAST - 1
  370. };
  371. /*
  372. * Allow user space programs to use #ifdef on new attributes by defining them
  373. * here
  374. */
  375. #define NL80211_ATTR_HT_CAPABILITY NL80211_ATTR_HT_CAPABILITY
  376. #define NL80211_ATTR_BSS_BASIC_RATES NL80211_ATTR_BSS_BASIC_RATES
  377. #define NL80211_ATTR_WIPHY_TXQ_PARAMS NL80211_ATTR_WIPHY_TXQ_PARAMS
  378. #define NL80211_ATTR_WIPHY_FREQ NL80211_ATTR_WIPHY_FREQ
  379. #define NL80211_ATTR_WIPHY_CHANNEL_TYPE NL80211_ATTR_WIPHY_CHANNEL_TYPE
  380. #define NL80211_ATTR_MGMT_SUBTYPE NL80211_ATTR_MGMT_SUBTYPE
  381. #define NL80211_ATTR_IE NL80211_ATTR_IE
  382. #define NL80211_MAX_SUPP_RATES 32
  383. #define NL80211_MAX_SUPP_REG_RULES 32
  384. #define NL80211_TKIP_DATA_OFFSET_ENCR_KEY 0
  385. #define NL80211_TKIP_DATA_OFFSET_TX_MIC_KEY 16
  386. #define NL80211_TKIP_DATA_OFFSET_RX_MIC_KEY 24
  387. #define NL80211_HT_CAPABILITY_LEN 26
  388. /**
  389. * enum nl80211_iftype - (virtual) interface types
  390. *
  391. * @NL80211_IFTYPE_UNSPECIFIED: unspecified type, driver decides
  392. * @NL80211_IFTYPE_ADHOC: independent BSS member
  393. * @NL80211_IFTYPE_STATION: managed BSS member
  394. * @NL80211_IFTYPE_AP: access point
  395. * @NL80211_IFTYPE_AP_VLAN: VLAN interface for access points
  396. * @NL80211_IFTYPE_WDS: wireless distribution interface
  397. * @NL80211_IFTYPE_MONITOR: monitor interface receiving all frames
  398. * @NL80211_IFTYPE_MESH_POINT: mesh point
  399. * @NL80211_IFTYPE_MAX: highest interface type number currently defined
  400. * @__NL80211_IFTYPE_AFTER_LAST: internal use
  401. *
  402. * These values are used with the %NL80211_ATTR_IFTYPE
  403. * to set the type of an interface.
  404. *
  405. */
  406. enum nl80211_iftype {
  407. NL80211_IFTYPE_UNSPECIFIED,
  408. NL80211_IFTYPE_ADHOC,
  409. NL80211_IFTYPE_STATION,
  410. NL80211_IFTYPE_AP,
  411. NL80211_IFTYPE_AP_VLAN,
  412. NL80211_IFTYPE_WDS,
  413. NL80211_IFTYPE_MONITOR,
  414. NL80211_IFTYPE_MESH_POINT,
  415. /* keep last */
  416. __NL80211_IFTYPE_AFTER_LAST,
  417. NL80211_IFTYPE_MAX = __NL80211_IFTYPE_AFTER_LAST - 1
  418. };
  419. /**
  420. * enum nl80211_sta_flags - station flags
  421. *
  422. * Station flags. When a station is added to an AP interface, it is
  423. * assumed to be already associated (and hence authenticated.)
  424. *
  425. * @NL80211_STA_FLAG_AUTHORIZED: station is authorized (802.1X)
  426. * @NL80211_STA_FLAG_SHORT_PREAMBLE: station is capable of receiving frames
  427. * with short barker preamble
  428. * @NL80211_STA_FLAG_WME: station is WME/QoS capable
  429. * @NL80211_STA_FLAG_MFP: station uses management frame protection
  430. */
  431. enum nl80211_sta_flags {
  432. __NL80211_STA_FLAG_INVALID,
  433. NL80211_STA_FLAG_AUTHORIZED,
  434. NL80211_STA_FLAG_SHORT_PREAMBLE,
  435. NL80211_STA_FLAG_WME,
  436. NL80211_STA_FLAG_MFP,
  437. /* keep last */
  438. __NL80211_STA_FLAG_AFTER_LAST,
  439. NL80211_STA_FLAG_MAX = __NL80211_STA_FLAG_AFTER_LAST - 1
  440. };
  441. /**
  442. * enum nl80211_rate_info - bitrate information
  443. *
  444. * These attribute types are used with %NL80211_STA_INFO_TXRATE
  445. * when getting information about the bitrate of a station.
  446. *
  447. * @__NL80211_RATE_INFO_INVALID: attribute number 0 is reserved
  448. * @NL80211_RATE_INFO_BITRATE: total bitrate (u16, 100kbit/s)
  449. * @NL80211_RATE_INFO_MCS: mcs index for 802.11n (u8)
  450. * @NL80211_RATE_INFO_40_MHZ_WIDTH: 40 Mhz dualchannel bitrate
  451. * @NL80211_RATE_INFO_SHORT_GI: 400ns guard interval
  452. * @NL80211_RATE_INFO_MAX: highest rate_info number currently defined
  453. * @__NL80211_RATE_INFO_AFTER_LAST: internal use
  454. */
  455. enum nl80211_rate_info {
  456. __NL80211_RATE_INFO_INVALID,
  457. NL80211_RATE_INFO_BITRATE,
  458. NL80211_RATE_INFO_MCS,
  459. NL80211_RATE_INFO_40_MHZ_WIDTH,
  460. NL80211_RATE_INFO_SHORT_GI,
  461. /* keep last */
  462. __NL80211_RATE_INFO_AFTER_LAST,
  463. NL80211_RATE_INFO_MAX = __NL80211_RATE_INFO_AFTER_LAST - 1
  464. };
  465. /**
  466. * enum nl80211_sta_info - station information
  467. *
  468. * These attribute types are used with %NL80211_ATTR_STA_INFO
  469. * when getting information about a station.
  470. *
  471. * @__NL80211_STA_INFO_INVALID: attribute number 0 is reserved
  472. * @NL80211_STA_INFO_INACTIVE_TIME: time since last activity (u32, msecs)
  473. * @NL80211_STA_INFO_RX_BYTES: total received bytes (u32, from this station)
  474. * @NL80211_STA_INFO_TX_BYTES: total transmitted bytes (u32, to this station)
  475. * @__NL80211_STA_INFO_AFTER_LAST: internal
  476. * @NL80211_STA_INFO_MAX: highest possible station info attribute
  477. * @NL80211_STA_INFO_SIGNAL: signal strength of last received PPDU (u8, dBm)
  478. * @NL80211_STA_INFO_TX_BITRATE: current unicast tx rate, nested attribute
  479. * containing info as possible, see &enum nl80211_sta_info_txrate.
  480. * @NL80211_STA_INFO_RX_PACKETS: total received packet (u32, from this station)
  481. * @NL80211_STA_INFO_TX_PACKETS: total transmitted packets (u32, to this
  482. * station)
  483. */
  484. enum nl80211_sta_info {
  485. __NL80211_STA_INFO_INVALID,
  486. NL80211_STA_INFO_INACTIVE_TIME,
  487. NL80211_STA_INFO_RX_BYTES,
  488. NL80211_STA_INFO_TX_BYTES,
  489. NL80211_STA_INFO_LLID,
  490. NL80211_STA_INFO_PLID,
  491. NL80211_STA_INFO_PLINK_STATE,
  492. NL80211_STA_INFO_SIGNAL,
  493. NL80211_STA_INFO_TX_BITRATE,
  494. NL80211_STA_INFO_RX_PACKETS,
  495. NL80211_STA_INFO_TX_PACKETS,
  496. /* keep last */
  497. __NL80211_STA_INFO_AFTER_LAST,
  498. NL80211_STA_INFO_MAX = __NL80211_STA_INFO_AFTER_LAST - 1
  499. };
  500. /**
  501. * enum nl80211_mpath_flags - nl80211 mesh path flags
  502. *
  503. * @NL80211_MPATH_FLAG_ACTIVE: the mesh path is active
  504. * @NL80211_MPATH_FLAG_RESOLVING: the mesh path discovery process is running
  505. * @NL80211_MPATH_FLAG_DSN_VALID: the mesh path contains a valid DSN
  506. * @NL80211_MPATH_FLAG_FIXED: the mesh path has been manually set
  507. * @NL80211_MPATH_FLAG_RESOLVED: the mesh path discovery process succeeded
  508. */
  509. enum nl80211_mpath_flags {
  510. NL80211_MPATH_FLAG_ACTIVE = 1<<0,
  511. NL80211_MPATH_FLAG_RESOLVING = 1<<1,
  512. NL80211_MPATH_FLAG_DSN_VALID = 1<<2,
  513. NL80211_MPATH_FLAG_FIXED = 1<<3,
  514. NL80211_MPATH_FLAG_RESOLVED = 1<<4,
  515. };
  516. /**
  517. * enum nl80211_mpath_info - mesh path information
  518. *
  519. * These attribute types are used with %NL80211_ATTR_MPATH_INFO when getting
  520. * information about a mesh path.
  521. *
  522. * @__NL80211_MPATH_INFO_INVALID: attribute number 0 is reserved
  523. * @NL80211_ATTR_MPATH_FRAME_QLEN: number of queued frames for this destination
  524. * @NL80211_ATTR_MPATH_DSN: destination sequence number
  525. * @NL80211_ATTR_MPATH_METRIC: metric (cost) of this mesh path
  526. * @NL80211_ATTR_MPATH_EXPTIME: expiration time for the path, in msec from now
  527. * @NL80211_ATTR_MPATH_FLAGS: mesh path flags, enumerated in
  528. * &enum nl80211_mpath_flags;
  529. * @NL80211_ATTR_MPATH_DISCOVERY_TIMEOUT: total path discovery timeout, in msec
  530. * @NL80211_ATTR_MPATH_DISCOVERY_RETRIES: mesh path discovery retries
  531. */
  532. enum nl80211_mpath_info {
  533. __NL80211_MPATH_INFO_INVALID,
  534. NL80211_MPATH_INFO_FRAME_QLEN,
  535. NL80211_MPATH_INFO_DSN,
  536. NL80211_MPATH_INFO_METRIC,
  537. NL80211_MPATH_INFO_EXPTIME,
  538. NL80211_MPATH_INFO_FLAGS,
  539. NL80211_MPATH_INFO_DISCOVERY_TIMEOUT,
  540. NL80211_MPATH_INFO_DISCOVERY_RETRIES,
  541. /* keep last */
  542. __NL80211_MPATH_INFO_AFTER_LAST,
  543. NL80211_MPATH_INFO_MAX = __NL80211_MPATH_INFO_AFTER_LAST - 1
  544. };
  545. /**
  546. * enum nl80211_band_attr - band attributes
  547. * @__NL80211_BAND_ATTR_INVALID: attribute number 0 is reserved
  548. * @NL80211_BAND_ATTR_FREQS: supported frequencies in this band,
  549. * an array of nested frequency attributes
  550. * @NL80211_BAND_ATTR_RATES: supported bitrates in this band,
  551. * an array of nested bitrate attributes
  552. * @NL80211_BAND_ATTR_HT_MCS_SET: 16-byte attribute containing the MCS set as
  553. * defined in 802.11n
  554. * @NL80211_BAND_ATTR_HT_CAPA: HT capabilities, as in the HT information IE
  555. * @NL80211_BAND_ATTR_HT_AMPDU_FACTOR: A-MPDU factor, as in 11n
  556. * @NL80211_BAND_ATTR_HT_AMPDU_DENSITY: A-MPDU density, as in 11n
  557. */
  558. enum nl80211_band_attr {
  559. __NL80211_BAND_ATTR_INVALID,
  560. NL80211_BAND_ATTR_FREQS,
  561. NL80211_BAND_ATTR_RATES,
  562. NL80211_BAND_ATTR_HT_MCS_SET,
  563. NL80211_BAND_ATTR_HT_CAPA,
  564. NL80211_BAND_ATTR_HT_AMPDU_FACTOR,
  565. NL80211_BAND_ATTR_HT_AMPDU_DENSITY,
  566. /* keep last */
  567. __NL80211_BAND_ATTR_AFTER_LAST,
  568. NL80211_BAND_ATTR_MAX = __NL80211_BAND_ATTR_AFTER_LAST - 1
  569. };
  570. #define NL80211_BAND_ATTR_HT_CAPA NL80211_BAND_ATTR_HT_CAPA
  571. /**
  572. * enum nl80211_frequency_attr - frequency attributes
  573. * @NL80211_FREQUENCY_ATTR_FREQ: Frequency in MHz
  574. * @NL80211_FREQUENCY_ATTR_DISABLED: Channel is disabled in current
  575. * regulatory domain.
  576. * @NL80211_FREQUENCY_ATTR_PASSIVE_SCAN: Only passive scanning is
  577. * permitted on this channel in current regulatory domain.
  578. * @NL80211_FREQUENCY_ATTR_NO_IBSS: IBSS networks are not permitted
  579. * on this channel in current regulatory domain.
  580. * @NL80211_FREQUENCY_ATTR_RADAR: Radar detection is mandatory
  581. * on this channel in current regulatory domain.
  582. * @NL80211_FREQUENCY_ATTR_MAX_TX_POWER: Maximum transmission power in mBm
  583. * (100 * dBm).
  584. */
  585. enum nl80211_frequency_attr {
  586. __NL80211_FREQUENCY_ATTR_INVALID,
  587. NL80211_FREQUENCY_ATTR_FREQ,
  588. NL80211_FREQUENCY_ATTR_DISABLED,
  589. NL80211_FREQUENCY_ATTR_PASSIVE_SCAN,
  590. NL80211_FREQUENCY_ATTR_NO_IBSS,
  591. NL80211_FREQUENCY_ATTR_RADAR,
  592. NL80211_FREQUENCY_ATTR_MAX_TX_POWER,
  593. /* keep last */
  594. __NL80211_FREQUENCY_ATTR_AFTER_LAST,
  595. NL80211_FREQUENCY_ATTR_MAX = __NL80211_FREQUENCY_ATTR_AFTER_LAST - 1
  596. };
  597. #define NL80211_FREQUENCY_ATTR_MAX_TX_POWER NL80211_FREQUENCY_ATTR_MAX_TX_POWER
  598. /**
  599. * enum nl80211_bitrate_attr - bitrate attributes
  600. * @NL80211_BITRATE_ATTR_RATE: Bitrate in units of 100 kbps
  601. * @NL80211_BITRATE_ATTR_2GHZ_SHORTPREAMBLE: Short preamble supported
  602. * in 2.4 GHz band.
  603. */
  604. enum nl80211_bitrate_attr {
  605. __NL80211_BITRATE_ATTR_INVALID,
  606. NL80211_BITRATE_ATTR_RATE,
  607. NL80211_BITRATE_ATTR_2GHZ_SHORTPREAMBLE,
  608. /* keep last */
  609. __NL80211_BITRATE_ATTR_AFTER_LAST,
  610. NL80211_BITRATE_ATTR_MAX = __NL80211_BITRATE_ATTR_AFTER_LAST - 1
  611. };
  612. /**
  613. * enum nl80211_reg_rule_attr - regulatory rule attributes
  614. * @NL80211_ATTR_REG_RULE_FLAGS: a set of flags which specify additional
  615. * considerations for a given frequency range. These are the
  616. * &enum nl80211_reg_rule_flags.
  617. * @NL80211_ATTR_FREQ_RANGE_START: starting frequencry for the regulatory
  618. * rule in KHz. This is not a center of frequency but an actual regulatory
  619. * band edge.
  620. * @NL80211_ATTR_FREQ_RANGE_END: ending frequency for the regulatory rule
  621. * in KHz. This is not a center a frequency but an actual regulatory
  622. * band edge.
  623. * @NL80211_ATTR_FREQ_RANGE_MAX_BW: maximum allowed bandwidth for this
  624. * frequency range, in KHz.
  625. * @NL80211_ATTR_POWER_RULE_MAX_ANT_GAIN: the maximum allowed antenna gain
  626. * for a given frequency range. The value is in mBi (100 * dBi).
  627. * If you don't have one then don't send this.
  628. * @NL80211_ATTR_POWER_RULE_MAX_EIRP: the maximum allowed EIRP for
  629. * a given frequency range. The value is in mBm (100 * dBm).
  630. */
  631. enum nl80211_reg_rule_attr {
  632. __NL80211_REG_RULE_ATTR_INVALID,
  633. NL80211_ATTR_REG_RULE_FLAGS,
  634. NL80211_ATTR_FREQ_RANGE_START,
  635. NL80211_ATTR_FREQ_RANGE_END,
  636. NL80211_ATTR_FREQ_RANGE_MAX_BW,
  637. NL80211_ATTR_POWER_RULE_MAX_ANT_GAIN,
  638. NL80211_ATTR_POWER_RULE_MAX_EIRP,
  639. /* keep last */
  640. __NL80211_REG_RULE_ATTR_AFTER_LAST,
  641. NL80211_REG_RULE_ATTR_MAX = __NL80211_REG_RULE_ATTR_AFTER_LAST - 1
  642. };
  643. /**
  644. * enum nl80211_reg_rule_flags - regulatory rule flags
  645. *
  646. * @NL80211_RRF_NO_OFDM: OFDM modulation not allowed
  647. * @NL80211_RRF_NO_CCK: CCK modulation not allowed
  648. * @NL80211_RRF_NO_INDOOR: indoor operation not allowed
  649. * @NL80211_RRF_NO_OUTDOOR: outdoor operation not allowed
  650. * @NL80211_RRF_DFS: DFS support is required to be used
  651. * @NL80211_RRF_PTP_ONLY: this is only for Point To Point links
  652. * @NL80211_RRF_PTMP_ONLY: this is only for Point To Multi Point links
  653. * @NL80211_RRF_PASSIVE_SCAN: passive scan is required
  654. * @NL80211_RRF_NO_IBSS: no IBSS is allowed
  655. */
  656. enum nl80211_reg_rule_flags {
  657. NL80211_RRF_NO_OFDM = 1<<0,
  658. NL80211_RRF_NO_CCK = 1<<1,
  659. NL80211_RRF_NO_INDOOR = 1<<2,
  660. NL80211_RRF_NO_OUTDOOR = 1<<3,
  661. NL80211_RRF_DFS = 1<<4,
  662. NL80211_RRF_PTP_ONLY = 1<<5,
  663. NL80211_RRF_PTMP_ONLY = 1<<6,
  664. NL80211_RRF_PASSIVE_SCAN = 1<<7,
  665. NL80211_RRF_NO_IBSS = 1<<8,
  666. };
  667. /**
  668. * enum nl80211_mntr_flags - monitor configuration flags
  669. *
  670. * Monitor configuration flags.
  671. *
  672. * @__NL80211_MNTR_FLAG_INVALID: reserved
  673. *
  674. * @NL80211_MNTR_FLAG_FCSFAIL: pass frames with bad FCS
  675. * @NL80211_MNTR_FLAG_PLCPFAIL: pass frames with bad PLCP
  676. * @NL80211_MNTR_FLAG_CONTROL: pass control frames
  677. * @NL80211_MNTR_FLAG_OTHER_BSS: disable BSSID filtering
  678. * @NL80211_MNTR_FLAG_COOK_FRAMES: report frames after processing.
  679. * overrides all other flags.
  680. *
  681. * @__NL80211_MNTR_FLAG_AFTER_LAST: internal use
  682. * @NL80211_MNTR_FLAG_MAX: highest possible monitor flag
  683. */
  684. enum nl80211_mntr_flags {
  685. __NL80211_MNTR_FLAG_INVALID,
  686. NL80211_MNTR_FLAG_FCSFAIL,
  687. NL80211_MNTR_FLAG_PLCPFAIL,
  688. NL80211_MNTR_FLAG_CONTROL,
  689. NL80211_MNTR_FLAG_OTHER_BSS,
  690. NL80211_MNTR_FLAG_COOK_FRAMES,
  691. /* keep last */
  692. __NL80211_MNTR_FLAG_AFTER_LAST,
  693. NL80211_MNTR_FLAG_MAX = __NL80211_MNTR_FLAG_AFTER_LAST - 1
  694. };
  695. /**
  696. * enum nl80211_meshconf_params - mesh configuration parameters
  697. *
  698. * Mesh configuration parameters
  699. *
  700. * @__NL80211_MESHCONF_INVALID: internal use
  701. *
  702. * @NL80211_MESHCONF_RETRY_TIMEOUT: specifies the initial retry timeout in
  703. * millisecond units, used by the Peer Link Open message
  704. *
  705. * @NL80211_MESHCONF_CONFIRM_TIMEOUT: specifies the inital confirm timeout, in
  706. * millisecond units, used by the peer link management to close a peer link
  707. *
  708. * @NL80211_MESHCONF_HOLDING_TIMEOUT: specifies the holding timeout, in
  709. * millisecond units
  710. *
  711. * @NL80211_MESHCONF_MAX_PEER_LINKS: maximum number of peer links allowed
  712. * on this mesh interface
  713. *
  714. * @NL80211_MESHCONF_MAX_RETRIES: specifies the maximum number of peer link
  715. * open retries that can be sent to establish a new peer link instance in a
  716. * mesh
  717. *
  718. * @NL80211_MESHCONF_TTL: specifies the value of TTL field set at a source mesh
  719. * point.
  720. *
  721. * @NL80211_MESHCONF_AUTO_OPEN_PLINKS: whether we should automatically
  722. * open peer links when we detect compatible mesh peers.
  723. *
  724. * @NL80211_MESHCONF_HWMP_MAX_PREQ_RETRIES: the number of action frames
  725. * containing a PREQ that an MP can send to a particular destination (path
  726. * target)
  727. *
  728. * @NL80211_MESHCONF_PATH_REFRESH_TIME: how frequently to refresh mesh paths
  729. * (in milliseconds)
  730. *
  731. * @NL80211_MESHCONF_MIN_DISCOVERY_TIMEOUT: minimum length of time to wait
  732. * until giving up on a path discovery (in milliseconds)
  733. *
  734. * @NL80211_MESHCONF_HWMP_ACTIVE_PATH_TIMEOUT: The time (in TUs) for which mesh
  735. * points receiving a PREQ shall consider the forwarding information from the
  736. * root to be valid. (TU = time unit)
  737. *
  738. * @NL80211_MESHCONF_HWMP_PREQ_MIN_INTERVAL: The minimum interval of time (in
  739. * TUs) during which an MP can send only one action frame containing a PREQ
  740. * reference element
  741. *
  742. * @NL80211_MESHCONF_HWMP_NET_DIAM_TRVS_TIME: The interval of time (in TUs)
  743. * that it takes for an HWMP information element to propagate across the mesh
  744. *
  745. * @NL80211_MESHCONF_ATTR_MAX: highest possible mesh configuration attribute
  746. *
  747. * @__NL80211_MESHCONF_ATTR_AFTER_LAST: internal use
  748. */
  749. enum nl80211_meshconf_params {
  750. __NL80211_MESHCONF_INVALID,
  751. NL80211_MESHCONF_RETRY_TIMEOUT,
  752. NL80211_MESHCONF_CONFIRM_TIMEOUT,
  753. NL80211_MESHCONF_HOLDING_TIMEOUT,
  754. NL80211_MESHCONF_MAX_PEER_LINKS,
  755. NL80211_MESHCONF_MAX_RETRIES,
  756. NL80211_MESHCONF_TTL,
  757. NL80211_MESHCONF_AUTO_OPEN_PLINKS,
  758. NL80211_MESHCONF_HWMP_MAX_PREQ_RETRIES,
  759. NL80211_MESHCONF_PATH_REFRESH_TIME,
  760. NL80211_MESHCONF_MIN_DISCOVERY_TIMEOUT,
  761. NL80211_MESHCONF_HWMP_ACTIVE_PATH_TIMEOUT,
  762. NL80211_MESHCONF_HWMP_PREQ_MIN_INTERVAL,
  763. NL80211_MESHCONF_HWMP_NET_DIAM_TRVS_TIME,
  764. /* keep last */
  765. __NL80211_MESHCONF_ATTR_AFTER_LAST,
  766. NL80211_MESHCONF_ATTR_MAX = __NL80211_MESHCONF_ATTR_AFTER_LAST - 1
  767. };
  768. /**
  769. * enum nl80211_txq_attr - TX queue parameter attributes
  770. * @__NL80211_TXQ_ATTR_INVALID: Attribute number 0 is reserved
  771. * @NL80211_TXQ_ATTR_QUEUE: TX queue identifier (NL80211_TXQ_Q_*)
  772. * @NL80211_TXQ_ATTR_TXOP: Maximum burst time in units of 32 usecs, 0 meaning
  773. * disabled
  774. * @NL80211_TXQ_ATTR_CWMIN: Minimum contention window [a value of the form
  775. * 2^n-1 in the range 1..32767]
  776. * @NL80211_TXQ_ATTR_CWMAX: Maximum contention window [a value of the form
  777. * 2^n-1 in the range 1..32767]
  778. * @NL80211_TXQ_ATTR_AIFS: Arbitration interframe space [0..255]
  779. * @__NL80211_TXQ_ATTR_AFTER_LAST: Internal
  780. * @NL80211_TXQ_ATTR_MAX: Maximum TXQ attribute number
  781. */
  782. enum nl80211_txq_attr {
  783. __NL80211_TXQ_ATTR_INVALID,
  784. NL80211_TXQ_ATTR_QUEUE,
  785. NL80211_TXQ_ATTR_TXOP,
  786. NL80211_TXQ_ATTR_CWMIN,
  787. NL80211_TXQ_ATTR_CWMAX,
  788. NL80211_TXQ_ATTR_AIFS,
  789. /* keep last */
  790. __NL80211_TXQ_ATTR_AFTER_LAST,
  791. NL80211_TXQ_ATTR_MAX = __NL80211_TXQ_ATTR_AFTER_LAST - 1
  792. };
  793. enum nl80211_txq_q {
  794. NL80211_TXQ_Q_VO,
  795. NL80211_TXQ_Q_VI,
  796. NL80211_TXQ_Q_BE,
  797. NL80211_TXQ_Q_BK
  798. };
  799. enum nl80211_channel_type {
  800. NL80211_CHAN_NO_HT,
  801. NL80211_CHAN_HT20,
  802. NL80211_CHAN_HT40MINUS,
  803. NL80211_CHAN_HT40PLUS
  804. };
  805. /**
  806. * enum nl80211_bss - netlink attributes for a BSS
  807. *
  808. * @__NL80211_BSS_INVALID: invalid
  809. * @NL80211_BSS_FREQUENCY: frequency in MHz (u32)
  810. * @NL80211_BSS_TSF: TSF of the received probe response/beacon (u64)
  811. * @NL80211_BSS_BEACON_INTERVAL: beacon interval of the (I)BSS (u16)
  812. * @NL80211_BSS_CAPABILITY: capability field (CPU order, u16)
  813. * @NL80211_BSS_INFORMATION_ELEMENTS: binary attribute containing the
  814. * raw information elements from the probe response/beacon (bin)
  815. * @NL80211_BSS_SIGNAL_MBM: signal strength of probe response/beacon
  816. * in mBm (100 * dBm) (s32)
  817. * @NL80211_BSS_SIGNAL_UNSPEC: signal strength of the probe response/beacon
  818. * in unspecified units, scaled to 0..100 (u8)
  819. * @__NL80211_BSS_AFTER_LAST: internal
  820. * @NL80211_BSS_MAX: highest BSS attribute
  821. */
  822. enum nl80211_bss {
  823. __NL80211_BSS_INVALID,
  824. NL80211_BSS_BSSID,
  825. NL80211_BSS_FREQUENCY,
  826. NL80211_BSS_TSF,
  827. NL80211_BSS_BEACON_INTERVAL,
  828. NL80211_BSS_CAPABILITY,
  829. NL80211_BSS_INFORMATION_ELEMENTS,
  830. NL80211_BSS_SIGNAL_MBM,
  831. NL80211_BSS_SIGNAL_UNSPEC,
  832. /* keep last */
  833. __NL80211_BSS_AFTER_LAST,
  834. NL80211_BSS_MAX = __NL80211_BSS_AFTER_LAST - 1
  835. };
  836. #endif /* __LINUX_NL80211_H */