diff options
author | Alexander Bondar <alexander.bondar@intel.com> | 2013-10-23 05:50:34 -0400 |
---|---|---|
committer | Emmanuel Grumbach <emmanuel.grumbach@intel.com> | 2013-12-17 12:39:42 -0500 |
commit | 92d8556250c81bd6d4df522926a2cb3711dd01e2 (patch) | |
tree | 5c1dcec1aa2344f2dc7299e713371f59508d2db3 /drivers/net/wireless/iwlwifi/mvm/mac80211.c | |
parent | 1c2abf724b3397830e60596a6a41e2d9f870d1a6 (diff) |
iwlwifi: mvm: Disable power save for monitor interface
When monitor interface is activated device power save needs
to be disabled.
Re-consider power management status on other active
interfaces when monitor interface is bound or unbound.
Signed-off-by: Alexander Bondar <alexander.bondar@intel.com>
Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/mvm/mac80211.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/mac80211.c | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/drivers/net/wireless/iwlwifi/mvm/mac80211.c b/drivers/net/wireless/iwlwifi/mvm/mac80211.c index e1c379a61d83..d36105fa4bf6 100644 --- a/drivers/net/wireless/iwlwifi/mvm/mac80211.c +++ b/drivers/net/wireless/iwlwifi/mvm/mac80211.c | |||
@@ -1610,7 +1610,13 @@ static int iwl_mvm_assign_vif_chanctx(struct ieee80211_hw *hw, | |||
1610 | goto out_unlock; | 1610 | goto out_unlock; |
1611 | 1611 | ||
1612 | /* | 1612 | /* |
1613 | * Setting the quota at this stage is only required for monitor | 1613 | * Power state must be updated before quotas, |
1614 | * otherwise fw will complain. | ||
1615 | */ | ||
1616 | mvm->bound_vif_cnt++; | ||
1617 | iwl_mvm_power_update_binding(mvm, vif, true); | ||
1618 | |||
1619 | /* Setting the quota at this stage is only required for monitor | ||
1614 | * interfaces. For the other types, the bss_info changed flow | 1620 | * interfaces. For the other types, the bss_info changed flow |
1615 | * will handle quota settings. | 1621 | * will handle quota settings. |
1616 | */ | 1622 | */ |
@@ -1621,13 +1627,12 @@ static int iwl_mvm_assign_vif_chanctx(struct ieee80211_hw *hw, | |||
1621 | goto out_remove_binding; | 1627 | goto out_remove_binding; |
1622 | } | 1628 | } |
1623 | 1629 | ||
1624 | mvm->bound_vif_cnt++; | ||
1625 | iwl_mvm_power_update_binding(mvm, vif); | ||
1626 | |||
1627 | goto out_unlock; | 1630 | goto out_unlock; |
1628 | 1631 | ||
1629 | out_remove_binding: | 1632 | out_remove_binding: |
1630 | iwl_mvm_binding_remove_vif(mvm, vif); | 1633 | iwl_mvm_binding_remove_vif(mvm, vif); |
1634 | mvm->bound_vif_cnt--; | ||
1635 | iwl_mvm_power_update_binding(mvm, vif, false); | ||
1631 | out_unlock: | 1636 | out_unlock: |
1632 | mutex_unlock(&mvm->mutex); | 1637 | mutex_unlock(&mvm->mutex); |
1633 | if (ret) | 1638 | if (ret) |
@@ -1662,7 +1667,7 @@ static void iwl_mvm_unassign_vif_chanctx(struct ieee80211_hw *hw, | |||
1662 | out_unlock: | 1667 | out_unlock: |
1663 | mvmvif->phy_ctxt = NULL; | 1668 | mvmvif->phy_ctxt = NULL; |
1664 | mvm->bound_vif_cnt--; | 1669 | mvm->bound_vif_cnt--; |
1665 | iwl_mvm_power_update_binding(mvm, vif); | 1670 | iwl_mvm_power_update_binding(mvm, vif, false); |
1666 | 1671 | ||
1667 | mutex_unlock(&mvm->mutex); | 1672 | mutex_unlock(&mvm->mutex); |
1668 | } | 1673 | } |