]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
[new uImage] Respect autostart setting in linux bootm
authorKumar Gala <galak@kernel.crashing.org>
Thu, 28 Feb 2008 03:51:51 +0000 (21:51 -0600)
committerMarian Balakowicz <m8@semihalf.com>
Fri, 29 Feb 2008 12:15:56 +0000 (13:15 +0100)
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Acked-by: Marian Balakowicz <m8@semihalf.com>
lib_arm/bootm.c
lib_avr32/bootm.c
lib_blackfin/bootm.c
lib_i386/bootm.c
lib_m68k/bootm.c
lib_microblaze/bootm.c
lib_mips/bootm.c
lib_nios2/bootm.c
lib_ppc/bootm.c
lib_sh/bootm.c

index e1a9ee28714757db57d19b0241025b574b67f930..77d35fcc656bc2b6eeeda8243afc67f47571c44d 100644 (file)
@@ -133,6 +133,9 @@ void do_bootm_linux (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],
        setup_end_tag (bd);
 #endif
 
+       if (!images->autostart)
+               return ;
+
        /* we assume that the kernel is in place */
        printf ("\nStarting kernel ...\n\n");
 
index 69a69dfa6e831feacb7a7486dbb20e90a75ffcb5..918e4cfadf5a03c2c2625a262804b7e39da60416 100644 (file)
@@ -214,6 +214,9 @@ void do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],
        params = setup_ethernet_tags(params);
        setup_end_tag(params);
 
+       if (!images->autostart)
+               return ;
+
        printf("\nStarting kernel at %p (params at %p)...\n\n",
               theKernel, params_start);
 
index 26ac88b267bbe506c25a19c3d6cc6997c0979613..33979a9fb2ce131752ffbc10c2a08f82e4a335ef 100644 (file)
@@ -53,6 +53,9 @@ void do_bootm_linux(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[],
        char    *cmdline;
        ulong   ep = 0;
 
+       if (!images->autostart)
+               return ;
+
 #ifdef SHARED_RESOURCES
        swap_to(FLASH);
 #endif
index aea58d178b966ece87235da4ef6803b25bab7532..89a423c24375591a283b04388c4ca5dc79d7e68e 100644 (file)
@@ -72,6 +72,9 @@ void do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],
 
        }
 
+       if (!images->autostart)
+               return ;
+
 #ifdef DEBUG
        printf ("## Transferring control to Linux (at address %08x) ...\n",
                (u32)base_ptr);
index eca044ecead67be3db6951a6677610b8c6cc24f5..e12d1d4aaddea8f2c305e2809ec5039dd57eb727 100644 (file)
@@ -127,6 +127,8 @@ void do_bootm_linux(cmd_tbl_t * cmdtp, int flag,
 
        show_boot_progress (15);
 
+       if (!images->autostart)
+               return;
        /*
         * Linux Kernel Parameters (passing board info data):
         *   r3: ptr to board info data
@@ -140,7 +142,8 @@ void do_bootm_linux(cmd_tbl_t * cmdtp, int flag,
        return ;
 
 error:
-       do_reset (cmdtp, flag, argc, argv);
+       if (images->autostart)
+               do_reset (cmdtp, flag, argc, argv);
        return ;
 }
 
index 5881df64f6f23c36ad8cf74ae4bcdb868f6c23d9..99c453369d2c433b66b7f20bda18e05d45b56d92 100644 (file)
@@ -63,5 +63,8 @@ void do_bootm_linux (cmd_tbl_t * cmdtp, int flag, int argc, char *argv[],
                (ulong) theKernel);
 #endif
 
+       if (!images->autostart)
+               return ;
+
        theKernel (commandline);
 }
index 998aa22c3484ba3ae795013617f3b638303e004a..39869c18008bee9d9ce381290bb31b05b0700074 100644 (file)
@@ -106,6 +106,9 @@ void do_bootm_linux (cmd_tbl_t * cmdtp, int flag, int argc, char *argv[],
        sprintf (env_buf, "0x%X", (uint) (gd->bd->bi_flashsize));
        linux_env_set ("flash_size", env_buf);
 
+       if (!images->autostart)
+               return ;
+
        /* we assume that the kernel is in place */
        printf ("\nStarting kernel ...\n\n");
 
index 70d2bb07696fdf00baeee40f5f3b3288d3b5d3f9..4b940cb6195108b0ccfb6b379d7044d859680018 100644 (file)
@@ -46,6 +46,9 @@ void do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],
        }
        void (*kernel)(void) = (void (*)(void))ep;
 
+       if (!images->autostart)
+               return ;
+
        /* For now we assume the Microtronix linux ... which only
         * needs to be called ;-)
         */
index 59cc2a44718ebf83c9d9a60c58f3660c65d6d5b4..1afef46df7531bbd7467b3e419c4d93af4775fc1 100644 (file)
@@ -242,6 +242,8 @@ do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],
 #if defined(CFG_INIT_RAM_LOCK) && !defined(CONFIG_E500)
        unlock_ram_in_cache();
 #endif
+       if (!images->autostart)
+               return ;
 
 #if defined(CONFIG_OF_LIBFDT)
        if (of_flat_tree) {     /* device tree; boot new style */
@@ -270,7 +272,8 @@ do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],
        return ;
 
 error:
-       do_reset (cmdtp, flag, argc, argv);
+       if (images->autostart)
+               do_reset (cmdtp, flag, argc, argv);
        return ;
 }
 
index de5c9eaf389ce6898b910183aaa878899b61eb55..8055841d2fcda9f5fd6c8bd0962c184438a70bdd 100644 (file)
@@ -79,6 +79,9 @@ void do_bootm_linux (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],
        }
        void (*kernel) (void) = (void (*)(void))ep;
 
+       if (!images->autostart)
+               return ;
+
        /* Setup parameters */
        memset(PARAM, 0, 0x1000);       /* Clear zero page */
        strcpy(COMMAND_LINE, bootargs);