mx25 clocks: Fix MXC_FEC_CLK
[platform/kernel/u-boot.git] / common / main.c
index d96ba0a..9507cec 100644 (file)
@@ -114,6 +114,11 @@ int abortboot(int bootdelay)
        u_int presskey_max = 0;
        u_int i;
 
+#ifndef CONFIG_ZERO_BOOTDELAY_CHECK
+       if (bootdelay == 0)
+               return 0;
+#endif
+
 #  ifdef CONFIG_AUTOBOOT_PROMPT
        printf(CONFIG_AUTOBOOT_PROMPT);
 #  endif
@@ -217,7 +222,8 @@ int abortboot(int bootdelay)
 #ifdef CONFIG_MENUPROMPT
        printf(CONFIG_MENUPROMPT);
 #else
-       printf("Hit any key to stop autoboot: %2d ", bootdelay);
+       if (bootdelay >= 0)
+               printf("Hit any key to stop autoboot: %2d ", bootdelay);
 #endif
 
 #if defined CONFIG_ZERO_BOOTDELAY_CHECK
@@ -334,7 +340,7 @@ void main_loop (void)
                int prev = disable_ctrlc(1);    /* disable Control C checking */
 # endif
 
-               run_command(p, 0);
+               run_command_list(p, -1, 0);
 
 # ifdef CONFIG_AUTOBOOT_KEYED
                disable_ctrlc(prev);    /* restore Control C checking */
@@ -377,12 +383,12 @@ void main_loop (void)
 
        debug ("### main_loop: bootcmd=\"%s\"\n", s ? s : "<UNDEFINED>");
 
-       if (bootdelay >= 0 && s && !abortboot (bootdelay)) {
+       if (bootdelay != -1 && s && !abortboot(bootdelay)) {
 # ifdef CONFIG_AUTOBOOT_KEYED
                int prev = disable_ctrlc(1);    /* disable Control C checking */
 # endif
 
-               run_command(s, 0);
+               run_command_list(s, -1, 0);
 
 # ifdef CONFIG_AUTOBOOT_KEYED
                disable_ctrlc(prev);    /* restore Control C checking */
@@ -393,7 +399,7 @@ void main_loop (void)
        if (menukey == CONFIG_MENUKEY) {
                s = getenv("menucmd");
                if (s)
-                       run_command(s, 0);
+                       run_command_list(s, -1, 0);
        }
 #endif /* CONFIG_MENUKEY */
 #endif /* CONFIG_BOOTDELAY */