diff options
author | Tony Dinh | 2023-03-14 17:24:26 -0700 |
---|---|---|
committer | Tom Rini | 2023-03-22 12:51:08 -0400 |
commit | c5f4cdb8eb60cbfc71b356204245a046c74a30c1 (patch) | |
tree | 5405a399cb6f30e167e096766d75a378f99f30f3 /arch/arm/lib | |
parent | 45156edb168328602e494a00c37e2c4876087e0f (diff) |
console: Use flush() before panic and reset
To make sure the panic and the reset messages will go out, console flush() should be used.
Sleep periods do not work in early u-boot phase when timer driver is not initialized yet.
Reference: https://lists.denx.de/pipermail/u-boot/2023-March/512233.html
Signed-off-by: Tony Dinh <mibodhi@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Stefan Roese <sr@denx.de>
Diffstat (limited to 'arch/arm/lib')
-rw-r--r-- | arch/arm/lib/reset.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm/lib/reset.c b/arch/arm/lib/reset.c index 95169bae1c1..3e051e36f12 100644 --- a/arch/arm/lib/reset.c +++ b/arch/arm/lib/reset.c @@ -25,6 +25,7 @@ #include <cpu_func.h> #include <irq_func.h> #include <linux/delay.h> +#include <stdio.h> __weak void reset_misc(void) { @@ -33,8 +34,7 @@ __weak void reset_misc(void) int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { puts ("resetting ...\n"); - - mdelay(50); /* wait 50 ms */ + flush(); disable_interrupts(); |