From: Pali Rohár Date: Mon, 23 May 2022 09:14:35 +0000 (+0200) Subject: arm: mvebu: a3720: Set BOOT_TARGET_DEVICES list to enabled peripherals X-Git-Tag: baikal/mips/sdk5.8.2~5^2~281^2~9 X-Git-Url: https://git.baikalelectronics.ru/sdk/?a=commitdiff_plain;h=289f76a62945e5582f4944e9d6523b8bb26eefb2;p=uboot.git arm: mvebu: a3720: Set BOOT_TARGET_DEVICES list to enabled peripherals This allows to compile U-Boot without some boot option for some A3720 board which does not have that peripheral. Signed-off-by: Pali Rohár Reviewed-by: Stefan Roese --- diff --git a/include/configs/mvebu_armada-37xx.h b/include/configs/mvebu_armada-37xx.h index 51f7e16ece..58c7606288 100644 --- a/include/configs/mvebu_armada-37xx.h +++ b/include/configs/mvebu_armada-37xx.h @@ -32,13 +32,43 @@ */ #define DEFAULT_ENV_IS_RW /* required for configuring default fdtfile= */ +#ifdef CONFIG_MMC +#define BOOT_TARGET_DEVICES_MMC(func, i) func(MMC, mmc, i) +#else +#define BOOT_TARGET_DEVICES_MMC(func, i) +#endif + +#ifdef CONFIG_USB_STORAGE +#define BOOT_TARGET_DEVICES_USB(func) func(USB, usb, 0) +#else +#define BOOT_TARGET_DEVICES_USB(func) +#endif + +#ifdef CONFIG_SCSI +#define BOOT_TARGET_DEVICES_SCSI(func) func(SCSI, scsi, 0) +#else +#define BOOT_TARGET_DEVICES_SCSI(func) +#endif + +#if defined(CONFIG_CMD_DHCP) && defined(CONFIG_CMD_PXE) +#define BOOT_TARGET_DEVICES_PXE(func) func(PXE, pxe, na) +#else +#define BOOT_TARGET_DEVICES_PXE(func) +#endif + +#ifdef CONFIG_CMD_DHCP +#define BOOT_TARGET_DEVICES_DHCP(func) func(DHCP, dhcp, na) +#else +#define BOOT_TARGET_DEVICES_DHCP(func) +#endif + #define BOOT_TARGET_DEVICES(func) \ - func(MMC, mmc, 1) \ - func(MMC, mmc, 0) \ - func(USB, usb, 0) \ - func(SCSI, scsi, 0) \ - func(PXE, pxe, na) \ - func(DHCP, dhcp, na) + BOOT_TARGET_DEVICES_MMC(func, 1) \ + BOOT_TARGET_DEVICES_MMC(func, 0) \ + BOOT_TARGET_DEVICES_USB(func) \ + BOOT_TARGET_DEVICES_SCSI(func) \ + BOOT_TARGET_DEVICES_PXE(func) \ + BOOT_TARGET_DEVICES_DHCP(func) #include