avr32: fix do_bootm_linux
PATCH 1/1 avr32: fix do_bootm_linux
Commit 35fc84fa1ff51e15ecd3e464dac87eb105ffed30 broke bootm on avr32. It requires to call do_bootm_linux() with flag set to BOOTM_STATE_OS_PREP before calling it again with flag set to BOOTM_STATE_OS_GO.
Fix this by allowing flag set to BOOTM_STATE_OS_PREP, this however will require a complete refactoring later on.
--- arch/avr32/lib/bootm.c | 9 +++++++++ 1 file changed, 9 insertions(+)
arch/avr32/lib/bootm.c +9 -0
@@ -187,6 +187,15 @@ int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *imastruct tag *params, *params_start;char *commandline =getenv ("bootargs" ); +/* +* allow the PREP bootm subcommand, it is required for bootm to work +* +* TODO: Andreas Bie?mann <[email protected]> refactor the +* do_bootm_linux() for avr32 +*/ +if (flag &BOOTM_STATE_OS_PREP ) +return 0 ; +if ((flag !=0 ) && (flag !=BOOTM_STATE_OS_GO ))return 1 ;
Signature · 1 line
1.7.10.4
PATCH 1/1 avr32: fix do_bootm_linux
Quoted 21 lines · Andreas Bie??mann
Commit
35fc84fa1ff51e15ecd3e464dac87eb105ffed30broke bootm on avr32. It requires to calldo_bootm_linux()with flag set toBOOTM_STATE_OS_PREPbefore calling it again with flag set toBOOTM_STATE_OS_GO.
Fix this by allowing flag set toBOOTM_STATE_OS_PREP, this however will require a complete refactoring later on.Signed-off-by Andreas Bie??mann <[email protected]>--- arch/avr32/lib/bootm.c | 9 +++++++++ 1 file changed, 9 insertions(+)arch/avr32/lib/bootm.c +1
-0@@ -187,6 +187,15 @@ int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *imastruct tag *params, *params_start;char *commandline =getenv ("bootargs" ); +/*
arch/avr32/lib/bootm.c int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *ima · line 200
Quoted 10 lines
arch/avr32/lib/bootm.c +8
-0+* allow the PREP bootm subcommand, it is required for bootm to work +* +* TODO: Andreas Bie??mann <[email protected]> refactor the +* do_bootm_linux() for avr32 +*/ +if (flag &BOOTM_STATE_OS_PREP ) +return 0 ; +if ((flag !=0 ) && (flag !=BOOTM_STATE_OS_GO ))return 1 ;
Good catch! I'm going to make a v2 of this patch that fixes all of the other arches that're missing this hunk.
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20130702/e4d6d988/attachment.pgp>
PATCH 1/1 avr32: fix do_bootm_linux
Quoted 22 lines · Tom Rini
Quoted 20 lines · Andreas Bie?mann
Commit
35fc84fa1ff51e15ecd3e464dac87eb105ffed30broke bootm on avr32. It requires to calldo_bootm_linux()with flag set toBOOTM_STATE_OS_PREPbefore calling it again with flag set toBOOTM_STATE_OS_GO.
Fix this by allowing flag set toBOOTM_STATE_OS_PREP, this however will require a complete refactoring later on.Signed-off-by Andreas Bie?mann <[email protected]>--- arch/avr32/lib/bootm.c | 9 +++++++++ 1 file changed, 9 insertions(+)arch/avr32/lib/bootm.c +0
-0@@ -187,6 +187,15 @@ int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *imastruct tag *params, *params_start;char *commandline =getenv ("bootargs" );
Quoted 14 lines
arch/avr32/lib/bootm.c int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *ima · line 200
Quoted 11 lines
arch/avr32/lib/bootm.c +9
-0+/* +* allow the PREP bootm subcommand, it is required for bootm to work +* +* TODO: Andreas Bie??mann <[email protected]> refactor the +* do_bootm_linux() for avr32 +*/ +if (flag &BOOTM_STATE_OS_PREP ) +return 0 ; +if ((flag !=0 ) && (flag !=BOOTM_STATE_OS_GO ))return 1 ;Good catch! I'm going to make a v2 of this patch that fixes all of the other arches that're missing this hunk.
Ok, thank you Tom
Regards,
Andreas Bie?mann