diff options
| author | Luis R. Rodriguez <mcgrof@do-not-panic.com> | 2013-10-21 13:22:25 -0400 |
|---|---|---|
| committer | Johannes Berg <johannes.berg@intel.com> | 2013-11-25 14:49:35 -0500 |
| commit | 8fe02e167efa8ed4a4503a5eedc0f49fcb7e3eb9 (patch) | |
| tree | 751497c11ae0b02cd90113a379e1fc35c84783ac /include/uapi/linux | |
| parent | c17bff87bed4bda1835ee41dc908e926414d8d85 (diff) | |
cfg80211: consolidate passive-scan and no-ibss flags
These two flags are used for the same purpose, just
combine them into a no-ir flag to annotate no initiating
radiation is allowed.
Old userspace sending either flag will have it treated as
the no-ir flag. To be considerate to older userspace we
also send both the no-ir flag and the old no-ibss flags.
Newer userspace will have to be aware of older kernels.
Update all places in the tree using these flags with the
following semantic patch:
@@
@@
-NL80211_RRF_PASSIVE_SCAN
+NL80211_RRF_NO_IR
@@
@@
-NL80211_RRF_NO_IBSS
+NL80211_RRF_NO_IR
@@
@@
-IEEE80211_CHAN_PASSIVE_SCAN
+IEEE80211_CHAN_NO_IR
@@
@@
-IEEE80211_CHAN_NO_IBSS
+IEEE80211_CHAN_NO_IR
@@
@@
-NL80211_RRF_NO_IR | NL80211_RRF_NO_IR
+NL80211_RRF_NO_IR
@@
@@
-IEEE80211_CHAN_NO_IR | IEEE80211_CHAN_NO_IR
+IEEE80211_CHAN_NO_IR
@@
@@
-(NL80211_RRF_NO_IR)
+NL80211_RRF_NO_IR
@@
@@
-(IEEE80211_CHAN_NO_IR)
+IEEE80211_CHAN_NO_IR
Along with some hand-optimisations in documentation, to
remove duplicates and to fix some indentation.
Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com>
[do all the driver updates in one go]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'include/uapi/linux')
| -rw-r--r-- | include/uapi/linux/nl80211.h | 30 |
1 files changed, 20 insertions, 10 deletions
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h index 3d8325bb50cd..7e25164adfe9 100644 --- a/include/uapi/linux/nl80211.h +++ b/include/uapi/linux/nl80211.h | |||
| @@ -2231,10 +2231,9 @@ enum nl80211_band_attr { | |||
| 2231 | * @NL80211_FREQUENCY_ATTR_FREQ: Frequency in MHz | 2231 | * @NL80211_FREQUENCY_ATTR_FREQ: Frequency in MHz |
| 2232 | * @NL80211_FREQUENCY_ATTR_DISABLED: Channel is disabled in current | 2232 | * @NL80211_FREQUENCY_ATTR_DISABLED: Channel is disabled in current |
| 2233 | * regulatory domain. | 2233 | * regulatory domain. |
| 2234 | * @NL80211_FREQUENCY_ATTR_PASSIVE_SCAN: Only passive scanning is | 2234 | * @NL80211_FREQUENCY_ATTR_NO_IR: no mechanisms that initiate radiation |
| 2235 | * permitted on this channel in current regulatory domain. | 2235 | * are permitted on this channel, this includes sending probe |
| 2236 | * @NL80211_FREQUENCY_ATTR_NO_IBSS: IBSS networks are not permitted | 2236 | * requests, or modes of operation that require beaconing. |
| 2237 | * on this channel in current regulatory domain. | ||
| 2238 | * @NL80211_FREQUENCY_ATTR_RADAR: Radar detection is mandatory | 2237 | * @NL80211_FREQUENCY_ATTR_RADAR: Radar detection is mandatory |
| 2239 | * on this channel in current regulatory domain. | 2238 | * on this channel in current regulatory domain. |
| 2240 | * @NL80211_FREQUENCY_ATTR_MAX_TX_POWER: Maximum transmission power in mBm | 2239 | * @NL80211_FREQUENCY_ATTR_MAX_TX_POWER: Maximum transmission power in mBm |
| @@ -2261,8 +2260,8 @@ enum nl80211_frequency_attr { | |||
| 2261 | __NL80211_FREQUENCY_ATTR_INVALID, | 2260 | __NL80211_FREQUENCY_ATTR_INVALID, |
| 2262 | NL80211_FREQUENCY_ATTR_FREQ, | 2261 | NL80211_FREQUENCY_ATTR_FREQ, |
| 2263 | NL80211_FREQUENCY_ATTR_DISABLED, | 2262 | NL80211_FREQUENCY_ATTR_DISABLED, |
| 2264 | NL80211_FREQUENCY_ATTR_PASSIVE_SCAN, | 2263 | NL80211_FREQUENCY_ATTR_NO_IR, |
| 2265 | NL80211_FREQUENCY_ATTR_NO_IBSS, | 2264 | __NL80211_FREQUENCY_ATTR_NO_IBSS, |
| 2266 | NL80211_FREQUENCY_ATTR_RADAR, | 2265 | NL80211_FREQUENCY_ATTR_RADAR, |
| 2267 | NL80211_FREQUENCY_ATTR_MAX_TX_POWER, | 2266 | NL80211_FREQUENCY_ATTR_MAX_TX_POWER, |
| 2268 | NL80211_FREQUENCY_ATTR_DFS_STATE, | 2267 | NL80211_FREQUENCY_ATTR_DFS_STATE, |
| @@ -2278,6 +2277,9 @@ enum nl80211_frequency_attr { | |||
| 2278 | }; | 2277 | }; |
| 2279 | 2278 | ||
| 2280 | #define NL80211_FREQUENCY_ATTR_MAX_TX_POWER NL80211_FREQUENCY_ATTR_MAX_TX_POWER | 2279 | #define NL80211_FREQUENCY_ATTR_MAX_TX_POWER NL80211_FREQUENCY_ATTR_MAX_TX_POWER |
| 2280 | #define NL80211_FREQUENCY_ATTR_PASSIVE_SCAN NL80211_FREQUENCY_ATTR_NO_IR | ||
| 2281 | #define NL80211_FREQUENCY_ATTR_NO_IBSS NL80211_FREQUENCY_ATTR_NO_IR | ||
| 2282 | #define NL80211_FREQUENCY_ATTR_NO_IR NL80211_FREQUENCY_ATTR_NO_IR | ||
| 2281 | 2283 | ||
| 2282 | /** | 2284 | /** |
| 2283 | * enum nl80211_bitrate_attr - bitrate attributes | 2285 | * enum nl80211_bitrate_attr - bitrate attributes |
| @@ -2420,8 +2422,9 @@ enum nl80211_sched_scan_match_attr { | |||
| 2420 | * @NL80211_RRF_DFS: DFS support is required to be used | 2422 | * @NL80211_RRF_DFS: DFS support is required to be used |
| 2421 | * @NL80211_RRF_PTP_ONLY: this is only for Point To Point links | 2423 | * @NL80211_RRF_PTP_ONLY: this is only for Point To Point links |
| 2422 | * @NL80211_RRF_PTMP_ONLY: this is only for Point To Multi Point links | 2424 | * @NL80211_RRF_PTMP_ONLY: this is only for Point To Multi Point links |
| 2423 | * @NL80211_RRF_PASSIVE_SCAN: passive scan is required | 2425 | * @NL80211_RRF_NO_IR: no mechanisms that initiate radiation are allowed, |
| 2424 | * @NL80211_RRF_NO_IBSS: no IBSS is allowed | 2426 | * this includes probe requests or modes of operation that require |
| 2427 | * beaconing. | ||
| 2425 | */ | 2428 | */ |
| 2426 | enum nl80211_reg_rule_flags { | 2429 | enum nl80211_reg_rule_flags { |
| 2427 | NL80211_RRF_NO_OFDM = 1<<0, | 2430 | NL80211_RRF_NO_OFDM = 1<<0, |
| @@ -2431,10 +2434,17 @@ enum nl80211_reg_rule_flags { | |||
| 2431 | NL80211_RRF_DFS = 1<<4, | 2434 | NL80211_RRF_DFS = 1<<4, |
| 2432 | NL80211_RRF_PTP_ONLY = 1<<5, | 2435 | NL80211_RRF_PTP_ONLY = 1<<5, |
| 2433 | NL80211_RRF_PTMP_ONLY = 1<<6, | 2436 | NL80211_RRF_PTMP_ONLY = 1<<6, |
| 2434 | NL80211_RRF_PASSIVE_SCAN = 1<<7, | 2437 | NL80211_RRF_NO_IR = 1<<7, |
| 2435 | NL80211_RRF_NO_IBSS = 1<<8, | 2438 | __NL80211_RRF_NO_IBSS = 1<<8, |
| 2436 | }; | 2439 | }; |
| 2437 | 2440 | ||
| 2441 | #define NL80211_RRF_PASSIVE_SCAN NL80211_RRF_NO_IR | ||
| 2442 | #define NL80211_RRF_NO_IBSS NL80211_RRF_NO_IR | ||
| 2443 | #define NL80211_RRF_NO_IR NL80211_RRF_NO_IR | ||
| 2444 | |||
| 2445 | /* For backport compatibility with older userspace */ | ||
| 2446 | #define NL80211_RRF_NO_IR_ALL (NL80211_RRF_NO_IR | __NL80211_RRF_NO_IBSS) | ||
| 2447 | |||
| 2438 | /** | 2448 | /** |
| 2439 | * enum nl80211_dfs_regions - regulatory DFS regions | 2449 | * enum nl80211_dfs_regions - regulatory DFS regions |
| 2440 | * | 2450 | * |
