From: Bruno Randolf <br1@einfach.org>
To: linville@tuxdriver.com
Cc: ath5k-devel@lists.ath5k.org, linux-wireless@vger.kernel.org
Subject: [PATCH] ath5k: disable all tasklets while resetting
Date: Fri, 11 Jun 2010 19:12:21 +0900 [thread overview]
Message-ID: <20100611101221.26538.46913.stgit@tt-desk> (raw)
Make sure no tasklets can run concurrently to a reset.
Signed-off-by: Bruno Randolf <br1@einfach.org>
---
drivers/net/wireless/ath/ath5k/base.c | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/drivers/net/wireless/ath/ath5k/base.c b/drivers/net/wireless/ath/ath5k/base.c
index 9d37c1a..585c517 100644
--- a/drivers/net/wireless/ath/ath5k/base.c
+++ b/drivers/net/wireless/ath/ath5k/base.c
@@ -2908,6 +2908,12 @@ ath5k_reset(struct ath5k_softc *sc, struct ieee80211_channel *chan)
ATH5K_DBG(sc, ATH5K_DEBUG_RESET, "resetting\n");
+ tasklet_disable(&sc->rxtq); /* ath5k_tasklet_rx */
+ tasklet_disable(&sc->txtq); /* ath5k_tasklet_tx */
+ tasklet_disable(&sc->calib); /* ath5k_tasklet_calibrate */
+ tasklet_disable(&sc->beacontq); /* ath5k_tasklet_beacon */
+ tasklet_disable(&sc->ani_tasklet); /* ath5k_tasklet_ani */
+
if (chan) {
ath5k_hw_set_imr(ah, 0);
ath5k_txq_cleanup(sc);
@@ -2948,6 +2954,12 @@ ath5k_reset(struct ath5k_softc *sc, struct ieee80211_channel *chan)
ath5k_beacon_config(sc);
/* intrs are enabled by ath5k_beacon_config */
+ tasklet_enable(&sc->rxtq); /* ath5k_tasklet_rx */
+ tasklet_enable(&sc->txtq); /* ath5k_tasklet_tx */
+ tasklet_enable(&sc->calib); /* ath5k_tasklet_calibrate */
+ tasklet_enable(&sc->beacontq); /* ath5k_tasklet_beacon */
+ tasklet_enable(&sc->ani_tasklet); /* ath5k_tasklet_ani */
+
ieee80211_wake_queues(sc->hw);
return 0;
next reply other threads:[~2010-06-11 10:12 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-11 10:12 Bruno Randolf [this message]
2010-06-11 10:41 ` [PATCH] ath5k: disable all tasklets while resetting Johannes Berg
2010-06-11 14:21 ` [ath5k-devel] " Bob Copeland
2010-06-11 14:38 ` Bob Copeland
2010-06-14 1:50 ` Bruno Randolf
2010-06-14 11:43 ` Bob Copeland
2010-06-15 1:07 ` Bruno Randolf
2010-06-15 4:10 ` Bob Copeland
2010-06-15 4:54 ` Bruno Randolf
2010-06-15 11:21 ` Bob Copeland
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=20100611101221.26538.46913.stgit@tt-desk \
--to=br1@einfach.org \
--cc=ath5k-devel@lists.ath5k.org \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.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.