This is the key to the problem. It took me a while to find the cause of this. Along the way I found a few other ref counting bugs in this area as well. All of these bugs stem from the idev reference
... ... ... I agree with your analysis, however... this change is not sufficient. You have to then walk over all the uses of rt6i_dev and sanitize the cases that still expect the split semantics. For
You're right of course. I thought they were all harmless but I was obviously wrong about this one. So here is a patch that essentially reverts the split devices semantics introduced by these two chan
Ok. But Herbert, let's take a step back real quick because I want to point something out. IPv6 does try to handle the dangling mismatched idev's, in route.c:ip6_dst_ifdown(), this is called via net/c
This doesn't work because net/core/dst.c can only search based on dst->dev. For the split device case, dst->dev is set to loopback_dev while rt6i_idev is set to the real device. Therefore net/core/ds
Although I still think this is a bug, I'm now starting to suspect that there is another bug around as well. There is probably an ifp leak which in turn leads to a split dst leak that allows the first
Herbert Xu wrote: On Fri, Feb 04, 2005 at 09:38:13PM -0800, David S. Miller wrote: It is just the first such thing I found, scanning rt6i_idev uses will easily find several others. You're right of co
Please tell me, why your lo is down... Anyway, if we really want to "fix" this, we should do in other way. I think "Make loopback idev stick around" patches (for IPv4 and IPv6) could be start of that
YOSHIFUJI Hideaki / wrote: In article <4204AA7C.9010509@xxxxxxxx> (at Sat, 05 Feb 2005 12:14:04 +0100), Andre Tomt <andre@xxxxxxxx> says: This patch fixes my problems with hangs when dot1q VLAN
Unfortunately that patch can't fix this particular problem. This problem will show up whenever there is a dst on the GC list that has split devices and a non-zero refcnt. So if you had a process hold
OK. Is there any reason why IPv4 should be different from IPv6 in this respect though? If the split device dst's are to be kept, we'll need a way to clean them up. There are two choices: 1) Put the d
Indeed. I didn't catch that. Ok, so this would entail changing each ipv6 dst_free() call into one to ip6_dst_free(), which would: ip6_garbage_add(dst); dst_free(dst); It would mean that dst_run_gc()
How about making dst->ops->dev_check() like this: static int inline dst_dev_check(struct dst_entry *dst, struct net_device *dev) { if (dst->ops->dev_check) return dst->ops->dev_check(dst, dev) else r
I'm not sure it is explicitly specified, but there're some hints: 1. we need to allow multiple addresses on multiple interfaces. e.g. link-local address 2. if a packet has come from A to link-local a
Well... Here, lo is going down. I think we already see dst->dev == dev (==lo) now. So, I doubt that fix the problem. The source of problem is entry (*) which still on routing entry, not on gc list. A
Which means in addrconf_notiry(), if the dev == &loopback_dev, call addrconf_ifdown for every device like this: Signed-off-by: Hideaki YOSHIFUJI <yoshfuji@xxxxxxxxxxxxxx> == net/ipv6/addrconf.c 1.129