diff options
author | Rafał Miłecki <zajec5@gmail.com> | 2014-05-31 22:49:37 +0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2014-06-19 23:49:13 +0400 |
commit | f9471e9973fd887b8af888b98860182b6c534ea2 (patch) | |
tree | bb84f7dd9230c673d3348db68cb014058116aa70 | |
parent | eb530b0fed7ec8ca435ec421cbff773b318a6a00 (diff) | |
download | linux-f9471e9973fd887b8af888b98860182b6c534ea2.tar.xz |
b43: b43_op_config: set channel info before switching band
Band switching code needs to know what channel we switch to.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | drivers/net/wireless/b43/main.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/b43/phy_common.c | 1 |
2 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/b43/main.c b/drivers/net/wireless/b43/main.c index 59aa4fdb2aeb..5e4eed37e3ce 100644 --- a/drivers/net/wireless/b43/main.c +++ b/drivers/net/wireless/b43/main.c @@ -3808,6 +3808,7 @@ static int b43_op_config(struct ieee80211_hw *hw, u32 changed) b43_mac_suspend(dev); if (changed & IEEE80211_CONF_CHANGE_CHANNEL) { + phy->channel = conf->chandef.chan->hw_value; if (conf_is_ht(conf)) phy->is_40mhz = conf_is_ht40_minus(conf) || conf_is_ht40_plus(conf); @@ -3822,7 +3823,7 @@ static int b43_op_config(struct ieee80211_hw *hw, u32 changed) /* Switch to the requested channel. * The firmware takes care of races with the TX handler. */ - b43_switch_channel(dev, conf->chandef.chan->hw_value); + b43_switch_channel(dev, phy->channel); } if (changed & IEEE80211_CONF_CHANGE_RETRY_LIMITS) diff --git a/drivers/net/wireless/b43/phy_common.c b/drivers/net/wireless/b43/phy_common.c index 3bfb795f6a6d..b465011c14ea 100644 --- a/drivers/net/wireless/b43/phy_common.c +++ b/drivers/net/wireless/b43/phy_common.c @@ -424,7 +424,6 @@ int b43_switch_channel(struct b43_wldev *dev, unsigned int new_channel) if (err) goto err_restore_cookie; - dev->phy.channel = new_channel; /* Wait for the radio to tune to the channel and stabilize. */ msleep(8); |