aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Rigby <john.rigby@linaro.org>2011-10-21 11:43:36 -0600
committerJohn Rigby <john.rigby@linaro.org>2011-11-14 19:48:19 -0700
commit675b2a080e721de9142486f686bf1889177fb2b1 (patch)
treeb9a3a7ac1f27c6c318b1ff993331828d8c3f0fb7
parent68b0e603e0d446180ce18c8c873f389798df94f5 (diff)
OMAP4: Make mmc and fat conditional in spl
Size problems when trying to include usb, mmc and fat Signed-off-by: John Rigby <john.rigby@linaro.org>
-rw-r--r--arch/arm/cpu/armv7/omap-common/spl.c4
-rw-r--r--include/configs/omap4_common.h3
2 files changed, 7 insertions, 0 deletions
diff --git a/arch/arm/cpu/armv7/omap-common/spl.c b/arch/arm/cpu/armv7/omap-common/spl.c
index 281f3cd8c..f7f18b651 100644
--- a/arch/arm/cpu/armv7/omap-common/spl.c
+++ b/arch/arm/cpu/armv7/omap-common/spl.c
@@ -141,6 +141,7 @@ end:
}
}
+#ifdef CONFIG_SPL_MMC_SUPPORT
static void mmc_load_image_fat(struct mmc *mmc)
{
s32 err;
@@ -215,6 +216,7 @@ static void mmc_load_image(void)
hang();
}
}
+#endif
void jump_to_image_no_args(void)
{
@@ -237,10 +239,12 @@ void board_init_r(gd_t *id, ulong dummy)
boot_device = omap_boot_device();
debug("boot device - %d\n", boot_device);
switch (boot_device) {
+#ifdef CONFIG_SPL_MMC_SUPPORT
case BOOT_DEVICE_MMC1:
case BOOT_DEVICE_MMC2:
mmc_load_image();
break;
+#endif
default:
printf("SPL: Un-supported Boot Device - %d!!!\n", boot_device);
hang();
diff --git a/include/configs/omap4_common.h b/include/configs/omap4_common.h
index 492ab2fb9..139f53848 100644
--- a/include/configs/omap4_common.h
+++ b/include/configs/omap4_common.h
@@ -289,8 +289,11 @@
#define CONFIG_SPL_LIBCOMMON_SUPPORT
#define CONFIG_SPL_LIBDISK_SUPPORT
#define CONFIG_SPL_I2C_SUPPORT
+#ifdef CONFIG_USB_SPL
+#else
#define CONFIG_SPL_MMC_SUPPORT
#define CONFIG_SPL_FAT_SUPPORT
+#endif
#define CONFIG_SPL_LIBGENERIC_SUPPORT
#define CONFIG_SPL_SERIAL_SUPPORT
#define CONFIG_SPL_LDSCRIPT "arch/arm/cpu/armv7/omap-common/u-boot-spl.lds"