summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--common/cmd_mmc.c4
-rw-r--r--drivers/mmc/mmc.c3
-rw-r--r--include/configs/da850evm.h2
3 files changed, 5 insertions, 4 deletions
diff --git a/common/cmd_mmc.c b/common/cmd_mmc.c
index 0e3393b5f44..1d7521c3246 100644
--- a/common/cmd_mmc.c
+++ b/common/cmd_mmc.c
@@ -153,9 +153,9 @@ int do_mmcops(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
if (!mmc)
return 1;
- mmc_init(mmc);
+ rc = mmc_init(mmc);
- return 0;
+ return rc;
}
case 0:
diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c
index 346e6478e00..c0aa683a4d9 100644
--- a/drivers/mmc/mmc.c
+++ b/drivers/mmc/mmc.c
@@ -32,6 +32,7 @@
#include <linux/list.h>
#include <mmc.h>
#include <div64.h>
+#include <asm-generic/errno.h>
static struct list_head mmc_devices;
static int cur_dev_num = -1;
@@ -879,7 +880,7 @@ int mmc_init(struct mmc *mmc)
if (err) {
printf("Card did not respond to voltage select!\n");
- return UNUSABLE_ERR;
+ return ENODEV;
}
}
diff --git a/include/configs/da850evm.h b/include/configs/da850evm.h
index 812bad8f41b..73ef2c4e804 100644
--- a/include/configs/da850evm.h
+++ b/include/configs/da850evm.h
@@ -218,7 +218,7 @@
#define CONFIG_CMDLINE_TAG
#define CONFIG_SETUP_MEMORY_TAGS
#define CONFIG_BOOTARGS "mem=32M console=ttyS2,115200n8 root=/dev/mmcblk0p2 rw rootwait ip=off"
-#define CONFIG_BOOTCOMMAND "if fatload mmc 0 0xc0600000 boot.scr; then source 0xc0600000; else if fatload mmc 0 0xc0700000 uImage; then bootm c0700000; else sf probe 0; sf read 0xc0700000 0x80000 0x220000; bootm 0xc0700000; fi; fi"
+#define CONFIG_BOOTCOMMAND "if mmc rescan 0; then if fatload mmc 0 0xc0600000 boot.scr; then source 0xc0600000; else fatload mmc 0 0xc0700000 uImage; bootm c0700000; fi; else sf probe 0; sf read 0xc0700000 0x80000 0x220000; bootm 0xc0700000; fi"
#define CONFIG_BOOTDELAY 3
/*
* U-Boot commands