afa55064e5b7641177542eeed7f6703877c127c7
[openwrt/openwrt.git] / package / network / utils / iw / patches / 001-nl80211_h_sync.patch
1 --- a/nl80211.h
2 +++ b/nl80211.h
3 @@ -1761,6 +1761,9 @@ enum nl80211_commands {
4 * @NL80211_ATTR_REG_INDOOR: flag attribute, if set indicates that the device
5 * is operating in an indoor environment.
6 *
7 + * @NL80211_ATTR_WIPHY_ANTENNA_GAIN: Configured antenna gain. Used to reduce
8 + * transmit power to stay within regulatory limits. u32, dBi.
9 + *
10 * @NUM_NL80211_ATTR: total number of nl80211_attrs available
11 * @NL80211_ATTR_MAX: highest attribute number currently defined
12 * @__NL80211_ATTR_AFTER_LAST: internal use
13 @@ -2130,6 +2133,8 @@ enum nl80211_attrs {
14
15 NL80211_ATTR_REG_INDOOR,
16
17 + NL80211_ATTR_WIPHY_ANTENNA_GAIN,
18 +
19 /* add attributes here, update the policy in nl80211.c */
20
21 __NL80211_ATTR_AFTER_LAST,
22 @@ -2620,16 +2625,17 @@ enum nl80211_band_attr {
23 * an indoor surroundings, i.e., it is connected to AC power (and not
24 * through portable DC inverters) or is under the control of a master
25 * that is acting as an AP and is connected to AC power.
26 - * @NL80211_FREQUENCY_ATTR_GO_CONCURRENT: GO operation is allowed on this
27 + * @NL80211_FREQUENCY_ATTR_IR_CONCURRENT: IR operation is allowed on this
28 * channel if it's connected concurrently to a BSS on the same channel on
29 * the 2 GHz band or to a channel in the same UNII band (on the 5 GHz
30 - * band), and IEEE80211_CHAN_RADAR is not set. Instantiating a GO on a
31 - * channel that has the GO_CONCURRENT attribute set can be done when there
32 - * is a clear assessment that the device is operating under the guidance of
33 - * an authorized master, i.e., setting up a GO while the device is also
34 - * connected to an AP with DFS and radar detection on the UNII band (it is
35 - * up to user-space, i.e., wpa_supplicant to perform the required
36 - * verifications)
37 + * band), and IEEE80211_CHAN_RADAR is not set. Instantiating a GO or TDLS
38 + * off-channel on a channel that has the IR_CONCURRENT attribute set can be
39 + * done when there is a clear assessment that the device is operating under
40 + * the guidance of an authorized master, i.e., setting up a GO or TDLS
41 + * off-channel while the device is also connected to an AP with DFS and
42 + * radar detection on the UNII band (it is up to user-space, i.e.,
43 + * wpa_supplicant to perform the required verifications). Using this
44 + * attribute for IR is disallowed for master interfaces (IBSS, AP).
45 * @NL80211_FREQUENCY_ATTR_NO_20MHZ: 20 MHz operation is not allowed
46 * on this channel in current regulatory domain.
47 * @NL80211_FREQUENCY_ATTR_NO_10MHZ: 10 MHz operation is not allowed
48 @@ -2641,7 +2647,7 @@ enum nl80211_band_attr {
49 * See https://apps.fcc.gov/eas/comments/GetPublishedDocument.html?id=327&tn=528122
50 * for more information on the FCC description of the relaxations allowed
51 * by NL80211_FREQUENCY_ATTR_INDOOR_ONLY and
52 - * NL80211_FREQUENCY_ATTR_GO_CONCURRENT.
53 + * NL80211_FREQUENCY_ATTR_IR_CONCURRENT.
54 */
55 enum nl80211_frequency_attr {
56 __NL80211_FREQUENCY_ATTR_INVALID,
57 @@ -2659,7 +2665,7 @@ enum nl80211_frequency_attr {
58 NL80211_FREQUENCY_ATTR_NO_160MHZ,
59 NL80211_FREQUENCY_ATTR_DFS_CAC_TIME,
60 NL80211_FREQUENCY_ATTR_INDOOR_ONLY,
61 - NL80211_FREQUENCY_ATTR_GO_CONCURRENT,
62 + NL80211_FREQUENCY_ATTR_IR_CONCURRENT,
63 NL80211_FREQUENCY_ATTR_NO_20MHZ,
64 NL80211_FREQUENCY_ATTR_NO_10MHZ,
65
66 @@ -2672,6 +2678,8 @@ enum nl80211_frequency_attr {
67 #define NL80211_FREQUENCY_ATTR_PASSIVE_SCAN NL80211_FREQUENCY_ATTR_NO_IR
68 #define NL80211_FREQUENCY_ATTR_NO_IBSS NL80211_FREQUENCY_ATTR_NO_IR
69 #define NL80211_FREQUENCY_ATTR_NO_IR NL80211_FREQUENCY_ATTR_NO_IR
70 +#define NL80211_FREQUENCY_ATTR_GO_CONCURRENT \
71 + NL80211_FREQUENCY_ATTR_IR_CONCURRENT
72
73 /**
74 * enum nl80211_bitrate_attr - bitrate attributes
75 @@ -2830,7 +2838,7 @@ enum nl80211_sched_scan_match_attr {
76 * @NL80211_RRF_AUTO_BW: maximum available bandwidth should be calculated
77 * base on contiguous rules and wider channels will be allowed to cross
78 * multiple contiguous/overlapping frequency ranges.
79 - * @NL80211_RRF_GO_CONCURRENT: See &NL80211_FREQUENCY_ATTR_GO_CONCURRENT
80 + * @NL80211_RRF_IR_CONCURRENT: See &NL80211_FREQUENCY_ATTR_IR_CONCURRENT
81 * @NL80211_RRF_NO_HT40MINUS: channels can't be used in HT40- operation
82 * @NL80211_RRF_NO_HT40PLUS: channels can't be used in HT40+ operation
83 * @NL80211_RRF_NO_80MHZ: 80MHz operation not allowed
84 @@ -2847,7 +2855,7 @@ enum nl80211_reg_rule_flags {
85 NL80211_RRF_NO_IR = 1<<7,
86 __NL80211_RRF_NO_IBSS = 1<<8,
87 NL80211_RRF_AUTO_BW = 1<<11,
88 - NL80211_RRF_GO_CONCURRENT = 1<<12,
89 + NL80211_RRF_IR_CONCURRENT = 1<<12,
90 NL80211_RRF_NO_HT40MINUS = 1<<13,
91 NL80211_RRF_NO_HT40PLUS = 1<<14,
92 NL80211_RRF_NO_80MHZ = 1<<15,
93 @@ -2859,6 +2867,7 @@ enum nl80211_reg_rule_flags {
94 #define NL80211_RRF_NO_IR NL80211_RRF_NO_IR
95 #define NL80211_RRF_NO_HT40 (NL80211_RRF_NO_HT40MINUS |\
96 NL80211_RRF_NO_HT40PLUS)
97 +#define NL80211_RRF_GO_CONCURRENT NL80211_RRF_IR_CONCURRENT
98
99 /* For backport compatibility with older userspace */
100 #define NL80211_RRF_NO_IR_ALL (NL80211_RRF_NO_IR | __NL80211_RRF_NO_IBSS)