iw: update nl80211.h
[openwrt/openwrt.git] / package / network / utils / iw / patches / 001-nl80211_h_sync.patch
1 diff --git a/nl80211.h b/nl80211.h
2 index c587a61..255a971 100644
3 --- a/nl80211.h
4 +++ b/nl80211.h
5 @@ -11,6 +11,7 @@
6 * Copyright 2008 Jouni Malinen <jouni.malinen@atheros.com>
7 * Copyright 2008 Colin McCabe <colin@cozybit.com>
8 * Copyright 2015-2017 Intel Deutschland GmbH
9 + * Copyright (C) 2018 Intel Corporation
10 *
11 * Permission to use, copy, modify, and/or distribute this software for any
12 * purpose with or without fee is hereby granted, provided that the above
13 @@ -203,7 +204,8 @@
14 * FILS shared key authentication offload should be able to construct the
15 * authentication and association frames for FILS shared key authentication and
16 * eventually do a key derivation as per IEEE 802.11ai. The below additional
17 - * parameters should be given to driver in %NL80211_CMD_CONNECT.
18 + * parameters should be given to driver in %NL80211_CMD_CONNECT and/or in
19 + * %NL80211_CMD_UPDATE_CONNECT_PARAMS.
20 * %NL80211_ATTR_FILS_ERP_USERNAME - used to construct keyname_nai
21 * %NL80211_ATTR_FILS_ERP_REALM - used to construct keyname_nai
22 * %NL80211_ATTR_FILS_ERP_NEXT_SEQ_NUM - used to construct erp message
23 @@ -214,7 +216,8 @@
24 * as specified in IETF RFC 6696.
25 *
26 * When FILS shared key authentication is completed, driver needs to provide the
27 - * below additional parameters to userspace.
28 + * below additional parameters to userspace, which can be either after setting
29 + * up a connection or after roaming.
30 * %NL80211_ATTR_FILS_KEK - used for key renewal
31 * %NL80211_ATTR_FILS_ERP_NEXT_SEQ_NUM - used in further EAP-RP exchanges
32 * %NL80211_ATTR_PMKID - used to identify the PMKSA used/generated
33 @@ -542,7 +545,8 @@
34 * IEs in %NL80211_ATTR_IE, %NL80211_ATTR_AUTH_TYPE, %NL80211_ATTR_USE_MFP,
35 * %NL80211_ATTR_MAC, %NL80211_ATTR_WIPHY_FREQ, %NL80211_ATTR_CONTROL_PORT,
36 * %NL80211_ATTR_CONTROL_PORT_ETHERTYPE,
37 - * %NL80211_ATTR_CONTROL_PORT_NO_ENCRYPT, %NL80211_ATTR_MAC_HINT, and
38 + * %NL80211_ATTR_CONTROL_PORT_NO_ENCRYPT,
39 + * %NL80211_ATTR_CONTROL_PORT_OVER_NL80211, %NL80211_ATTR_MAC_HINT, and
40 * %NL80211_ATTR_WIPHY_FREQ_HINT.
41 * If included, %NL80211_ATTR_MAC and %NL80211_ATTR_WIPHY_FREQ are
42 * restrictions on BSS selection, i.e., they effectively prevent roaming
43 @@ -977,21 +981,58 @@
44 * only the %NL80211_ATTR_IE data is used and updated with this command.
45 *
46 * @NL80211_CMD_SET_PMK: For offloaded 4-Way handshake, set the PMK or PMK-R0
47 - * for the given authenticator address (specified with &NL80211_ATTR_MAC).
48 - * When &NL80211_ATTR_PMKR0_NAME is set, &NL80211_ATTR_PMK specifies the
49 + * for the given authenticator address (specified with %NL80211_ATTR_MAC).
50 + * When %NL80211_ATTR_PMKR0_NAME is set, %NL80211_ATTR_PMK specifies the
51 * PMK-R0, otherwise it specifies the PMK.
52 * @NL80211_CMD_DEL_PMK: For offloaded 4-Way handshake, delete the previously
53 * configured PMK for the authenticator address identified by
54 - * &NL80211_ATTR_MAC.
55 + * %NL80211_ATTR_MAC.
56 * @NL80211_CMD_PORT_AUTHORIZED: An event that indicates that the 4 way
57 * handshake was completed successfully by the driver. The BSSID is
58 - * specified with &NL80211_ATTR_MAC. Drivers that support 4 way handshake
59 + * specified with %NL80211_ATTR_MAC. Drivers that support 4 way handshake
60 * offload should send this event after indicating 802.11 association with
61 - * &NL80211_CMD_CONNECT or &NL80211_CMD_ROAM. If the 4 way handshake failed
62 - * &NL80211_CMD_DISCONNECT should be indicated instead.
63 + * %NL80211_CMD_CONNECT or %NL80211_CMD_ROAM. If the 4 way handshake failed
64 + * %NL80211_CMD_DISCONNECT should be indicated instead.
65 + *
66 + * @NL80211_CMD_CONTROL_PORT_FRAME: Control Port (e.g. PAE) frame TX request
67 + * and RX notification. This command is used both as a request to transmit
68 + * a control port frame and as a notification that a control port frame
69 + * has been received. %NL80211_ATTR_FRAME is used to specify the
70 + * frame contents. The frame is the raw EAPoL data, without ethernet or
71 + * 802.11 headers.
72 + * When used as an event indication %NL80211_ATTR_CONTROL_PORT_ETHERTYPE,
73 + * %NL80211_ATTR_CONTROL_PORT_NO_ENCRYPT and %NL80211_ATTR_MAC are added
74 + * indicating the protocol type of the received frame; whether the frame
75 + * was received unencrypted and the MAC address of the peer respectively.
76 *
77 * @NL80211_CMD_RELOAD_REGDB: Request that the regdb firmware file is reloaded.
78 *
79 + * @NL80211_CMD_EXTERNAL_AUTH: This interface is exclusively defined for host
80 + * drivers that do not define separate commands for authentication and
81 + * association, but rely on user space for the authentication to happen.
82 + * This interface acts both as the event request (driver to user space)
83 + * to trigger the authentication and command response (userspace to
84 + * driver) to indicate the authentication status.
85 + *
86 + * User space uses the %NL80211_CMD_CONNECT command to the host driver to
87 + * trigger a connection. The host driver selects a BSS and further uses
88 + * this interface to offload only the authentication part to the user
89 + * space. Authentication frames are passed between the driver and user
90 + * space through the %NL80211_CMD_FRAME interface. Host driver proceeds
91 + * further with the association after getting successful authentication
92 + * status. User space indicates the authentication status through
93 + * %NL80211_ATTR_STATUS_CODE attribute in %NL80211_CMD_EXTERNAL_AUTH
94 + * command interface.
95 + *
96 + * Host driver reports this status on an authentication failure to the
97 + * user space through the connect result as the user space would have
98 + * initiated the connection through the connect request.
99 + *
100 + * @NL80211_CMD_STA_OPMODE_CHANGED: An event that notify station's
101 + * ht opmode or vht opmode changes using any of %NL80211_ATTR_SMPS_MODE,
102 + * %NL80211_ATTR_CHANNEL_WIDTH,%NL80211_ATTR_NSS attributes with its
103 + * address(specified in %NL80211_ATTR_MAC).
104 + *
105 * @NL80211_CMD_MAX: highest used command number
106 * @__NL80211_CMD_AFTER_LAST: internal use
107 */
108 @@ -1198,6 +1239,12 @@ enum nl80211_commands {
109
110 NL80211_CMD_RELOAD_REGDB,
111
112 + NL80211_CMD_EXTERNAL_AUTH,
113 +
114 + NL80211_CMD_STA_OPMODE_CHANGED,
115 +
116 + NL80211_CMD_CONTROL_PORT_FRAME,
117 +
118 /* add new commands above here */
119
120 /* used to define NL80211_CMD_MAX below */
121 @@ -1445,6 +1492,15 @@ enum nl80211_commands {
122 * @NL80211_ATTR_CONTROL_PORT_NO_ENCRYPT: When included along with
123 * %NL80211_ATTR_CONTROL_PORT_ETHERTYPE, indicates that the custom
124 * ethertype frames used for key negotiation must not be encrypted.
125 + * @NL80211_ATTR_CONTROL_PORT_OVER_NL80211: A flag indicating whether control
126 + * port frames (e.g. of type given in %NL80211_ATTR_CONTROL_PORT_ETHERTYPE)
127 + * will be sent directly to the network interface or sent via the NL80211
128 + * socket. If this attribute is missing, then legacy behavior of sending
129 + * control port frames directly to the network interface is used. If the
130 + * flag is included, then control port frames are sent over NL80211 instead
131 + * using %CMD_CONTROL_PORT_FRAME. If control port routing over NL80211 is
132 + * to be used then userspace must also use the %NL80211_ATTR_SOCKET_OWNER
133 + * flag.
134 *
135 * @NL80211_ATTR_TESTDATA: Testmode data blob, passed through to the driver.
136 * We recommend using nested, driver-specific attributes within this.
137 @@ -1932,6 +1988,12 @@ enum nl80211_commands {
138 * multicast group.
139 * If set during %NL80211_CMD_ASSOCIATE or %NL80211_CMD_CONNECT the
140 * station will deauthenticate when the socket is closed.
141 + * If set during %NL80211_CMD_JOIN_IBSS the IBSS will be automatically
142 + * torn down when the socket is closed.
143 + * If set during %NL80211_CMD_JOIN_MESH the mesh setup will be
144 + * automatically torn down when the socket is closed.
145 + * If set during %NL80211_CMD_START_AP the AP will be automatically
146 + * disabled when the socket is closed.
147 *
148 * @NL80211_ATTR_TDLS_INITIATOR: flag attribute indicating the current end is
149 * the TDLS link initiator.
150 @@ -2153,6 +2215,35 @@ enum nl80211_commands {
151 * @NL80211_ATTR_PMKR0_NAME: PMK-R0 Name for offloaded FT.
152 * @NL80211_ATTR_PORT_AUTHORIZED: (reserved)
153 *
154 + * @NL80211_ATTR_EXTERNAL_AUTH_ACTION: Identify the requested external
155 + * authentication operation (u32 attribute with an
156 + * &enum nl80211_external_auth_action value). This is used with the
157 + * %NL80211_CMD_EXTERNAL_AUTH request event.
158 + * @NL80211_ATTR_EXTERNAL_AUTH_SUPPORT: Flag attribute indicating that the user
159 + * space supports external authentication. This attribute shall be used
160 + * only with %NL80211_CMD_CONNECT request. The driver may offload
161 + * authentication processing to user space if this capability is indicated
162 + * in NL80211_CMD_CONNECT requests from the user space.
163 + *
164 + * @NL80211_ATTR_NSS: Station's New/updated RX_NSS value notified using this
165 + * u8 attribute. This is used with %NL80211_CMD_STA_OPMODE_CHANGED.
166 + *
167 + * @NL80211_ATTR_TXQ_STATS: TXQ statistics (nested attribute, see &enum
168 + * nl80211_txq_stats)
169 + * @NL80211_ATTR_TXQ_LIMIT: Total packet limit for the TXQ queues for this phy.
170 + * The smaller of this and the memory limit is enforced.
171 + * @NL80211_ATTR_TXQ_MEMORY_LIMIT: Total memory memory limit (in bytes) for the
172 + * TXQ queues for this phy. The smaller of this and the packet limit is
173 + * enforced.
174 + * @NL80211_ATTR_TXQ_QUANTUM: TXQ scheduler quantum (bytes). Number of bytes
175 + * a flow is assigned on each round of the DRR scheduler.
176 + * @NL80211_ATTR_HE_CAPABILITY: HE Capability information element (from
177 + * association request when used with NL80211_CMD_NEW_STATION). Can be set
178 + * only if %NL80211_STA_FLAG_WME is set.
179 + *
180 + * @NL80211_ATTR_WIPHY_ANTENNA_GAIN: Configured antenna gain. Used to reduce
181 + * transmit power to stay within regulatory limits. u32, dBi.
182 + *
183 * @NUM_NL80211_ATTR: total number of nl80211_attrs available
184 * @NL80211_ATTR_MAX: highest attribute number currently defined
185 * @__NL80211_ATTR_AFTER_LAST: internal use
186 @@ -2579,6 +2670,23 @@ enum nl80211_attrs {
187 NL80211_ATTR_PMKR0_NAME,
188 NL80211_ATTR_PORT_AUTHORIZED,
189
190 + NL80211_ATTR_EXTERNAL_AUTH_ACTION,
191 + NL80211_ATTR_EXTERNAL_AUTH_SUPPORT,
192 +
193 + NL80211_ATTR_NSS,
194 + NL80211_ATTR_ACK_SIGNAL,
195 +
196 + NL80211_ATTR_CONTROL_PORT_OVER_NL80211,
197 +
198 + NL80211_ATTR_TXQ_STATS,
199 + NL80211_ATTR_TXQ_LIMIT,
200 + NL80211_ATTR_TXQ_MEMORY_LIMIT,
201 + NL80211_ATTR_TXQ_QUANTUM,
202 +
203 + NL80211_ATTR_HE_CAPABILITY,
204 +
205 + NL80211_ATTR_WIPHY_ANTENNA_GAIN,
206 +
207 /* add attributes here, update the policy in nl80211.c */
208
209 __NL80211_ATTR_AFTER_LAST,
210 @@ -2618,6 +2726,8 @@ enum nl80211_attrs {
211 #define NL80211_ATTR_KEYS NL80211_ATTR_KEYS
212 #define NL80211_ATTR_FEATURE_FLAGS NL80211_ATTR_FEATURE_FLAGS
213
214 +#define NL80211_WIPHY_NAME_MAXLEN 64
215 +
216 #define NL80211_MAX_SUPP_RATES 32
217 #define NL80211_MAX_SUPP_HT_RATES 77
218 #define NL80211_MAX_SUPP_REG_RULES 64
219 @@ -2626,7 +2736,8 @@ enum nl80211_attrs {
220 #define NL80211_TKIP_DATA_OFFSET_RX_MIC_KEY 24
221 #define NL80211_HT_CAPABILITY_LEN 26
222 #define NL80211_VHT_CAPABILITY_LEN 12
223 -
224 +#define NL80211_HE_MIN_CAPABILITY_LEN 16
225 +#define NL80211_HE_MAX_CAPABILITY_LEN 51
226 #define NL80211_MAX_NR_CIPHER_SUITES 5
227 #define NL80211_MAX_NR_AKM_SUITES 2
228
229 @@ -2754,6 +2865,38 @@ struct nl80211_sta_flag_update {
230 } __attribute__((packed));
231
232 /**
233 + * enum nl80211_he_gi - HE guard interval
234 + * @NL80211_RATE_INFO_HE_GI_0_8: 0.8 usec
235 + * @NL80211_RATE_INFO_HE_GI_1_6: 1.6 usec
236 + * @NL80211_RATE_INFO_HE_GI_3_2: 3.2 usec
237 + */
238 +enum nl80211_he_gi {
239 + NL80211_RATE_INFO_HE_GI_0_8,
240 + NL80211_RATE_INFO_HE_GI_1_6,
241 + NL80211_RATE_INFO_HE_GI_3_2,
242 +};
243 +
244 +/**
245 + * enum nl80211_he_ru_alloc - HE RU allocation values
246 + * @NL80211_RATE_INFO_HE_RU_ALLOC_26: 26-tone RU allocation
247 + * @NL80211_RATE_INFO_HE_RU_ALLOC_52: 52-tone RU allocation
248 + * @NL80211_RATE_INFO_HE_RU_ALLOC_106: 106-tone RU allocation
249 + * @NL80211_RATE_INFO_HE_RU_ALLOC_242: 242-tone RU allocation
250 + * @NL80211_RATE_INFO_HE_RU_ALLOC_484: 484-tone RU allocation
251 + * @NL80211_RATE_INFO_HE_RU_ALLOC_996: 996-tone RU allocation
252 + * @NL80211_RATE_INFO_HE_RU_ALLOC_2x996: 2x996-tone RU allocation
253 + */
254 +enum nl80211_he_ru_alloc {
255 + NL80211_RATE_INFO_HE_RU_ALLOC_26,
256 + NL80211_RATE_INFO_HE_RU_ALLOC_52,
257 + NL80211_RATE_INFO_HE_RU_ALLOC_106,
258 + NL80211_RATE_INFO_HE_RU_ALLOC_242,
259 + NL80211_RATE_INFO_HE_RU_ALLOC_484,
260 + NL80211_RATE_INFO_HE_RU_ALLOC_996,
261 + NL80211_RATE_INFO_HE_RU_ALLOC_2x996,
262 +};
263 +
264 +/**
265 * enum nl80211_rate_info - bitrate information
266 *
267 * These attribute types are used with %NL80211_STA_INFO_TXRATE
268 @@ -2785,6 +2928,13 @@ struct nl80211_sta_flag_update {
269 * @NL80211_RATE_INFO_5_MHZ_WIDTH: 5 MHz width - note that this is
270 * a legacy rate and will be reported as the actual bitrate, i.e.
271 * a quarter of the base (20 MHz) rate
272 + * @NL80211_RATE_INFO_HE_MCS: HE MCS index (u8, 0-11)
273 + * @NL80211_RATE_INFO_HE_NSS: HE NSS value (u8, 1-8)
274 + * @NL80211_RATE_INFO_HE_GI: HE guard interval identifier
275 + * (u8, see &enum nl80211_he_gi)
276 + * @NL80211_RATE_INFO_HE_DCM: HE DCM value (u8, 0/1)
277 + * @NL80211_RATE_INFO_RU_ALLOC: HE RU allocation, if not present then
278 + * non-OFDMA was used (u8, see &enum nl80211_he_ru_alloc)
279 * @__NL80211_RATE_INFO_AFTER_LAST: internal use
280 */
281 enum nl80211_rate_info {
282 @@ -2801,6 +2951,11 @@ enum nl80211_rate_info {
283 NL80211_RATE_INFO_160_MHZ_WIDTH,
284 NL80211_RATE_INFO_10_MHZ_WIDTH,
285 NL80211_RATE_INFO_5_MHZ_WIDTH,
286 + NL80211_RATE_INFO_HE_MCS,
287 + NL80211_RATE_INFO_HE_NSS,
288 + NL80211_RATE_INFO_HE_GI,
289 + NL80211_RATE_INFO_HE_DCM,
290 + NL80211_RATE_INFO_HE_RU_ALLOC,
291
292 /* keep last */
293 __NL80211_RATE_INFO_AFTER_LAST,
294 @@ -2899,6 +3054,9 @@ enum nl80211_sta_bss_param {
295 * @NL80211_STA_INFO_RX_DURATION: aggregate PPDU duration for all frames
296 * received from the station (u64, usec)
297 * @NL80211_STA_INFO_PAD: attribute used for padding for 64-bit alignment
298 + * @NL80211_STA_INFO_ACK_SIGNAL: signal strength of the last ACK frame(u8, dBm)
299 + * @NL80211_STA_INFO_DATA_ACK_SIGNAL_AVG: avg signal strength of (data)
300 + * ACK frame (s8, dBm)
301 * @__NL80211_STA_INFO_AFTER_LAST: internal
302 * @NL80211_STA_INFO_MAX: highest possible station info attribute
303 */
304 @@ -2937,6 +3095,8 @@ enum nl80211_sta_info {
305 NL80211_STA_INFO_TID_STATS,
306 NL80211_STA_INFO_RX_DURATION,
307 NL80211_STA_INFO_PAD,
308 + NL80211_STA_INFO_ACK_SIGNAL,
309 + NL80211_STA_INFO_DATA_ACK_SIGNAL_AVG,
310
311 /* keep last */
312 __NL80211_STA_INFO_AFTER_LAST,
313 @@ -2954,6 +3114,7 @@ enum nl80211_sta_info {
314 * @NL80211_TID_STATS_TX_MSDU_FAILED: number of failed transmitted
315 * MSDUs (u64)
316 * @NL80211_TID_STATS_PAD: attribute used for padding for 64-bit alignment
317 + * @NL80211_TID_STATS_TXQ_STATS: TXQ stats (nested attribute)
318 * @NUM_NL80211_TID_STATS: number of attributes here
319 * @NL80211_TID_STATS_MAX: highest numbered attribute here
320 */
321 @@ -2964,6 +3125,7 @@ enum nl80211_tid_stats {
322 NL80211_TID_STATS_TX_MSDU_RETRIES,
323 NL80211_TID_STATS_TX_MSDU_FAILED,
324 NL80211_TID_STATS_PAD,
325 + NL80211_TID_STATS_TXQ_STATS,
326
327 /* keep last */
328 NUM_NL80211_TID_STATS,
329 @@ -2971,6 +3133,44 @@ enum nl80211_tid_stats {
330 };
331
332 /**
333 + * enum nl80211_txq_stats - per TXQ statistics attributes
334 + * @__NL80211_TXQ_STATS_INVALID: attribute number 0 is reserved
335 + * @NUM_NL80211_TXQ_STATS: number of attributes here
336 + * @NL80211_TXQ_STATS_BACKLOG_BYTES: number of bytes currently backlogged
337 + * @NL80211_TXQ_STATS_BACKLOG_PACKETS: number of packets currently
338 + * backlogged
339 + * @NL80211_TXQ_STATS_FLOWS: total number of new flows seen
340 + * @NL80211_TXQ_STATS_DROPS: total number of packet drops
341 + * @NL80211_TXQ_STATS_ECN_MARKS: total number of packet ECN marks
342 + * @NL80211_TXQ_STATS_OVERLIMIT: number of drops due to queue space overflow
343 + * @NL80211_TXQ_STATS_OVERMEMORY: number of drops due to memory limit overflow
344 + * (only for per-phy stats)
345 + * @NL80211_TXQ_STATS_COLLISIONS: number of hash collisions
346 + * @NL80211_TXQ_STATS_TX_BYTES: total number of bytes dequeued from TXQ
347 + * @NL80211_TXQ_STATS_TX_PACKETS: total number of packets dequeued from TXQ
348 + * @NL80211_TXQ_STATS_MAX_FLOWS: number of flow buckets for PHY
349 + * @NL80211_TXQ_STATS_MAX: highest numbered attribute here
350 + */
351 +enum nl80211_txq_stats {
352 + __NL80211_TXQ_STATS_INVALID,
353 + NL80211_TXQ_STATS_BACKLOG_BYTES,
354 + NL80211_TXQ_STATS_BACKLOG_PACKETS,
355 + NL80211_TXQ_STATS_FLOWS,
356 + NL80211_TXQ_STATS_DROPS,
357 + NL80211_TXQ_STATS_ECN_MARKS,
358 + NL80211_TXQ_STATS_OVERLIMIT,
359 + NL80211_TXQ_STATS_OVERMEMORY,
360 + NL80211_TXQ_STATS_COLLISIONS,
361 + NL80211_TXQ_STATS_TX_BYTES,
362 + NL80211_TXQ_STATS_TX_PACKETS,
363 + NL80211_TXQ_STATS_MAX_FLOWS,
364 +
365 + /* keep last */
366 + NUM_NL80211_TXQ_STATS,
367 + NL80211_TXQ_STATS_MAX = NUM_NL80211_TXQ_STATS - 1
368 +};
369 +
370 +/**
371 * enum nl80211_mpath_flags - nl80211 mesh path flags
372 *
373 * @NL80211_MPATH_FLAG_ACTIVE: the mesh path is active
374 @@ -3022,6 +3222,38 @@ enum nl80211_mpath_info {
375 };
376
377 /**
378 + * enum nl80211_band_iftype_attr - Interface type data attributes
379 + *
380 + * @__NL80211_BAND_IFTYPE_ATTR_INVALID: attribute number 0 is reserved
381 + * @NL80211_BAND_IFTYPE_ATTR_IFTYPES: nested attribute containing a flag attribute
382 + * for each interface type that supports the band data
383 + * @NL80211_BAND_IFTYPE_ATTR_HE_CAP_MAC: HE MAC capabilities as in HE
384 + * capabilities IE
385 + * @NL80211_BAND_IFTYPE_ATTR_HE_CAP_PHY: HE PHY capabilities as in HE
386 + * capabilities IE
387 + * @NL80211_BAND_IFTYPE_ATTR_HE_CAP_MCS_SET: HE supported NSS/MCS as in HE
388 + * capabilities IE
389 + * @NL80211_BAND_IFTYPE_ATTR_HE_CAP_PPE: HE PPE thresholds information as
390 + * defined in HE capabilities IE
391 + * @NL80211_BAND_IFTYPE_ATTR_MAX: highest band HE capability attribute currently
392 + * defined
393 + * @__NL80211_BAND_IFTYPE_ATTR_AFTER_LAST: internal use
394 + */
395 +enum nl80211_band_iftype_attr {
396 + __NL80211_BAND_IFTYPE_ATTR_INVALID,
397 +
398 + NL80211_BAND_IFTYPE_ATTR_IFTYPES,
399 + NL80211_BAND_IFTYPE_ATTR_HE_CAP_MAC,
400 + NL80211_BAND_IFTYPE_ATTR_HE_CAP_PHY,
401 + NL80211_BAND_IFTYPE_ATTR_HE_CAP_MCS_SET,
402 + NL80211_BAND_IFTYPE_ATTR_HE_CAP_PPE,
403 +
404 + /* keep last */
405 + __NL80211_BAND_IFTYPE_ATTR_AFTER_LAST,
406 + NL80211_BAND_IFTYPE_ATTR_MAX = __NL80211_BAND_IFTYPE_ATTR_AFTER_LAST - 1
407 +};
408 +
409 +/**
410 * enum nl80211_band_attr - band attributes
411 * @__NL80211_BAND_ATTR_INVALID: attribute number 0 is reserved
412 * @NL80211_BAND_ATTR_FREQS: supported frequencies in this band,
413 @@ -3036,6 +3268,8 @@ enum nl80211_mpath_info {
414 * @NL80211_BAND_ATTR_VHT_MCS_SET: 32-byte attribute containing the MCS set as
415 * defined in 802.11ac
416 * @NL80211_BAND_ATTR_VHT_CAPA: VHT capabilities, as in the HT information IE
417 + * @NL80211_BAND_ATTR_IFTYPE_DATA: nested array attribute, with each entry using
418 + * attributes from &enum nl80211_band_iftype_attr
419 * @NL80211_BAND_ATTR_MAX: highest band attribute currently defined
420 * @__NL80211_BAND_ATTR_AFTER_LAST: internal use
421 */
422 @@ -3051,6 +3285,7 @@ enum nl80211_band_attr {
423
424 NL80211_BAND_ATTR_VHT_MCS_SET,
425 NL80211_BAND_ATTR_VHT_CAPA,
426 + NL80211_BAND_ATTR_IFTYPE_DATA,
427
428 /* keep last */
429 __NL80211_BAND_ATTR_AFTER_LAST,
430 @@ -3060,6 +3295,29 @@ enum nl80211_band_attr {
431 #define NL80211_BAND_ATTR_HT_CAPA NL80211_BAND_ATTR_HT_CAPA
432
433 /**
434 + * enum nl80211_wmm_rule - regulatory wmm rule
435 + *
436 + * @__NL80211_WMMR_INVALID: attribute number 0 is reserved
437 + * @NL80211_WMMR_CW_MIN: Minimum contention window slot.
438 + * @NL80211_WMMR_CW_MAX: Maximum contention window slot.
439 + * @NL80211_WMMR_AIFSN: Arbitration Inter Frame Space.
440 + * @NL80211_WMMR_TXOP: Maximum allowed tx operation time.
441 + * @nl80211_WMMR_MAX: highest possible wmm rule.
442 + * @__NL80211_WMMR_LAST: Internal use.
443 + */
444 +enum nl80211_wmm_rule {
445 + __NL80211_WMMR_INVALID,
446 + NL80211_WMMR_CW_MIN,
447 + NL80211_WMMR_CW_MAX,
448 + NL80211_WMMR_AIFSN,
449 + NL80211_WMMR_TXOP,
450 +
451 + /* keep last */
452 + __NL80211_WMMR_LAST,
453 + NL80211_WMMR_MAX = __NL80211_WMMR_LAST - 1
454 +};
455 +
456 +/**
457 * enum nl80211_frequency_attr - frequency attributes
458 * @__NL80211_FREQUENCY_ATTR_INVALID: attribute number 0 is reserved
459 * @NL80211_FREQUENCY_ATTR_FREQ: Frequency in MHz
460 @@ -3108,6 +3366,9 @@ enum nl80211_band_attr {
461 * on this channel in current regulatory domain.
462 * @NL80211_FREQUENCY_ATTR_NO_10MHZ: 10 MHz operation is not allowed
463 * on this channel in current regulatory domain.
464 + * @NL80211_FREQUENCY_ATTR_WMM: this channel has wmm limitations.
465 + * This is a nested attribute that contains the wmm limitation per AC.
466 + * (see &enum nl80211_wmm_rule)
467 * @NL80211_FREQUENCY_ATTR_MAX: highest frequency attribute number
468 * currently defined
469 * @__NL80211_FREQUENCY_ATTR_AFTER_LAST: internal use
470 @@ -3136,6 +3397,7 @@ enum nl80211_frequency_attr {
471 NL80211_FREQUENCY_ATTR_IR_CONCURRENT,
472 NL80211_FREQUENCY_ATTR_NO_20MHZ,
473 NL80211_FREQUENCY_ATTR_NO_10MHZ,
474 + NL80211_FREQUENCY_ATTR_WMM,
475
476 /* keep last */
477 __NL80211_FREQUENCY_ATTR_AFTER_LAST,
478 @@ -3319,7 +3581,7 @@ enum nl80211_sched_scan_match_attr {
479 * @NL80211_RRF_AUTO_BW: maximum available bandwidth should be calculated
480 * base on contiguous rules and wider channels will be allowed to cross
481 * multiple contiguous/overlapping frequency ranges.
482 - * @NL80211_RRF_IR_CONCURRENT: See &NL80211_FREQUENCY_ATTR_IR_CONCURRENT
483 + * @NL80211_RRF_IR_CONCURRENT: See %NL80211_FREQUENCY_ATTR_IR_CONCURRENT
484 * @NL80211_RRF_NO_HT40MINUS: channels can't be used in HT40- operation
485 * @NL80211_RRF_NO_HT40PLUS: channels can't be used in HT40+ operation
486 * @NL80211_RRF_NO_80MHZ: 80MHz operation not allowed
487 @@ -4945,6 +5207,27 @@ enum nl80211_feature_flags {
488 * probe request tx deferral and suppression
489 * @NL80211_EXT_FEATURE_MFP_OPTIONAL: Driver supports the %NL80211_MFP_OPTIONAL
490 * value in %NL80211_ATTR_USE_MFP.
491 + * @NL80211_EXT_FEATURE_LOW_SPAN_SCAN: Driver supports low span scan.
492 + * @NL80211_EXT_FEATURE_LOW_POWER_SCAN: Driver supports low power scan.
493 + * @NL80211_EXT_FEATURE_HIGH_ACCURACY_SCAN: Driver supports high accuracy scan.
494 + * @NL80211_EXT_FEATURE_DFS_OFFLOAD: HW/driver will offload DFS actions.
495 + * Device or driver will do all DFS-related actions by itself,
496 + * informing user-space about CAC progress, radar detection event,
497 + * channel change triggered by radar detection event.
498 + * No need to start CAC from user-space, no need to react to
499 + * "radar detected" event.
500 + * @NL80211_EXT_FEATURE_CONTROL_PORT_OVER_NL80211: Driver supports sending and
501 + * receiving control port frames over nl80211 instead of the netdevice.
502 + * @NL80211_EXT_FEATURE_DATA_ACK_SIGNAL_SUPPORT: This Driver support data ack
503 + * rssi if firmware support, this flag is to intimate about ack rssi
504 + * support to nl80211.
505 + * @NL80211_EXT_FEATURE_TXQS: Driver supports FQ-CoDel-enabled intermediate
506 + * TXQs.
507 + * @NL80211_EXT_FEATURE_SCAN_RANDOM_SN: Driver/device supports randomizing the
508 + * SN in probe request frames if requested by %NL80211_SCAN_FLAG_RANDOM_SN.
509 + * @NL80211_EXT_FEATURE_SCAN_MIN_PREQ_CONTENT: Driver/device can omit all data
510 + * except for supported rates from the probe request content if requested
511 + * by the %NL80211_SCAN_FLAG_MIN_PREQ_CONTENT flag.
512 *
513 * @NUM_NL80211_EXT_FEATURES: number of extended features.
514 * @MAX_NL80211_EXT_FEATURES: highest extended feature index.
515 @@ -4972,6 +5255,15 @@ enum nl80211_ext_feature_index {
516 NL80211_EXT_FEATURE_OCE_PROBE_REQ_HIGH_TX_RATE,
517 NL80211_EXT_FEATURE_OCE_PROBE_REQ_DEFERRAL_SUPPRESSION,
518 NL80211_EXT_FEATURE_MFP_OPTIONAL,
519 + NL80211_EXT_FEATURE_LOW_SPAN_SCAN,
520 + NL80211_EXT_FEATURE_LOW_POWER_SCAN,
521 + NL80211_EXT_FEATURE_HIGH_ACCURACY_SCAN,
522 + NL80211_EXT_FEATURE_DFS_OFFLOAD,
523 + NL80211_EXT_FEATURE_CONTROL_PORT_OVER_NL80211,
524 + NL80211_EXT_FEATURE_DATA_ACK_SIGNAL_SUPPORT,
525 + NL80211_EXT_FEATURE_TXQS,
526 + NL80211_EXT_FEATURE_SCAN_RANDOM_SN,
527 + NL80211_EXT_FEATURE_SCAN_MIN_PREQ_CONTENT,
528
529 /* add new features before the definition below */
530 NUM_NL80211_EXT_FEATURES,
531 @@ -5032,6 +5324,10 @@ enum nl80211_timeout_reason {
532 * of NL80211_CMD_TRIGGER_SCAN and NL80211_CMD_START_SCHED_SCAN
533 * requests.
534 *
535 + * NL80211_SCAN_FLAG_LOW_SPAN, NL80211_SCAN_FLAG_LOW_POWER, and
536 + * NL80211_SCAN_FLAG_HIGH_ACCURACY flags are exclusive of each other, i.e., only
537 + * one of them can be used in the request.
538 + *
539 * @NL80211_SCAN_FLAG_LOW_PRIORITY: scan request has low priority
540 * @NL80211_SCAN_FLAG_FLUSH: flush cache before scanning
541 * @NL80211_SCAN_FLAG_AP: force a scan even if the interface is configured
542 @@ -5059,7 +5355,26 @@ enum nl80211_timeout_reason {
543 * and suppression (if it has received a broadcast Probe Response frame,
544 * Beacon frame or FILS Discovery frame from an AP that the STA considers
545 * a suitable candidate for (re-)association - suitable in terms of
546 - * SSID and/or RSSI
547 + * SSID and/or RSSI.
548 + * @NL80211_SCAN_FLAG_LOW_SPAN: Span corresponds to the total time taken to
549 + * accomplish the scan. Thus, this flag intends the driver to perform the
550 + * scan request with lesser span/duration. It is specific to the driver
551 + * implementations on how this is accomplished. Scan accuracy may get
552 + * impacted with this flag.
553 + * @NL80211_SCAN_FLAG_LOW_POWER: This flag intends the scan attempts to consume
554 + * optimal possible power. Drivers can resort to their specific means to
555 + * optimize the power. Scan accuracy may get impacted with this flag.
556 + * @NL80211_SCAN_FLAG_HIGH_ACCURACY: Accuracy here intends to the extent of scan
557 + * results obtained. Thus HIGH_ACCURACY scan flag aims to get maximum
558 + * possible scan results. This flag hints the driver to use the best
559 + * possible scan configuration to improve the accuracy in scanning.
560 + * Latency and power use may get impacted with this flag.
561 + * @NL80211_SCAN_FLAG_RANDOM_SN: randomize the sequence number in probe
562 + * request frames from this scan to avoid correlation/tracking being
563 + * possible.
564 + * @NL80211_SCAN_FLAG_MIN_PREQ_CONTENT: minimize probe request content to
565 + * only have supported rates and no additional capabilities (unless
566 + * added by userspace explicitly.)
567 */
568 enum nl80211_scan_flags {
569 NL80211_SCAN_FLAG_LOW_PRIORITY = 1<<0,
570 @@ -5070,6 +5385,11 @@ enum nl80211_scan_flags {
571 NL80211_SCAN_FLAG_ACCEPT_BCAST_PROBE_RESP = 1<<5,
572 NL80211_SCAN_FLAG_OCE_PROBE_REQ_HIGH_TX_RATE = 1<<6,
573 NL80211_SCAN_FLAG_OCE_PROBE_REQ_DEFERRAL_SUPPRESSION = 1<<7,
574 + NL80211_SCAN_FLAG_LOW_SPAN = 1<<8,
575 + NL80211_SCAN_FLAG_LOW_POWER = 1<<9,
576 + NL80211_SCAN_FLAG_HIGH_ACCURACY = 1<<10,
577 + NL80211_SCAN_FLAG_RANDOM_SN = 1<<11,
578 + NL80211_SCAN_FLAG_MIN_PREQ_CONTENT = 1<<12,
579 };
580
581 /**
582 @@ -5127,6 +5447,8 @@ enum nl80211_smps_mode {
583 * non-operating channel is expired and no longer valid. New CAC must
584 * be done on this channel before starting the operation. This is not
585 * applicable for ETSI dfs domain where pre-CAC is valid for ever.
586 + * @NL80211_RADAR_CAC_STARTED: Channel Availability Check has been started,
587 + * should be generated by HW if NL80211_EXT_FEATURE_DFS_OFFLOAD is enabled.
588 */
589 enum nl80211_radar_event {
590 NL80211_RADAR_DETECTED,
591 @@ -5134,6 +5456,7 @@ enum nl80211_radar_event {
592 NL80211_RADAR_CAC_ABORTED,
593 NL80211_RADAR_NOP_FINISHED,
594 NL80211_RADAR_PRE_CAC_EXPIRED,
595 + NL80211_RADAR_CAC_STARTED,
596 };
597
598 /**
599 @@ -5425,11 +5748,11 @@ enum nl80211_nan_func_attributes {
600 * @NL80211_NAN_SRF_INCLUDE: present if the include bit of the SRF set.
601 * This is a flag.
602 * @NL80211_NAN_SRF_BF: Bloom Filter. Present if and only if
603 - * &NL80211_NAN_SRF_MAC_ADDRS isn't present. This attribute is binary.
604 + * %NL80211_NAN_SRF_MAC_ADDRS isn't present. This attribute is binary.
605 * @NL80211_NAN_SRF_BF_IDX: index of the Bloom Filter. Mandatory if
606 - * &NL80211_NAN_SRF_BF is present. This is a u8.
607 + * %NL80211_NAN_SRF_BF is present. This is a u8.
608 * @NL80211_NAN_SRF_MAC_ADDRS: list of MAC addresses for the SRF. Present if
609 - * and only if &NL80211_NAN_SRF_BF isn't present. This is a nested
610 + * and only if %NL80211_NAN_SRF_BF isn't present. This is a nested
611 * attribute. Each nested attribute is a MAC address.
612 * @NUM_NL80211_NAN_SRF_ATTR: internal
613 * @NL80211_NAN_SRF_ATTR_MAX: highest NAN SRF attribute
614 @@ -5469,4 +5792,15 @@ enum nl80211_nan_match_attributes {
615 NL80211_NAN_MATCH_ATTR_MAX = NUM_NL80211_NAN_MATCH_ATTR - 1
616 };
617
618 +/**
619 + * nl80211_external_auth_action - Action to perform with external
620 + * authentication request. Used by NL80211_ATTR_EXTERNAL_AUTH_ACTION.
621 + * @NL80211_EXTERNAL_AUTH_START: Start the authentication.
622 + * @NL80211_EXTERNAL_AUTH_ABORT: Abort the ongoing authentication.
623 + */
624 +enum nl80211_external_auth_action {
625 + NL80211_EXTERNAL_AUTH_START,
626 + NL80211_EXTERNAL_AUTH_ABORT,
627 +};
628 +
629 #endif /* __LINUX_NL80211_H */