Commit 895928b8 authored by Jeff Mahoney's avatar Jeff Mahoney Committed by Mark Fasheh

[PATCH] ocfs2: complete failure recovery for nodemanager init

 This patch finishes cleaning up the node manager allocations if it fails
 to initialize.
Signed-off-by: default avatarJeff Mahoney <jeffm@suse.com>
Signed-off-by: default avatarMark Fasheh <mark.fasheh@oracle.com>
parent 362342f6
...@@ -756,7 +756,7 @@ static int __init init_o2nm(void) ...@@ -756,7 +756,7 @@ static int __init init_o2nm(void)
if (!ocfs2_table_header) { if (!ocfs2_table_header) {
printk(KERN_ERR "nodemanager: unable to register sysctl\n"); printk(KERN_ERR "nodemanager: unable to register sysctl\n");
ret = -ENOMEM; /* or something. */ ret = -ENOMEM; /* or something. */
goto out; goto out_o2net;
} }
ret = o2net_register_hb_callbacks(); ret = o2net_register_hb_callbacks();
...@@ -780,6 +780,8 @@ static int __init init_o2nm(void) ...@@ -780,6 +780,8 @@ static int __init init_o2nm(void)
o2net_unregister_hb_callbacks(); o2net_unregister_hb_callbacks();
out_sysctl: out_sysctl:
unregister_sysctl_table(ocfs2_table_header); unregister_sysctl_table(ocfs2_table_header);
out_o2net:
o2net_exit();
out: out:
return ret; return ret;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment