diff options
author | Namhyung Kim <namhyung@gmail.com> | 2011-01-17 01:45:59 -0500 |
---|---|---|
committer | J. Bruce Fields <bfields@redhat.com> | 2011-03-07 12:05:09 -0500 |
commit | f32cb53219a956b96a4cd1ee7c6b1b8a48d40e9f (patch) | |
tree | 902efb83d1ffa7e7e9ebfe49ad1e9adca8ef52e6 /fs/locks.c | |
parent | dd9c1549edef02290edced639f67b54a25abbe0e (diff) |
locks: use assign_type()
Signed-off-by: Namhyung Kim <namhyung@gmail.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs/locks.c')
-rw-r--r-- | fs/locks.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/fs/locks.c b/fs/locks.c index 0f3998291f7..2c2d3b804d6 100644 --- a/fs/locks.c +++ b/fs/locks.c | |||
@@ -415,17 +415,7 @@ static int flock64_to_posix_lock(struct file *filp, struct file_lock *fl, | |||
415 | fl->fl_ops = NULL; | 415 | fl->fl_ops = NULL; |
416 | fl->fl_lmops = NULL; | 416 | fl->fl_lmops = NULL; |
417 | 417 | ||
418 | switch (l->l_type) { | 418 | return assign_type(fl, l->l_type); |
419 | case F_RDLCK: | ||
420 | case F_WRLCK: | ||
421 | case F_UNLCK: | ||
422 | fl->fl_type = l->l_type; | ||
423 | break; | ||
424 | default: | ||
425 | return -EINVAL; | ||
426 | } | ||
427 | |||
428 | return (0); | ||
429 | } | 419 | } |
430 | #endif | 420 | #endif |
431 | 421 | ||