blk-wbt: account and throttle O_DIRECT wbt-odirect
authorJens Axboe <axboe@kernel.dk>
Wed, 25 Oct 2017 20:47:00 +0000 (14:47 -0600)
committerJens Axboe <axboe@kernel.dk>
Wed, 25 Oct 2017 20:47:00 +0000 (14:47 -0600)
commit374e800f2140e66802400343211a627810053974
tree95cda22eeb1d25b05843c2ed032c3b923fbe17c5
parent16f1477ebeeef4170f1f16eb66ad565daecdc7a8
blk-wbt: account and throttle O_DIRECT

Before this patch, we had two buckets - one for kswapd writes and one
for normal buffered writes. The two bucket approach was introduced to
avoid starvation between the two different types of writes. Before that,
we treated all non-direct writes identically.

This patch adds a third bucket, for O_DIRECT writes. Mixed workloads,
with both lots of buffered and O_DIRECT writes, O_DIRECT writes are
unnecessarily starving the buffered writes. Account and throttle
O_DIRECT writes independently.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-wbt.c
block/blk-wbt.h