ARM926: compile cpu_init_crit function only if CONFIG_SKIP_LOWLEVEL_INIT is not defined
PATCH 1/1 ARM926: compile cpu_init_crit function only if CONFIG_SKIP_LOWLEVEL_INIT is not defined
Hi,
This patches allows cpu_init_crit function to be compilled only if CONFIG_SKIP_LOWLEVEL_INIT is not defined. At present irrespective of CONFIG_SKIP_LOWLEVEL_INIT, cpu_init_crit is always compilled. This is for arm926ejs module.
cpu/arm926ejs/start.S +4 -1
@@ -187,7 +187,7 @@ clbss_l:str r2, [r0] /* clear loop... _start_armboot: .word start_armboot - +#ifndef CONFIG_SKIP_LOWLEVEL_INIT /* ************************************************************************* *
@@ -225,6 +225,9 @@ cpu_init_crit: bl lowlevel_init /* go setup pll,mux,memory */ mov lr, ip /* restore link */ mov pc, lr /* back to my caller */ + +#endif /* CONFIG_SKIP_LOWLEVEL_INIT */ + /* ************************************************************************* *
I welcome comments, complaints, suggestions and advices.
Regards
Gururaja
Signature · 2 lines
View this message in context: http://www.nabble.com/-PATCH--ARM926%3A-compile-cpu_init_crit-function-only-if-CONFIG_SKIP_LOWLEVEL_INIT-is-not-defined-tp14408413p14408413.html Sent from the Uboot - Users mailing list archive at Nabble.com.
PATCH 1/1 ARM926: compile cpu_init_crit function only if CONFIG_SKIP_LOWLEVEL_INIT is not defined
Hi,
This patches allows cpu_init_crit function to be compilled only if CONFIG_SKIP_LOWLEVEL_INIT is not defined. At present irrespective of CONFIG_SKIP_LOWLEVEL_INIT, cpu_init_crit is always compilled. This is for arm926ejs module.
cpu/arm926ejs/start.S +4 -1
@@ -187,7 +187,7 @@ clbss_l:str r2, [r0] /* clear loop... _start_armboot: .word start_armboot - +#ifndef CONFIG_SKIP_LOWLEVEL_INIT /* ************************************************************************* *
@@ -225,6 +225,9 @@ cpu_init_crit: bl lowlevel_init /* go setup pll,mux,memory */ mov lr, ip /* restore link */ mov pc, lr /* back to my caller */ + +#endif /* CONFIG_SKIP_LOWLEVEL_INIT */ + /* ************************************************************************* *
I welcome comments, complaints, suggestions and advices.
Regards
Gururaja
Signature · 2 lines
View this message in context: http://www.nabble.com/-PATCH--ARM926%3A-compile-cpu_init_crit-function-only-if-CONFIG_SKIP_LOWLEVEL_INIT-is-not-defined-tp14408413p14408491.html Sent from the Uboot - Users mailing list archive at Nabble.com.
PATCH 1/1 ARM926: compile cpu_init_crit function only if CONFIG_SKIP_LOWLEVEL_INIT is not defined
Quoted 29 lines · Hebbar
This patches allows
cpu_init_critfunction to be compilled only ifCONFIG_SKIP_LOWLEVEL_INITis not defined. At present irrespective ofCONFIG_SKIP_LOWLEVEL_INIT,cpu_init_critis always compilled. This is for arm926ejs module.Signed-off-by K R Gururaja Hebbar <[email protected]>cpu/arm926ejs/start.S +4
-1@@ -187,7 +187,7 @@ clbss_l:str r2, [r0] /* clear loop... _start_armboot: .word start_armboot - +#ifndef CONFIG_SKIP_LOWLEVEL_INIT /* ************************************************************************* *@@ -225,6 +225,9 @@ cpu_init_crit: bl lowlevel_init /* go setup pll,mux,memory */ mov lr, ip /* restore link */ mov pc, lr /* back to my caller */ + +#endif /* CONFIG_SKIP_LOWLEVEL_INIT */ + /* ************************************************************************* *
Quoted 1 line
I welcome comments, complaints, suggestions and advices.
The reason for this is to decrease resulting binary size? If so, all lowlevel_init() should be encapsulated as well to save even more space?
Dirk
PATCH 1/1 ARM926: compile cpu_init_crit function only if CONFIG_SKIP_LOWLEVEL_INIT is not defined
In reply to HebbarQuoted 5 lines · In message <[email protected]> you wrote:
This patches allows
cpu_init_critfunction to be compilled only ifCONFIG_SKIP_LOWLEVEL_INITis not defined. At present irrespective ofCONFIG_SKIP_LOWLEVEL_INIT,cpu_init_critis always compilled. This is for arm926ejs module.
I'm not sure about this one. Probably the whole cpu_init_crit: part should be placed inside the "#ifndef CONFIG_SKIP_LOWLEVEL_INIT" part, as it is done for example in "cpu/arm920t/start.S" ?
Not applied.
Best regards,
Wolfgang Denk
Signature · 5 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 A direct quote from the Boss: "We passed over a lot of good people to get the ones we hired."
PATCH 1/1 ARM926: compile cpu_init_crit function only if CONFIG_SKIP_LOWLEVEL_INIT is not defined
Hi Wolfgang ,
At Present the call to "cpu_init_crit" in uboot/cpu/arm926ejs/start.S (142) is under ifndef
#ifndef CONFIG_SKIP_LOWLEVEL_INIT
bl cpu_init_crit
#endif
But the function definition (203) isn't under this ifndef. So irrespective
of CONFIG_SKIP_LOWLEVEL_INIT, this function is compiled. Hence i have applied the ifndef to function definition which places the entire cpu_init_crit inside the ifndef.
Regards
Gururaja
Quoted 5 lines · In message <[email protected]> you wrote:
This patches allows
cpu_init_critfunction to be compilled only ifCONFIG_SKIP_LOWLEVEL_INITis not defined. At present irrespective ofCONFIG_SKIP_LOWLEVEL_INIT,cpu_init_critis always compilled. This is for arm926ejs module.
I'm not sure about this one. Probably the whole cpu_init_crit: part should be placed inside the "#ifndef CONFIG_SKIP_LOWLEVEL_INIT" part, as it is done for example in "cpu/arm920t/start.S" ?
Not applied.
Best regards,
Wolfgang Denk
Signature · 2 lines
View this message in context: http://www.nabble.com/-PATCH--ARM926%3A-compile-cpu_init_crit-function-only-if-CONFIG_SKIP_LOWLEVEL_INIT-is-not-defined-tp14408413p15281823.html Sent from the Uboot - Users mailing list archive at Nabble.com.
PATCH 1/1 ARM926: compile cpu_init_crit function only if CONFIG_SKIP_LOWLEVEL_INIT is not defined
Quoted 4 lines · In message <[email protected]> you wrote:
At Present the call to "
cpu_init_crit" inuboot/cpu/arm926ejs/start.S(142) is under ifndef
Quoted 8 lines
#ifndef
CONFIG_SKIP_LOWLEVEL_INIT
blcpu_init_crit
#endifBut the function definition (203) isn't under this ifndef. So irrespective
ofCONFIG_SKIP_LOWLEVEL_INIT, this function is compiled. Hence i have applied the ifndef to function definition which places the entirecpu_init_critinside the ifndef.
I don't think you answer my question:
Quoted 3 lines
I'm not sure about this one. Probably the whole
cpu_init_crit: part should be placed inside the "#ifndefCONFIG_SKIP_LOWLEVEL_INIT" part, as it is done for example in "cpu/arm920t/start.S" ?
?
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 The years of peak mental activity are undoubtedly between the ages of four and eighteen. At four we know all the questions, at eighteen all the answers.
PATCH 1/1 ARM926: compile cpu_init_crit function only if CONFIG_SKIP_LOWLEVEL_INIT is not defined
Hi,
I went through "cpu/arm920t/start.S" file and found that this is what this patch is doing.
This patch places the entire cpu_init_crit function definition inside ifndef same as in arm920t/start.S.
Sorry if i havent understood you.
Present cpu/arm926ejs/start.S
_start_armboot:
.word start_armboot
-----> This is where i haveplaced #ifndef CONFIG_SKIP_LOWLEVEL_INIT
/*
*************************************************************************
*
* CPU_init_critical registers
*
* setup important registers
* setup memory timing
*
*************************************************************************
*/
cpu_init_crit:
/* * flush v4 I/D caches */ mov r0,
<snip>
<snip>
<snip>
<snip>
bl lowlevel_init /* go setup pll,mux,memory */
mov lr, ip /* restore link */
mov pc, lr /* back to my caller */
/*
----> here is the #endif
*************************************************************************
*
* Interrupt handling
*
*************************************************************************
*/
Regards
Gururaja
Quoted 17 lines · wd
In message <[email protected]> you wrote:
I don't think you answer my question:
Quoted 3 lines
I'm not sure about this one. Probably the whole
cpu_init_crit: part should be placed inside the "#ifndefCONFIG_SKIP_LOWLEVEL_INIT" part, as it is done for example in "cpu/arm920t/start.S" ??
Best regards,
Wolfgang Denk
Signature · 2 lines
View this message in context: http://www.nabble.com/-PATCH--ARM926%3A-compile-cpu_init_crit-function-only-if-CONFIG_SKIP_LOWLEVEL_INIT-is-not-defined-tp14408413p15471298.html Sent from the Uboot - Users mailing list archive at Nabble.com.