summaryrefslogtreecommitdiff
path: root/cleopatre/u-boot-1.1.6/common
diff options
context:
space:
mode:
Diffstat (limited to 'cleopatre/u-boot-1.1.6/common')
-rw-r--r--cleopatre/u-boot-1.1.6/common/main.c21
1 files changed, 16 insertions, 5 deletions
diff --git a/cleopatre/u-boot-1.1.6/common/main.c b/cleopatre/u-boot-1.1.6/common/main.c
index cc4b50f615..58d3262285 100644
--- a/cleopatre/u-boot-1.1.6/common/main.c
+++ b/cleopatre/u-boot-1.1.6/common/main.c
@@ -243,27 +243,38 @@ static __inline__ int abortboot(int bootdelay)
*/
if (bootdelay >= 0) {
if (tstc()) { /* we got a key press */
+#if defined CONFIG_EAT_FIRST_BREAK
+ char c = getc ();
+ if (c != '\0')
+ abort = 1;
+ puts ("\b\b\b 0");
+#else /* CONFIG_EAT_FIRST_BREAK */
(void) getc(); /* consume input */
puts ("\b\b\b 0");
abort = 1; /* don't auto boot */
+#endif /* CONFIG_EAT_FIRST_BREAK */
}
}
#endif
while ((bootdelay > 0) && (!abort)) {
int i;
-
- --bootdelay;
+ char c;
+ --bootdelay;
/* delay 100 * 10ms */
for (i=0; !abort && i<100; ++i) {
if (tstc()) { /* we got a key press */
- abort = 1; /* don't auto boot */
- bootdelay = 0; /* no more delay */
# ifdef CONFIG_MENUKEY
menukey = getc();
# else
- (void) getc(); /* consume input */
+ c = getc(); /* consume input */
# endif
+#if defined CONFIG_EAT_FIRST_BREAK
+ if (c == '\0')
+ continue;
+#endif /* CONFIG_EAT_FIRST_BREAK */
+ abort = 1; /* don't auto boot */
+ bootdelay = 0; /* no more delay */
break;
}
udelay (10000);