* [patch 0/1] ipv6 POSTDAD fix
@ 2010-10-25 9:06 Ursula Braun
2010-10-25 9:06 ` [patch 1/1] [PATCH BUG_FIX] ipv6: fix refcnt problem related to POSTDAD state Ursula Braun
0 siblings, 1 reply; 4+ messages in thread
From: Ursula Braun @ 2010-10-25 9:06 UTC (permalink / raw)
To: netdev, linux-s390; +Cc: vosburgh
Dave,
running into a refcnt problem with a bond device,
I propose this patch to solve it.
Regards, Ursula
^ permalink raw reply [flat|nested] 4+ messages in thread
* [patch 1/1] [PATCH BUG_FIX] ipv6: fix refcnt problem related to POSTDAD state
2010-10-25 9:06 [patch 0/1] ipv6 POSTDAD fix Ursula Braun
@ 2010-10-25 9:06 ` Ursula Braun
2010-10-25 23:01 ` Herbert Xu
0 siblings, 1 reply; 4+ messages in thread
From: Ursula Braun @ 2010-10-25 9:06 UTC (permalink / raw)
To: netdev, linux-s390; +Cc: vosburgh, Ursula Braun, David S. Miller, Herbert Xu
[-- Attachment #1: addrconf.patch --]
[-- Type: text/plain, Size: 1281 bytes --]
Subject: [patch 1/1] [PATCH BUG_FIX] ipv6: fix refcnt problem related to POSTDAD state
From: Ursula Braun <ursula.braun@de.ibm.com>
After running this bonding setup script
modprobe bonding miimon=100 mode=0 max_bonds=1
ifconfig bond0 10.1.1.1/16
ifenslave bond0 eth1
ifenslave bond0 eth3
on s390 with qeth-driven slaves, modprobe -r fails with this message
unregister_netdevice: waiting for bond0 to become free. Usage count = 1
due to twice detection of duplicate address.
Problem is caused by a missing decrease of ifp->refcnt in addrconf_dad_failure.
An extra call of in6_ifa_put(ifp) solves it.
Problem has been introduced with commit f2344a131bccdbfc5338e17fa71a807dee7944fa.
Signed-off-by: Ursula Braun <ursula.braun@de.ibm.com>
Cc: David S. Miller <davem@davemloft.net>
Cc: Herbert Xu <herbert@gondor.apana.org.au>
---
net/ipv6/addrconf.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -1426,8 +1426,10 @@ void addrconf_dad_failure(struct inet6_i
{
struct inet6_dev *idev = ifp->idev;
- if (addrconf_dad_end(ifp))
+ if (addrconf_dad_end(ifp)) {
+ in6_ifa_put(ifp);
return;
+ }
if (net_ratelimit())
printk(KERN_INFO "%s: IPv6 duplicate address %pI6c detected!\n",
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [patch 1/1] [PATCH BUG_FIX] ipv6: fix refcnt problem related to POSTDAD state
2010-10-25 9:06 ` [patch 1/1] [PATCH BUG_FIX] ipv6: fix refcnt problem related to POSTDAD state Ursula Braun
@ 2010-10-25 23:01 ` Herbert Xu
2010-10-27 18:10 ` David Miller
0 siblings, 1 reply; 4+ messages in thread
From: Herbert Xu @ 2010-10-25 23:01 UTC (permalink / raw)
To: Ursula Braun; +Cc: netdev, linux-s390, vosburgh, David S. Miller
On Mon, Oct 25, 2010 at 11:06:43AM +0200, Ursula Braun wrote:
> Subject: [patch 1/1] [PATCH BUG_FIX] ipv6: fix refcnt problem related to POSTDAD state
>
> From: Ursula Braun <ursula.braun@de.ibm.com>
>
> After running this bonding setup script
> modprobe bonding miimon=100 mode=0 max_bonds=1
> ifconfig bond0 10.1.1.1/16
> ifenslave bond0 eth1
> ifenslave bond0 eth3
> on s390 with qeth-driven slaves, modprobe -r fails with this message
> unregister_netdevice: waiting for bond0 to become free. Usage count = 1
> due to twice detection of duplicate address.
> Problem is caused by a missing decrease of ifp->refcnt in addrconf_dad_failure.
> An extra call of in6_ifa_put(ifp) solves it.
> Problem has been introduced with commit f2344a131bccdbfc5338e17fa71a807dee7944fa.
>
> Signed-off-by: Ursula Braun <ursula.braun@de.ibm.com>
> Cc: David S. Miller <davem@davemloft.net>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Thanks for catching this!
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [patch 1/1] [PATCH BUG_FIX] ipv6: fix refcnt problem related to POSTDAD state
2010-10-25 23:01 ` Herbert Xu
@ 2010-10-27 18:10 ` David Miller
0 siblings, 0 replies; 4+ messages in thread
From: David Miller @ 2010-10-27 18:10 UTC (permalink / raw)
To: herbert; +Cc: ursula.braun, netdev, linux-s390, vosburgh
From: Herbert Xu <herbert@gondor.apana.org.au>
Date: Mon, 25 Oct 2010 16:01:32 -0700
> On Mon, Oct 25, 2010 at 11:06:43AM +0200, Ursula Braun wrote:
>> Subject: [patch 1/1] [PATCH BUG_FIX] ipv6: fix refcnt problem related to POSTDAD state
>>
>> From: Ursula Braun <ursula.braun@de.ibm.com>
>>
>> After running this bonding setup script
>> modprobe bonding miimon=100 mode=0 max_bonds=1
>> ifconfig bond0 10.1.1.1/16
>> ifenslave bond0 eth1
>> ifenslave bond0 eth3
>> on s390 with qeth-driven slaves, modprobe -r fails with this message
>> unregister_netdevice: waiting for bond0 to become free. Usage count = 1
>> due to twice detection of duplicate address.
>> Problem is caused by a missing decrease of ifp->refcnt in addrconf_dad_failure.
>> An extra call of in6_ifa_put(ifp) solves it.
>> Problem has been introduced with commit f2344a131bccdbfc5338e17fa71a807dee7944fa.
>>
>> Signed-off-by: Ursula Braun <ursula.braun@de.ibm.com>
>> Cc: David S. Miller <davem@davemloft.net>
>
> Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
>
> Thanks for catching this!
Applied, thanks everyone.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-10-27 18:09 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-25 9:06 [patch 0/1] ipv6 POSTDAD fix Ursula Braun
2010-10-25 9:06 ` [patch 1/1] [PATCH BUG_FIX] ipv6: fix refcnt problem related to POSTDAD state Ursula Braun
2010-10-25 23:01 ` Herbert Xu
2010-10-27 18:10 ` David Miller
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).