Skip to content

Commit

Permalink
[GFS2] setup lock_dlm kobject earlier
Browse files Browse the repository at this point in the history
Setup the lock_dlm kobject before setting up the dlm lockspace instead
of after.  We want to use the sysfs files to detect the mount without
having to wait for the dlm setup which can take a while.

Signed-off-by: David Teigland <teigland@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
  • Loading branch information
David Teigland authored and Steven Whitehouse committed May 19, 2006
1 parent 320dd10 commit d2f222e
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions fs/gfs2/locking/dlm/mount.c
Original file line number Diff line number Diff line change
Expand Up @@ -143,19 +143,19 @@ static int gdlm_mount(char *table_name, char *host_data,
if (error)
goto out_free;

error = gdlm_kobject_setup(ls, fskobj);
if (error)
goto out_thread;

error = dlm_new_lockspace(ls->fsname, strlen(ls->fsname),
&ls->dlm_lockspace,
nodir ? DLM_LSFL_NODIR : 0,
GDLM_LVB_SIZE);
if (error) {
log_error("dlm_new_lockspace error %d", error);
goto out_thread;
goto out_kobj;
}

error = gdlm_kobject_setup(ls, fskobj);
if (error)
goto out_dlm;

lockstruct->ls_jid = ls->jid;
lockstruct->ls_first = ls->first;
lockstruct->ls_lockspace = ls;
Expand All @@ -164,8 +164,8 @@ static int gdlm_mount(char *table_name, char *host_data,
lockstruct->ls_lvb_size = GDLM_LVB_SIZE;
return 0;

out_dlm:
dlm_release_lockspace(ls->dlm_lockspace, 2);
out_kobj:
gdlm_kobject_release(ls);
out_thread:
gdlm_release_threads(ls);
out_free:
Expand Down

0 comments on commit d2f222e

Please sign in to comment.