OSDN Git Service

block: introduce blk_req_zone_write_trylock
authorJohannes Thumshirn <johannes.thumshirn@wdc.com>
Tue, 12 May 2020 08:55:48 +0000 (17:55 +0900)
committerJens Axboe <axboe@kernel.dk>
Wed, 13 May 2020 02:36:28 +0000 (20:36 -0600)
commit1392d37018d4f68c5bb2c98dae9a018b73926865
tree9bd4b688838406c57655576a41fbad66ab121598
parent0512a75b98f847c2e9a4b664013424e603e202f7
block: introduce blk_req_zone_write_trylock

Introduce blk_req_zone_write_trylock(), which either grabs the write-lock
for a sequential zone or returns false, if the zone is already locked.

Signed-off-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-zoned.c
include/linux/blkdev.h