summaryrefslogtreecommitdiff
path: root/block
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2016-10-20 15:12:09 +0200
committerLeonard Crestez <leonard.crestez@nxp.com>2018-08-24 12:41:33 +0300
commite99b15723885b2224ee9b6b49ff85b55de382f09 (patch)
treebf9d633054dc5f2dff2983bb54c6acb8ca1f33f5 /block
parent9e0ee3e756e1bf28299a5d597fcc5aadf238c138 (diff)
block: remove bio_is_rw
With the addition of the zoned operations the tests in this function became incorrect. But I think it's much better to just open code the allow operations in the only caller anyway. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Shaun Tancheff <shaun.tancheff@seagate.com> Signed-off-by: Jens Axboe <axboe@fb.com> (cherry picked from commit c4aebd0332da831a3403faf2035af45059ab6b7c)
Diffstat (limited to 'block')
-rw-r--r--block/bio-integrity.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/bio-integrity.c b/block/bio-integrity.c
index 80dedde0de73..b5009a896a7f 100644
--- a/block/bio-integrity.c
+++ b/block/bio-integrity.c
@@ -172,7 +172,7 @@ bool bio_integrity_enabled(struct bio *bio)
{
struct blk_integrity *bi = bdev_get_integrity(bio->bi_bdev);
- if (!bio_is_rw(bio))
+ if (bio_op(bio) != REQ_OP_READ && bio_op(bio) != REQ_OP_WRITE)
return false;
if (!bio_sectors(bio))