]> www.infradead.org Git - users/hch/misc.git/commit
block: introduce add_disk_fwnode()
authorChristian Marangi <ansuelsmth@gmail.com>
Wed, 2 Oct 2024 22:11:43 +0000 (00:11 +0200)
committerJens Axboe <axboe@kernel.dk>
Tue, 22 Oct 2024 14:14:56 +0000 (08:14 -0600)
commit9dfd9ea93aeab57d897bb7fc7c0707f26b0b9af8
treeeb48bd5c17a191381d07546172cbf170440bbcb5
parent592e4deeab50aa71a0b20820f2376c900e920211
block: introduce add_disk_fwnode()

Introduce add_disk_fwnode() as a replacement of device_add_disk() that
permits to pass and attach a fwnode to disk dev.

This variant can be useful for eMMC that might have the partition table
for the disk defined in DT. A parser can later make use of the attached
fwnode to parse the related table and init the hardcoded partition for
the disk.

device_add_disk() is converted to a simple wrapper of add_disk_fwnode()
with the fwnode entry set as NULL.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20241002221306.4403-4-ansuelsmth@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/genhd.c
include/linux/blkdev.h