Skip to content

Commit

Permalink
fs: ext4: disable support for fallocate FALLOC_FL_PUNCH_HOLE
Browse files Browse the repository at this point in the history
Bug: 28760453
Change-Id: I019c2de559db9e4b95860ab852211b456d78c4ca
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
  • Loading branch information
nickdesaulniers authored and andi34 committed Jul 8, 2017
1 parent 2b17823 commit 189485a
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions fs/ext4/inode.c
Expand Up @@ -4475,6 +4475,7 @@ int ext4_can_truncate(struct inode *inode)

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 -ENOTSUPP;
Expand All @@ -4485,6 +4486,12 @@ int ext4_punch_hole(struct file *file, loff_t offset, loff_t length)
}

return ext4_ext_punch_hole(file, offset, length);
#else
/*
* Disabled as per b/28760453
*/
return -EOPNOTSUPP;
#endif
}

/*
Expand Down

0 comments on commit 189485a

Please sign in to comment.