summaryrefslogtreecommitdiffstats
path: root/fs/fcntl.c
diff options
context:
space:
mode:
authorJeff Layton <jlayton@redhat.com>2014-02-03 12:13:09 -0500
committerJeff Layton <jlayton@redhat.com>2014-03-31 08:24:43 -0400
commitc1e62b8fc355e0c3706f1ae0dacb72d1c514dc80 (patch)
tree67167d2ae9569d83d08edda65aa047faf21500e1 /fs/fcntl.c
parent3fd80cddc6af5ba53244514a61450d4b30a9fb9d (diff)
downloadop-kernel-dev-c1e62b8fc355e0c3706f1ae0dacb72d1c514dc80.zip
op-kernel-dev-c1e62b8fc355e0c3706f1ae0dacb72d1c514dc80.tar.gz
locks: pass the cmd value to fcntl_getlk/getlk64
Once we introduce file private locks, we'll need to know what cmd value was used, as that affects the ownership and whether a conflict would arise. Signed-off-by: Jeff Layton <jlayton@redhat.com>
Diffstat (limited to 'fs/fcntl.c')
-rw-r--r--fs/fcntl.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/fcntl.c b/fs/fcntl.c
index ef68665..7ef7f2d 100644
--- a/fs/fcntl.c
+++ b/fs/fcntl.c
@@ -273,7 +273,7 @@ static long do_fcntl(int fd, unsigned int cmd, unsigned long arg,
err = setfl(fd, filp, arg);
break;
case F_GETLK:
- err = fcntl_getlk(filp, (struct flock __user *) arg);
+ err = fcntl_getlk(filp, cmd, (struct flock __user *) arg);
break;
case F_SETLK:
case F_SETLKW:
@@ -389,7 +389,7 @@ SYSCALL_DEFINE3(fcntl64, unsigned int, fd, unsigned int, cmd,
switch (cmd) {
case F_GETLK64:
- err = fcntl_getlk64(f.file, (struct flock64 __user *) arg);
+ err = fcntl_getlk64(f.file, cmd, (struct flock64 __user *) arg);
break;
case F_SETLK64:
case F_SETLKW64:
OpenPOWER on IntegriCloud