Skip to contentSkip to conversation

Fix autoboot countdown printing wrong

PATCH In review David Zang 2 participants 2 messages Jul 7, 2025 – Jul 14, 2025

lore
Share & tools
lore

David Zang

author
#0 lore raw

PATCH 1/1 Fix autoboot countdown printing wrong

Originally when bootdelay >99, the countdown breaks. Setting bootdelay at 101 or bigger will trigger this error.

---
 common/autoboot.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
common/autoboot.c +1 -1
index 0a254498d40..e39f4a32f95 100644
@@ -410,7 +410,7 @@ static int abortboot_single_key(int bootdelay)
 			udelay(10000);
 		} while (!abort && get_timer(ts) < 1000);
 
-		printf("\b\b\b%2d ", bootdelay);
+		printf("\rHit any key to stop autoboot: %1d\033[K", bootdelay);
 	}
 
 	putc('\n');
Signature · 1 line
2.34.1
#1 lore raw
Quoted 4 lines · David Zang

Originally when bootdelay >99, the countdown breaks. Setting bootdelay at 101 or bigger will trigger this error.

Applied to u-boot/master, thanks!

[1/1] Fix autoboot countdown printing wrong

      commit: 5f70be08b015a5dc2296ea0073ecc8165fc48588
Signature · 1 line
Tom