]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
fhandle: move compat syscalls from compat.c
authorAl Viro <viro@zeniv.linux.org.uk>
Sat, 8 Apr 2017 22:16:56 +0000 (18:16 -0400)
committerAl Viro <viro@zeniv.linux.org.uk>
Mon, 17 Apr 2017 16:52:26 +0000 (12:52 -0400)
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/compat.c
fs/fhandle.c
fs/internal.h

index e1822ec8a87c75cd99458c78d941fb0a27179233..3e94559c452e5a0a99a64b135940696fad2eae17 100644 (file)
@@ -310,15 +310,3 @@ COMPAT_SYSCALL_DEFINE5(mount, const char __user *, dev_name,
  out:
        return retval;
 }
-
-#ifdef CONFIG_FHANDLE
-/*
- * Exactly like fs/open.c:sys_open_by_handle_at(), except that it
- * doesn't set the O_LARGEFILE flag.
- */
-COMPAT_SYSCALL_DEFINE3(open_by_handle_at, int, mountdirfd,
-                            struct file_handle __user *, handle, int, flags)
-{
-       return do_handle_open(mountdirfd, handle, flags);
-}
-#endif
index 5559168d5637310d2712eab97af1117a786cfba1..58a61f55e0d09f868bb1bac6a0b4d6e5042822ad 100644 (file)
@@ -9,6 +9,7 @@
 #include <linux/fsnotify.h>
 #include <linux/personality.h>
 #include <linux/uaccess.h>
+#include <linux/compat.h>
 #include "internal.h"
 #include "mount.h"
 
@@ -264,3 +265,15 @@ SYSCALL_DEFINE3(open_by_handle_at, int, mountdirfd,
        ret = do_handle_open(mountdirfd, handle, flags);
        return ret;
 }
+
+#ifdef CONFIG_COMPAT
+/*
+ * Exactly like fs/open.c:sys_open_by_handle_at(), except that it
+ * doesn't set the O_LARGEFILE flag.
+ */
+COMPAT_SYSCALL_DEFINE3(open_by_handle_at, int, mountdirfd,
+                            struct file_handle __user *, handle, int, flags)
+{
+       return do_handle_open(mountdirfd, handle, flags);
+}
+#endif
index 11c6d89dce9c9ae2e1bc1d04614a732ccc0a952e..076751d90ba256678aeb414238d18d4d27b1b42d 100644 (file)
@@ -108,8 +108,6 @@ extern struct file *do_filp_open(int dfd, struct filename *pathname,
 extern struct file *do_file_open_root(struct dentry *, struct vfsmount *,
                const char *, const struct open_flags *);
 
-extern long do_handle_open(int mountdirfd,
-                          struct file_handle __user *ufh, int open_flag);
 extern int open_check_o_direct(struct file *f);
 extern int vfs_open(const struct path *, struct file *, const struct cred *);
 extern struct file *filp_clone_open(struct file *);