aboutsummaryrefslogtreecommitdiffstats
path: root/include/uapi/linux/nl80211.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/uapi/linux/nl80211.h')
-rw-r--r--include/uapi/linux/nl80211.h113
1 files changed, 95 insertions, 18 deletions
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index 617d0fbfc96f..33a417481ad8 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -118,8 +118,9 @@
118 * to get a list of all present wiphys. 118 * to get a list of all present wiphys.
119 * @NL80211_CMD_SET_WIPHY: set wiphy parameters, needs %NL80211_ATTR_WIPHY or 119 * @NL80211_CMD_SET_WIPHY: set wiphy parameters, needs %NL80211_ATTR_WIPHY or
120 * %NL80211_ATTR_IFINDEX; can be used to set %NL80211_ATTR_WIPHY_NAME, 120 * %NL80211_ATTR_IFINDEX; can be used to set %NL80211_ATTR_WIPHY_NAME,
121 * %NL80211_ATTR_WIPHY_TXQ_PARAMS, %NL80211_ATTR_WIPHY_FREQ, 121 * %NL80211_ATTR_WIPHY_TXQ_PARAMS, %NL80211_ATTR_WIPHY_FREQ (and the
122 * %NL80211_ATTR_WIPHY_CHANNEL_TYPE, %NL80211_ATTR_WIPHY_RETRY_SHORT, 122 * attributes determining the channel width; this is used for setting
123 * monitor mode channel), %NL80211_ATTR_WIPHY_RETRY_SHORT,
123 * %NL80211_ATTR_WIPHY_RETRY_LONG, %NL80211_ATTR_WIPHY_FRAG_THRESHOLD, 124 * %NL80211_ATTR_WIPHY_RETRY_LONG, %NL80211_ATTR_WIPHY_FRAG_THRESHOLD,
124 * and/or %NL80211_ATTR_WIPHY_RTS_THRESHOLD. 125 * and/or %NL80211_ATTR_WIPHY_RTS_THRESHOLD.
125 * However, for setting the channel, see %NL80211_CMD_SET_CHANNEL 126 * However, for setting the channel, see %NL80211_CMD_SET_CHANNEL
@@ -171,7 +172,7 @@
171 * %NL80211_ATTR_AKM_SUITES, %NL80211_ATTR_PRIVACY, 172 * %NL80211_ATTR_AKM_SUITES, %NL80211_ATTR_PRIVACY,
172 * %NL80211_ATTR_AUTH_TYPE and %NL80211_ATTR_INACTIVITY_TIMEOUT. 173 * %NL80211_ATTR_AUTH_TYPE and %NL80211_ATTR_INACTIVITY_TIMEOUT.
173 * The channel to use can be set on the interface or be given using the 174 * The channel to use can be set on the interface or be given using the
174 * %NL80211_ATTR_WIPHY_FREQ and %NL80211_ATTR_WIPHY_CHANNEL_TYPE attrs. 175 * %NL80211_ATTR_WIPHY_FREQ and the attributes determining channel width.
175 * @NL80211_CMD_NEW_BEACON: old alias for %NL80211_CMD_START_AP 176 * @NL80211_CMD_NEW_BEACON: old alias for %NL80211_CMD_START_AP
176 * @NL80211_CMD_STOP_AP: Stop AP operation on the given interface 177 * @NL80211_CMD_STOP_AP: Stop AP operation on the given interface
177 * @NL80211_CMD_DEL_BEACON: old alias for %NL80211_CMD_STOP_AP 178 * @NL80211_CMD_DEL_BEACON: old alias for %NL80211_CMD_STOP_AP
@@ -401,8 +402,7 @@
401 * a response while being associated to an AP on another channel. 402 * a response while being associated to an AP on another channel.
402 * %NL80211_ATTR_IFINDEX is used to specify which interface (and thus 403 * %NL80211_ATTR_IFINDEX is used to specify which interface (and thus
403 * radio) is used. %NL80211_ATTR_WIPHY_FREQ is used to specify the 404 * radio) is used. %NL80211_ATTR_WIPHY_FREQ is used to specify the
404 * frequency for the operation and %NL80211_ATTR_WIPHY_CHANNEL_TYPE may be 405 * frequency for the operation.
405 * optionally used to specify additional channel parameters.
406 * %NL80211_ATTR_DURATION is used to specify the duration in milliseconds 406 * %NL80211_ATTR_DURATION is used to specify the duration in milliseconds
407 * to remain on the channel. This command is also used as an event to 407 * to remain on the channel. This command is also used as an event to
408 * notify when the requested duration starts (it may take a while for the 408 * notify when the requested duration starts (it may take a while for the
@@ -440,12 +440,11 @@
440 * as an event indicating reception of a frame that was not processed in 440 * as an event indicating reception of a frame that was not processed in
441 * kernel code, but is for us (i.e., which may need to be processed in a 441 * kernel code, but is for us (i.e., which may need to be processed in a
442 * user space application). %NL80211_ATTR_FRAME is used to specify the 442 * user space application). %NL80211_ATTR_FRAME is used to specify the
443 * frame contents (including header). %NL80211_ATTR_WIPHY_FREQ (and 443 * frame contents (including header). %NL80211_ATTR_WIPHY_FREQ is used
444 * optionally %NL80211_ATTR_WIPHY_CHANNEL_TYPE) is used to indicate on 444 * to indicate on which channel the frame is to be transmitted or was
445 * which channel the frame is to be transmitted or was received. If this 445 * received. If this channel is not the current channel (remain-on-channel
446 * channel is not the current channel (remain-on-channel or the 446 * or the operational channel) the device will switch to the given channel
447 * operational channel) the device will switch to the given channel and 447 * and transmit the frame, optionally waiting for a response for the time
448 * transmit the frame, optionally waiting for a response for the time
449 * specified using %NL80211_ATTR_DURATION. When called, this operation 448 * specified using %NL80211_ATTR_DURATION. When called, this operation
450 * returns a cookie (%NL80211_ATTR_COOKIE) that will be included with the 449 * returns a cookie (%NL80211_ATTR_COOKIE) that will be included with the
451 * TX status event pertaining to the TX request. 450 * TX status event pertaining to the TX request.
@@ -473,8 +472,8 @@
473 * command is used as an event to indicate the that a trigger level was 472 * command is used as an event to indicate the that a trigger level was
474 * reached. 473 * reached.
475 * @NL80211_CMD_SET_CHANNEL: Set the channel (using %NL80211_ATTR_WIPHY_FREQ 474 * @NL80211_CMD_SET_CHANNEL: Set the channel (using %NL80211_ATTR_WIPHY_FREQ
476 * and %NL80211_ATTR_WIPHY_CHANNEL_TYPE) the given interface (identifed 475 * and the attributes determining channel width) the given interface
477 * by %NL80211_ATTR_IFINDEX) shall operate on. 476 * (identifed by %NL80211_ATTR_IFINDEX) shall operate on.
478 * In case multiple channels are supported by the device, the mechanism 477 * In case multiple channels are supported by the device, the mechanism
479 * with which it switches channels is implementation-defined. 478 * with which it switches channels is implementation-defined.
480 * When a monitor interface is given, it can only switch channel while 479 * When a monitor interface is given, it can only switch channel while
@@ -526,6 +525,12 @@
526 * of PMKSA caching dandidates. 525 * of PMKSA caching dandidates.
527 * 526 *
528 * @NL80211_CMD_TDLS_OPER: Perform a high-level TDLS command (e.g. link setup). 527 * @NL80211_CMD_TDLS_OPER: Perform a high-level TDLS command (e.g. link setup).
528 * In addition, this can be used as an event to request userspace to take
529 * actions on TDLS links (set up a new link or tear down an existing one).
530 * In such events, %NL80211_ATTR_TDLS_OPERATION indicates the requested
531 * operation, %NL80211_ATTR_MAC contains the peer MAC address, and
532 * %NL80211_ATTR_REASON_CODE the reason code to be used (only with
533 * %NL80211_TDLS_TEARDOWN).
529 * @NL80211_CMD_TDLS_MGMT: Send a TDLS management frame. 534 * @NL80211_CMD_TDLS_MGMT: Send a TDLS management frame.
530 * 535 *
531 * @NL80211_CMD_UNEXPECTED_FRAME: Used by an application controlling an AP 536 * @NL80211_CMD_UNEXPECTED_FRAME: Used by an application controlling an AP
@@ -562,8 +567,8 @@
562 * 567 *
563 * @NL80211_CMD_CH_SWITCH_NOTIFY: An AP or GO may decide to switch channels 568 * @NL80211_CMD_CH_SWITCH_NOTIFY: An AP or GO may decide to switch channels
564 * independently of the userspace SME, send this event indicating 569 * independently of the userspace SME, send this event indicating
565 * %NL80211_ATTR_IFINDEX is now on %NL80211_ATTR_WIPHY_FREQ with 570 * %NL80211_ATTR_IFINDEX is now on %NL80211_ATTR_WIPHY_FREQ and the
566 * %NL80211_ATTR_WIPHY_CHANNEL_TYPE. 571 * attributes determining channel width.
567 * 572 *
568 * @NL80211_CMD_START_P2P_DEVICE: Start the given P2P Device, identified by 573 * @NL80211_CMD_START_P2P_DEVICE: Start the given P2P Device, identified by
569 * its %NL80211_ATTR_WDEV identifier. It must have been created with 574 * its %NL80211_ATTR_WDEV identifier. It must have been created with
@@ -578,6 +583,9 @@
578 * station, due to particular reason. %NL80211_ATTR_CONN_FAILED_REASON 583 * station, due to particular reason. %NL80211_ATTR_CONN_FAILED_REASON
579 * is used for this. 584 * is used for this.
580 * 585 *
586 * @NL80211_CMD_SET_MCAST_RATE: Change the rate used to send multicast frames
587 * for IBSS or MESH vif.
588 *
581 * @NL80211_CMD_MAX: highest used command number 589 * @NL80211_CMD_MAX: highest used command number
582 * @__NL80211_CMD_AFTER_LAST: internal use 590 * @__NL80211_CMD_AFTER_LAST: internal use
583 */ 591 */
@@ -726,6 +734,8 @@ enum nl80211_commands {
726 734
727 NL80211_CMD_CONN_FAILED, 735 NL80211_CMD_CONN_FAILED,
728 736
737 NL80211_CMD_SET_MCAST_RATE,
738
729 /* add new commands above here */ 739 /* add new commands above here */
730 740
731 /* used to define NL80211_CMD_MAX below */ 741 /* used to define NL80211_CMD_MAX below */
@@ -762,14 +772,26 @@ enum nl80211_commands {
762 * /sys/class/ieee80211/<phyname>/index 772 * /sys/class/ieee80211/<phyname>/index
763 * @NL80211_ATTR_WIPHY_NAME: wiphy name (used for renaming) 773 * @NL80211_ATTR_WIPHY_NAME: wiphy name (used for renaming)
764 * @NL80211_ATTR_WIPHY_TXQ_PARAMS: a nested array of TX queue parameters 774 * @NL80211_ATTR_WIPHY_TXQ_PARAMS: a nested array of TX queue parameters
765 * @NL80211_ATTR_WIPHY_FREQ: frequency of the selected channel in MHz 775 * @NL80211_ATTR_WIPHY_FREQ: frequency of the selected channel in MHz,
776 * defines the channel together with the (deprecated)
777 * %NL80211_ATTR_WIPHY_CHANNEL_TYPE attribute or the attributes
778 * %NL80211_ATTR_CHANNEL_WIDTH and if needed %NL80211_ATTR_CENTER_FREQ1
779 * and %NL80211_ATTR_CENTER_FREQ2
780 * @NL80211_ATTR_CHANNEL_WIDTH: u32 attribute containing one of the values
781 * of &enum nl80211_chan_width, describing the channel width. See the
782 * documentation of the enum for more information.
783 * @NL80211_ATTR_CENTER_FREQ1: Center frequency of the first part of the
784 * channel, used for anything but 20 MHz bandwidth
785 * @NL80211_ATTR_CENTER_FREQ2: Center frequency of the second part of the
786 * channel, used only for 80+80 MHz bandwidth
766 * @NL80211_ATTR_WIPHY_CHANNEL_TYPE: included with NL80211_ATTR_WIPHY_FREQ 787 * @NL80211_ATTR_WIPHY_CHANNEL_TYPE: included with NL80211_ATTR_WIPHY_FREQ
767 * if HT20 or HT40 are allowed (i.e., 802.11n disabled if not included): 788 * if HT20 or HT40 are to be used (i.e., HT disabled if not included):
768 * NL80211_CHAN_NO_HT = HT not allowed (i.e., same as not including 789 * NL80211_CHAN_NO_HT = HT not allowed (i.e., same as not including
769 * this attribute) 790 * this attribute)
770 * NL80211_CHAN_HT20 = HT20 only 791 * NL80211_CHAN_HT20 = HT20 only
771 * NL80211_CHAN_HT40MINUS = secondary channel is below the primary channel 792 * NL80211_CHAN_HT40MINUS = secondary channel is below the primary channel
772 * NL80211_CHAN_HT40PLUS = secondary channel is above the primary channel 793 * NL80211_CHAN_HT40PLUS = secondary channel is above the primary channel
794 * This attribute is now deprecated.
773 * @NL80211_ATTR_WIPHY_RETRY_SHORT: TX retry limit for frames whose length is 795 * @NL80211_ATTR_WIPHY_RETRY_SHORT: TX retry limit for frames whose length is
774 * less than or equal to the RTS threshold; allowed range: 1..255; 796 * less than or equal to the RTS threshold; allowed range: 1..255;
775 * dot11ShortRetryLimit; u8 797 * dot11ShortRetryLimit; u8
@@ -1544,6 +1566,10 @@ enum nl80211_attrs {
1544 1566
1545 NL80211_ATTR_SCAN_FLAGS, 1567 NL80211_ATTR_SCAN_FLAGS,
1546 1568
1569 NL80211_ATTR_CHANNEL_WIDTH,
1570 NL80211_ATTR_CENTER_FREQ1,
1571 NL80211_ATTR_CENTER_FREQ2,
1572
1547 /* add attributes here, update the policy in nl80211.c */ 1573 /* add attributes here, update the policy in nl80211.c */
1548 1574
1549 __NL80211_ATTR_AFTER_LAST, 1575 __NL80211_ATTR_AFTER_LAST,
@@ -1708,10 +1734,15 @@ struct nl80211_sta_flag_update {
1708 * @__NL80211_RATE_INFO_INVALID: attribute number 0 is reserved 1734 * @__NL80211_RATE_INFO_INVALID: attribute number 0 is reserved
1709 * @NL80211_RATE_INFO_BITRATE: total bitrate (u16, 100kbit/s) 1735 * @NL80211_RATE_INFO_BITRATE: total bitrate (u16, 100kbit/s)
1710 * @NL80211_RATE_INFO_MCS: mcs index for 802.11n (u8) 1736 * @NL80211_RATE_INFO_MCS: mcs index for 802.11n (u8)
1711 * @NL80211_RATE_INFO_40_MHZ_WIDTH: 40 Mhz dualchannel bitrate 1737 * @NL80211_RATE_INFO_40_MHZ_WIDTH: 40 MHz dualchannel bitrate
1712 * @NL80211_RATE_INFO_SHORT_GI: 400ns guard interval 1738 * @NL80211_RATE_INFO_SHORT_GI: 400ns guard interval
1713 * @NL80211_RATE_INFO_BITRATE32: total bitrate (u32, 100kbit/s) 1739 * @NL80211_RATE_INFO_BITRATE32: total bitrate (u32, 100kbit/s)
1714 * @NL80211_RATE_INFO_MAX: highest rate_info number currently defined 1740 * @NL80211_RATE_INFO_MAX: highest rate_info number currently defined
1741 * @NL80211_RATE_INFO_VHT_MCS: MCS index for VHT (u8)
1742 * @NL80211_RATE_INFO_VHT_NSS: number of streams in VHT (u8)
1743 * @NL80211_RATE_INFO_80_MHZ_WIDTH: 80 MHz VHT rate
1744 * @NL80211_RATE_INFO_80P80_MHZ_WIDTH: 80+80 MHz VHT rate
1745 * @NL80211_RATE_INFO_160_MHZ_WIDTH: 160 MHz VHT rate
1715 * @__NL80211_RATE_INFO_AFTER_LAST: internal use 1746 * @__NL80211_RATE_INFO_AFTER_LAST: internal use
1716 */ 1747 */
1717enum nl80211_rate_info { 1748enum nl80211_rate_info {
@@ -1721,6 +1752,11 @@ enum nl80211_rate_info {
1721 NL80211_RATE_INFO_40_MHZ_WIDTH, 1752 NL80211_RATE_INFO_40_MHZ_WIDTH,
1722 NL80211_RATE_INFO_SHORT_GI, 1753 NL80211_RATE_INFO_SHORT_GI,
1723 NL80211_RATE_INFO_BITRATE32, 1754 NL80211_RATE_INFO_BITRATE32,
1755 NL80211_RATE_INFO_VHT_MCS,
1756 NL80211_RATE_INFO_VHT_NSS,
1757 NL80211_RATE_INFO_80_MHZ_WIDTH,
1758 NL80211_RATE_INFO_80P80_MHZ_WIDTH,
1759 NL80211_RATE_INFO_160_MHZ_WIDTH,
1724 1760
1725 /* keep last */ 1761 /* keep last */
1726 __NL80211_RATE_INFO_AFTER_LAST, 1762 __NL80211_RATE_INFO_AFTER_LAST,
@@ -2429,6 +2465,15 @@ enum nl80211_ac {
2429#define NL80211_TXQ_Q_BE NL80211_AC_BE 2465#define NL80211_TXQ_Q_BE NL80211_AC_BE
2430#define NL80211_TXQ_Q_BK NL80211_AC_BK 2466#define NL80211_TXQ_Q_BK NL80211_AC_BK
2431 2467
2468/**
2469 * enum nl80211_channel_type - channel type
2470 * @NL80211_CHAN_NO_HT: 20 MHz, non-HT channel
2471 * @NL80211_CHAN_HT20: 20 MHz HT channel
2472 * @NL80211_CHAN_HT40MINUS: HT40 channel, secondary channel
2473 * below the control channel
2474 * @NL80211_CHAN_HT40PLUS: HT40 channel, secondary channel
2475 * above the control channel
2476 */
2432enum nl80211_channel_type { 2477enum nl80211_channel_type {
2433 NL80211_CHAN_NO_HT, 2478 NL80211_CHAN_NO_HT,
2434 NL80211_CHAN_HT20, 2479 NL80211_CHAN_HT20,
@@ -2437,6 +2482,32 @@ enum nl80211_channel_type {
2437}; 2482};
2438 2483
2439/** 2484/**
2485 * enum nl80211_chan_width - channel width definitions
2486 *
2487 * These values are used with the %NL80211_ATTR_CHANNEL_WIDTH
2488 * attribute.
2489 *
2490 * @NL80211_CHAN_WIDTH_20_NOHT: 20 MHz, non-HT channel
2491 * @NL80211_CHAN_WIDTH_20: 20 MHz HT channel
2492 * @NL80211_CHAN_WIDTH_40: 40 MHz channel, the %NL80211_ATTR_CENTER_FREQ1
2493 * attribute must be provided as well
2494 * @NL80211_CHAN_WIDTH_80: 80 MHz channel, the %NL80211_ATTR_CENTER_FREQ1
2495 * attribute must be provided as well
2496 * @NL80211_CHAN_WIDTH_80P80: 80+80 MHz channel, the %NL80211_ATTR_CENTER_FREQ1
2497 * and %NL80211_ATTR_CENTER_FREQ2 attributes must be provided as well
2498 * @NL80211_CHAN_WIDTH_160: 160 MHz channel, the %NL80211_ATTR_CENTER_FREQ1
2499 * attribute must be provided as well
2500 */
2501enum nl80211_chan_width {
2502 NL80211_CHAN_WIDTH_20_NOHT,
2503 NL80211_CHAN_WIDTH_20,
2504 NL80211_CHAN_WIDTH_40,
2505 NL80211_CHAN_WIDTH_80,
2506 NL80211_CHAN_WIDTH_80P80,
2507 NL80211_CHAN_WIDTH_160,
2508};
2509
2510/**
2440 * enum nl80211_bss - netlink attributes for a BSS 2511 * enum nl80211_bss - netlink attributes for a BSS
2441 * 2512 *
2442 * @__NL80211_BSS_INVALID: invalid 2513 * @__NL80211_BSS_INVALID: invalid
@@ -3051,6 +3122,10 @@ enum nl80211_ap_sme_features {
3051 * @NL80211_FEATURE_LOW_PRIORITY_SCAN: This driver supports low priority scan 3122 * @NL80211_FEATURE_LOW_PRIORITY_SCAN: This driver supports low priority scan
3052 * @NL80211_FEATURE_SCAN_FLUSH: Scan flush is supported 3123 * @NL80211_FEATURE_SCAN_FLUSH: Scan flush is supported
3053 * @NL80211_FEATURE_AP_SCAN: Support scanning using an AP vif 3124 * @NL80211_FEATURE_AP_SCAN: Support scanning using an AP vif
3125 * @NL80211_FEATURE_VIF_TXPOWER: The driver supports per-vif TX power setting
3126 * @NL80211_FEATURE_NEED_OBSS_SCAN: The driver expects userspace to perform
3127 * OBSS scans and generate 20/40 BSS coex reports. This flag is used only
3128 * for drivers implementing the CONNECT API, for AUTH/ASSOC it is implied.
3054 */ 3129 */
3055enum nl80211_feature_flags { 3130enum nl80211_feature_flags {
3056 NL80211_FEATURE_SK_TX_STATUS = 1 << 0, 3131 NL80211_FEATURE_SK_TX_STATUS = 1 << 0,
@@ -3062,6 +3137,8 @@ enum nl80211_feature_flags {
3062 NL80211_FEATURE_LOW_PRIORITY_SCAN = 1 << 6, 3137 NL80211_FEATURE_LOW_PRIORITY_SCAN = 1 << 6,
3063 NL80211_FEATURE_SCAN_FLUSH = 1 << 7, 3138 NL80211_FEATURE_SCAN_FLUSH = 1 << 7,
3064 NL80211_FEATURE_AP_SCAN = 1 << 8, 3139 NL80211_FEATURE_AP_SCAN = 1 << 8,
3140 NL80211_FEATURE_VIF_TXPOWER = 1 << 9,
3141 NL80211_FEATURE_NEED_OBSS_SCAN = 1 << 10,
3065}; 3142};
3066 3143
3067/** 3144/**