summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/mvm/mvm.h
diff options
context:
space:
mode:
authorAlexander Bondar2013-08-27 19:31:48 +0200
committerEmmanuel Grumbach2013-12-17 18:39:41 +0100
commit1c2abf724b3397830e60596a6a41e2d9f870d1a6 (patch)
tree341fb56ca221fbf92dd3254c72b5166c468741e5 /drivers/net/wireless/iwlwifi/mvm/mvm.h
parentiwlwifi: mvm: Add uAPSD misbehaving AP notification handling (diff)
downloadkernel-qcow2-linux-1c2abf724b3397830e60596a6a41e2d9f870d1a6.tar.gz
kernel-qcow2-linux-1c2abf724b3397830e60596a6a41e2d9f870d1a6.tar.xz
kernel-qcow2-linux-1c2abf724b3397830e60596a6a41e2d9f870d1a6.zip
iwlwifi: mvm: Change power management dependency on multi MAC
FW still does not support power management on multiple MAC interfaces. Currently the driver enforce this limitation by disabling PM if second interface is added. Change this behavior to allow PM on a single interface even if other interfaces exist but not bound to any specific PHY. PM will be enabled if only one single interface is bound. 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/mvm.h')
-rw-r--r--drivers/net/wireless/iwlwifi/mvm/mvm.h19
1 files changed, 13 insertions, 6 deletions
diff --git a/drivers/net/wireless/iwlwifi/mvm/mvm.h b/drivers/net/wireless/iwlwifi/mvm/mvm.h
index 5da5e2deb11a..51b0e9a4883f 100644
--- a/drivers/net/wireless/iwlwifi/mvm/mvm.h
+++ b/drivers/net/wireless/iwlwifi/mvm/mvm.h
@@ -163,6 +163,8 @@ struct iwl_mvm_power_ops {
struct ieee80211_vif *vif);
int (*power_update_device_mode)(struct iwl_mvm *mvm);
int (*power_disable)(struct iwl_mvm *mvm, struct ieee80211_vif *vif);
+ void (*power_update_binding)(struct iwl_mvm *mvm,
+ struct ieee80211_vif *vif);
#ifdef CONFIG_IWLWIFI_DEBUGFS
int (*power_dbgfs_read)(struct iwl_mvm *mvm, struct ieee80211_vif *vif,
char *buf, int bufsz);
@@ -336,6 +338,8 @@ struct iwl_mvm_vif {
/* FW identified misbehaving AP */
u8 uapsd_misbehaving_bssid[ETH_ALEN];
+
+ bool pm_prevented;
};
static inline struct iwl_mvm_vif *
@@ -520,12 +524,6 @@ struct iwl_mvm {
*/
unsigned long fw_key_table[BITS_TO_LONGS(STA_KEY_MAX_NUM)];
- /*
- * This counter of created interfaces is referenced only in conjunction
- * with FW limitation related to power management. Currently PM is
- * supported only on a single interface.
- * IMPORTANT: this variable counts all interfaces except P2P device.
- */
u8 vif_count;
/* -1 for always, 0 for never, >0 for that many times */
@@ -568,6 +566,8 @@ struct iwl_mvm {
u8 aux_queue;
u8 first_agg_queue;
u8 last_agg_queue;
+
+ u8 bound_vif_cnt;
};
/* Extract MVM priv from op_mode and _hw */
@@ -786,6 +786,13 @@ static inline int iwl_mvm_power_update_device_mode(struct iwl_mvm *mvm)
return 0;
}
+static inline void iwl_mvm_power_update_binding(struct iwl_mvm *mvm,
+ struct ieee80211_vif *vif)
+{
+ if (mvm->pm_ops->power_update_binding)
+ mvm->pm_ops->power_update_binding(mvm, vif);
+}
+
void iwl_mvm_power_vif_assoc(struct iwl_mvm *mvm, struct ieee80211_vif *vif);
int iwl_mvm_power_uapsd_misbehaving_ap_notif(struct iwl_mvm *mvm,
struct iwl_rx_cmd_buffer *rxb,