Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ff24858c authored by Arne Jansen's avatar Arne Jansen Committed by Chris Mason
Browse files

Btrfs: ignore orphan qgroup relations



If a qgroup that has still assignments is deleted by the user, the corresponding
relations are left in the tree. This leads to an unmountable filesystem.
With this patch, those relations are simple ignored.

Reported-by: default avatarEric Hopper <hopper@omnifarious.org>
Signed-off-by: default avatarArne Jansen <sensille@gmx.net>
Signed-off-by: default avatarChris Mason <chris.mason@fusionio.com>
parent 57ba86c0
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -379,6 +379,13 @@ int btrfs_read_qgroup_config(struct btrfs_fs_info *fs_info)

		ret = add_relation_rb(fs_info, found_key.objectid,
				      found_key.offset);
		if (ret == -ENOENT) {
			printk(KERN_WARNING
				"btrfs: orphan qgroup relation 0x%llx->0x%llx\n",
				(unsigned long long)found_key.objectid,
				(unsigned long long)found_key.offset);
			ret = 0;	/* ignore the error */
		}
		if (ret)
			goto out;
next2: