From: Andrew Morton arch/x86/kernel/apm_32.c: At top level: arch/x86/kernel/apm_32.c:1477: error: conflicting types for 'do_ioctl' include/linux/fs.h:1929: error: previous declaration of 'do_ioctl' was here Cc: Christoph Hellwig Cc: Erez Zadok Signed-off-by: Andrew Morton --- fs/compat_ioctl.c | 2 +- fs/ioctl.c | 6 +++--- include/linux/fs.h | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff -puN fs/compat_ioctl.c~vfs-swap-do_ioctl-and-vfs_ioctl-names-fix fs/compat_ioctl.c --- a/fs/compat_ioctl.c~vfs-swap-do_ioctl-and-vfs_ioctl-names-fix +++ a/fs/compat_ioctl.c @@ -2944,7 +2944,7 @@ asmlinkage long compat_sys_ioctl(unsigne } do_ioctl: - error = do_ioctl(filp, fd, cmd, arg); + error = do_vfs_ioctl(filp, fd, cmd, arg); out_fput: fput_light(filp, fput_needed); out: diff -puN fs/ioctl.c~vfs-swap-do_ioctl-and-vfs_ioctl-names-fix fs/ioctl.c --- a/fs/ioctl.c~vfs-swap-do_ioctl-and-vfs_ioctl-names-fix +++ a/fs/ioctl.c @@ -92,10 +92,10 @@ static int file_ioctl(struct file *filp, * When you add any new common ioctls to the switches above and below * please update compat_sys_ioctl() too. * - * do_ioctl() is not for drivers and not intended to be EXPORT_SYMBOL()'d. + * do_vfs_ioctl() is not for drivers and not intended to be EXPORT_SYMBOL()'d. * It's just a simple helper for sys_ioctl and compat_sys_ioctl. */ -int do_ioctl(struct file *filp, unsigned int fd, unsigned int cmd, +int do_vfs_ioctl(struct file *filp, unsigned int fd, unsigned int cmd, unsigned long arg) { unsigned int flag; @@ -185,7 +185,7 @@ asmlinkage long sys_ioctl(unsigned int f if (error) goto out_fput; - error = do_ioctl(filp, fd, cmd, arg); + error = do_vfs_ioctl(filp, fd, cmd, arg); out_fput: fput_light(filp, fput_needed); out: diff -puN include/linux/fs.h~vfs-swap-do_ioctl-and-vfs_ioctl-names-fix include/linux/fs.h --- a/include/linux/fs.h~vfs-swap-do_ioctl-and-vfs_ioctl-names-fix +++ a/include/linux/fs.h @@ -1924,7 +1924,7 @@ extern int vfs_lstat_fd(int dfd, char __ extern int vfs_fstat(unsigned int, struct kstat *); extern long vfs_ioctl(struct file *filp, unsigned int cmd, unsigned long arg); -extern int do_ioctl(struct file *filp, unsigned int fd, unsigned int cmd, +extern int do_vfs_ioctl(struct file *filp, unsigned int fd, unsigned int cmd, unsigned long arg); extern void get_filesystem(struct file_system_type *fs); _