aboutsummaryrefslogtreecommitdiffstats
path: root/net/key
diff options
context:
space:
mode:
Diffstat (limited to 'net/key')
-rw-r--r--net/key/af_key.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/net/key/af_key.c b/net/key/af_key.c
index 1c853927810a..8b5f486ac80f 100644
--- a/net/key/af_key.c
+++ b/net/key/af_key.c
@@ -3807,17 +3807,16 @@ static int pfkey_init_proc(void)
3807{ 3807{
3808 struct proc_dir_entry *e; 3808 struct proc_dir_entry *e;
3809 3809
3810 e = create_proc_entry("pfkey", 0, init_net.proc_net); 3810 e = proc_net_fops_create(&init_net, "pfkey", 0, &pfkey_proc_ops);
3811 if (e == NULL) 3811 if (e == NULL)
3812 return -ENOMEM; 3812 return -ENOMEM;
3813 3813
3814 e->proc_fops = &pfkey_proc_ops;
3815 return 0; 3814 return 0;
3816} 3815}
3817 3816
3818static void pfkey_exit_proc(void) 3817static void pfkey_exit_proc(void)
3819{ 3818{
3820 remove_proc_entry("net/pfkey", NULL); 3819 proc_net_remove(&init_net, "pfkey");
3821} 3820}
3822#else 3821#else
3823static inline int pfkey_init_proc(void) 3822static inline int pfkey_init_proc(void)