aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/bcache/request.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2016-11-01 09:40:05 -0400
committerJens Axboe <axboe@fb.com>2016-11-01 11:43:26 -0400
commit83b5df67c50995ed93b2b7adac3f002ad8bb6069 (patch)
tree1a4d54bf32b13f1235e45117e45299e6e8380a83 /drivers/md/bcache/request.c
parent03ea4afa67566a3c4e83c0fde8bf0c48f16ac1a3 (diff)
bcache: use op_is_sync to check for synchronous requests
(and remove one layer of masking for the op_is_write call next to it). Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'drivers/md/bcache/request.c')
-rw-r--r--drivers/md/bcache/request.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/md/bcache/request.c b/drivers/md/bcache/request.c
index 40ffe5e424b3..e8a2b693c928 100644
--- a/drivers/md/bcache/request.c
+++ b/drivers/md/bcache/request.c
@@ -404,8 +404,8 @@ static bool check_should_bypass(struct cached_dev *dc, struct bio *bio)
404 404
405 if (!congested && 405 if (!congested &&
406 mode == CACHE_MODE_WRITEBACK && 406 mode == CACHE_MODE_WRITEBACK &&
407 op_is_write(bio_op(bio)) && 407 op_is_write(bio->bi_opf) &&
408 (bio->bi_opf & REQ_SYNC)) 408 op_is_sync(bio->bi_opf))
409 goto rescale; 409 goto rescale;
410 410
411 spin_lock(&dc->io_lock); 411 spin_lock(&dc->io_lock);