Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 277769
b: refs/heads/master
c: 5e5202a
h: refs/heads/master
i:
  277767: d0c7703
v: v3
  • Loading branch information
Stanislaw Gruszka authored and John W. Linville committed Nov 9, 2011
1 parent 60b5915 commit acbb6cc
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 68629c6133304f286a1f0c12d9aa8071a639f076
refs/heads/master: 5e5202a406896fb6d656d0e7d3f2f1cbfdda6384
14 changes: 6 additions & 8 deletions trunk/net/mac80211/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ static void ieee80211_reconfig_filter(struct work_struct *work)
*/
bool ieee80211_cfg_on_oper_channel(struct ieee80211_local *local)
{
struct ieee80211_channel *chan, *scan_chan;
struct ieee80211_channel *chan;
enum nl80211_channel_type channel_type;

/* This logic needs to match logic in ieee80211_hw_config */
Expand All @@ -114,7 +114,7 @@ bool ieee80211_cfg_on_oper_channel(struct ieee80211_local *local)
else
channel_type = NL80211_CHAN_NO_HT;
} else if (local->tmp_channel) {
chan = scan_chan = local->tmp_channel;
chan = local->tmp_channel;
channel_type = local->tmp_channel_type;
} else {
chan = local->oper_channel;
Expand All @@ -135,22 +135,20 @@ bool ieee80211_cfg_on_oper_channel(struct ieee80211_local *local)

int ieee80211_hw_config(struct ieee80211_local *local, u32 changed)
{
struct ieee80211_channel *chan, *scan_chan;
struct ieee80211_channel *chan;
int ret = 0;
int power;
enum nl80211_channel_type channel_type;
u32 offchannel_flag;

might_sleep();

scan_chan = local->scan_channel;

/* If this off-channel logic ever changes, ieee80211_on_oper_channel
* may need to change as well.
*/
offchannel_flag = local->hw.conf.flags & IEEE80211_CONF_OFFCHANNEL;
if (scan_chan) {
chan = scan_chan;
if (local->scan_channel) {
chan = local->scan_channel;
/* If scanning on oper channel, use whatever channel-type
* is currently in use.
*/
Expand All @@ -159,7 +157,7 @@ int ieee80211_hw_config(struct ieee80211_local *local, u32 changed)
else
channel_type = NL80211_CHAN_NO_HT;
} else if (local->tmp_channel) {
chan = scan_chan = local->tmp_channel;
chan = local->tmp_channel;
channel_type = local->tmp_channel_type;
} else {
chan = local->oper_channel;
Expand Down

0 comments on commit acbb6cc

Please sign in to comment.