From: Johannes Berg <johannes@sipsolutions.net>
To: John Linville <linville@tuxdriver.com>
Cc: linux-wireless <linux-wireless@vger.kernel.org>
Subject: Re: pull-request: mac80211-next 2012-07-10
Date: Thu, 12 Jul 2012 11:56:40 +0200 [thread overview]
Message-ID: <1342087000.4531.11.camel@jlt3.sipsolutions.net> (raw)
In-Reply-To: <1342085261.4531.9.camel@jlt3.sipsolutions.net> (sfid-20120712_112748_417680_83E2626B)
On Thu, 2012-07-12 at 11:27 +0200, Johannes Berg wrote:
> On Tue, 2012-07-10 at 20:48 +0200, Johannes Berg wrote:
> > John,
> >
> > Please pull some more patches. I've included the first round of API
> > additions/updates for the P2P Device abstraction, I don't know if we'll
> > get the actual code done in time for 3.6 but I didn't want to hang on to
> > these APIs for too long to avoid conflicts.
>
> Ugh, I found a bug with this, please drop, I'll respin. Sorry!
Ok the bug is this -- if we remove a wdev (that doesn't have a netdev),
this change is obviously needed:
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 27cd18e..70452aa 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -6768,6 +6768,7 @@ static int nl80211_pre_doit(struct genl_ops *ops, struct sk_buff *skb,
info->user_ptr[1] = dev;
} else {
info->user_ptr[1] = wdev;
+ info->user_ptr[2] = wdev->netdev;
}
if (dev) {
@@ -6799,10 +6800,8 @@ static void nl80211_post_doit(struct genl_ops *ops, struct sk_buff *skb,
cfg80211_unlock_rdev(info->user_ptr[0]);
if (info->user_ptr[1]) {
if (ops->internal_flags & NL80211_FLAG_NEED_WDEV) {
- struct wireless_dev *wdev = info->user_ptr[1];
-
- if (wdev->netdev)
- dev_put(wdev->netdev);
+ if (info->user_ptr[2])
+ dev_put(info->user_ptr[2]);
} else {
dev_put(info->user_ptr[1]);
}
I've rolled it into the patch that introduced the bug ("nl80211: add
NL80211_FLAG_NEED_WDEV") and will send a new pull request. Obviously,
I'm therefore rebasing my tree.
Sorry for the inconvenience!
johannes
next prev parent reply other threads:[~2012-07-12 9:56 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-10 18:48 pull-request: mac80211-next 2012-07-10 Johannes Berg
2012-07-12 9:27 ` Johannes Berg
2012-07-12 9:56 ` Johannes Berg [this message]
2012-07-12 10:00 ` Johannes Berg
2012-07-12 10:08 ` Johannes Berg
2012-07-12 10:15 ` pull-request: mac80211-next 2012-07-12 Johannes Berg
2012-07-12 12:41 ` Johannes Berg
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=1342087000.4531.11.camel@jlt3.sipsolutions.net \
--to=johannes@sipsolutions.net \
--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.