]> git.ipfire.org Git - thirdparty/linux.git/commit - include/linux/blkdev.h
block: adapt blk_mq_plug() to not plug for writes that require a zone lock
authorPankaj Raghav <p.raghav@samsung.com>
Thu, 29 Sep 2022 07:47:44 +0000 (09:47 +0200)
committerJens Axboe <axboe@kernel.dk>
Thu, 29 Sep 2022 13:45:47 +0000 (07:45 -0600)
commit8cafdb5ab94cda3ebb0975be16e2d564a05132ea
treee2ca60d8a274c3bd3d5a8e673428ac2ba267ade8
parentdfdcbf1fc3ecc395e56afcacf0aa601dfadebd28
block: adapt blk_mq_plug() to not plug for writes that require a zone lock

The current implementation of blk_mq_plug() disables plugging for all
operations that involves a transfer to the device as we just check if
the last bit in op_is_write() function.

Modify blk_mq_plug() to disable plugging only for REQ_OP_WRITE and
REQ_OP_WRITE_ZEROS as they might require a zone lock.

Suggested-by: Christoph Hellwig <hch@lst.de>
Suggested-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Pankaj Raghav <p.raghav@samsung.com>
Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Link: https://lore.kernel.org/r/20220929074745.103073-2-p.raghav@samsung.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-mq.h
block/blk-zoned.c
include/linux/blkdev.h