diff mbox

[U-Boot,v2,11/13] dm: spl: mmc: Support raw partitions with CONFIG_BLK

Message ID 1467760220-8615-12-git-send-email-sjg@chromium.org
State Accepted
Commit 1e2b3ef8653417f296ee23f32c28abfc086529dd
Delegated to: Simon Glass
Headers show

Commit Message

Simon Glass July 5, 2016, 11:10 p.m. UTC
Fix up the call in mmc_load_image_raw_partition() to use the correct
function to obtain the MMC device, so that this code can support driver
model.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

Changes in v2:
- Add new patch to support raw partitions with CONFIG_BLK

 common/spl/spl_mmc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Simon Glass July 17, 2016, 9 p.m. UTC | #1
On 5 July 2016 at 17:10, Simon Glass <sjg@chromium.org> wrote:
> Fix up the call in mmc_load_image_raw_partition() to use the correct
> function to obtain the MMC device, so that this code can support driver
> model.
>
> Signed-off-by: Simon Glass <sjg@chromium.org>
> ---
>
> Changes in v2:
> - Add new patch to support raw partitions with CONFIG_BLK
>
>  common/spl/spl_mmc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied to u-boot-dm.
diff mbox

Patch

diff --git a/common/spl/spl_mmc.c b/common/spl/spl_mmc.c
index 6b3e9e4..7c7f329 100644
--- a/common/spl/spl_mmc.c
+++ b/common/spl/spl_mmc.c
@@ -155,7 +155,7 @@  static int mmc_load_image_raw_partition(struct mmc *mmc, int partition)
 	disk_partition_t info;
 	int err;
 
-	err = part_get_info(&mmc->block_dev, partition, &info);
+	err = part_get_info(mmc_get_blk_desc(mmc), partition, &info);
 	if (err) {
 #ifdef CONFIG_SPL_LIBCOMMON_SUPPORT
 		puts("spl: partition error\n");