netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dan Williams <dcbw@redhat.com>
To: Daniel Drake <dsd@gentoo.org>
Cc: jt@hpl.hp.com, softmac-dev@sipsolutions.net, netdev@vger.kernel.org
Subject: Re: SIOCGIWSCAN wireless event behaviour
Date: Thu, 20 Apr 2006 10:37:32 -0400	[thread overview]
Message-ID: <1145543852.2654.11.camel@localhost.localdomain> (raw)
In-Reply-To: <4447979F.4050603@gentoo.org>

On Thu, 2006-04-20 at 15:15 +0100, Daniel Drake wrote:
> Hi Jean,
> 
> A query regarding wireless events: under which circumstances should a 
> driver/stack send a SIOCGIWSCAN event to userspace?
> 
> Should it be sent whenever a driver has new scan results available, or 
> only when the user requested a scan a short time beforehand (via 
> SIOCSIWSCAN)?

Similar situation:  when wpa_supplicant requests a scan, the driver
scans and pushes the GIWSCAN at completion.  _Every_ process (like
NetworkManager) listening for netlink WE messages gets the GIWSCAN event
even though only wpa_supplicant requested the original scan.

So what I'm saying is that applications that process GIWSCAN netlink
messages today should _already_ be able to handle random GIWSCAN events
at any time even when they have not explicitly requested a scan with
SIWSCAN.  The events are broadcast and the driver shouldn't really care
which user app initiated any particular request.  Multiple apps can
theoretically request scans at any time, though this isn't so good in
practice.

> I ask this because softmac is sending the SIOCGIWSCAN event even when 
> the user did not explicitly ask for it.

Given the above, I think this behavior is fine and even desirable.

> I think the 'extra' SIOCGIWSCAN event may be confusing wpa_supplicant 
> (but have not confirmed that yet).

If this is the case, wpa_supplicant should not be getting confused by
GIWSCAN events happening at random times, and should be fixed.  However,
in my experience with 0.4.8, this isn't a problem and wpa_supplicant
handles random scan events correctly.  Not sure about the 0.5.x branch
though.

Dan



  reply	other threads:[~2006-04-20 14:41 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-04-20 14:15 SIOCGIWSCAN wireless event behaviour Daniel Drake
2006-04-20 14:37 ` Dan Williams [this message]
2006-04-20 16:43   ` Jean Tourrilhes
2006-04-20 17:26     ` Jouni Malinen
2006-04-21  1:42     ` Daniel Drake
2006-04-20 16:39 ` Jouni Malinen

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=1145543852.2654.11.camel@localhost.localdomain \
    --to=dcbw@redhat.com \
    --cc=dsd@gentoo.org \
    --cc=jt@hpl.hp.com \
    --cc=netdev@vger.kernel.org \
    --cc=softmac-dev@sipsolutions.net \
    /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).