]> git.karo-electronics.de Git - karo-tx-linux.git/commit
dm cache policy mq: introduce three promotion threshold tunables
authorJoe Thornber <ejt@redhat.com>
Mon, 9 Dec 2013 12:53:05 +0000 (12:53 +0000)
committerMike Snitzer <snitzer@redhat.com>
Fri, 20 Dec 2013 23:15:20 +0000 (18:15 -0500)
commit3b1e77ef973fa524fe3c2de06e9401ce8a6f18cd
tree12329f0becfa6563e709c19ca96620ad83288370
parent4edc2e149c0503769a6eb25c95bf40305c7258aa
dm cache policy mq: introduce three promotion threshold tunables

Internally the mq policy maintains a promotion threshold variable.  If
the hit count of a block not in the cache goes above this threshold it
gets promoted to the cache.

This patch introduces three new tunables that allow you to tweak the
promotion threshold by adding a small value.  These adjustments depend
on the io type:

   read_promote_adjustment:    READ io, default 4
   write_promote_adjustment:   WRITE io, default 8
   discard_promote_adjustment: READ/WRITE io to a discarded block, default 1

If you're trying to quickly warm a new cache device you may wish to
reduce these to encourage promotion.  Remember to switch them back to
their defaults after the cache fills though.

Signed-off-by: Joe Thornber <ejt@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Documentation/device-mapper/cache-policies.txt
drivers/md/dm-cache-policy-mq.c