summaryrefslogtreecommitdiff
path: root/include/linux/blkdev.h
diff options
context:
space:
mode:
authorSong Liu <songliubraving@fb.com>2020-08-31 15:27:23 -0700
committerJens Axboe <axboe@kernel.dk>2020-09-11 16:41:30 -0600
commit7b26410b05f8c262688de8a689ba8e5d0c3cff01 (patch)
tree2e5f62110986ddd52f8fcce4c00f7d5fe2c466fb /include/linux/blkdev.h
parent285008501c65a3fcee05d2c2c26cbf629ceff2f0 (diff)
block: introduce part_[begin|end]_io_acct
These functions can be used to enable iostat for partitions on devices like md, bcache. Signed-off-by: Song Liu <songliubraving@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include/linux/blkdev.h')
-rw-r--r--include/linux/blkdev.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index 37ec5a73d027..5bd96fbab9b4 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -1933,6 +1933,11 @@ unsigned long disk_start_io_acct(struct gendisk *disk, unsigned int sectors,
void disk_end_io_acct(struct gendisk *disk, unsigned int op,
unsigned long start_time);
+unsigned long part_start_io_acct(struct gendisk *disk, struct hd_struct **part,
+ struct bio *bio);
+void part_end_io_acct(struct hd_struct *part, struct bio *bio,
+ unsigned long start_time);
+
/**
* bio_start_io_acct - start I/O accounting for bio based drivers
* @bio: bio to start account for