Skip to content

Commit

Permalink
bcachefs: Add missing sched_annotate_sleep() in bch2_journal_flush_se…
Browse files Browse the repository at this point in the history
…q_async()

Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
  • Loading branch information
Kent Overstreet committed May 7, 2024
1 parent 54541c1 commit 6e297a7
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions fs/bcachefs/journal.c
Original file line number Diff line number Diff line change
Expand Up @@ -706,6 +706,12 @@ int bch2_journal_flush_seq_async(struct journal *j, u64 seq,

spin_unlock(&j->lock);

/*
* We're called from bch2_journal_flush_seq() -> wait_event();
* but this might block. We won't usually block, so we won't
* livelock:
*/
sched_annotate_sleep();
ret = bch2_journal_res_get(j, &res, jset_u64s(0), 0);
if (ret)
return ret;
Expand Down

0 comments on commit 6e297a7

Please sign in to comment.