]> www.infradead.org Git - users/jedix/linux-maple.git/commit
bcachefs: Don't rely on snapshot_tree.master_subvol for reattaching
authorKent Overstreet <kent.overstreet@linux.dev>
Sat, 21 Dec 2024 04:56:42 +0000 (23:56 -0500)
committerKent Overstreet <kent.overstreet@linux.dev>
Fri, 10 Jan 2025 04:38:41 +0000 (23:38 -0500)
commitb5e4cd0871db885de05d531e8e72fa6059d81bd4
treeedc07397262a0c68562859b5fbb7a8c6f5b4a01c
parent45414083913f68cb7586924767a3fb2cc7710352
bcachefs: Don't rely on snapshot_tree.master_subvol for reattaching

Previously, fsck used the snapshot tree's master subvol for finding the
root inode number - but the master subvol might have been deleting, and
setting a new one should be a user operation; meaning we can't rely on
it existing.

Fortunately, for finding the root inode number in a tree of snapshots,
finding any associated subvolume works.

Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/errcode.h
fs/bcachefs/fsck.c