Index: linux-4.2-rc1/fs/compat_ioctl.c
===================================================================
--- linux-4.2-rc1.orig/fs/compat_ioctl.c	2015-07-09 16:17:16.000000000 +0200
+++ linux-4.2-rc1/fs/compat_ioctl.c	2015-07-09 16:18:50.000000000 +0200
@@ -896,6 +896,7 @@ COMPATIBLE_IOCTL(FIGETBSZ)
 /* 'X' - originally XFS but some now in the VFS */
 COMPATIBLE_IOCTL(FIFREEZE)
 COMPATIBLE_IOCTL(FITHAW)
+COMPATIBLE_IOCTL(FITRIM)
 COMPATIBLE_IOCTL(KDGETKEYCODE)
 COMPATIBLE_IOCTL(KDSETKEYCODE)
 COMPATIBLE_IOCTL(KDGKBTYPE)
Index: linux-4.2-rc1/fs/ecryptfs/file.c
===================================================================
--- linux-4.2-rc1.orig/fs/ecryptfs/file.c	2015-07-09 16:13:54.000000000 +0200
+++ linux-4.2-rc1/fs/ecryptfs/file.c	2015-07-09 16:14:05.000000000 +0200
@@ -325,7 +325,6 @@ ecryptfs_compat_ioctl(struct file *file,
 		return rc;
 
 	switch (cmd) {
-	case FITRIM:
 	case FS_IOC32_GETFLAGS:
 	case FS_IOC32_SETFLAGS:
 	case FS_IOC32_GETVERSION:
Index: linux-4.2-rc1/fs/ext4/ioctl.c
===================================================================
--- linux-4.2-rc1.orig/fs/ext4/ioctl.c	2015-07-09 16:16:38.000000000 +0200
+++ linux-4.2-rc1/fs/ext4/ioctl.c	2015-07-09 16:16:45.000000000 +0200
@@ -755,7 +755,6 @@ long ext4_compat_ioctl(struct file *file
 		return err;
 	}
 	case EXT4_IOC_MOVE_EXT:
-	case FITRIM:
 	case EXT4_IOC_RESIZE_FS:
 	case EXT4_IOC_PRECACHE_EXTENTS:
 	case EXT4_IOC_SET_ENCRYPTION_POLICY:
Index: linux-4.2-rc1/fs/hpfs/dir.c
===================================================================
--- linux-4.2-rc1.orig/fs/hpfs/dir.c	2015-07-09 16:15:22.000000000 +0200
+++ linux-4.2-rc1/fs/hpfs/dir.c	2015-07-09 16:15:26.000000000 +0200
@@ -328,7 +328,4 @@ const struct file_operations hpfs_dir_op
 	.release	= hpfs_dir_release,
 	.fsync		= hpfs_file_fsync,
 	.unlocked_ioctl	= hpfs_ioctl,
-#ifdef CONFIG_COMPAT
-	.compat_ioctl	= hpfs_compat_ioctl,
-#endif
 };
Index: linux-4.2-rc1/fs/hpfs/file.c
===================================================================
--- linux-4.2-rc1.orig/fs/hpfs/file.c	2015-07-09 16:15:30.000000000 +0200
+++ linux-4.2-rc1/fs/hpfs/file.c	2015-07-09 16:15:33.000000000 +0200
@@ -204,9 +204,6 @@ const struct file_operations hpfs_file_o
 	.fsync		= hpfs_file_fsync,
 	.splice_read	= generic_file_splice_read,
 	.unlocked_ioctl	= hpfs_ioctl,
-#ifdef CONFIG_COMPAT
-	.compat_ioctl	= hpfs_compat_ioctl,
-#endif
 };
 
 const struct inode_operations hpfs_file_iops =
Index: linux-4.2-rc1/fs/hpfs/super.c
===================================================================
--- linux-4.2-rc1.orig/fs/hpfs/super.c	2015-07-09 16:14:53.000000000 +0200
+++ linux-4.2-rc1/fs/hpfs/super.c	2015-07-09 16:15:12.000000000 +0200
@@ -228,13 +228,6 @@ long hpfs_ioctl(struct file *file, unsig
 	}
 }
 
-#ifdef CONFIG_COMPAT
-long hpfs_compat_ioctl(struct file *file, unsigned cmd, unsigned long arg)
-{
-	return hpfs_ioctl(file, cmd, (unsigned long)compat_ptr(arg));
-}
-#endif
-
 
 static struct kmem_cache * hpfs_inode_cachep;
 
Index: linux-4.2-rc1/fs/jfs/ioctl.c
===================================================================
--- linux-4.2-rc1.orig/fs/jfs/ioctl.c	2015-07-09 16:16:52.000000000 +0200
+++ linux-4.2-rc1/fs/jfs/ioctl.c	2015-07-09 16:17:03.000000000 +0200
@@ -180,10 +180,6 @@ long jfs_compat_ioctl(struct file *filp,
 	case JFS_IOC_SETFLAGS32:
 		cmd = JFS_IOC_SETFLAGS;
 		break;
-	case FITRIM:
-		cmd = FITRIM;
-		break;
-	}
 	return jfs_ioctl(filp, cmd, arg);
 }
 #endif
Index: linux-4.2-rc1/fs/nilfs2/ioctl.c
===================================================================
--- linux-4.2-rc1.orig/fs/nilfs2/ioctl.c	2015-07-09 16:13:37.000000000 +0200
+++ linux-4.2-rc1/fs/nilfs2/ioctl.c	2015-07-09 16:13:47.000000000 +0200
@@ -1369,7 +1369,6 @@ long nilfs_compat_ioctl(struct file *fil
 	case NILFS_IOCTL_SYNC:
 	case NILFS_IOCTL_RESIZE:
 	case NILFS_IOCTL_SET_ALLOC_RANGE:
-	case FITRIM:
 		break;
 	default:
 		return -ENOIOCTLCMD;
Index: linux-4.2-rc1/fs/ocfs2/ioctl.c
===================================================================
--- linux-4.2-rc1.orig/fs/ocfs2/ioctl.c	2015-07-09 16:14:20.000000000 +0200
+++ linux-4.2-rc1/fs/ocfs2/ioctl.c	2015-07-09 16:14:25.000000000 +0200
@@ -980,7 +980,6 @@ long ocfs2_compat_ioctl(struct file *fil
 	case OCFS2_IOC_GROUP_EXTEND:
 	case OCFS2_IOC_GROUP_ADD:
 	case OCFS2_IOC_GROUP_ADD64:
-	case FITRIM:
 		break;
 	case OCFS2_IOC_REFLINK:
 		if (copy_from_user(&args, argp, sizeof(args)))
