mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-09 02:00:43 -04:00
bcachefs: Don't spin in journal reclaim
If we're not able to flush anything, we shouldn't keep looping. Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
This commit is contained in:
committed by
Kent Overstreet
parent
a0a07c59f5
commit
2975cd4701
@@ -661,7 +661,7 @@ static int __bch2_journal_reclaim(struct journal *j, bool direct)
|
||||
|
||||
if (nr_flushed)
|
||||
wake_up(&j->reclaim_wait);
|
||||
} while ((min_nr || min_key_cache) && !direct);
|
||||
} while ((min_nr || min_key_cache) && nr_flushed && !direct);
|
||||
|
||||
memalloc_noreclaim_restore(flags);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user