diff options
author | 2024-05-06 23:11:43 -0400 | |
---|---|---|
committer | 2024-05-07 11:02:37 -0400 | |
commit | 6e297a73bccf852e7716207caa8eb868737c7155 (patch) | |
tree | 4ffb49325caf8f46667a3ddd7ef40d428b03480e | |
parent | bcachefs: Fix race in bch2_write_super() (diff) | |
download | linux-6e297a73bccf852e7716207caa8eb868737c7155.tar.gz linux-6e297a73bccf852e7716207caa8eb868737c7155.tar.bz2 linux-6e297a73bccf852e7716207caa8eb868737c7155.zip |
bcachefs: Add missing sched_annotate_sleep() in bch2_journal_flush_seq_async()
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
-rw-r--r-- | fs/bcachefs/journal.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/bcachefs/journal.c b/fs/bcachefs/journal.c index 9c2af544251a..a8b08e76d0d0 100644 --- a/fs/bcachefs/journal.c +++ b/fs/bcachefs/journal.c @@ -706,6 +706,12 @@ recheck_need_open: 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; |