[PATCH 19/22] spl: Provide more information on boot failure

Simon Glass sjg at chromium.org
Sat Jul 17 22:39:09 CEST 2021


If SPL fails to boot, try to provide an error code to indicate what is
wrong. For example, if a uclass is missing, this can return -EPFNOSUPPORT
(-96) which provides useful information.

Add a helper for accessing the image-loader name so we can drop the use
of #ifdefs in this code.

Put this feature behind a CONFIG_SHOW_ERRORS option to avoid increasing
the code size.

Signed-off-by: Simon Glass <sjg at chromium.org>
---

 common/spl/Kconfig | 10 ++++++++++
 common/spl/spl.c   | 48 ++++++++++++++++++++++++++++++----------------
 include/spl.h      | 10 ++++++++++
 3 files changed, 52 insertions(+), 16 deletions(-)

Applied to u-boot-dm, thanks!


More information about the U-Boot mailing list