All of lore.kernel.org
 help / color / mirror / Atom feed
From: Emmanuel Grumbach <egrumbach@gmail.com>
To: linux-wireless@vger.kernel.org
Cc: Johannes Berg <johannes.berg@intel.com>,
	Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Subject: [PATCH 09/12] iwlwifi: mvm: BT Coex - always initialize smps_mode
Date: Mon,  8 Sep 2014 19:56:14 +0300	[thread overview]
Message-ID: <1410195377-10075-9-git-send-email-egrumbach@gmail.com> (raw)
In-Reply-To: <540DDF37.5030801@gmail.com>

From: Johannes Berg <johannes.berg@intel.com>

smps_mode is used uninitialized in a debug statement in AP
mode, so always initialize it.

While at it, fix a typo.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Reviewed-by: Luciano Coelho <luciano.coelho@intel.com>
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
---
 drivers/net/wireless/iwlwifi/mvm/coex.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/net/wireless/iwlwifi/mvm/coex.c b/drivers/net/wireless/iwlwifi/mvm/coex.c
index 75178f3..ce71625 100644
--- a/drivers/net/wireless/iwlwifi/mvm/coex.c
+++ b/drivers/net/wireless/iwlwifi/mvm/coex.c
@@ -754,7 +754,8 @@ static void iwl_mvm_bt_notif_iterator(void *_data, u8 *mac,
 	struct iwl_bt_iterator_data *data = _data;
 	struct iwl_mvm *mvm = data->mvm;
 	struct ieee80211_chanctx_conf *chanctx_conf;
-	enum ieee80211_smps_mode smps_mode;
+	/* default smps_mode is AUTOMATIC - only used for client modes */
+	enum ieee80211_smps_mode smps_mode = IEEE80211_SMPS_AUTOMATIC;
 	u32 bt_activity_grading;
 	int ave_rssi;
 
@@ -762,8 +763,6 @@ static void iwl_mvm_bt_notif_iterator(void *_data, u8 *mac,
 
 	switch (vif->type) {
 	case NL80211_IFTYPE_STATION:
-		/* default smps_mode for BSS / P2P client is AUTOMATIC */
-		smps_mode = IEEE80211_SMPS_AUTOMATIC;
 		break;
 	case NL80211_IFTYPE_AP:
 		if (!mvmvif->ap_ibss_active)
@@ -795,7 +794,7 @@ static void iwl_mvm_bt_notif_iterator(void *_data, u8 *mac,
 	else if (bt_activity_grading >= BT_LOW_TRAFFIC)
 		smps_mode = IEEE80211_SMPS_DYNAMIC;
 
-	/* relax SMPS contraints for next association */
+	/* relax SMPS constraints for next association */
 	if (!vif->bss_conf.assoc)
 		smps_mode = IEEE80211_SMPS_AUTOMATIC;
 
-- 
1.9.1


  parent reply	other threads:[~2014-09-08 16:56 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-08 16:54 pull request: iwlwifi 2014-09-08 Emmanuel Grumbach
2014-09-08 16:56 ` [PATCH 01/12] iwlwifi: mvm: enable scheduled scan on newest firmware Emmanuel Grumbach
2014-09-08 16:56 ` [PATCH 02/12] iwlwifi: mvm: BT Coex - remove shadowing variable Emmanuel Grumbach
2014-09-08 16:56 ` [PATCH 03/12] iwlwifi: mvm: set MAC_FILTER_IN_BEACON correctly for STA/P2P client Emmanuel Grumbach
2014-09-08 16:56 ` [PATCH 04/12] iwlwifi: mvm: fix endianity issues with Smart Fifo commands Emmanuel Grumbach
2014-09-08 16:56 ` [PATCH 05/12] iwlwifi: increase DEFAULT_MAX_TX_POWER Emmanuel Grumbach
2014-09-08 16:56 ` [PATCH 06/12] iwlwifi: mvm: correctly handle PM/QoS changes from mac80211 Emmanuel Grumbach
2014-09-08 16:56 ` [PATCH 07/12] iwlwifi: mvm: treat EAPOLs like mgmt frames wrt rate Emmanuel Grumbach
2014-09-08 16:56 ` [PATCH 08/12] iwlwiwi: mvm: use bss_conf->dtim_period instead of conf.ps_dtim_period Emmanuel Grumbach
2014-09-08 16:56 ` Emmanuel Grumbach [this message]
2014-09-08 16:56 ` [PATCH 10/12] iwlwifi: dvm: disable power save by default Emmanuel Grumbach
2014-09-08 16:56 ` [PATCH 11/12] iwlwifi: add PCI IDs and add then new 3165 series Emmanuel Grumbach
2014-09-08 16:56 ` [PATCH 12/12] iwlwifi: mvm: fix an overflow in iwl_mvm_get_signal_strength Emmanuel Grumbach
2014-09-09 19:01 ` pull request: iwlwifi 2014-09-08 John W. Linville
2014-09-15  5:07 pull request: iwlwifi-next 2014-09-15 Emmanuel Grumbach
2014-09-15  5:10 ` [PATCH 09/12] iwlwifi: mvm: BT Coex - always initialize smps_mode Emmanuel Grumbach

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1410195377-10075-9-git-send-email-egrumbach@gmail.com \
    --to=egrumbach@gmail.com \
    --cc=emmanuel.grumbach@intel.com \
    --cc=johannes.berg@intel.com \
    --cc=linux-wireless@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.