Dear "Hu Mingkai-B21284",

In message 
<73839b4a0818e747864426270ac332c30447e...@zmy16exm20.fsl.freescale.net> you 
wrote:
> 
> > > > It should be enough to pass the make target name to the mkconfig 
> > > > script resp. the board config file, i. e. in this case either 
> > > > "CONFIG_MPC8536DS_NAND" or "CONFIG_MPC8536DS_NAND_36BIT". 
> > The rest 
> > > > of the scripting/decision making can then be done in the board 
> > > > config file.
> > > > 
> > >
> > > Thanks for your replay, but I'm not totally catch on you.
> > > "the board config file" in your words refer to 
> > board/*/config.mk, right?
> > 
> > No, with "board config file" I mean include/configs/*.h
>
> How can I parse the board name in a header file?

I'm not sure I understand the question (or rather the problem you are
seeing).

You already know the board name, because the board config file is
clearly related ot one (or eventually more) boards. The rest can be
done with some trivial #ifdef'fery.

> If config booting from NAND, we also need to override the TEXT_BASE
> in the board/*/config.mk file, how could we do that?

You can for example set CONFIG_SYS_MONITOR_BASE (or some other CONFIG_
variable - but CONFIG_SYS_MONITOR_BASE is used anyway) as needed in your
include/configs/*.h, which then gets exported through
include/autoconf.mk, so you can use some
"TEXT_BASE = $(CONFIG_SYS_MONITOR_BASE)" in your config.mk

Best regards,

Wolfgang Denk

-- 
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: w...@denx.de
If you're not part of the solution, then you're part of the  precipi-
tate.
_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to