diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-15 19:07:40 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-15 19:07:40 -0400 |
commit | 541010e4b8921cd781ff02ae68028501457045b6 (patch) | |
tree | 58bd529d4c6e69899a0aa20afa2d7f1c23326417 /fs/afs | |
parent | e457f790d8b05977853aa238bbc667b3bb375671 (diff) | |
parent | 5e7fc436426b1f9e106f511a049de91c82ec2c53 (diff) |
Merge branch 'locks' of git://linux-nfs.org/~bfields/linux
* 'locks' of git://linux-nfs.org/~bfields/linux:
nfsd: remove IS_ISMNDLCK macro
Rework /proc/locks via seq_files and seq_list helpers
fs/locks.c: use list_for_each_entry() instead of list_for_each()
NFS: clean up explicit check for mandatory locks
AFS: clean up explicit check for mandatory locks
9PFS: clean up explicit check for mandatory locks
GFS2: clean up explicit check for mandatory locks
Cleanup macros for distinguishing mandatory locks
Documentation: move locks.txt in filesystems/
locks: add warning about mandatory locking races
Documentation: move mandatory locking documentation to filesystems/
locks: Fix potential OOPS in generic_setlease()
Use list_first_entry in locks_wake_up_blocks
locks: fix flock_lock_file() comment
Memory shortage can result in inconsistent flocks state
locks: kill redundant local variable
locks: reverse order of posix_locks_conflict() arguments
Diffstat (limited to 'fs/afs')
-rw-r--r-- | fs/afs/flock.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/afs/flock.c b/fs/afs/flock.c index af6952e39a18..210acafe4a9b 100644 --- a/fs/afs/flock.c +++ b/fs/afs/flock.c | |||
@@ -524,8 +524,7 @@ int afs_lock(struct file *file, int cmd, struct file_lock *fl) | |||
524 | (long long) fl->fl_start, (long long) fl->fl_end); | 524 | (long long) fl->fl_start, (long long) fl->fl_end); |
525 | 525 | ||
526 | /* AFS doesn't support mandatory locks */ | 526 | /* AFS doesn't support mandatory locks */ |
527 | if ((vnode->vfs_inode.i_mode & (S_ISGID | S_IXGRP)) == S_ISGID && | 527 | if (__mandatory_lock(&vnode->vfs_inode) && fl->fl_type != F_UNLCK) |
528 | fl->fl_type != F_UNLCK) | ||
529 | return -ENOLCK; | 528 | return -ENOLCK; |
530 | 529 | ||
531 | if (IS_GETLK(cmd)) | 530 | if (IS_GETLK(cmd)) |