bcachefs: make sure to release last journal pin in replay
This fixes a deadlock when journal replay has many keys to insert that were from fsck, not the journal. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
parent
fabb4d4985
commit
79055f50a6
|
@ -249,7 +249,10 @@ int bch2_journal_replay(struct bch_fs *c)
|
|||
|
||||
struct journal_key *k = *kp;
|
||||
|
||||
replay_now_at(j, k->journal_seq);
|
||||
if (k->journal_seq)
|
||||
replay_now_at(j, k->journal_seq);
|
||||
else
|
||||
replay_now_at(j, j->replay_journal_seq_end);
|
||||
|
||||
ret = commit_do(trans, NULL, NULL,
|
||||
BCH_TRANS_COMMIT_no_enospc|
|
||||
|
|
Loading…
Reference in New Issue