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 /drivers/net/wireless/mac80211_hwsim.c | |
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 'drivers/net/wireless/mac80211_hwsim.c')
-rw-r--r-- | drivers/net/wireless/mac80211_hwsim.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c index de0df86704e7..33d4b31995da 100644 --- a/drivers/net/wireless/mac80211_hwsim.c +++ b/drivers/net/wireless/mac80211_hwsim.c | |||
@@ -159,7 +159,7 @@ static const struct ieee80211_regdomain hwsim_world_regdom_custom_02 = { | |||
159 | .reg_rules = { | 159 | .reg_rules = { |
160 | REG_RULE(2412-10, 2462+10, 40, 0, 20, 0), | 160 | REG_RULE(2412-10, 2462+10, 40, 0, 20, 0), |
161 | REG_RULE(5725-10, 5850+10, 40, 0, 30, | 161 | REG_RULE(5725-10, 5850+10, 40, 0, 30, |
162 | NL80211_RRF_PASSIVE_SCAN | NL80211_RRF_NO_IBSS), | 162 | NL80211_RRF_NO_IR), |
163 | } | 163 | } |
164 | }; | 164 | }; |
165 | 165 | ||
@@ -1485,7 +1485,7 @@ static void hw_scan_work(struct work_struct *work) | |||
1485 | req->channels[hwsim->scan_chan_idx]->center_freq); | 1485 | req->channels[hwsim->scan_chan_idx]->center_freq); |
1486 | 1486 | ||
1487 | hwsim->tmp_chan = req->channels[hwsim->scan_chan_idx]; | 1487 | hwsim->tmp_chan = req->channels[hwsim->scan_chan_idx]; |
1488 | if (hwsim->tmp_chan->flags & IEEE80211_CHAN_PASSIVE_SCAN || | 1488 | if (hwsim->tmp_chan->flags & IEEE80211_CHAN_NO_IR || |
1489 | !req->n_ssids) { | 1489 | !req->n_ssids) { |
1490 | dwell = 120; | 1490 | dwell = 120; |
1491 | } else { | 1491 | } else { |