]> git.baikalelectronics.ru Git - uboot.git/commitdiff
arm: mvebu: fix boot from UART on ClearFog Base
authorBaruch Siach <baruch@tkos.co.il>
Sun, 24 Sep 2017 12:50:17 +0000 (15:50 +0300)
committerStefan Roese <sr@denx.de>
Tue, 26 Sep 2017 04:53:18 +0000 (06:53 +0200)
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.

Note that this alternative value is not documented (Armada 38x Hardware
Specifications, Table 48). But experimentations showed it on the
ClearFog Base.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Stefan Roese <sr@denx.de>
arch/arm/mach-mvebu/include/mach/soc.h
arch/arm/mach-mvebu/spl.c

index cdd64fb285271031cb1af6dd1d6a9f3dcbdce1cf..1d302761f090f67ba71d498c619e6ba4471fdf75 100644 (file)
 #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
index 3cf02a54cea2664423c5e7c669ccb6228756c76d..a72a769f7c740eeb8c4fabf46964c0ba913f2e3d 100644 (file)
@@ -42,6 +42,9 @@ static u32 get_boot_device(void)
                return BOOT_DEVICE_MMC1;
 #endif
        case BOOT_FROM_UART:
+#ifdef BOOT_FROM_UART_ALT
+       case BOOT_FROM_UART_ALT:
+#endif
                return BOOT_DEVICE_UART;
        case BOOT_FROM_SPI:
        default: