blk: Call part_init() in the post_probe() method
part_init() is currently called in every DM BLK driver, either
in its bind() or probe() method. However we can use the BLK
uclass driver's post_probe() method to do it automatically.
Update all DM BLK drivers to adopt this change.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
diff --git a/drivers/block/sandbox.c b/drivers/block/sandbox.c
index 576d049..d3b1aaa 100644
--- a/drivers/block/sandbox.c
+++ b/drivers/block/sandbox.c
@@ -142,7 +142,7 @@
goto err_file;
}
- return blk_prepare_device(dev);
+ return 0;
err_file:
os_close(fd);
err: