vfs: Add open by file handle support

[AV: duplicate of open() guts removed; file_open_root() used instead]

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
Aneesh Kumar K.V
2011-01-29 18:43:26 +05:30
committed by Al Viro
parent 990d6c2d7a
commit becfd1f375
6 changed files with 181 additions and 0 deletions

View File

@@ -2284,3 +2284,16 @@ asmlinkage long compat_sys_timerfd_gettime(int ufd,
}
#endif /* CONFIG_TIMERFD */
#ifdef CONFIG_FHANDLE
/*
* Exactly like fs/open.c:sys_open_by_handle_at(), except that it
* doesn't set the O_LARGEFILE flag.
*/
asmlinkage long
compat_sys_open_by_handle_at(int mountdirfd,
struct file_handle __user *handle, int flags)
{
return do_handle_open(mountdirfd, handle, flags);
}
#endif