Xiaotian Feng 41bb78b4b9 net dst: fix percpu_counter list corruption and poison overwritten
There're some percpu_counter list corruption and poison overwritten warnings
in recent kernel, which is resulted by fc66f95c.

commit fc66f95c switches to use percpu_counter, in ip6_route_net_init, kernel
init the percpu_counter for dst entries, but, the percpu_counter is never destroyed
in ip6_route_net_exit. So if the related data is freed by kernel, the freed percpu_counter
is still on the list, then if we insert/remove other percpu_counter, list corruption
resulted. Also, if the insert/remove option modifies the ->prev,->next pointer of
the freed value, the poison overwritten is resulted then.

With the following patch, the percpu_counter list corruption and poison overwritten
warnings disappeared.

Signed-off-by: Xiaotian Feng <dfeng@redhat.com>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>
Cc: "Pekka Savola (ipv6)" <pekkas@netcore.fi>
Cc: James Morris <jmorris@namei.org>
Cc: Hideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>
Cc: Patrick McHardy <kaber@trash.net>
Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-03 18:50:07 -07:00
..
2010-10-21 04:26:39 -07:00
2010-10-25 13:09:44 -07:00
2010-10-25 13:09:43 -07:00
2010-10-28 10:27:01 -07:00
2010-09-23 14:33:39 -07:00
2010-09-23 14:33:39 -07:00
2010-10-30 16:21:28 -07:00
2010-10-21 15:44:13 +02:00
2010-06-03 03:21:52 -07:00
2010-09-23 14:33:39 -07:00
2010-04-20 16:37:13 -07:00
2010-11-03 18:50:07 -07:00
2010-08-09 11:25:17 +02:00
2010-10-21 03:09:46 -07:00
2010-10-15 15:53:27 +02:00