summaryrefslogtreecommitdiffstats
path: root/block/blk.h
diff options
context:
space:
mode:
authorChristoph Hellwig2017-01-31 16:57:29 +0100
committerJens Axboe2017-01-31 22:00:34 +0100
commit57292b58ddb58689e8c3b4c6eadbef10d9ca44dd (patch)
treedd6e5af538b2f2684d2090781f668c7099a0455e /block/blk.h
parentnbd: move request validity checking into nbd_send_cmd (diff)
downloadkernel-qcow2-linux-57292b58ddb58689e8c3b4c6eadbef10d9ca44dd.tar.gz
kernel-qcow2-linux-57292b58ddb58689e8c3b4c6eadbef10d9ca44dd.tar.xz
kernel-qcow2-linux-57292b58ddb58689e8c3b4c6eadbef10d9ca44dd.zip
block: introduce blk_rq_is_passthrough
This can be used to check for fs vs non-fs requests and basically removes all knowledge of BLOCK_PC specific from the block layer, as well as preparing for removing the cmd_type field in struct request. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block/blk.h')
-rw-r--r--block/blk.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/blk.h b/block/blk.h
index 9a716b5925a4..c1bd4bf9e645 100644
--- a/block/blk.h
+++ b/block/blk.h
@@ -249,7 +249,7 @@ static inline int blk_do_io_stat(struct request *rq)
{
return rq->rq_disk &&
(rq->rq_flags & RQF_IO_STAT) &&
- (rq->cmd_type == REQ_TYPE_FS);
+ !blk_rq_is_passthrough(rq);
}
/*