aboutsummaryrefslogtreecommitdiff
path: root/include/linux/blkdev.h
diff options
context:
space:
mode:
authorGravatar Ming Lei <ming.lei@redhat.com> 2022-03-04 21:08:03 -0500
committerGravatar Mike Snitzer <snitzer@redhat.com> 2022-03-09 12:21:35 -0500
commit69fe0f29892077f14b56e2a479b6bcf533209d53 (patch)
tree26b37dbcc06ed8b12ff07482eb2fe060b89d3e1d /include/linux/blkdev.h
parentdm mpath: use DMINFO instead of printk with KERN_INFO (diff)
downloadlinux-69fe0f29892077f14b56e2a479b6bcf533209d53.tar.gz
linux-69fe0f29892077f14b56e2a479b6bcf533209d53.tar.bz2
linux-69fe0f29892077f14b56e2a479b6bcf533209d53.zip
block: add ->poll_bio to block_device_operations
Prepare for supporting IO polling for bio-based driver. Add ->poll_bio callback so that bio-based driver can provide their own logic for polling bio. Also fix ->submit_bio_bio typo in comment block above __submit_bio_noacct. Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Jens Axboe <axboe@kernel.dk> Signed-off-by: Ming Lei <ming.lei@redhat.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'include/linux/blkdev.h')
-rw-r--r--include/linux/blkdev.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index f757f9c2871f..51f1b1ddbed2 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -1455,6 +1455,8 @@ enum blk_unique_id {
struct block_device_operations {
void (*submit_bio)(struct bio *bio);
+ int (*poll_bio)(struct bio *bio, struct io_comp_batch *iob,
+ unsigned int flags);
int (*open) (struct block_device *, fmode_t);
void (*release) (struct gendisk *, fmode_t);
int (*rw_page)(struct block_device *, sector_t, struct page *, unsigned int);