All of lore.kernel.org
 help / color / mirror / Atom feed
From: Seth Forshee <seth.forshee@canonical.com>
To: Johannes Berg <johannes@sipsolutions.net>
Cc: linux-wireless@vger.kernel.org, Stanislaw Gruszka <sgruszka@redhat.com>
Subject: Re: [PATCH v3 1/2] mac80211: Fix tx queue handling during scans
Date: Fri, 8 Feb 2013 11:11:55 -0600	[thread overview]
Message-ID: <20130208171155.GC2622@thinkpad-t410> (raw)
In-Reply-To: <1360314212.29851.4.camel@jlt4.sipsolutions.net>

On Fri, Feb 08, 2013 at 10:03:32AM +0100, Johannes Berg wrote:
> On Thu, 2013-02-07 at 11:54 -0600, Seth Forshee wrote:
> > Scans currently work by stopping the netdev tx queues but leaving the
> > mac80211 queues active. This stops the flow of incoming packets while
> > still allowing mac80211 to transmit nullfunc and probe request frames to
> > facilitate scanning. However, the driver may try to wake the mac80211
> > queues while in this state, which will also wake the netdev queues.
> > 
> > To prevent this, add a new queue stop reason,
> > IEEE80211_QUEUE_STOP_REASON_OFFCHANNEL, to be used when stopping the tx
> > queues for off-channel operation. This prevents the netdev queues from
> > waking when a driver wakes the mac80211 queues.
> > 
> > This also stops all frames from being transmitted, even those required
> > for scanning. To get around this, add a new offchan_tx_ok argument to
> > most of the tx interfaces. This flag can be set for frames which need to
> > be transmitted during off-channel operation, allowing off-channel frames
> > to be passed down to the driver if the queues have only been stopped for
> > off-channel. Add ieee80211_tx_skb_offchannel() for transmitting
> > off-channel frames with this flag set.
> 
> I started wondering -- is there a reason to modify the entire TX path?
> Could we maybe bypass it instead and call the driver's TX op almost
> directly? The frames in question don't really need much TX handling, the
> only thing that might be relevant _could_ be rate control but even that
> I'd argue isn't really needed, just using rate_control_send_low() should
> be ok (by setting IEEE80211_TX_CTL_USE_MINRATE it will always return
> true). For the null data packets the sta pointer is also obvious, the AP
> station (BSSID) ... we don't need any of the extra monitor/whatever
> handling either.
> 
> That might be simpler overall?

Okay, I'll take a look at this.

Another option that might simplify things a bit  would be to use a
ieee80211_tx_data flag. If I added another interface into tx.c for
offchannel frames then the offchan argument would only be needed for
ieee80211_xmit() and ieee80211_tx(). Though it would be nice to avoid
adding an argument to ieee80211_xmit().

Seth


  reply	other threads:[~2013-02-08 17:12 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-06 15:01 [PATCH 0/4] Improve queue handling for off-channel operation Seth Forshee
2013-02-06 15:01 ` [PATCH 1/4] mac80211: Return a status for tx operations Seth Forshee
2013-02-06 15:01 ` [PATCH 2/4] mac80211: Fix tx queue handling during scans Seth Forshee
2013-02-06 15:01 ` [PATCH 3/4] mac80211: Improve error handling for off-channel operation Seth Forshee
2013-02-06 21:44   ` Johannes Berg
2013-02-06 22:05     ` Seth Forshee
2013-02-06 22:10       ` Johannes Berg
2013-02-06 22:20         ` Seth Forshee
2013-02-06 22:26           ` Johannes Berg
2013-02-06 22:30             ` Johannes Berg
2013-02-07 17:54               ` [PATCH v3 1/2] mac80211: Fix tx queue handling during scans Seth Forshee
2013-02-07 17:54                 ` [PATCH v3 2/2] mac80211: Add flushes before going off-channel Seth Forshee
2013-02-08  9:03                 ` [PATCH v3 1/2] mac80211: Fix tx queue handling during scans Johannes Berg
2013-02-08 17:11                   ` Seth Forshee [this message]
2013-02-08 17:17                     ` Johannes Berg
2013-02-08 18:10                       ` Seth Forshee
2013-02-08 19:05                         ` Johannes Berg
2013-02-08 20:46                           ` Seth Forshee
2013-02-08 20:53                             ` Johannes Berg
2013-02-11 17:18                               ` Seth Forshee
2013-02-11 17:21                                 ` [PATCH v4 " Seth Forshee
2013-02-11 17:21                                   ` [PATCH v4 2/2] mac80211: Add flushes before going off-channel Seth Forshee
2013-02-11 21:40                                   ` [PATCH v4 1/2] mac80211: Fix tx queue handling during scans Johannes Berg
2013-02-11 21:50                                     ` Seth Forshee
2013-02-06 15:01 ` [PATCH 4/4] mac80211: Add flushes before going off-channel Seth Forshee

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=20130208171155.GC2622@thinkpad-t410 \
    --to=seth.forshee@canonical.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=sgruszka@redhat.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.