From: David Miller <davem@davemloft.net>
To: eric.dumazet@gmail.com
Cc: nicolas.dichtel@6wind.com, netdev@vger.kernel.org
Subject: Re: [RFC PATCH] ipv4: release dev refcnt early when destroying inetdev
Date: Tue, 14 Sep 2010 13:45:29 -0700 (PDT) [thread overview]
Message-ID: <20100914.134529.45905377.davem@davemloft.net> (raw)
In-Reply-To: <1284131774.24675.46.camel@edumazet-laptop>
From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Fri, 10 Sep 2010 17:16:14 +0200
> Le vendredi 10 septembre 2010 à 16:57 +0200, Nicolas Dichtel a écrit :
>
>> Is this not true in IPv6? What is the difference?
>
> It might be a bug on ipv6, who knows ?
>
> Releasing a reference count, but not setting idev->dev to NULL is
> a sign something is wrong...
If anything this is more of a BUG trap than a true correctness patch,
but either way if you want me to apply this please formally submit
this with a proper commit message and signoff, thanks!
> diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
> index 5bc893e..26e39bc 100644
> --- a/net/ipv6/addrconf.c
> +++ b/net/ipv6/addrconf.c
> @@ -330,6 +330,7 @@ void in6_dev_finish_destroy(struct inet6_dev *idev)
> printk(KERN_DEBUG "in6_dev_finish_destroy: %s\n", dev ? dev->name : "NIL");
> #endif
> dev_put(dev);
> + idev->dev = NULL;
> if (!idev->dead) {
> pr_warning("Freeing alive inet6 device %p\n", idev);
> return;
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2010-09-14 20:45 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-09-10 13:35 [RFC PATCH] ipv4: release dev refcnt early when destroying inetdev Nicolas Dichtel
2010-09-10 14:24 ` Eric Dumazet
2010-09-10 14:57 ` Nicolas Dichtel
2010-09-10 15:16 ` Eric Dumazet
2010-09-14 20:45 ` David Miller [this message]
2010-09-15 6:01 ` Eric Dumazet
2010-09-13 22:24 ` [PATCH] net: use rcu_barrier() in rollback_registered_many Eric Dumazet
2010-09-14 21:27 ` David Miller
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=20100914.134529.45905377.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=eric.dumazet@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=nicolas.dichtel@6wind.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).