summaryrefslogtreecommitdiff
path: root/common/env_mmc.c
diff options
context:
space:
mode:
authorTerry Lv <r65388@freescale.com>2010-03-29 12:01:00 +0800
committerTerry Lv <r65388@freescale.com>2010-03-30 15:38:37 +0800
commit6dd2709514d0f5d151529681efa3430adf09a513 (patch)
tree85e9f5b6e4708b4c1d59b46be73b819fe158686a /common/env_mmc.c
parent76ca5d255b4920986c66c1a66e826420719f433c (diff)
downloadu-boot-imx-6dd2709514d0f5d151529681efa3430adf09a513.zip
u-boot-imx-6dd2709514d0f5d151529681efa3430adf09a513.tar.gz
u-boot-imx-6dd2709514d0f5d151529681efa3430adf09a513.tar.bz2
ENGR00119033: System can not find MMC/SD card in SD slot 1
System can not find MMC/SD card in SD slot 1 when booting from Uboot. Signed-off-by: Terry Lv <r65388@freescale.com>
Diffstat (limited to 'common/env_mmc.c')
-rw-r--r--common/env_mmc.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/common/env_mmc.c b/common/env_mmc.c
index 8c98ad2..79b5ed3 100644
--- a/common/env_mmc.c
+++ b/common/env_mmc.c
@@ -1,5 +1,5 @@
/*
- * (C) Copyright 2008-2009 Freescale Semiconductor, Inc.
+ * (C) Copyright 2008-2010 Freescale Semiconductor, Inc.
* (C) Copyright 2000-2006
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
@@ -112,12 +112,12 @@ inline int write_env(struct mmc *mmc, unsigned long size,
int saveenv(void)
{
- struct mmc *mmc = find_mmc_device(0);
+ struct mmc *mmc = find_mmc_device(CONFIG_SYS_MMC_ENV_DEV);
if (init_mmc_for_env(mmc))
return 1;
- puts("Writing to MMC... ");
+ printf("Writing to MMC(%d)... ", CONFIG_SYS_MMC_ENV_DEV);
if (write_env(mmc, CONFIG_ENV_SIZE, \
CONFIG_ENV_OFFSET, env_ptr)) {
puts("failed\n");
@@ -147,7 +147,7 @@ inline int read_env(struct mmc *mmc, unsigned long size,
void env_relocate_spec(void)
{
#if !defined(ENV_IS_EMBEDDED)
- struct mmc *mmc = find_mmc_device(0);
+ struct mmc *mmc = find_mmc_device(CONFIG_SYS_MMC_ENV_DEV);
if (init_mmc_for_env(mmc))
return;