On Tue, 2010-11-09 at 14:11 -0700, Wolfgang Denk wrote:
> Dear Scott Wood,
> 
> In message <20101109143747.685f9...@udp111988uds.am.freescale.net> you
> wrote:
> >
> > I don't see how
> >
> > #ifdef NAND_SPL
> > #define CONFIG_SYS_TEXT_BASE xxx
> > #else
> > #define CONFIG_SYS_TEXT_BASE yyy
> > #endif
> >
> > is more of a maintenance problem than
> >
> > #define CONFIG_SYS_TEXT_BASE_SPL xxx
> > #define CONFIG_SYS_TEXT_BASE yyy
> >
> > followed by multiple instances of
> >
> > #ifdef NAND_SPL
> > do something with CONFIG_SYS_TEXT_BASE_SPL
> > #else
> > do something with CONFIG_SYS_TEXT_BASE
> > #endif
> 
> Assuming that your code really needs to know the start address of the
> image, it should probably do something like this instead:
> 
> #ifdef NAND_SPL
> #define CONFIG_SYS_TEXT_BASE xxx
> #define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE
> #else
> #define CONFIG_SYS_TEXT_BASE yyy
> #define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE
> #endif
> 
This doesn't make sense if there is still one autoconfig.mk. The value
for CONFIG_SYS_TEXT_BASE will always be yyy for NAND_SPL.

Haiying



_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to