fs: ext4: disable support for fallocate FALLOC_FL_PUNCH_HOLE
Bug: 28760453
Change-Id: I019c2de559db9e4b95860ab852211b456d78c4ca
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
index c77b0bd..8055129 100644
--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@ -3338,6 +3338,7 @@
int ext4_punch_hole(struct file *file, loff_t offset, loff_t length)
{
+#if 0
struct inode *inode = file->f_path.dentry->d_inode;
if (!S_ISREG(inode->i_mode))
return -EOPNOTSUPP;
@@ -3353,6 +3354,12 @@
}
return ext4_ext_punch_hole(file, offset, length);
+#else
+ /*
+ * Disabled as per b/28760453
+ */
+ return -EOPNOTSUPP;
+#endif
}
/*