aboutsummaryrefslogtreecommitdiffstats
path: root/arch/alpha/kernel/osf_sys.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2012-08-26 20:36:23 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2012-09-26 21:10:04 -0400
commit866ecfdd7cf05680acba635ecf7f30695d8039db (patch)
tree28e730887ef1fae3ee96891f36553a34d59983a6 /arch/alpha/kernel/osf_sys.c
parentswitch readahead(2) to fget_light() (diff)
downloadlinux-dev-866ecfdd7cf05680acba635ecf7f30695d8039db.tar.xz
linux-dev-866ecfdd7cf05680acba635ecf7f30695d8039db.zip
switch osf_getdirentries() to fget_light()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to '')
-rw-r--r--arch/alpha/kernel/osf_sys.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/alpha/kernel/osf_sys.c b/arch/alpha/kernel/osf_sys.c
index bc1acdda7a5e..d6c49e67d3fc 100644
--- a/arch/alpha/kernel/osf_sys.c
+++ b/arch/alpha/kernel/osf_sys.c
@@ -144,12 +144,12 @@ SYSCALL_DEFINE4(osf_getdirentries, unsigned int, fd,
struct osf_dirent __user *, dirent, unsigned int, count,
long __user *, basep)
{
- int error;
+ int error, fput_needed;
struct file *file;
struct osf_dirent_callback buf;
error = -EBADF;
- file = fget(fd);
+ file = fget_light(fd, &fput_needed);
if (!file)
goto out;
@@ -164,7 +164,7 @@ SYSCALL_DEFINE4(osf_getdirentries, unsigned int, fd,
if (count != buf.count)
error = count - buf.count;
- fput(file);
+ fput_light(file, fput_needed);
out:
return error;
}