summaryrefslogtreecommitdiff
path: root/include/configs/sunxi-common.h
diff options
context:
space:
mode:
authorChen-Yu Tsai <wens@csie.org>2014-10-07 15:11:49 +0800
committerHans de Goede <hdegoede@redhat.com>2014-10-24 09:35:38 +0200
commit41f8e9f5c48ec919b1a44591008ddc3e5a045228 (patch)
tree31641709301e0eb30a88ee0806a4bcbf16a063fb /include/configs/sunxi-common.h
parente71189168553ddf59f25132027d662458db8f3c5 (diff)
downloadu-boot-imx-41f8e9f5c48ec919b1a44591008ddc3e5a045228.zip
u-boot-imx-41f8e9f5c48ec919b1a44591008ddc3e5a045228.tar.gz
u-boot-imx-41f8e9f5c48ec919b1a44591008ddc3e5a045228.tar.bz2
ARM: sunxi: Fix build break when CONFIG_MMC is not defined
BOOT_TARGET_DEVICES includes MMC unconditionally. This breaks when CONFIG_CMD_MMC is not defined. Use a secondary macro to conditionally include it when CONFIG_MMC is enabled, as we do for CONFIG_AHCI. This is used when we want to use uart0 from port F, which conflicts with mmc0. Signed-off-by: Chen-Yu Tsai <wens@csie.org> Acked-by: Ian Campbell <ijc@hellion.org.uk>
Diffstat (limited to 'include/configs/sunxi-common.h')
-rw-r--r--include/configs/sunxi-common.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/include/configs/sunxi-common.h b/include/configs/sunxi-common.h
index 5f54c01..d55e4ca 100644
--- a/include/configs/sunxi-common.h
+++ b/include/configs/sunxi-common.h
@@ -226,6 +226,12 @@
"pxefile_addr_r=0x43200000\0" \
"ramdisk_addr_r=0x43300000\0"
+#ifdef CONFIG_MMC
+#define BOOT_TARGET_DEVICES_MMC(func) func(MMC, mmc, 0)
+#else
+#define BOOT_TARGET_DEVICES_MMC(func)
+#endif
+
#ifdef CONFIG_AHCI
#define BOOT_TARGET_DEVICES_SCSI(func) func(SCSI, scsi, 0)
#else
@@ -239,7 +245,7 @@
#endif
#define BOOT_TARGET_DEVICES(func) \
- func(MMC, mmc, 0) \
+ BOOT_TARGET_DEVICES_MMC(func) \
BOOT_TARGET_DEVICES_SCSI(func) \
BOOT_TARGET_DEVICES_USB(func) \
func(PXE, pxe, na) \