diff options
| author | Benjamin Coddington <bcodding@redhat.com> | 2015-10-22 13:38:14 -0400 |
|---|---|---|
| committer | Jeff Layton <jeff.layton@primarydata.com> | 2015-10-22 14:57:36 -0400 |
| commit | 4f6563677ae833baad8003e14353241bc25da4fc (patch) | |
| tree | 6b54bdaa39f67c13cea45933dedc39f138051de9 /fs/9p | |
| parent | e55c34a66f87e78fb1fc6b623b78c5ad74b475af (diff) | |
Move locks API users to locks_lock_inode_wait()
Instead of having users check for FL_POSIX or FL_FLOCK to call the correct
locks API function, use the check within locks_lock_inode_wait(). This
allows for some later cleanup.
Signed-off-by: Benjamin Coddington <bcodding@redhat.com>
Signed-off-by: Jeff Layton <jeff.layton@primarydata.com>
Diffstat (limited to 'fs/9p')
| -rw-r--r-- | fs/9p/vfs_file.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/9p/vfs_file.c b/fs/9p/vfs_file.c index 3abc447783aa..f23fd86697ea 100644 --- a/fs/9p/vfs_file.c +++ b/fs/9p/vfs_file.c | |||
| @@ -161,7 +161,7 @@ static int v9fs_file_do_lock(struct file *filp, int cmd, struct file_lock *fl) | |||
| 161 | if ((fl->fl_flags & FL_POSIX) != FL_POSIX) | 161 | if ((fl->fl_flags & FL_POSIX) != FL_POSIX) |
| 162 | BUG(); | 162 | BUG(); |
| 163 | 163 | ||
| 164 | res = posix_lock_file_wait(filp, fl); | 164 | res = locks_lock_file_wait(filp, fl); |
| 165 | if (res < 0) | 165 | if (res < 0) |
| 166 | goto out; | 166 | goto out; |
| 167 | 167 | ||
| @@ -231,7 +231,7 @@ out_unlock: | |||
| 231 | if (res < 0 && fl->fl_type != F_UNLCK) { | 231 | if (res < 0 && fl->fl_type != F_UNLCK) { |
| 232 | fl_type = fl->fl_type; | 232 | fl_type = fl->fl_type; |
| 233 | fl->fl_type = F_UNLCK; | 233 | fl->fl_type = F_UNLCK; |
| 234 | res = posix_lock_file_wait(filp, fl); | 234 | res = locks_lock_file_wait(filp, fl); |
| 235 | fl->fl_type = fl_type; | 235 | fl->fl_type = fl_type; |
| 236 | } | 236 | } |
| 237 | out: | 237 | out: |
