Fix fallout from autostart revert
PATCH 1/1 Fix fallout from autostart revert
The autostart revert caused a bit of duplicated code as well as code that was using images->autostart that needs to get removed so we can build again.
Signed-off-by Kumar Gala <[email protected]>
--- common/cmd_bootm.c | 5 ++--- common/image.c | 17 ----------------- lib_arm/bootm.c | 6 +----- lib_avr32/bootm.c | 6 +----- lib_blackfin/bootm.c | 6 +----- lib_i386/bootm.c | 6 +----- lib_m68k/bootm.c | 5 +---- lib_microblaze/bootm.c | 6 +----- lib_mips/bootm.c | 6 +----- lib_nios2/bootm.c | 6 +----- lib_ppc/bootm.c | 5 +---- lib_sh/bootm.c | 6 +----- lib_sparc/bootm.c | 6 +----- 13 files changed, 13 insertions(+), 73 deletions(-)
common/cmd_bootm.c +2 -3
@@ -361,10 +361,9 @@ int do_bootm (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])show_boot_progress (-9 );#ifdef DEBUG puts ("\n## Control returned to monitor - resetting...\n" ); -if (images.autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv);#endif -if (!images.autostart && iflag) +if (iflag)enable_interrupts ();return 1 ;
common/image.c +0 -17
@@ -189,23 +189,6 @@ int image_check_dcrc (image_header_t *hdr)return (dcrc ==image_get_dcrc (hdr)); } -void memmove_wd (void *to,void *from,size_t len,ulong chunksz) -{ -#if defined(CONFIG_HW_WATCHDOG ) || defined(CONFIG_WATCHDOG ) -while (len >0 ) { -size_t tail = (len > chunksz) ? chunksz : len; -WATCHDOG_RESET (); -memmove (to, from, tail); - to += tail; - from += tail; - len -= tail; - } -#else /* !(CONFIG_HW_WATCHDOG || CONFIG_WATCHDOG) */ -memmove (to, from, len); -#endif /* CONFIG_HW_WATCHDOG || CONFIG_WATCHDOG */ -} -#endif /* USE_HOSTCC */ -/** * image_multi_count - get component (sub-image) count * @hdr: pointer to the header of the multi component image
lib_arm/bootm.c +1 -5
@@ -137,9 +137,6 @@ 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" );
@@ -157,8 +154,7 @@ void do_bootm_linux (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],return ; error: -if (images->autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv);return ; }
lib_avr32/bootm.c +1 -5
@@ -221,9 +221,6 @@ 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);
@@ -234,7 +231,6 @@ void do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],return ; error: -if (images->autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv);return ; }
lib_blackfin/bootm.c +1 -5
@@ -40,9 +40,6 @@ 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
@@ -74,6 +71,5 @@ void do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],return ; error: -if (images->autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv); }
lib_i386/bootm.c +1 -5
@@ -84,9 +84,6 @@ 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);
@@ -100,7 +97,6 @@ void do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],return ; error: -if (images->autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv);return ; }
lib_m68k/bootm.c +1 -4
@@ -129,8 +129,6 @@ 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
@@ -144,8 +142,7 @@ void do_bootm_linux(cmd_tbl_t * cmdtp, int flag,return ; error: -if (images->autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv);return ; }
lib_microblaze/bootm.c +1 -5
@@ -67,15 +67,11 @@ void do_bootm_linux (cmd_tbl_t * cmdtp, int flag, int argc, char *argv[], (ulong) theKernel);#endif -if (!images->autostart) -return ; -theKernel (commandline);/* does not return */ return ; error: -if (images->autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv);return ; }
lib_mips/bootm.c +1 -5
@@ -120,9 +120,6 @@ void do_bootm_linux (cmd_tbl_t * cmdtp, int flag, int argc, char *argv[],linux_env_set ("eth1addr" , cp); } -if (!images->autostart) -return ; -/* we assume that the kernel is in place */ printf ("\nStarting kernel ...\n\n" );
@@ -131,8 +128,7 @@ void do_bootm_linux (cmd_tbl_t * cmdtp, int flag, int argc, char *argv[],return ; error: -if (images->autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv);return ; }
lib_nios2/bootm.c +1 -5
@@ -50,9 +50,6 @@ 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 ;-) */
@@ -61,7 +58,6 @@ void do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],return ; error: -if (images->autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv);return ; }
lib_ppc/bootm.c +1 -4
@@ -277,8 +277,6 @@ 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 */
@@ -311,8 +309,7 @@ do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],return ; error: -if (images->autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv);return ; }
lib_sh/bootm.c +1 -5
@@ -83,9 +83,6 @@ 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);
@@ -95,7 +92,6 @@ void do_bootm_linux (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],return ; error: -if (images->autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv);return ; }
lib_sparc/bootm.c +1 -5
@@ -204,9 +204,6 @@ void do_bootm_linux(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[], bootargs =getenv ("bootargs" );prepare_bootargs (bootargs); -if (!images->autostart) -return ; -/* turn on mmu & setup context table & page table for process 0 (kernel) */ srmmu_init_cpu ((unsigned int )kernel);
@@ -220,7 +217,6 @@ void do_bootm_linux(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[],while (1 ) ; error: -if (images->autostart) -do_reset (cmdtp, flag, argc, argv); +do_reset (cmdtp, flag, argc, argv);return ; }
Signature · 1 line
1.5.5.1
Wolfgang Denk
AppliedPATCH 1/1 Fix fallout from autostart revert
Dear Kumar Gala,
Quoted 5 lines · In message <[email protected]> you wrote:
The autostart revert caused a bit of duplicated code as well as code that was using
images->autostartthat needs to get removed so we can build again.Signed-off-by Kumar Gala <[email protected]>
Quoted 15 lines
--- common/cmd_bootm.c | 5 ++--- common/image.c | 17 ----------------- lib_arm/bootm.c | 6 +----- lib_avr32/bootm.c | 6 +----- lib_blackfin/bootm.c | 6 +----- lib_i386/bootm.c | 6 +----- lib_m68k/bootm.c | 5 +---- lib_microblaze/bootm.c | 6 +----- lib_mips/bootm.c | 6 +----- lib_nios2/bootm.c | 6 +----- lib_ppc/bootm.c | 5 +---- lib_sh/bootm.c | 6 +----- lib_sparc/bootm.c | 6 +----- 13 files changed, 13 insertions(+), 73 deletions(-)
Applied, thanks.
Best regards,
Wolfgang Denk
Signature · 6 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de Even historians fail to learn from history -- they repeat the same mistakes. -- John Gill, "Patterns of Force", stardate 2534.7