aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_vnodeops.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/xfs_vnodeops.c')
-rw-r--r--fs/xfs/xfs_vnodeops.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/xfs/xfs_vnodeops.c b/fs/xfs/xfs_vnodeops.c
index 35ac59dabf8b..40b95e3a88ba 100644
--- a/fs/xfs/xfs_vnodeops.c
+++ b/fs/xfs/xfs_vnodeops.c
@@ -3437,7 +3437,9 @@ xfs_rwunlock(
3437{ 3437{
3438 if (S_ISDIR(ip->i_d.di_mode)) 3438 if (S_ISDIR(ip->i_d.di_mode))
3439 return; 3439 return;
3440 if (locktype != VRWLOCK_WRITE) { 3440 if (locktype == VRWLOCK_WRITE) {
3441 xfs_iunlock(ip, XFS_IOLOCK_EXCL);
3442 } else {
3441 ASSERT((locktype == VRWLOCK_READ) || 3443 ASSERT((locktype == VRWLOCK_READ) ||
3442 (locktype == VRWLOCK_WRITE_DIRECT)); 3444 (locktype == VRWLOCK_WRITE_DIRECT));
3443 xfs_iunlock(ip, XFS_IOLOCK_SHARED); 3445 xfs_iunlock(ip, XFS_IOLOCK_SHARED);