mmc: block: cleanup gendisk creation
authorChristoph Hellwig <hch@lst.de>
Mon, 9 Aug 2021 06:40:22 +0000 (08:40 +0200)
committerJens Axboe <axboe@kernel.dk>
Thu, 12 Aug 2021 16:29:35 +0000 (10:29 -0600)
commita94dcfce70d3f4f6cd99f3b43d74305e3a4f3983
treea555d103b5989b32601eec39fa77f70b61467238
parent29e6a5e01d0adae52a2859ed39cb9e607430e011
mmc: block: cleanup gendisk creation

Restructure mmc_blk_probe to avoid a failure path with a half created
disk.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Acked-by: Ulf Hansson <ulf.hansson@linaro.org>
Link: https://lore.kernel.org/r/20210809064028.1198327-3-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/mmc/core/block.c