From 1cd1c97a0b50bda074404d1004d9f04a8e512f39 Mon Sep 17 00:00:00 2001 From: Denis Cheng Date: Tue, 29 Jan 2008 13:50:16 +0800 Subject: [PATCH] --- yaml --- r: 80621 b: refs/heads/master c: 0fe410d3f3b1496190f37ef74cd089229cef97fa h: refs/heads/master i: 80619: 4263622fc703980c9f1ac1fd6e2391d96fb6f97a v: v3 --- [refs] | 2 +- trunk/fs/dlm/user.c | 13 +++++++------ 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/[refs] b/[refs] index ccf757d75f2d..5e240358d3d7 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: dbcfc34733d1ae37e7a78c9e4e5325451223a5eb +refs/heads/master: 0fe410d3f3b1496190f37ef74cd089229cef97fa diff --git a/trunk/fs/dlm/user.c b/trunk/fs/dlm/user.c index 1acb4c5813cd..7cbc6826239b 100644 --- a/trunk/fs/dlm/user.c +++ b/trunk/fs/dlm/user.c @@ -24,8 +24,7 @@ #include "lvb_table.h" #include "user.h" -static const char *name_prefix="dlm"; -static struct miscdevice ctl_device; +static const char name_prefix[] = "dlm"; static const struct file_operations device_fops; #ifdef CONFIG_COMPAT @@ -902,14 +901,16 @@ static const struct file_operations ctl_device_fops = { .owner = THIS_MODULE, }; +static struct miscdevice ctl_device = { + .name = "dlm-control", + .fops = &ctl_device_fops, + .minor = MISC_DYNAMIC_MINOR, +}; + int dlm_user_init(void) { int error; - ctl_device.name = "dlm-control"; - ctl_device.fops = &ctl_device_fops; - ctl_device.minor = MISC_DYNAMIC_MINOR; - error = misc_register(&ctl_device); if (error) log_print("misc_register failed for control device");