diff options
author | Tony Lindgren <tony@atomide.com> | 2011-06-14 05:53:42 -0700 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2011-06-14 05:53:42 -0700 |
commit | b8ce9fb8e18af7466e0b915bb5979322cdace322 (patch) | |
tree | eec6f9b58ce154fd863f0f78b374a697a5a7139b /drivers/net/wireless/iwlegacy/iwl4965-base.c | |
parent | c8e0bf95fc01d6e2ca585fe08010800b6c56e823 (diff) | |
parent | e9e35c5a2b2c803b5e2f25906d8ffe110670ceb6 (diff) | |
download | op-kernel-dev-b8ce9fb8e18af7466e0b915bb5979322cdace322.zip op-kernel-dev-b8ce9fb8e18af7466e0b915bb5979322cdace322.tar.gz |
Merge branch 'fixes-v3.0-rc3' into devel-fixes
Diffstat (limited to 'drivers/net/wireless/iwlegacy/iwl4965-base.c')
-rw-r--r-- | drivers/net/wireless/iwlegacy/iwl4965-base.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/drivers/net/wireless/iwlegacy/iwl4965-base.c b/drivers/net/wireless/iwlegacy/iwl4965-base.c index af2ae22..7157ba5 100644 --- a/drivers/net/wireless/iwlegacy/iwl4965-base.c +++ b/drivers/net/wireless/iwlegacy/iwl4965-base.c @@ -2861,16 +2861,13 @@ void iwl4965_mac_channel_switch(struct ieee80211_hw *hw, goto out; if (test_bit(STATUS_EXIT_PENDING, &priv->status) || - test_bit(STATUS_SCANNING, &priv->status)) + test_bit(STATUS_SCANNING, &priv->status) || + test_bit(STATUS_CHANNEL_SWITCH_PENDING, &priv->status)) goto out; if (!iwl_legacy_is_associated_ctx(ctx)) goto out; - /* channel switch in progress */ - if (priv->switch_rxon.switch_in_progress == true) - goto out; - if (priv->cfg->ops->lib->set_channel_switch) { ch = channel->hw_value; @@ -2919,15 +2916,18 @@ void iwl4965_mac_channel_switch(struct ieee80211_hw *hw, * at this point, staging_rxon has the * configuration for channel switch */ - if (priv->cfg->ops->lib->set_channel_switch(priv, - ch_switch)) - priv->switch_rxon.switch_in_progress = false; + set_bit(STATUS_CHANNEL_SWITCH_PENDING, &priv->status); + priv->switch_channel = cpu_to_le16(ch); + if (priv->cfg->ops->lib->set_channel_switch(priv, ch_switch)) { + clear_bit(STATUS_CHANNEL_SWITCH_PENDING, + &priv->status); + priv->switch_channel = 0; + ieee80211_chswitch_done(ctx->vif, false); + } } } out: mutex_unlock(&priv->mutex); - if (!priv->switch_rxon.switch_in_progress) - ieee80211_chswitch_done(ctx->vif, false); IWL_DEBUG_MAC80211(priv, "leave\n"); } |