From: hujianyang Date: Tue, 12 May 2015 08:05:57 +0000 (+0800) Subject: f2fs: add compat_ioctl to provide backward compatability X-Git-Tag: v4.2-rc1~123^2~34 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=08b95126c787441e4ef572422a5237dd985147be;p=karo-tx-linux.git f2fs: add compat_ioctl to provide backward compatability introduce compat_ioctl to regular files, but doesn't add this functionality to f2fs_dir_operations. While running a 32-bit busybox, I met an error like this: (A is a directory) chattr: reading flags on A: Inappropriate ioctl for device This patch copies compat_ioctl from f2fs_file_operations and fix this problem. Signed-off-by: hujianyang Reviewed-by: Chao Yu Signed-off-by: Jaegeuk Kim --- diff --git a/fs/f2fs/dir.c b/fs/f2fs/dir.c index 12f686914d38..3e923763daca 100644 --- a/fs/f2fs/dir.c +++ b/fs/f2fs/dir.c @@ -879,4 +879,7 @@ const struct file_operations f2fs_dir_operations = { .iterate = f2fs_readdir, .fsync = f2fs_sync_file, .unlocked_ioctl = f2fs_ioctl, +#ifdef CONFIG_COMPAT + .compat_ioctl = f2fs_compat_ioctl, +#endif };