mac80211: update to wireless-testing 2013-06-27, fix ATH_USER_REGD handling
[openwrt/svn-archive/archive.git] / package / network / utils / iw / patches / 001-nl80211_h_sync.patch
1 --- a/nl80211.h
2 +++ b/nl80211.h
3 @@ -27,6 +27,8 @@
4
5 #include <linux/types.h>
6
7 +#define NL80211_GENL_NAME "nl80211"
8 +
9 /**
10 * DOC: Station handling
11 *
12 @@ -1429,6 +1431,11 @@ enum nl80211_commands {
13 * @NL80211_ATTR_MAX_CRIT_PROT_DURATION: duration in milliseconds in which
14 * the connection should have increased reliability (u16).
15 *
16 + * @NL80211_ATTR_PEER_AID: Association ID for the peer TDLS station (u16).
17 + * This is similar to @NL80211_ATTR_STA_AID but with a difference of being
18 + * allowed to be used with the first @NL80211_CMD_SET_STATION command to
19 + * update a TDLS peer STA entry.
20 + *
21 * @NL80211_ATTR_MAX: highest attribute number currently defined
22 * @__NL80211_ATTR_AFTER_LAST: internal use
23 */
24 @@ -1727,6 +1734,10 @@ enum nl80211_attrs {
25 NL80211_ATTR_CRIT_PROT_ID,
26 NL80211_ATTR_MAX_CRIT_PROT_DURATION,
27
28 + NL80211_ATTR_PEER_AID,
29 +
30 + NL80211_ATTR_WIPHY_ANTENNA_GAIN,
31 +
32 /* add attributes here, update the policy in nl80211.c */
33
34 __NL80211_ATTR_AFTER_LAST,
35 @@ -1991,6 +2002,10 @@ enum nl80211_sta_bss_param {
36 * @NL80211_STA_INFO_PEER_PM: peer mesh STA link-specific power mode
37 * @NL80211_STA_INFO_NONPEER_PM: neighbor mesh STA power save mode towards
38 * non-peer STA
39 + * @NL80211_STA_INFO_CHAIN_SIGNAL: per-chain signal strength of last PPDU
40 + * Contains a nested array of signal strength attributes (u8, dBm)
41 + * @NL80211_STA_INFO_CHAIN_SIGNAL_AVG: per-chain signal strength average
42 + * Same format as NL80211_STA_INFO_CHAIN_SIGNAL.
43 * @__NL80211_STA_INFO_AFTER_LAST: internal
44 * @NL80211_STA_INFO_MAX: highest possible station info attribute
45 */
46 @@ -2020,6 +2035,8 @@ enum nl80211_sta_info {
47 NL80211_STA_INFO_NONPEER_PM,
48 NL80211_STA_INFO_RX_BYTES64,
49 NL80211_STA_INFO_TX_BYTES64,
50 + NL80211_STA_INFO_CHAIN_SIGNAL,
51 + NL80211_STA_INFO_CHAIN_SIGNAL_AVG,
52
53 /* keep last */
54 __NL80211_STA_INFO_AFTER_LAST,
55 @@ -2413,6 +2430,8 @@ enum nl80211_survey_info {
56 * @NL80211_MNTR_FLAG_OTHER_BSS: disable BSSID filtering
57 * @NL80211_MNTR_FLAG_COOK_FRAMES: report frames after processing.
58 * overrides all other flags.
59 + * @NL80211_MNTR_FLAG_ACTIVE: use the configured MAC address
60 + * and ACK incoming unicast packets.
61 *
62 * @__NL80211_MNTR_FLAG_AFTER_LAST: internal use
63 * @NL80211_MNTR_FLAG_MAX: highest possible monitor flag
64 @@ -2424,6 +2443,7 @@ enum nl80211_mntr_flags {
65 NL80211_MNTR_FLAG_CONTROL,
66 NL80211_MNTR_FLAG_OTHER_BSS,
67 NL80211_MNTR_FLAG_COOK_FRAMES,
68 + NL80211_MNTR_FLAG_ACTIVE,
69
70 /* keep last */
71 __NL80211_MNTR_FLAG_AFTER_LAST,
72 @@ -2559,6 +2579,10 @@ enum nl80211_mesh_power_mode {
73 *
74 * @NL80211_MESHCONF_AWAKE_WINDOW: awake window duration (in TUs)
75 *
76 + * @NL80211_MESHCONF_PLINK_TIMEOUT: If no tx activity is seen from a STA we've
77 + * established peering with for longer than this time (in seconds), then
78 + * remove it from the STA's list of peers. Default is 30 minutes.
79 + *
80 * @__NL80211_MESHCONF_ATTR_AFTER_LAST: internal use
81 */
82 enum nl80211_meshconf_params {
83 @@ -2590,6 +2614,7 @@ enum nl80211_meshconf_params {
84 NL80211_MESHCONF_HWMP_CONFIRMATION_INTERVAL,
85 NL80211_MESHCONF_POWER_MODE,
86 NL80211_MESHCONF_AWAKE_WINDOW,
87 + NL80211_MESHCONF_PLINK_TIMEOUT,
88
89 /* keep last */
90 __NL80211_MESHCONF_ATTR_AFTER_LAST,
91 @@ -2637,6 +2662,10 @@ enum nl80211_meshconf_params {
92 * @NL80211_MESH_SETUP_USERSPACE_MPM: Enable this option if userspace will
93 * implement an MPM which handles peer allocation and state.
94 *
95 + * @NL80211_MESH_SETUP_AUTH_PROTOCOL: Inform the kernel of the authentication
96 + * method (u8, as defined in IEEE 8.4.2.100.6, e.g. 0x1 for SAE).
97 + * Default is no authentication method required.
98 + *
99 * @NL80211_MESH_SETUP_ATTR_MAX: highest possible mesh setup attribute number
100 *
101 * @__NL80211_MESH_SETUP_ATTR_AFTER_LAST: Internal use
102 @@ -2650,6 +2679,7 @@ enum nl80211_mesh_setup_params {
103 NL80211_MESH_SETUP_USERSPACE_AMPE,
104 NL80211_MESH_SETUP_ENABLE_VENDOR_SYNC,
105 NL80211_MESH_SETUP_USERSPACE_MPM,
106 + NL80211_MESH_SETUP_AUTH_PROTOCOL,
107
108 /* keep last */
109 __NL80211_MESH_SETUP_ATTR_AFTER_LAST,
110 @@ -2730,6 +2760,8 @@ enum nl80211_channel_type {
111 * and %NL80211_ATTR_CENTER_FREQ2 attributes must be provided as well
112 * @NL80211_CHAN_WIDTH_160: 160 MHz channel, the %NL80211_ATTR_CENTER_FREQ1
113 * attribute must be provided as well
114 + * @NL80211_CHAN_WIDTH_5: 5 MHz OFDM channel
115 + * @NL80211_CHAN_WIDTH_10: 10 MHz OFDM channel
116 */
117 enum nl80211_chan_width {
118 NL80211_CHAN_WIDTH_20_NOHT,
119 @@ -2738,6 +2770,8 @@ enum nl80211_chan_width {
120 NL80211_CHAN_WIDTH_80,
121 NL80211_CHAN_WIDTH_80P80,
122 NL80211_CHAN_WIDTH_160,
123 + NL80211_CHAN_WIDTH_5,
124 + NL80211_CHAN_WIDTH_10,
125 };
126
127 /**
128 @@ -3028,11 +3062,11 @@ enum nl80211_tx_power_setting {
129 };
130
131 /**
132 - * enum nl80211_wowlan_packet_pattern_attr - WoWLAN packet pattern attribute
133 - * @__NL80211_WOWLAN_PKTPAT_INVALID: invalid number for nested attribute
134 - * @NL80211_WOWLAN_PKTPAT_PATTERN: the pattern, values where the mask has
135 + * enum nl80211_packet_pattern_attr - packet pattern attribute
136 + * @__NL80211_PKTPAT_INVALID: invalid number for nested attribute
137 + * @NL80211_PKTPAT_PATTERN: the pattern, values where the mask has
138 * a zero bit are ignored
139 - * @NL80211_WOWLAN_PKTPAT_MASK: pattern mask, must be long enough to have
140 + * @NL80211_PKTPAT_MASK: pattern mask, must be long enough to have
141 * a bit for each byte in the pattern. The lowest-order bit corresponds
142 * to the first byte of the pattern, but the bytes of the pattern are
143 * in a little-endian-like format, i.e. the 9th byte of the pattern
144 @@ -3043,23 +3077,23 @@ enum nl80211_tx_power_setting {
145 * Note that the pattern matching is done as though frames were not
146 * 802.11 frames but 802.3 frames, i.e. the frame is fully unpacked
147 * first (including SNAP header unpacking) and then matched.
148 - * @NL80211_WOWLAN_PKTPAT_OFFSET: packet offset, pattern is matched after
149 + * @NL80211_PKTPAT_OFFSET: packet offset, pattern is matched after
150 * these fixed number of bytes of received packet
151 - * @NUM_NL80211_WOWLAN_PKTPAT: number of attributes
152 - * @MAX_NL80211_WOWLAN_PKTPAT: max attribute number
153 + * @NUM_NL80211_PKTPAT: number of attributes
154 + * @MAX_NL80211_PKTPAT: max attribute number
155 */
156 -enum nl80211_wowlan_packet_pattern_attr {
157 - __NL80211_WOWLAN_PKTPAT_INVALID,
158 - NL80211_WOWLAN_PKTPAT_MASK,
159 - NL80211_WOWLAN_PKTPAT_PATTERN,
160 - NL80211_WOWLAN_PKTPAT_OFFSET,
161 +enum nl80211_packet_pattern_attr {
162 + __NL80211_PKTPAT_INVALID,
163 + NL80211_PKTPAT_MASK,
164 + NL80211_PKTPAT_PATTERN,
165 + NL80211_PKTPAT_OFFSET,
166
167 - NUM_NL80211_WOWLAN_PKTPAT,
168 - MAX_NL80211_WOWLAN_PKTPAT = NUM_NL80211_WOWLAN_PKTPAT - 1,
169 + NUM_NL80211_PKTPAT,
170 + MAX_NL80211_PKTPAT = NUM_NL80211_PKTPAT - 1,
171 };
172
173 /**
174 - * struct nl80211_wowlan_pattern_support - pattern support information
175 + * struct nl80211_pattern_support - packet pattern support information
176 * @max_patterns: maximum number of patterns supported
177 * @min_pattern_len: minimum length of each pattern
178 * @max_pattern_len: maximum length of each pattern
179 @@ -3069,13 +3103,22 @@ enum nl80211_wowlan_packet_pattern_attr
180 * that is part of %NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED in the
181 * capability information given by the kernel to userspace.
182 */
183 -struct nl80211_wowlan_pattern_support {
184 +struct nl80211_pattern_support {
185 __u32 max_patterns;
186 __u32 min_pattern_len;
187 __u32 max_pattern_len;
188 __u32 max_pkt_offset;
189 } __attribute__((packed));
190
191 +/* only for backward compatibility */
192 +#define __NL80211_WOWLAN_PKTPAT_INVALID __NL80211_PKTPAT_INVALID
193 +#define NL80211_WOWLAN_PKTPAT_MASK NL80211_PKTPAT_MASK
194 +#define NL80211_WOWLAN_PKTPAT_PATTERN NL80211_PKTPAT_PATTERN
195 +#define NL80211_WOWLAN_PKTPAT_OFFSET NL80211_PKTPAT_OFFSET
196 +#define NUM_NL80211_WOWLAN_PKTPAT NUM_NL80211_PKTPAT
197 +#define MAX_NL80211_WOWLAN_PKTPAT MAX_NL80211_PKTPAT
198 +#define nl80211_wowlan_pattern_support nl80211_pattern_support
199 +
200 /**
201 * enum nl80211_wowlan_triggers - WoWLAN trigger definitions
202 * @__NL80211_WOWLAN_TRIG_INVALID: invalid number for nested attributes
203 @@ -3095,7 +3138,7 @@ struct nl80211_wowlan_pattern_support {
204 * pattern matching is done after the packet is converted to the MSDU.
205 *
206 * In %NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED, it is a binary attribute
207 - * carrying a &struct nl80211_wowlan_pattern_support.
208 + * carrying a &struct nl80211_pattern_support.
209 *
210 * When reporting wakeup. it is a u32 attribute containing the 0-based
211 * index of the pattern that caused the wakeup, in the patterns passed
212 @@ -3252,7 +3295,7 @@ struct nl80211_wowlan_tcp_data_token_fea
213 * @NL80211_WOWLAN_TCP_WAKE_PAYLOAD: wake packet payload, for advertising a
214 * u32 attribute holding the maximum length
215 * @NL80211_WOWLAN_TCP_WAKE_MASK: Wake packet payload mask, not used for
216 - * feature advertising. The mask works like @NL80211_WOWLAN_PKTPAT_MASK
217 + * feature advertising. The mask works like @NL80211_PKTPAT_MASK
218 * but on the TCP payload only.
219 * @NUM_NL80211_WOWLAN_TCP: number of TCP attributes
220 * @MAX_NL80211_WOWLAN_TCP: highest attribute number
221 @@ -3556,6 +3599,10 @@ enum nl80211_ap_sme_features {
222 * Peering Management entity which may be implemented by registering for
223 * beacons or NL80211_CMD_NEW_PEER_CANDIDATE events. The mesh beacon is
224 * still generated by the driver.
225 + * @NL80211_FEATURE_ACTIVE_MONITOR: This driver supports an active monitor
226 + * interface. An active monitor interface behaves like a normal monitor
227 + * interface, but gets added to the driver. It ensures that incoming
228 + * unicast packets directed at the configured interface address get ACKed.
229 */
230 enum nl80211_feature_flags {
231 NL80211_FEATURE_SK_TX_STATUS = 1 << 0,
232 @@ -3575,6 +3622,7 @@ enum nl80211_feature_flags {
233 NL80211_FEATURE_ADVERTISE_CHAN_LIMITS = 1 << 14,
234 NL80211_FEATURE_FULL_AP_CLIENT_STATE = 1 << 15,
235 NL80211_FEATURE_USERSPACE_MPM = 1 << 16,
236 + NL80211_FEATURE_ACTIVE_MONITOR = 1 << 17,
237 };
238
239 /**