From: Johannes Berg <johannes@sipsolutions.net>
To: linux-wireless@vger.kernel.org
Cc: John Linville <linville@tuxdriver.com>
Subject: Re: [PATCH 1/4] create cfg80211
Date: Sun, 11 Feb 2007 20:39:27 +0100 [thread overview]
Message-ID: <1171222767.3576.2.camel@johannes.berg> (raw)
In-Reply-To: <20070209162826.930724000@sipsolutions.net>
[-- Attachment #1: Type: text/plain, Size: 964 bytes --]
On Fri, 2007-02-09 at 17:27 +0100, johannes@sipsolutions.net wrote:
This
> +void wiphy_free(struct wiphy *wiphy)
> +{
> + if (wiphy->wiphy_index != -1)
> + wiphy_sysfs_del(wiphy);
> + else
> + cfg80211_drv_free(wiphy_to_drv(wiphy));
> +}
and this
> +static void wiphy_class_dev_release(struct class_device *cdev)
> +{
> + struct cfg80211_registered_driver *drv = cdev_to_drv(cdev);
> +
> + cfg80211_drv_free(drv);
> +}
needs to be changed. wiphy_free() should wait for
wiphy_class_dev_release (to make sure sysfs is gone) before freeing the
structure (if it has ever been added to sysfs).
I'll respin both patchsets tomorrow. Until then, should you want to test
it and not just review the code, please just comment out the
cfg80211_drv_free(drv) in wiphy_class_dev_release, that'll give you a
memory leak though, but I have to leave and can't write the code
handling it with a completion etc. in under a minute ;)
johannes
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 190 bytes --]
next prev parent reply other threads:[~2007-02-11 19:41 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-02-09 16:27 [PATCH 0/4] cfg80211 johannes
2007-02-09 16:27 ` [PATCH 1/4] create cfg80211 johannes
2007-02-11 19:39 ` Johannes Berg [this message]
2007-02-12 8:12 ` Johannes Berg
2007-02-13 0:15 ` Michael Buesch
2007-02-09 16:27 ` [PATCH 3/4] cfg80211: wext compat code johannes
2007-02-13 15:42 ` Johannes Berg
2007-02-09 16:27 ` [PATCH 4/4] wext: clean up johannes
2007-02-09 16:33 ` [PATCH 0/4] cfg80211 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=1171222767.3576.2.camel@johannes.berg \
--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 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).