From: Johannes Berg <johannes@sipsolutions.net>
To: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Maxim Levitsky <maximlevitsky@gmail.com>,
linux-wireless <linux-wireless@vger.kernel.org>
Subject: Re: commit #1868cf308a3b3a336fcfe52c5aea4ac12d5e42ac breaks wireless on my system
Date: Sat, 30 May 2009 23:04:31 +0200 [thread overview]
Message-ID: <1243717471.19302.1.camel@johannes.local> (raw)
In-Reply-To: <4A219E78.5070009@lwfinger.net>
[-- Attachment #1: Type: text/plain, Size: 1425 bytes --]
On Sat, 2009-05-30 at 16:00 -0500, Larry Finger wrote:
> From the above patch, this hunk looks a little strange:
>
> diff --git a/net/mac80211/wext.c b/net/mac80211/wext.c
> index c143947..a01154e 100644
> --- a/net/mac80211/wext.c
> +++ b/net/mac80211/wext.c
> @@ -37,12 +37,13 @@ static int ieee80211_ioctl_siwgenie(struct
> net_device *dev,
>
> if (sdata->vif.type == NL80211_IFTYPE_STATION) {
> int ret = ieee80211_sta_set_extra_ie(sdata, extra, data->length);
> - if (ret)
> + if (ret && ret != -EALREADY)
> return ret;
> sdata->u.mgd.flags &= ~IEEE80211_STA_AUTO_BSSID_SEL;
> sdata->u.mgd.flags &= ~IEEE80211_STA_EXT_SME;
> sdata->u.mgd.flags &= ~IEEE80211_STA_CONTROL_PORT;
> - ieee80211_sta_req_auth(sdata);
> + if (ret != -EALREADY)
> + ieee80211_sta_req_auth(sdata);
> return 0;
> }
>
> Why is there a check before the call to ieee80211_sta_req_auth()? If
> ret != -EALREADY, would we not have already exited?
No, it's && deliberately, I don't want to show -EALREADY to userspace,
but I _do_ want to skip the req_auth() step, that's the whole purpose of
the patch. Problem is I forgot to change the cfg80211 handlers
accordingly and that created a problem Luis fixed.
johannes
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 801 bytes --]
prev parent reply other threads:[~2009-05-30 21:04 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-05-30 20:47 commit #1868cf308a3b3a336fcfe52c5aea4ac12d5e42ac breaks wireless on my system Maxim Levitsky
2009-05-30 20:49 ` Johannes Berg
2009-05-30 20:59 ` Maxim Levitsky
2009-05-30 22:37 ` Maxim Levitsky
2009-05-31 10:11 ` Johannes Berg
2009-05-31 12:03 ` Maxim Levitsky
2009-05-31 12:41 ` Maxim Levitsky
2009-06-01 7:29 ` Kalle Valo
2009-05-30 21:00 ` Larry Finger
2009-05-30 21:04 ` Johannes Berg [this message]
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=1243717471.19302.1.camel@johannes.local \
--to=johannes@sipsolutions.net \
--cc=Larry.Finger@lwfinger.net \
--cc=linux-wireless@vger.kernel.org \
--cc=maximlevitsky@gmail.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