bcachefs: Ensure we don't use a blacklisted journal seq
authorKent Overstreet <kent.overstreet@linux.dev>
Fri, 23 May 2025 18:03:06 +0000 (14:03 -0400)
committerKent Overstreet <kent.overstreet@linux.dev>
Fri, 23 May 2025 23:52:31 +0000 (19:52 -0400)
commit521f9584c2bd48198ac9d9b99a372b1306f3bb97
treeff99004661b98cd6d216c975fd83f058c2d478a4
parent9b133c0d74b17db2dc0d2d70b6591b0ebb604463
bcachefs: Ensure we don't use a blacklisted journal seq

Different versions differ on the size of the blacklist range; it is
theoretically possible that we could end up with blacklisted journal
sequence numbers newer than the newest seq we find in the journal, and
pick a new start seq that's blacklisted.

Explicitly check for this in bch2_fs_journal_start().

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