mtd: block2mtd: factor the early block device open logic into a helper
authorChristoph Hellwig <hch@lst.de>
Wed, 31 May 2023 12:55:33 +0000 (14:55 +0200)
committerJens Axboe <axboe@kernel.dk>
Mon, 5 Jun 2023 17:10:10 +0000 (11:10 -0600)
commitb2baa57475e3a24bb9ad27bb9047ea3be94627f5
tree2c234b35263b8904a336040b98d5ca57e808ea8f
parent1e8c813b083c4122dfeaa5c3b11028331026e85d
mtd: block2mtd: factor the early block device open logic into a helper

Simplify add_device a bit by splitting out the cumbersome early boot logic
into a separate helper.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/r/20230531125535.676098-23-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/mtd/devices/block2mtd.c