From: Johannes Berg <johannes@sipsolutions.net>
To: Helmut Schaa <helmut.schaa@googlemail.com>
Cc: linville@tuxdriver.com, linux-wireless@vger.kernel.org
Subject: Re: [PATCH] mac80211: handle failed scan requests in STA mode
Date: Mon, 09 Mar 2009 15:50:00 +0100 [thread overview]
Message-ID: <1236610200.4205.82.camel@johannes.local> (raw)
In-Reply-To: <200903091547.09223.helmut.schaa@gmail.com> (sfid-20090309_154751_798473_51238D7E)
[-- Attachment #1: Type: text/plain, Size: 1588 bytes --]
On Mon, 2009-03-09 at 15:47 +0100, Helmut Schaa wrote:
> If cfg80211 requests a scan it awaits either a return code != 0 from
> the scan function or the cfg80211_scan_done to be called. In case of
> a STA mac80211's scan function ever returns 0 and queues the scan request.
> If ieee80211_sta_work is executed and ieee80211_start_scan fails for
> some reason cfg80211_scan_done will never be called but cfg80211 still
> thinks the scan was triggered successfully and will refuse any future
> scan requests due to drv->scan_req not being cleaned up.
>
> If a scan is triggered from within the MLME a similar problem appears. If
> ieee80211_start_scan returns an error, local->scan_req will not be reset
> and mac80211 will refuse any future scan requests.
>
> Hence, in both cases call ieee80211_scan_failed (which notifies cfg80211
> and resets local->scan_req) if ieee80211_start_scan returns an error.
This patch looks good.
> Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com>
> ---
>
> It just happend to me that after rf-killing iwlwifi wpa_supplicant triggered
> a scan (which was accepted by mac80211 as it is not rfkill aware yet) which
> failed in iwlwifi and left cfg80211 in a state where it won't accept a new
> scan request even after unkilling the radio again.
>
> Johannes, do you think it is worth to add something like a scan watchdog that
> triggers after 30 seconds to cfg80211 and prints "scan request failed", cancels
> the scan request and notifies user space?
But I don't really think it's worth doing that.
johannes
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2009-03-09 14:50 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-09 14:47 [PATCH] mac80211: handle failed scan requests in STA mode Helmut Schaa
2009-03-09 14:50 ` Johannes Berg [this message]
2009-03-09 15:03 ` Helmut Schaa
2009-03-09 15:07 ` Johannes Berg
2009-03-09 15:17 ` Helmut Schaa
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=1236610200.4205.82.camel@johannes.local \
--to=johannes@sipsolutions.net \
--cc=helmut.schaa@googlemail.com \
--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.