diff options
author | Christoph Hellwig <hch@lst.de> | 2021-11-17 07:13:58 +0100 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2021-11-29 14:34:50 +0100 |
commit | 06c8c691e2820077936e59ad334eb806e90b69eb (patch) | |
tree | a2878ddf632e5d6c84e4a75ac5f81d1cb5365ef5 /block/blk.h | |
parent | blk-mq: move blk_mq_flush_plug_list (diff) | |
download | linux-06c8c691e2820077936e59ad334eb806e90b69eb.tar.xz linux-06c8c691e2820077936e59ad334eb806e90b69eb.zip |
block: move request based cloning helpers to blk-mq.c
Keep all the request based code together.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Link: https://lore.kernel.org/r/20211117061404.331732-6-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/blk.h')
-rw-r--r-- | block/blk.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/block/blk.h b/block/blk.h index ccde6e6f1736..8a3761b6dc33 100644 --- a/block/blk.h +++ b/block/blk.h @@ -493,4 +493,14 @@ int disk_register_independent_access_ranges(struct gendisk *disk, struct blk_independent_access_ranges *new_iars); void disk_unregister_independent_access_ranges(struct gendisk *disk); +#ifdef CONFIG_FAIL_MAKE_REQUEST +bool should_fail_request(struct block_device *part, unsigned int bytes); +#else /* CONFIG_FAIL_MAKE_REQUEST */ +static inline bool should_fail_request(struct block_device *part, + unsigned int bytes) +{ + return false; +} +#endif /* CONFIG_FAIL_MAKE_REQUEST */ + #endif /* BLK_INTERNAL_H */ |