@@ -40,8 +40,10 @@ void spl_board_init(void)
u32 spl_boot_device(void)
{
u32 mode;
+ u8 boot_mode;
- switch ((zynq_slcr_get_boot_mode()) & ZYNQ_BM_MASK) {
+ boot_mode = (zynq_slcr_get_boot_mode() & ZYNQ_BM_MASK);
+ switch (boot_mode) {
#ifdef CONFIG_SPL_SPI_SUPPORT
case ZYNQ_BM_QSPI:
puts("qspi boot\n");
@@ -64,7 +66,7 @@ u32 spl_boot_device(void)
mode = BOOT_DEVICE_RAM;
break;
default:
- puts("Unsupported boot mode selected\n");
+ printf("Unsupported boot mode selected: 0x%x.\n", boot_mode);
hang();
}
When hit with an 'unsupported boot mode' error, a user would be happy to know more, or the why. What boot mode is being tried. Was it as expected. Since we know the selected boot mode at the point of failure, lets print it so we have a better chance at figuring out what went wrong. Signed-off-by: Olliver Schinagl <oliver at schinagl.nl> --- arch/arm/mach-zynq/spl.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)