diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-01-26 19:42:05 +0100 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-01-26 19:42:05 +0100 |
commit | a90e8a75fbf9e7fe2d88da6a5cf38be07fd81c35 (patch) | |
tree | 0c5388fdefd00f2f7e381e4f8bd7707e6baeb374 /fs | |
parent | Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jac... (diff) | |
parent | dlm: initialize file_lock struct in GETLK before copying conflicting lock (diff) | |
download | linux-a90e8a75fbf9e7fe2d88da6a5cf38be07fd81c35.tar.xz linux-a90e8a75fbf9e7fe2d88da6a5cf38be07fd81c35.zip |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/teigland/dlm
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/teigland/dlm:
dlm: initialize file_lock struct in GETLK before copying conflicting lock
dlm: fix plock notify callback to lockd
Diffstat (limited to 'fs')
-rw-r--r-- | fs/dlm/plock.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/dlm/plock.c b/fs/dlm/plock.c index eba87ff3177b..894a32d438d5 100644 --- a/fs/dlm/plock.c +++ b/fs/dlm/plock.c @@ -168,7 +168,7 @@ static int dlm_plock_callback(struct plock_op *op) notify = xop->callback; if (op->info.rv) { - notify(flc, NULL, op->info.rv); + notify(fl, NULL, op->info.rv); goto out; } @@ -187,7 +187,7 @@ static int dlm_plock_callback(struct plock_op *op) (unsigned long long)op->info.number, file, fl); } - rv = notify(flc, NULL, 0); + rv = notify(fl, NULL, 0); if (rv) { /* XXX: We need to cancel the fs lock here: */ log_print("dlm_plock_callback: lock granted after lock request " @@ -304,7 +304,9 @@ int dlm_posix_get(dlm_lockspace_t *lockspace, u64 number, struct file *file, if (rv == -ENOENT) rv = 0; else if (rv > 0) { + locks_init_lock(fl); fl->fl_type = (op->info.ex) ? F_WRLCK : F_RDLCK; + fl->fl_flags = FL_POSIX; fl->fl_pid = op->info.pid; fl->fl_start = op->info.start; fl->fl_end = op->info.end; |