[U-Boot] [PATCH 1/2] arm: mvebu: fix boot from UART on ClearFog Base
Stefan Roese
sr at denx.de
Mon Sep 18 16:00:23 UTC 2017
Hi Baruch,
On 20.08.2017 15:46, Baruch Siach wrote:
> The ClearFog Base boot from UART when setting the DIP switches to 01001.
> Unfortunately, the SPL code sometimes fails to detect the UART boot
> method at run-time. Add an alternative SAR UART boot value to fix this.
>
> Signed-off-by: Baruch Siach <baruch at tkos.co.il>
> ---
> arch/arm/mach-mvebu/include/mach/soc.h | 1 +
> arch/arm/mach-mvebu/spl.c | 1 +
> 2 files changed, 2 insertions(+)
>
> diff --git a/arch/arm/mach-mvebu/include/mach/soc.h b/arch/arm/mach-mvebu/include/mach/soc.h
> index 0900e4008c12..44bac63b4447 100644
> --- a/arch/arm/mach-mvebu/include/mach/soc.h
> +++ b/arch/arm/mach-mvebu/include/mach/soc.h
> @@ -139,6 +139,7 @@
> #define BOOT_DEV_SEL_MASK (0x3f << BOOT_DEV_SEL_OFFS)
>
> #define BOOT_FROM_UART 0x28
> +#define BOOT_FROM_UART_ALT 0x3f
> #define BOOT_FROM_SPI 0x32
> #define BOOT_FROM_MMC 0x30
> #define BOOT_FROM_MMC_ALT 0x31
> diff --git a/arch/arm/mach-mvebu/spl.c b/arch/arm/mach-mvebu/spl.c
> index 3cf02a54cea2..4b9c41360589 100644
> --- a/arch/arm/mach-mvebu/spl.c
> +++ b/arch/arm/mach-mvebu/spl.c
> @@ -42,6 +42,7 @@ static u32 get_boot_device(void)
> return BOOT_DEVICE_MMC1;
> #endif
> case BOOT_FROM_UART:
> + case BOOT_FROM_UART_ALT:
> return BOOT_DEVICE_UART;
> case BOOT_FROM_SPI:
> default:
>
This patch produces this error for some MVEBU boards:
[stefan at stefan-work u-boot-marvell (master)]$ make db-mv784mp-gp_defconfig
HOSTCC scripts/basic/fixdep
HOSTCC scripts/kconfig/conf.o
SHIPPED scripts/kconfig/zconf.tab.c
SHIPPED scripts/kconfig/zconf.lex.c
SHIPPED scripts/kconfig/zconf.hash.c
HOSTCC scripts/kconfig/zconf.tab.o
HOSTLD scripts/kconfig/conf
#
# configuration written to .config
#
[stefan at stefan-work u-boot-marvell (master)]$ make -s -j10
arch/arm/mach-mvebu/spl.c: In function ‘get_boot_device’:
arch/arm/mach-mvebu/spl.c:45:7: error: ‘BOOT_FROM_UART_ALT’ undeclared (first use in this function)
case BOOT_FROM_UART_ALT:
^~~~~~~~~~~~~~~~~~
arch/arm/mach-mvebu/spl.c:45:7: note: each undeclared identifier is reported only once for each function it appears in
scripts/Makefile.build:280: recipe for target 'spl/arch/arm/mach-mvebu/spl.o' failed
Could you please fix this by either adding this UART_ALT for other
MVEBUs as well (AXP, I didn't check if its available), or restricting
its usage on the A38x?
Please make sure that future patches are compile clean for at least
all MVEBU targets.
Thanks,
Stefan
More information about the U-Boot
mailing list