bcachefs: Snapshot deletion fix
authorKent Overstreet <kent.overstreet@gmail.com>
Fri, 1 Oct 2021 00:09:08 +0000 (20:09 -0400)
committerKent Overstreet <kent.overstreet@linux.dev>
Sun, 22 Oct 2023 21:09:13 +0000 (17:09 -0400)
commit7bd68c73044f1ba39f505082bbed3b2e26f69a13
tree31f2ddc21449891c29d64af7ce8087622e7a04c7
parent107fe5af562303cda985c6bb72d36dbcd2076f06
bcachefs: Snapshot deletion fix

When we delete a snapshot, we unlink the inode but we don't want to run
the inode_rm path - the unlink path deletes the subvolume directly,
which does everything we need. Also allowing the inode_rm path to run
was getting us "missing subvolume" errors.

There's still another bug with snapshot deletion: we need to make
snapshot deletion a multi stage process, where we unlink the root
dentry, then tear down the page cache, then delete the snapshot.

Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
fs/bcachefs/fs-common.c