The gendisk can be trivially deducted from the block_device.
Showing the changes to include/linux (1 of 3 files). Show all
Unified · Split
| @@ -339,7 +339,7 @@ extern dev_t blk_lookup_devt(const char *name, int partno); · 338 unmodified lines | |||
| 339 | 339 | ||
| 340 | int bdev_disk_changed(struct block_device *bdev, bool invalidate); | 340 | int bdev_disk_changed(struct block_device *bdev, bool invalidate); |
| 341 | int blk_add_partitions(struct gendisk *disk, struct block_device *bdev); | 341 | int blk_add_partitions(struct gendisk *disk, struct block_device *bdev); |
| 342 | int blk_drop_partitions(struct gendisk *disk, struct block_device *bdev); | 342 | int blk_drop_partitions(struct block_device *bdev); |
| 343 | extern void printk_all_partitions(void); | 343 | extern void printk_all_partitions(void); |
| 344 | 344 | ||
| 345 | extern struct gendisk *__alloc_disk_node(int minors, int node_id); | 345 | extern struct gendisk *__alloc_disk_node(int minors, int node_id); |