From: Johannes Berg <johannes@sipsolutions.net>
To: Vasanthakumar Thiagarajan <vasanth@atheros.com>
Cc: linville@tuxdriver.com, linux-wireless@vger.kernel.org
Subject: Re: [PATCH 1/2] mac80211: Dont allow to wake up netif tx queues while on off channel
Date: Wed, 30 Jun 2010 12:17:06 +0200 [thread overview]
Message-ID: <1277893026.7823.7.camel@jlt3.sipsolutions.net> (raw)
In-Reply-To: <1277892907-2401-1-git-send-email-vasanth@atheros.com>
On Wed, 2010-06-30 at 03:15 -0700, Vasanthakumar Thiagarajan wrote:
> Drivers are not supposed to call ieee80211_wake_queue() while operating
> on off channel during sw scanning, but there is no clear way for
> the driver to know that it is operating on off channel during scanning.
> There are cases (unavailablity/availability of tx buffers in ath9k, for
> example) where driver needs to stop/restart tx queues during background
> scanning state, this might result in waking up the corresponding netif
> tx queue when the device is on off channel which is not desired. This
> patches fixes this by checking SCAN_OFF_CHANNEL bit in scanning before
> restarting the tx queue.
>
> Signed-off-by: Vasanthakumar Thiagarajan <vasanth@atheros.com>
> ---
> net/mac80211/util.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/net/mac80211/util.c b/net/mac80211/util.c
> index a54cf14..1938a67 100644
> --- a/net/mac80211/util.c
> +++ b/net/mac80211/util.c
> @@ -277,7 +277,8 @@ static void __ieee80211_wake_queue(struct ieee80211_hw *hw, int queue,
>
> __clear_bit(reason, &local->queue_stop_reasons[queue]);
>
> - if (local->queue_stop_reasons[queue] != 0)
> + if ((local->queue_stop_reasons[queue] != 0) ||
> + test_bit(SCAN_OFF_CHANNEL, &local->scanning))
> /* someone still has this queue stopped */
> return;
That doesn't seem to make sense, since we treat driver and scan stop
status separately via wake_queue_by_reason()
johannes
next prev parent reply other threads:[~2010-06-30 10:17 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-30 10:15 [PATCH 1/2] mac80211: Dont allow to wake up netif tx queues while on off channel Vasanthakumar Thiagarajan
2010-06-30 10:17 ` Johannes Berg [this message]
2010-06-30 10:26 ` Johannes Berg
2010-06-30 10:51 ` Vasanthakumar Thiagarajan
2010-06-30 10:57 ` Vasanthakumar Thiagarajan
2010-06-30 10:47 ` Vasanthakumar Thiagarajan
2010-07-01 9:34 ` Vasanthakumar Thiagarajan
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=1277893026.7823.7.camel@jlt3.sipsolutions.net \
--to=johannes@sipsolutions.net \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=vasanth@atheros.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).