summaryrefslogtreecommitdiffstats
path: root/fs/block_dev.c
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2018-08-29 10:36:56 -0600
committerJens Axboe <axboe@kernel.dk>2018-11-07 13:45:00 -0700
commitd1e36282b0bbd5de6a9c4d5275e94ef3b3438f48 (patch)
tree80328ea0526706f873113125f3bbee640615d3f2 /fs/block_dev.c
parent3b6592f70ad7b4c24dd3eb2ac9bbe3353d02c992 (diff)
downloadlinux-d1e36282b0bbd5de6a9c4d5275e94ef3b3438f48.tar.bz2
block: add REQ_HIPRI and inherit it from IOCB_HIPRI
We use IOCB_HIPRI to poll for IO in the caller instead of scheduling. This information is not available for (or after) IO submission. The driver may make different queue choices based on the type of IO, so make the fact that we will poll for this IO known to the lower layers as well. Reviewed-by: Hannes Reinecke <hare@suse.com> Reviewed-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'fs/block_dev.c')
-rw-r--r--fs/block_dev.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/block_dev.c b/fs/block_dev.c
index a80b4f0ee7c4..c039abfb2052 100644
--- a/fs/block_dev.c
+++ b/fs/block_dev.c
@@ -232,6 +232,8 @@ __blkdev_direct_IO_simple(struct kiocb *iocb, struct iov_iter *iter,
bio.bi_opf = dio_bio_write_op(iocb);
task_io_account_write(ret);
}
+ if (iocb->ki_flags & IOCB_HIPRI)
+ bio.bi_opf |= REQ_HIPRI;
qc = submit_bio(&bio);
for (;;) {