diff options
author | David S. Miller <davem@davemloft.net> | 2009-05-18 14:48:30 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-05-18 14:48:30 -0700 |
commit | 82d048186e403f36e083b37ad42aa90abb7dcaac (patch) | |
tree | dc0b92ace036ef435318f38ef35b8c6e6b84103a /net/mac80211/main.c | |
parent | 62551d3ea05242d97d47f26fb517b2dfdb752310 (diff) | |
parent | d3707d9918d47c0997a6b1e4ae24e7ab55e43796 (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6
Diffstat (limited to 'net/mac80211/main.c')
-rw-r--r-- | net/mac80211/main.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/net/mac80211/main.c b/net/mac80211/main.c index b80bc80e46c..76df5eabf26 100644 --- a/net/mac80211/main.c +++ b/net/mac80211/main.c @@ -154,15 +154,17 @@ static void ieee80211_master_set_multicast_list(struct net_device *dev) int ieee80211_hw_config(struct ieee80211_local *local, u32 changed) { - struct ieee80211_channel *chan; + struct ieee80211_channel *chan, *scan_chan; int ret = 0; int power; enum nl80211_channel_type channel_type; might_sleep(); - if (local->sw_scanning) { - chan = local->scan_channel; + scan_chan = local->scan_channel; + + if (scan_chan) { + chan = scan_chan; channel_type = NL80211_CHAN_NO_HT; } else { chan = local->oper_channel; @@ -176,7 +178,7 @@ int ieee80211_hw_config(struct ieee80211_local *local, u32 changed) changed |= IEEE80211_CONF_CHANGE_CHANNEL; } - if (local->sw_scanning) + if (scan_chan) power = chan->max_power; else power = local->power_constr_level ? @@ -859,8 +861,8 @@ int ieee80211_register_hw(struct ieee80211_hw *hw) if (!local->oper_channel) { /* init channel we're on */ local->hw.conf.channel = - local->oper_channel = - local->scan_channel = &sband->channels[0]; + local->oper_channel = &sband->channels[0]; + local->hw.conf.channel_type = NL80211_CHAN_NO_HT; } channels += sband->n_channels; |