All of lore.kernel.org
 help / color / mirror / Atom feed
From: Maya Erez <qca_merez@qca.qualcomm.com>
To: Kalle Valo <kvalo@codeaurora.org>
Cc: Hamad Kadmany <QCA_hkadmany@QCA.qualcomm.com>,
	linux-wireless@vger.kernel.org, wil6210@qca.qualcomm.com,
	Maya Erez <qca_merez@qca.qualcomm.com>
Subject: [PATCH v2 04/12] wil6210: abort properly in cfg suspend
Date: Wed,  1 Nov 2017 21:23:14 +0200	[thread overview]
Message-ID: <1509564202-30078-5-git-send-email-qca_merez@qca.qualcomm.com> (raw)
In-Reply-To: <1509564202-30078-1-git-send-email-qca_merez@qca.qualcomm.com>

From: Hamad Kadmany <qca_hkadmany@qca.qualcomm.com>

On-going operations were not aborted properly
and required locks were not taken.

Signed-off-by: Hamad Kadmany <qca_hkadmany@qca.qualcomm.com>
Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com>
---
 drivers/net/wireless/ath/wil6210/cfg80211.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/ath/wil6210/cfg80211.c b/drivers/net/wireless/ath/wil6210/cfg80211.c
index 85d5c04..c3d3c0c 100644
--- a/drivers/net/wireless/ath/wil6210/cfg80211.c
+++ b/drivers/net/wireless/ath/wil6210/cfg80211.c
@@ -1727,9 +1727,12 @@ static int wil_cfg80211_suspend(struct wiphy *wiphy,
 
 	wil_dbg_pm(wil, "suspending\n");
 
-	wil_p2p_stop_discovery(wil);
-
+	mutex_lock(&wil->mutex);
+	mutex_lock(&wil->p2p_wdev_mutex);
+	wil_p2p_stop_radio_operations(wil);
 	wil_abort_scan(wil, true);
+	mutex_unlock(&wil->p2p_wdev_mutex);
+	mutex_unlock(&wil->mutex);
 
 out:
 	return rc;
-- 
1.9.1

  parent reply	other threads:[~2017-11-01 19:23 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-01 19:23 [PATCH v2 00/12] wil6210 patches Maya Erez
2017-11-01 19:23 ` [PATCH v2 01/12] wil6210: run-time PM when interface down Maya Erez
2017-11-01 19:23 ` [PATCH v2 02/12] wil6210: print human readable names of WMI commands and events Maya Erez
2017-11-01 19:23 ` [PATCH v2 03/12] wil6210: refresh FW capabilities during interface up Maya Erez
2017-11-01 19:23 ` Maya Erez [this message]
2017-11-01 19:23 ` [PATCH v2 05/12] wil6210: fix length check in __wmi_send Maya Erez
2017-11-01 19:23 ` [PATCH v2 06/12] wil6210: add block size checks during FW load Maya Erez
2017-11-01 19:23 ` [PATCH v2 07/12] wil6210: missing length check in wmi_set_ie Maya Erez
2017-11-01 19:23 ` [PATCH v2 08/12] wil6210: missing length check in wil_cfg80211_mgmt_tx Maya Erez
2017-11-01 19:23 ` [PATCH v2 09/12] wil6210: get suspend reject reason and resume triggers from FW Maya Erez
2017-11-01 19:23 ` [PATCH v2 10/12] wil6210: fix PCIe bus mastering in case of interface down Maya Erez
2017-11-01 19:23 ` [PATCH v2 11/12] wil6210: remove suspend time statistics Maya Erez
2017-11-01 19:23 ` [PATCH v2 12/12] wil6210: update statistics for suspend Maya Erez

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=1509564202-30078-5-git-send-email-qca_merez@qca.qualcomm.com \
    --to=qca_merez@qca.qualcomm.com \
    --cc=QCA_hkadmany@QCA.qualcomm.com \
    --cc=kvalo@codeaurora.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=wil6210@qca.qualcomm.com \
    /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.