From a4d935bd97b9ccf40aa0ec59646612df8ed46640 Mon Sep 17 00:00:00 2001 From: Changli Gao Date: Mon, 26 Jul 2010 17:19:19 +0800 Subject: dlm: use genl_register_family_with_ops() Signed-off-by: Changli Gao Signed-off-by: David Teigland --- fs/dlm/netlink.c | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'fs/dlm') diff --git a/fs/dlm/netlink.c b/fs/dlm/netlink.c index 2c6ad518100..ef17e0169da 100644 --- a/fs/dlm/netlink.c +++ b/fs/dlm/netlink.c @@ -81,24 +81,11 @@ static struct genl_ops dlm_nl_ops = { int __init dlm_netlink_init(void) { - int rv; - - rv = genl_register_family(&family); - if (rv) - return rv; - - rv = genl_register_ops(&family, &dlm_nl_ops); - if (rv < 0) - goto err; - return 0; - err: - genl_unregister_family(&family); - return rv; + return genl_register_family_with_ops(&family, &dlm_nl_ops, 1); } void dlm_netlink_exit(void) { - genl_unregister_ops(&family, &dlm_nl_ops); genl_unregister_family(&family); } -- cgit v1.2.3-70-g09d2