Skip to content

Commit

Permalink
dm cache policy smq: be more aggressive about triggering a writeback
Browse files Browse the repository at this point in the history
If there are no clean entries to demote we really want to writeback
immediately.

Signed-off-by: Joe Thornber <[email protected]>
Signed-off-by: Mike Snitzer <[email protected]>
  • Loading branch information
jthornber authored and snitm committed May 15, 2017
1 parent a8cd1eb commit 78c4560
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/md/dm-cache-policy-smq.c
Original file line number Diff line number Diff line change
Expand Up @@ -1192,7 +1192,7 @@ static void queue_demotion(struct smq_policy *mq)

e = q_peek(&mq->clean, mq->clean.nr_levels / 2, true);
if (!e) {
if (!clean_target_met(mq, false))
if (!clean_target_met(mq, true))
queue_writeback(mq);
return;
}
Expand Down

0 comments on commit 78c4560

Please sign in to comment.