bcachefs: Fix 'journal not marked as containing replicas'
authorKent Overstreet <kent.overstreet@linux.dev>
Fri, 11 Aug 2023 23:30:38 +0000 (19:30 -0400)
committerKent Overstreet <kent.overstreet@linux.dev>
Sun, 22 Oct 2023 21:10:10 +0000 (17:10 -0400)
commit83b3d9598a650d28071dbda0b97c7a9a6abd6e4a
tree19794609f899e0bc9e636868850e33681628eced
parent401585fe87c2359f7aa24a309ec90e2589da9b46
bcachefs: Fix 'journal not marked as containing replicas'

This fixes the replicas_write_errors test: the patch
  bcachefs: mark journal replicas before journal write submission

partially fixed replicas marking for the journal, but it broke the case
where one replica failed - this patch re-adds marking after the journal
write completes, when we know how many replicas succeeded.

Additionally, we do not consider it a fsck error when the very last
journal entry is not correctly marked, since there is an inherent race
there.

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