*/
#if defined(CONFIG_BOOTDELAY) && (CONFIG_BOOTDELAY >= 0)
static __inline__ int abortboot(int bootdelay){
-#ifdef CONFIG_AUTOBOOT_STOP_CHAR
char stopc;
-#endif
int abort = 0;
#ifdef CONFIG_SILENT_CONSOLE
/* delay 100 * 10ms */
for(i = 0; !abort && i < 100; ++i){
-
/* we got a key press */
if(tstc()){
-#ifdef CONFIG_AUTOBOOT_STOP_CHAR
stopc = getc();
+#ifdef CONFIG_AUTOBOOT_STOP_CHAR
if (stopc == CONFIG_AUTOBOOT_STOP_CHAR) {
+#else
+ if (stopc != 0) {
+#endif
abort = 1;
bootdelay = 0;
break;
}
-#else
- /* don't auto boot */
- abort = 1;
- /* no more delay */
- bootdelay = 0;
- /* consume input */
- (void) getc();
- break;
-#endif /* CONFIG_AUTOBOOT_STOP_CHAR */
}
udelay(10000);
}