]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/blobdiff - fs/ext4/inode.c
ext4: enforce bigalloc restrictions (e.g., no online resizing, etc.)
[mirror_ubuntu-focal-kernel.git] / fs / ext4 / inode.c
index 6ecc93979e48168d5d62f98de49445152f74a58b..904a9a623dab5e6b6d25925412aee7542837b5a8 100644 (file)
@@ -3358,6 +3358,11 @@ int ext4_punch_hole(struct file *file, loff_t offset, loff_t length)
                return -ENOTSUPP;
        }
 
+       if (EXT4_SB(inode->i_sb)->s_cluster_ratio > 1) {
+               /* TODO: Add support for bigalloc file systems */
+               return -ENOTSUPP;
+       }
+
        return ext4_ext_punch_hole(file, offset, length);
 }