873a763
Bugzilla: 1046495
873a763
Upstream-status: Sent for 3.14 http://marc.info/?l=linux-wireless&m=139453882510796&w=2
873a763
873a763
From: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
873a763
873a763
There is a flow in which we send the host command in SYNC
873a763
mode, but we don't take priv->mutex.
873a763
873a763
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1046495
873a763
873a763
Cc: <stable@vger.kernel.org>
873a763
Reviewed-by: Johannes Berg <johannes.berg@intel.com>
873a763
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
873a763
---
873a763
 drivers/net/wireless/iwlwifi/dvm/main.c | 8 ++++++--
873a763
 1 file changed, 6 insertions(+), 2 deletions(-)
873a763
873a763
diff --git a/drivers/net/wireless/iwlwifi/dvm/main.c b/drivers/net/wireless/iwlwifi/dvm/main.c
873a763
index ba1b1ea..ea7e70c 100644
873a763
--- a/drivers/net/wireless/iwlwifi/dvm/main.c
873a763
+++ b/drivers/net/wireless/iwlwifi/dvm/main.c
873a763
@@ -252,13 +252,17 @@ static void iwl_bg_bt_runtime_config(struct work_struct *work)
873a763
 	struct iwl_priv *priv =
873a763
 		container_of(work, struct iwl_priv, bt_runtime_config);
873a763
 
873a763
+	mutex_lock(&priv->mutex);
873a763
 	if (test_bit(STATUS_EXIT_PENDING, &priv->status))
873a763
-		return;
873a763
+		goto out;
873a763
 
873a763
 	/* dont send host command if rf-kill is on */
873a763
 	if (!iwl_is_ready_rf(priv))
873a763
-		return;
873a763
+		goto out;
873a763
+
873a763
 	iwlagn_send_advance_bt_config(priv);
873a763
+out:
873a763
+	mutex_unlock(&priv->mutex);
873a763
 }
873a763
 
873a763
 static void iwl_bg_bt_full_concurrency(struct work_struct *work)
873a763
-- 
873a763
1.8.3.2
873a763
873a763
--
873a763
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
873a763
the body of a message to majordomo@vger.kernel.org
873a763
More majordomo info at  http://vger.kernel.org/majordomo-info.html