mirror of
https://github.com/torvalds/linux.git
synced 2026-07-29 02:31:27 +02:00
bcachefs: Clear fs_path_parent on subvolume unlink
This fixes recursive subvolume removal. Subvolume deletion is asynchronous; fs_path_parent, and thus the entry in the subvolume_children btree, need to be cleared when the subvolume is unlinked from the fs heirarchy - else we'll spuriously think a subvolume has children and deletion will fail. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
parent
63c3b8f616
commit
b3981564ca
|
|
@ -561,6 +561,7 @@ int bch2_subvolume_unlink(struct btree_trans *trans, u32 subvolid)
|
|||
}
|
||||
|
||||
SET_BCH_SUBVOLUME_UNLINKED(&n->v, true);
|
||||
n->v.fs_path_parent = 0;
|
||||
bch2_trans_iter_exit(trans, &iter);
|
||||
return ret;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user