diff options
author | David S. Miller <davem@davemloft.net> | 2010-02-04 04:38:22 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-04 04:38:22 +0100 |
commit | 9c119ba54c0fcae72881948af3d37b47a2f8e1f9 (patch) | |
tree | 0be51b0bf02ece3bb32955e9d33a3998ecd57250 /net/key | |
parent | sfc: Do not include unneeded headers (diff) | |
parent | ixgbe: Fix return of invalid txq (diff) | |
download | linux-9c119ba54c0fcae72881948af3d37b47a2f8e1f9.tar.xz linux-9c119ba54c0fcae72881948af3d37b47a2f8e1f9.zip |
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Diffstat (limited to 'net/key')
-rw-r--r-- | net/key/af_key.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/net/key/af_key.c b/net/key/af_key.c index e2aacf0ba013..41dd2cb07ef3 100644 --- a/net/key/af_key.c +++ b/net/key/af_key.c @@ -3793,9 +3793,9 @@ static struct pernet_operations pfkey_net_ops = { static void __exit ipsec_pfkey_exit(void) { - unregister_pernet_subsys(&pfkey_net_ops); xfrm_unregister_km(&pfkeyv2_mgr); sock_unregister(PF_KEY); + unregister_pernet_subsys(&pfkey_net_ops); proto_unregister(&key_proto); } @@ -3806,21 +3806,22 @@ static int __init ipsec_pfkey_init(void) if (err != 0) goto out; - err = sock_register(&pfkey_family_ops); + err = register_pernet_subsys(&pfkey_net_ops); if (err != 0) goto out_unregister_key_proto; + err = sock_register(&pfkey_family_ops); + if (err != 0) + goto out_unregister_pernet; err = xfrm_register_km(&pfkeyv2_mgr); if (err != 0) goto out_sock_unregister; - err = register_pernet_subsys(&pfkey_net_ops); - if (err != 0) - goto out_xfrm_unregister_km; out: return err; -out_xfrm_unregister_km: - xfrm_unregister_km(&pfkeyv2_mgr); + out_sock_unregister: sock_unregister(PF_KEY); +out_unregister_pernet: + unregister_pernet_subsys(&pfkey_net_ops); out_unregister_key_proto: proto_unregister(&key_proto); goto out; |