bcachefs: Refactor replicas code
authorKent Overstreet <kent.overstreet@gmail.com>
Fri, 10 Jul 2020 20:13:52 +0000 (16:13 -0400)
committerKent Overstreet <kent.overstreet@linux.dev>
Sun, 22 Oct 2023 21:08:43 +0000 (17:08 -0400)
commit988e98cfce26ecad20595cb52056759e798cd8de
treed2e87e917561948e12d3ed67c8642349a76ee639
parent8f3b41ab4f39f87712ed57e0443642d7bcabd1ff
bcachefs: Refactor replicas code

Awhile back the mechanism for garbage collecting unused replicas entries
was significantly improved, but some cleanup was missed - this patch
does that now.

This is also prep work for a patch to account for erasure coded parity
blocks separately - we need to consolidate the logic for
checking/marking the various replicas entries from one bkey into a
single function.

Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/btree_gc.c
fs/bcachefs/extents.c
fs/bcachefs/journal_io.c
fs/bcachefs/replicas.c
fs/bcachefs/replicas.h