
Sometimes (for debugging purposes mostly but also to overcome some hardware limitations) it's desirable to be able to force boot device to some fixed value. This patch adds this possibility via CONFIG_SPL_FORCE_BOOT_DEVICE option.
Signed-off-by: Ilya Yanok ilya.yanok@cogentembedded.com --- common/spl/spl.c | 4 ++++ 1 file changed, 4 insertions(+)
diff --git a/common/spl/spl.c b/common/spl/spl.c index 6a5a136..37f4d38 100644 --- a/common/spl/spl.c +++ b/common/spl/spl.c @@ -177,7 +177,11 @@ void board_init_r(gd_t *dummy1, ulong dummy2) spl_board_init(); #endif
+#ifdef CONFIG_SPL_FORCE_BOOT_DEVICE + boot_device = CONFIG_SPL_FORCE_BOOT_DEVICE; +#else boot_device = spl_boot_device(); +#endif debug("boot device - %d\n", boot_device); switch (boot_device) { #ifdef CONFIG_SPL_RAM_DEVICE