add patch enable-punch-hole-for-bigalloc
[ext4-patch-queue.git] / enable-punch-hole-for-bigalloc
blob41edb7b15301569edf28bafbc2153e05b2012b13
1 ext4: enable punch hole for bigalloc
3 From: Zheng Liu <wenqing.lz@taobao.com>
5 After applied this commit (d23142c6), ext4 has supported punch hole for
6 a file system with bigalloc feature.  But we forgot to enable it.  This
7 commit fixes it.
9 Cc: Lukas Czerner <lczerner@redhat.com>
10 Signed-off-by: Zheng Liu <wenqing.lz@taobao.com>
11 Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
12 ---
13  fs/ext4/inode.c |    5 -----
14  1 file changed, 5 deletions(-)
16 diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
17 index 0757634..2d73587 100644
18 --- a/fs/ext4/inode.c
19 +++ b/fs/ext4/inode.c
20 @@ -3513,11 +3513,6 @@ int ext4_punch_hole(struct inode *inode, loff_t offset, loff_t length)
21         if (!S_ISREG(inode->i_mode))
22                 return -EOPNOTSUPP;
24 -       if (EXT4_SB(sb)->s_cluster_ratio > 1) {
25 -               /* TODO: Add support for bigalloc file systems */
26 -               return -EOPNOTSUPP;
27 -       }
29         trace_ext4_punch_hole(inode, offset, length);
31         /*
32 -- 
33 1.7.9.7