Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 75744
b: refs/heads/master
c: d405936
h: refs/heads/master
v: v3
  • Loading branch information
Greg Kroah-Hartman committed Jan 25, 2008
1 parent df60b6e commit 72e88b9
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 12 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 136a27507fd09006973f11b17ca971d4c176a06a
refs/heads/master: d405936b322220dc5cca9d2b58ef1911ae8efec9
20 changes: 9 additions & 11 deletions trunk/fs/dlm/lockspace.c
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ static struct kobj_type dlm_ktype = {
.release = lockspace_kobj_release,
};

static struct kset dlm_kset;
static struct kset *dlm_kset;

static int kobject_setup(struct dlm_ls *ls)
{
Expand All @@ -180,7 +180,7 @@ static int kobject_setup(struct dlm_ls *ls)
if (error)
return error;

ls->ls_kobj.kset = &dlm_kset;
ls->ls_kobj.kset = dlm_kset;
ls->ls_kobj.ktype = &dlm_ktype;
return 0;
}
Expand Down Expand Up @@ -218,24 +218,22 @@ static int do_uevent(struct dlm_ls *ls, int in)

int dlm_lockspace_init(void)
{
int error;

ls_count = 0;
mutex_init(&ls_lock);
INIT_LIST_HEAD(&lslist);
spin_lock_init(&lslist_lock);

kobject_set_name(&dlm_kset.kobj, "dlm");
dlm_kset.kobj.kset = &kernel_subsys;
error = kset_register(&dlm_kset);
if (error)
printk("dlm_lockspace_init: cannot register kset %d\n", error);
return error;
dlm_kset = kset_create_and_add("dlm", NULL, &kernel_subsys.kobj);
if (!dlm_kset) {
printk(KERN_WARNING "%s: can not create kset\n", __FUNCTION__);
return -ENOMEM;
}
return 0;
}

void dlm_lockspace_exit(void)
{
kset_unregister(&dlm_kset);
kset_unregister(dlm_kset);
}

static int dlm_scand(void *data)
Expand Down

0 comments on commit 72e88b9

Please sign in to comment.