diff options
Diffstat (limited to 'include/linux/nl80211.h')
-rw-r--r-- | include/linux/nl80211.h | 110 |
1 files changed, 105 insertions, 5 deletions
diff --git a/include/linux/nl80211.h b/include/linux/nl80211.h index e86ed59f9ad5..f6e56370ea65 100644 --- a/include/linux/nl80211.h +++ b/include/linux/nl80211.h | |||
@@ -47,7 +47,7 @@ | |||
47 | * @NL80211_CMD_SET_WIPHY: set wiphy parameters, needs %NL80211_ATTR_WIPHY or | 47 | * @NL80211_CMD_SET_WIPHY: set wiphy parameters, needs %NL80211_ATTR_WIPHY or |
48 | * %NL80211_ATTR_IFINDEX; can be used to set %NL80211_ATTR_WIPHY_NAME, | 48 | * %NL80211_ATTR_IFINDEX; can be used to set %NL80211_ATTR_WIPHY_NAME, |
49 | * %NL80211_ATTR_WIPHY_TXQ_PARAMS, %NL80211_ATTR_WIPHY_FREQ, and/or | 49 | * %NL80211_ATTR_WIPHY_TXQ_PARAMS, %NL80211_ATTR_WIPHY_FREQ, and/or |
50 | * %NL80211_ATTR_WIPHY_SEC_CHAN_OFFSET. | 50 | * %NL80211_ATTR_WIPHY_CHANNEL_TYPE. |
51 | * @NL80211_CMD_NEW_WIPHY: Newly created wiphy, response to get request | 51 | * @NL80211_CMD_NEW_WIPHY: Newly created wiphy, response to get request |
52 | * or rename notification. Has attributes %NL80211_ATTR_WIPHY and | 52 | * or rename notification. Has attributes %NL80211_ATTR_WIPHY and |
53 | * %NL80211_ATTR_WIPHY_NAME. | 53 | * %NL80211_ATTR_WIPHY_NAME. |
@@ -72,8 +72,8 @@ | |||
72 | * | 72 | * |
73 | * @NL80211_CMD_GET_KEY: Get sequence counter information for a key specified | 73 | * @NL80211_CMD_GET_KEY: Get sequence counter information for a key specified |
74 | * by %NL80211_ATTR_KEY_IDX and/or %NL80211_ATTR_MAC. | 74 | * by %NL80211_ATTR_KEY_IDX and/or %NL80211_ATTR_MAC. |
75 | * @NL80211_CMD_SET_KEY: Set key attributes %NL80211_ATTR_KEY_DEFAULT or | 75 | * @NL80211_CMD_SET_KEY: Set key attributes %NL80211_ATTR_KEY_DEFAULT, |
76 | * %NL80211_ATTR_KEY_THRESHOLD. | 76 | * %NL80211_ATTR_KEY_DEFAULT_MGMT, or %NL80211_ATTR_KEY_THRESHOLD. |
77 | * @NL80211_CMD_NEW_KEY: add a key with given %NL80211_ATTR_KEY_DATA, | 77 | * @NL80211_CMD_NEW_KEY: add a key with given %NL80211_ATTR_KEY_DATA, |
78 | * %NL80211_ATTR_KEY_IDX, %NL80211_ATTR_MAC and %NL80211_ATTR_KEY_CIPHER | 78 | * %NL80211_ATTR_KEY_IDX, %NL80211_ATTR_MAC and %NL80211_ATTR_KEY_CIPHER |
79 | * attributes. | 79 | * attributes. |
@@ -84,7 +84,7 @@ | |||
84 | * %NL80222_CMD_NEW_BEACON message) | 84 | * %NL80222_CMD_NEW_BEACON message) |
85 | * @NL80211_CMD_SET_BEACON: set the beacon on an access point interface | 85 | * @NL80211_CMD_SET_BEACON: set the beacon on an access point interface |
86 | * using the %NL80211_ATTR_BEACON_INTERVAL, %NL80211_ATTR_DTIM_PERIOD, | 86 | * using the %NL80211_ATTR_BEACON_INTERVAL, %NL80211_ATTR_DTIM_PERIOD, |
87 | * %NL80211_BEACON_HEAD and %NL80211_BEACON_TAIL attributes. | 87 | * %NL80211_ATTR_BEACON_HEAD and %NL80211_ATTR_BEACON_TAIL attributes. |
88 | * @NL80211_CMD_NEW_BEACON: add a new beacon to an access point interface, | 88 | * @NL80211_CMD_NEW_BEACON: add a new beacon to an access point interface, |
89 | * parameters are like for %NL80211_CMD_SET_BEACON. | 89 | * parameters are like for %NL80211_CMD_SET_BEACON. |
90 | * @NL80211_CMD_DEL_BEACON: remove the beacon, stop sending it | 90 | * @NL80211_CMD_DEL_BEACON: remove the beacon, stop sending it |
@@ -113,6 +113,8 @@ | |||
113 | * @NL80211_CMD_SET_BSS: Set BSS attributes for BSS identified by | 113 | * @NL80211_CMD_SET_BSS: Set BSS attributes for BSS identified by |
114 | * %NL80211_ATTR_IFINDEX. | 114 | * %NL80211_ATTR_IFINDEX. |
115 | * | 115 | * |
116 | * @NL80211_CMD_GET_REG: ask the wireless core to send us its currently set | ||
117 | * regulatory domain. | ||
116 | * @NL80211_CMD_SET_REG: Set current regulatory domain. CRDA sends this command | 118 | * @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 | 119 | * 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 | 120 | * domain structure which consists of %NL80211_ATTR_REG_ALPHA set to our |
@@ -133,6 +135,21 @@ | |||
133 | * @NL80211_CMD_SET_MESH_PARAMS: Set mesh networking properties for the | 135 | * @NL80211_CMD_SET_MESH_PARAMS: Set mesh networking properties for the |
134 | * interface identified by %NL80211_ATTR_IFINDEX | 136 | * interface identified by %NL80211_ATTR_IFINDEX |
135 | * | 137 | * |
138 | * @NL80211_CMD_SET_MGMT_EXTRA_IE: Set extra IEs for management frames. The | ||
139 | * interface is identified with %NL80211_ATTR_IFINDEX and the management | ||
140 | * frame subtype with %NL80211_ATTR_MGMT_SUBTYPE. The extra IE data to be | ||
141 | * added to the end of the specified management frame is specified with | ||
142 | * %NL80211_ATTR_IE. If the command succeeds, the requested data will be | ||
143 | * added to all specified management frames generated by | ||
144 | * kernel/firmware/driver. | ||
145 | * | ||
146 | * @NL80211_CMD_GET_SCAN: get scan results | ||
147 | * @NL80211_CMD_TRIGGER_SCAN: trigger a new scan with the given parameters | ||
148 | * @NL80211_CMD_NEW_SCAN_RESULTS: scan notification (as a reply to | ||
149 | * NL80211_CMD_GET_SCAN and on the "scan" multicast group) | ||
150 | * @NL80211_CMD_SCAN_ABORTED: scan was aborted, for unspecified reasons, | ||
151 | * partial scan results may be available | ||
152 | * | ||
136 | * @NL80211_CMD_MAX: highest used command number | 153 | * @NL80211_CMD_MAX: highest used command number |
137 | * @__NL80211_CMD_AFTER_LAST: internal use | 154 | * @__NL80211_CMD_AFTER_LAST: internal use |
138 | */ | 155 | */ |
@@ -178,6 +195,15 @@ enum nl80211_commands { | |||
178 | NL80211_CMD_GET_MESH_PARAMS, | 195 | NL80211_CMD_GET_MESH_PARAMS, |
179 | NL80211_CMD_SET_MESH_PARAMS, | 196 | NL80211_CMD_SET_MESH_PARAMS, |
180 | 197 | ||
198 | NL80211_CMD_SET_MGMT_EXTRA_IE, | ||
199 | |||
200 | NL80211_CMD_GET_REG, | ||
201 | |||
202 | NL80211_CMD_GET_SCAN, | ||
203 | NL80211_CMD_TRIGGER_SCAN, | ||
204 | NL80211_CMD_NEW_SCAN_RESULTS, | ||
205 | NL80211_CMD_SCAN_ABORTED, | ||
206 | |||
181 | /* add new commands above here */ | 207 | /* add new commands above here */ |
182 | 208 | ||
183 | /* used to define NL80211_CMD_MAX below */ | 209 | /* used to define NL80211_CMD_MAX below */ |
@@ -190,6 +216,7 @@ enum nl80211_commands { | |||
190 | * here | 216 | * here |
191 | */ | 217 | */ |
192 | #define NL80211_CMD_SET_BSS NL80211_CMD_SET_BSS | 218 | #define NL80211_CMD_SET_BSS NL80211_CMD_SET_BSS |
219 | #define NL80211_CMD_SET_MGMT_EXTRA_IE NL80211_CMD_SET_MGMT_EXTRA_IE | ||
193 | 220 | ||
194 | /** | 221 | /** |
195 | * enum nl80211_attrs - nl80211 netlink attributes | 222 | * enum nl80211_attrs - nl80211 netlink attributes |
@@ -284,6 +311,24 @@ enum nl80211_commands { | |||
284 | * supported interface types, each a flag attribute with the number | 311 | * supported interface types, each a flag attribute with the number |
285 | * of the interface mode. | 312 | * of the interface mode. |
286 | * | 313 | * |
314 | * @NL80211_ATTR_MGMT_SUBTYPE: Management frame subtype for | ||
315 | * %NL80211_CMD_SET_MGMT_EXTRA_IE. | ||
316 | * | ||
317 | * @NL80211_ATTR_IE: Information element(s) data (used, e.g., with | ||
318 | * %NL80211_CMD_SET_MGMT_EXTRA_IE). | ||
319 | * | ||
320 | * @NL80211_ATTR_MAX_NUM_SCAN_SSIDS: number of SSIDs you can scan with | ||
321 | * a single scan request, a wiphy attribute. | ||
322 | * | ||
323 | * @NL80211_ATTR_SCAN_FREQUENCIES: nested attribute with frequencies (in MHz) | ||
324 | * @NL80211_ATTR_SCAN_SSIDS: nested attribute with SSIDs, leave out for passive | ||
325 | * scanning and include a zero-length SSID (wildcard) for wildcard scan | ||
326 | * @NL80211_ATTR_SCAN_GENERATION: the scan generation increases whenever the | ||
327 | * scan result list changes (BSS expired or added) so that applications | ||
328 | * can verify that they got a single, consistent snapshot (when all dump | ||
329 | * messages carried the same generation number) | ||
330 | * @NL80211_ATTR_BSS: scan result BSS | ||
331 | * | ||
287 | * @NL80211_ATTR_MAX: highest attribute number currently defined | 332 | * @NL80211_ATTR_MAX: highest attribute number currently defined |
288 | * @__NL80211_ATTR_AFTER_LAST: internal use | 333 | * @__NL80211_ATTR_AFTER_LAST: internal use |
289 | */ | 334 | */ |
@@ -346,6 +391,18 @@ enum nl80211_attrs { | |||
346 | NL80211_ATTR_WIPHY_FREQ, | 391 | NL80211_ATTR_WIPHY_FREQ, |
347 | NL80211_ATTR_WIPHY_CHANNEL_TYPE, | 392 | NL80211_ATTR_WIPHY_CHANNEL_TYPE, |
348 | 393 | ||
394 | NL80211_ATTR_KEY_DEFAULT_MGMT, | ||
395 | |||
396 | NL80211_ATTR_MGMT_SUBTYPE, | ||
397 | NL80211_ATTR_IE, | ||
398 | |||
399 | NL80211_ATTR_MAX_NUM_SCAN_SSIDS, | ||
400 | |||
401 | NL80211_ATTR_SCAN_FREQUENCIES, | ||
402 | NL80211_ATTR_SCAN_SSIDS, | ||
403 | NL80211_ATTR_SCAN_GENERATION, | ||
404 | NL80211_ATTR_BSS, | ||
405 | |||
349 | /* add attributes here, update the policy in nl80211.c */ | 406 | /* add attributes here, update the policy in nl80211.c */ |
350 | 407 | ||
351 | __NL80211_ATTR_AFTER_LAST, | 408 | __NL80211_ATTR_AFTER_LAST, |
@@ -360,7 +417,9 @@ enum nl80211_attrs { | |||
360 | #define NL80211_ATTR_BSS_BASIC_RATES NL80211_ATTR_BSS_BASIC_RATES | 417 | #define NL80211_ATTR_BSS_BASIC_RATES NL80211_ATTR_BSS_BASIC_RATES |
361 | #define NL80211_ATTR_WIPHY_TXQ_PARAMS NL80211_ATTR_WIPHY_TXQ_PARAMS | 418 | #define NL80211_ATTR_WIPHY_TXQ_PARAMS NL80211_ATTR_WIPHY_TXQ_PARAMS |
362 | #define NL80211_ATTR_WIPHY_FREQ NL80211_ATTR_WIPHY_FREQ | 419 | #define NL80211_ATTR_WIPHY_FREQ NL80211_ATTR_WIPHY_FREQ |
363 | #define NL80211_ATTR_WIPHY_SEC_CHAN_OFFSET NL80211_ATTR_WIPHY_SEC_CHAN_OFFSET | 420 | #define NL80211_ATTR_WIPHY_CHANNEL_TYPE NL80211_ATTR_WIPHY_CHANNEL_TYPE |
421 | #define NL80211_ATTR_MGMT_SUBTYPE NL80211_ATTR_MGMT_SUBTYPE | ||
422 | #define NL80211_ATTR_IE NL80211_ATTR_IE | ||
364 | 423 | ||
365 | #define NL80211_MAX_SUPP_RATES 32 | 424 | #define NL80211_MAX_SUPP_RATES 32 |
366 | #define NL80211_MAX_SUPP_REG_RULES 32 | 425 | #define NL80211_MAX_SUPP_REG_RULES 32 |
@@ -412,12 +471,14 @@ enum nl80211_iftype { | |||
412 | * @NL80211_STA_FLAG_SHORT_PREAMBLE: station is capable of receiving frames | 471 | * @NL80211_STA_FLAG_SHORT_PREAMBLE: station is capable of receiving frames |
413 | * with short barker preamble | 472 | * with short barker preamble |
414 | * @NL80211_STA_FLAG_WME: station is WME/QoS capable | 473 | * @NL80211_STA_FLAG_WME: station is WME/QoS capable |
474 | * @NL80211_STA_FLAG_MFP: station uses management frame protection | ||
415 | */ | 475 | */ |
416 | enum nl80211_sta_flags { | 476 | enum nl80211_sta_flags { |
417 | __NL80211_STA_FLAG_INVALID, | 477 | __NL80211_STA_FLAG_INVALID, |
418 | NL80211_STA_FLAG_AUTHORIZED, | 478 | NL80211_STA_FLAG_AUTHORIZED, |
419 | NL80211_STA_FLAG_SHORT_PREAMBLE, | 479 | NL80211_STA_FLAG_SHORT_PREAMBLE, |
420 | NL80211_STA_FLAG_WME, | 480 | NL80211_STA_FLAG_WME, |
481 | NL80211_STA_FLAG_MFP, | ||
421 | 482 | ||
422 | /* keep last */ | 483 | /* keep last */ |
423 | __NL80211_STA_FLAG_AFTER_LAST, | 484 | __NL80211_STA_FLAG_AFTER_LAST, |
@@ -465,6 +526,9 @@ enum nl80211_rate_info { | |||
465 | * @NL80211_STA_INFO_SIGNAL: signal strength of last received PPDU (u8, dBm) | 526 | * @NL80211_STA_INFO_SIGNAL: signal strength of last received PPDU (u8, dBm) |
466 | * @NL80211_STA_INFO_TX_BITRATE: current unicast tx rate, nested attribute | 527 | * @NL80211_STA_INFO_TX_BITRATE: current unicast tx rate, nested attribute |
467 | * containing info as possible, see &enum nl80211_sta_info_txrate. | 528 | * containing info as possible, see &enum nl80211_sta_info_txrate. |
529 | * @NL80211_STA_INFO_RX_PACKETS: total received packet (u32, from this station) | ||
530 | * @NL80211_STA_INFO_TX_PACKETS: total transmitted packets (u32, to this | ||
531 | * station) | ||
468 | */ | 532 | */ |
469 | enum nl80211_sta_info { | 533 | enum nl80211_sta_info { |
470 | __NL80211_STA_INFO_INVALID, | 534 | __NL80211_STA_INFO_INVALID, |
@@ -476,6 +540,8 @@ enum nl80211_sta_info { | |||
476 | NL80211_STA_INFO_PLINK_STATE, | 540 | NL80211_STA_INFO_PLINK_STATE, |
477 | NL80211_STA_INFO_SIGNAL, | 541 | NL80211_STA_INFO_SIGNAL, |
478 | NL80211_STA_INFO_TX_BITRATE, | 542 | NL80211_STA_INFO_TX_BITRATE, |
543 | NL80211_STA_INFO_RX_PACKETS, | ||
544 | NL80211_STA_INFO_TX_PACKETS, | ||
479 | 545 | ||
480 | /* keep last */ | 546 | /* keep last */ |
481 | __NL80211_STA_INFO_AFTER_LAST, | 547 | __NL80211_STA_INFO_AFTER_LAST, |
@@ -811,4 +877,38 @@ enum nl80211_channel_type { | |||
811 | NL80211_CHAN_HT40MINUS, | 877 | NL80211_CHAN_HT40MINUS, |
812 | NL80211_CHAN_HT40PLUS | 878 | NL80211_CHAN_HT40PLUS |
813 | }; | 879 | }; |
880 | |||
881 | /** | ||
882 | * enum nl80211_bss - netlink attributes for a BSS | ||
883 | * | ||
884 | * @__NL80211_BSS_INVALID: invalid | ||
885 | * @NL80211_BSS_FREQUENCY: frequency in MHz (u32) | ||
886 | * @NL80211_BSS_TSF: TSF of the received probe response/beacon (u64) | ||
887 | * @NL80211_BSS_BEACON_INTERVAL: beacon interval of the (I)BSS (u16) | ||
888 | * @NL80211_BSS_CAPABILITY: capability field (CPU order, u16) | ||
889 | * @NL80211_BSS_INFORMATION_ELEMENTS: binary attribute containing the | ||
890 | * raw information elements from the probe response/beacon (bin) | ||
891 | * @NL80211_BSS_SIGNAL_MBM: signal strength of probe response/beacon | ||
892 | * in mBm (100 * dBm) (s32) | ||
893 | * @NL80211_BSS_SIGNAL_UNSPEC: signal strength of the probe response/beacon | ||
894 | * in unspecified units, scaled to 0..100 (u8) | ||
895 | * @__NL80211_BSS_AFTER_LAST: internal | ||
896 | * @NL80211_BSS_MAX: highest BSS attribute | ||
897 | */ | ||
898 | enum nl80211_bss { | ||
899 | __NL80211_BSS_INVALID, | ||
900 | NL80211_BSS_BSSID, | ||
901 | NL80211_BSS_FREQUENCY, | ||
902 | NL80211_BSS_TSF, | ||
903 | NL80211_BSS_BEACON_INTERVAL, | ||
904 | NL80211_BSS_CAPABILITY, | ||
905 | NL80211_BSS_INFORMATION_ELEMENTS, | ||
906 | NL80211_BSS_SIGNAL_MBM, | ||
907 | NL80211_BSS_SIGNAL_UNSPEC, | ||
908 | |||
909 | /* keep last */ | ||
910 | __NL80211_BSS_AFTER_LAST, | ||
911 | NL80211_BSS_MAX = __NL80211_BSS_AFTER_LAST - 1 | ||
912 | }; | ||
913 | |||
814 | #endif /* __LINUX_NL80211_H */ | 914 | #endif /* __LINUX_NL80211_H */ |