ipv6: fix icmpv6_cleanup/icmpv6_init section mismatch
Subsystems (3)
icmpv6_cleanup() is called from inet6_init() which is __init, so the former can't be __exit.
---
net/ipv6/icmp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
net/ipv6/icmp.c +1 -1
@@ -868,7 +868,7 @@ fail:return err; } -void __exit icmpv6_cleanup(void) +void icmpv6_cleanup (void ) {unregister_pernet_subsys (&icmpv6_sk_ops);inet6_del_protocol (&icmpv6_protocol,IPPROTO_ICMPV6 );
PATCH v2 1/1 ipv6: fix icmpv6_cleanup/icmpv6_init section mismatch
Quoted 2 lines · Alexey Dobriyan
icmpv6_cleanup()is called frominet6_init()which is__init, so the former can't be__exit.
Doh! Ignore this one. Below is correct.
--------
[PATCH] ipv6: fix inet6_init/icmpv6_cleanup sections mismatch
---
net/ipv6/icmp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
net/ipv6/icmp.c +2 -2
@@ -844,7 +844,7 @@ static void __net_exit icmpv6_sk_exit(struct net *net)kfree (net->ipv6.icmp_sk); } -static struct pernet_operations __net_initdata icmpv6_sk_ops = { +static struct pernet_operations icmpv6_sk_ops = { .init = icmpv6_sk_init, .exit = icmpv6_sk_exit, };
@@ -868,7 +868,7 @@ fail:return err; } -void __exit icmpv6_cleanup(void) +void icmpv6_cleanup (void ) {unregister_pernet_subsys (&icmpv6_sk_ops);inet6_del_protocol (&icmpv6_protocol,IPPROTO_ICMPV6 );
From: Alexey Dobriyan <[email protected]>
Date: Mon, 3 Mar 2008 17:54:51 +0300
Quoted 6 lines
Doh! Ignore this one. Below is correct.
--------[PATCH] ipv6: fix inet6_init/icmpv6_cleanup sections mismatch
Signed-off-by Alexey Dobriyan <[email protected]>
Applied.
However, dealing with all of these interactions between real __{init,exit} and __net_{init,exit} becomes tiresome.
We used to be able to mark icmpv6_cleanup as __exit now with the netns stuff we can't, that's a step backwards and it's happening a lot as the conversions take place.