diff options
author | Christoph Hellwig <hch@lst.de> | 2016-12-09 08:19:06 -0500 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2016-12-09 10:29:35 -0500 |
commit | be07e14f96e3121483339a64d917fddb3b86ba98 (patch) | |
tree | 12059820b1fd1db5a5de2365bbc35b8ee4d0732e /block/blk-wbt.c | |
parent | a897b6664e9565c980f76af1c123cb0597d79822 (diff) |
blk-wbt: don't throttle discard or write zeroes
Both of these are metadata only commands that are not issued by the
writeback code and not directly relevant to the writeback bandwith.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block/blk-wbt.c')
-rw-r--r-- | block/blk-wbt.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/block/blk-wbt.c b/block/blk-wbt.c index d500e43da5d9..6e82769f4042 100644 --- a/block/blk-wbt.c +++ b/block/blk-wbt.c | |||
@@ -575,10 +575,9 @@ static inline bool wbt_should_throttle(struct rq_wb *rwb, struct bio *bio) | |||
575 | const int op = bio_op(bio); | 575 | const int op = bio_op(bio); |
576 | 576 | ||
577 | /* | 577 | /* |
578 | * If not a WRITE (or a discard or write zeroes), do nothing | 578 | * If not a WRITE, do nothing |
579 | */ | 579 | */ |
580 | if (!(op == REQ_OP_WRITE || op == REQ_OP_DISCARD || | 580 | if (op != REQ_OP_WRITE) |
581 | op == REQ_OP_WRITE_ZEROES)) | ||
582 | return false; | 581 | return false; |
583 | 582 | ||
584 | /* | 583 | /* |