summaryrefslogtreecommitdiff
path: root/block/blk.h
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2020-11-27 18:43:51 +0300
committerJens Axboe <axboe@kernel.dk>2020-12-02 00:53:40 +0300
commit0d02129e76edf91cf04fabf1efbc3a9a1f1d729a (patch)
tree20fd7e1e54d4430038eb74d8e276decee65ee7c3 /block/blk.h
parent9499ffc7521742e3fea32f6ac6c1213b6fc4e914 (diff)
downloadlinux-0d02129e76edf91cf04fabf1efbc3a9a1f1d729a.tar.xz
block: merge struct block_device and struct hd_struct
Instead of having two structures that represent each block device with different life time rules, merge them into a single one. This also greatly simplifies the reference counting rules, as we can use the inode reference count as the main reference count for the new struct block_device, with the device model reference front ending it for device model interaction. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Jan Kara <jack@suse.cz> Reviewed-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/blk.h')
-rw-r--r--block/blk.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/blk.h b/block/blk.h
index 9657c6da7c77..98f0b1ae2641 100644
--- a/block/blk.h
+++ b/block/blk.h
@@ -356,7 +356,7 @@ char *disk_name(struct gendisk *hd, int partno, char *buf);
#define ADDPART_FLAG_NONE 0
#define ADDPART_FLAG_RAID 1
#define ADDPART_FLAG_WHOLEDISK 2
-void delete_partition(struct hd_struct *part);
+void delete_partition(struct block_device *part);
int bdev_add_partition(struct block_device *bdev, int partno,
sector_t start, sector_t length);
int bdev_del_partition(struct block_device *bdev, int partno);