btrfs: disable qgroups in extent tree v2
authorJosef Bacik <josef@toxicpanda.com>
Wed, 15 Dec 2021 20:40:01 +0000 (15:40 -0500)
committerDavid Sterba <dsterba@suse.com>
Mon, 14 Mar 2022 12:13:48 +0000 (13:13 +0100)
Backref lookups are going to be drastically different with extent tree
v2, disable qgroups until we do the work to add this support for extent
tree v2.

Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/qgroup.c

index 4a9bde1e2c50f89cfc487810ca5016d1cd2f31c7..d437511ed35406f3e359ad6806a60c2ab19a61c3 100644 (file)
@@ -948,6 +948,12 @@ int btrfs_quota_enable(struct btrfs_fs_info *fs_info)
         */
        lockdep_assert_held_write(&fs_info->subvol_sem);
 
+       if (btrfs_fs_incompat(fs_info, EXTENT_TREE_V2)) {
+               btrfs_err(fs_info,
+                         "qgroups are currently unsupported in extent tree v2");
+               return -EINVAL;
+       }
+
        mutex_lock(&fs_info->qgroup_ioctl_lock);
        if (fs_info->quota_root)
                goto out;