FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Cluster Development

 
 
LinkBack Thread Tools
 
Old 07-26-2010, 04:04 PM
David Teigland
 
Default dlm: use genl_register_family_with_ops()

On Mon, Jul 26, 2010 at 05:19:19PM +0800, Changli Gao wrote:
> Signed-off-by: Changli Gao <xiaosuo@gmail.com>
> ----
> fs/dlm/netlink.c | 15 +--------------
> 1 file changed, 1 insertion(+), 14 deletions(-)
> diff --git a/fs/dlm/netlink.c b/fs/dlm/netlink.c
> index 2c6ad51..ef17e01 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);
> }

Looks fine, ack.
Dave
 

Thread Tools




All times are GMT. The time now is 11:40 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org