summaryrefslogtreecommitdiffstats
path: root/net/key
diff options
context:
space:
mode:
authorZhengchao Shao <shaozhengchao@huawei.com>2022-06-15 09:55:19 +0800
committerSteffen Klassert <steffen.klassert@secunet.com>2022-06-24 10:19:11 +0200
commitf41b284a2c187c299f496f6fa1914ec986bdf0ee (patch)
tree41f2df2ebf0244f155af8c444993e6deacff440c /net/key
parent924b290655c0f17ac84e752addfc9bc3ec361069 (diff)
downloadlinux-stable-f41b284a2c187c299f496f6fa1914ec986bdf0ee.tar.gz
linux-stable-f41b284a2c187c299f496f6fa1914ec986bdf0ee.tar.bz2
linux-stable-f41b284a2c187c299f496f6fa1914ec986bdf0ee.zip
xfrm: change the type of xfrm_register_km and xfrm_unregister_km
Functions xfrm_register_km and xfrm_unregister_km do always return 0, change the type of functions to void. Signed-off-by: Zhengchao Shao <shaozhengchao@huawei.com> Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Diffstat (limited to 'net/key')
-rw-r--r--net/key/af_key.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/net/key/af_key.c b/net/key/af_key.c
index fb16d7c4e1b8..fda2dcc8a383 100644
--- a/net/key/af_key.c
+++ b/net/key/af_key.c
@@ -3894,14 +3894,10 @@ static int __init ipsec_pfkey_init(void)
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;
+ xfrm_register_km(&pfkeyv2_mgr);
out:
return err;
-out_sock_unregister:
- sock_unregister(PF_KEY);
out_unregister_pernet:
unregister_pernet_subsys(&pfkey_net_ops);
out_unregister_key_proto: