spl: Avoid printing boot device if silent console is enabled
PATCH 1/2 spl: Avoid printing boot device if silent console is enabled
This avoid emitting message if silent console is in use, otherwise it pollutes the output and user desires a quiet console
---
common/spl/spl.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
common/spl/spl.c +3 -1
@@ -552,7 +552,9 @@ static int boot_from_devices(struct spl_image_info *spl_image,struct spl_image_loader *loader; loader =spl_ll_find_loader (spl_boot_list[i]); -#if defined(CONFIG_SPL_SERIAL_SUPPORT ) && defined(CONFIG_SPL_LIBCOMMON_SUPPORT ) +#if defined(CONFIG_SPL_SERIAL_SUPPORT ) \ + && defined(CONFIG_SPL_LIBCOMMON_SUPPORT ) \ + && !defined(CONFIG_SILENT_CONSOLE )if (loader)printf ("Trying to boot from %s\n" , loader->name);else
Signature · 1 line
2.28.0
PATCH 2/2 spl: Add SPL_SERIAL as requirement for SDP_USB_SDP
The USB SDP protocol require the SPL serial support to allow the build to succeed.
---
common/spl/Kconfig | 1 + 1 file changed, 1 insertion(+)
common/spl/Kconfig +1 -0
@@ -1237,6 +1237,7 @@ endchoice config SPL_USB_SDP_SUPPORT bool "Support SDP (Serial Download Protocol)" + depends on SPL_SERIAL_SUPPORT help Enable Serial Download Protocol (SDP) device support in SPL. This allows to download images into memory and execute (jump to) them
Signature · 1 line
2.28.0
PATCH 2/2 spl: Add SPL_SERIAL as requirement for SDP_USB_SDP
Quoted 4 lines · Otavio Salvador
The USB SDP protocol require the SPL serial support to allow the build to succeed.
Signed-off-by Otavio Salvador <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 659 bytes Desc: not available URL: <https://lists.denx.de/pipermail/u-boot/attachments/20201014/95a8456a/attachment.sig>
PATCH 1/2 spl: Avoid printing boot device if silent console is enabled
In reply to Otavio SalvadorHi Otavio,
Quoted 15 lines · Otavio Salvador
This avoid emitting message if silent console is in use, otherwise it pollutes the output and user desires a quiet console
Signed-off-by Otavio Salvador <[email protected]>---
common/spl/spl.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)common/spl/spl.c +0
-0
common/spl/spl.c static int boot_from_devices(struct spl_image_info *spl_image, · line 560
Quoted 10 lines
common/spl/spl.c +3
-1@@ -552,7 +552,9 @@ static int boot_from_devices(struct spl_image_info *spl_image,struct spl_image_loader *loader; loader =spl_ll_find_loader (spl_boot_list[i]); -#if defined(CONFIG_SPL_SERIAL_SUPPORT ) && defined(CONFIG_SPL_LIBCOMMON_SUPPORT ) +#if defined(CONFIG_SPL_SERIAL_SUPPORT ) \ + && defined(CONFIG_SPL_LIBCOMMON_SUPPORT ) \ + && !defined(CONFIG_SILENT_CONSOLE )if (loader)printf ("Trying to boot from %s\n" , loader->name);else
Wouldn't it be better, to add this CONFIG_SILENT_CONSOLE check to the console / printf function itself instead of adding it to all callers?
Thanks,
Stefan
PATCH 1/2 spl: Avoid printing boot device if silent console is enabled
Em qua., 30 de set. de 2020 ?s 02:23, Stefan Roese <[email protected]> escreveu:
Quoted 4 lines · Otavio Salvador
Wouldn't it be better, to add this
CONFIG_SILENT_CONSOLEcheck to the console / printf function itself instead of adding it to all callers?
I believe in critical errors and like, it is important to print so I'd say that using a more controlled "hide" mechanism is good.
Signature · 3 lines
Otavio Salvador O.S. Systems http://www.ossystems.com.br http://code.ossystems.com.br Mobile: +55 (53) 9 9981-7854 Mobile: +1 (347) 903-9750
PATCH 1/2 spl: Avoid printing boot device if silent console is enabled
Quoted 8 lines · Otavio Salvador
Em qua., 30 de set. de 2020 ?s 02:23, Stefan Roese <[email protected]> escreveu:
Quoted 4 lines · Otavio Salvador
Wouldn't it be better, to add this
CONFIG_SILENT_CONSOLEcheck to the console / printf function itself instead of adding it to all callers?I believe in critical errors and like, it is important to print so I'd say that using a more controlled "hide" mechanism is good.
Agreed. I forgot about that.
Thanks,
Stefan