[U-Boot-Users] bd_info vs. global_data

Wolfgang Denk wd at denx.de
Sat Nov 11 00:03:54 CET 2006


In message <4554AB0E.7000805 at freescale.com> you wrote:
>
> So gd initially lives in cache?  I don't see in the README where it says where 
> gd_t is initially allocated, but I do see this in the code:

This depends on the architecture. It may be cache,  or  some  on-chip
memory,  or some SRAM, or whatever is available on a board that works
as RAM without specific initialization.

> However, it looks like there's some redundancy in this.  Couldn't the variable 
> disable_of perform the same function?  Or even better, couldn't we just check 

No, it cannot. Because the change was done a long time ago in the 2.4
kernel tree, somewhere around 2.4.5-pre5. Using a 2.4.4 kernel  or  a
2.4.5  kernel require different clock encoding (one in MHz, the other
in Hz). This does not depend on any OF stuff at all.

> whether a pointer to an OF tree is passed to the bootm parameter?  If the user 
> includes an OF tree on the bootm command line, then boot an OF kernel. 
> Otherwise, convert the frequency values to MHZ and boot a traditional kernel.

It seems you did not read much of the documentation.

> Speaking of do_bootm_linux(), why is the PPC version of this function in 
> cmd_bootm.c instead of lib_ppc/ppc_linux.c?

For historical reasons. We started with PPC only, so it  was  natural
to  have  this  in cmd_bootm.c. Other architectures placed theit code
somewhere else, but nobody changed the PPC code.

Best regards,

Wolfgang Denk

-- 
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
GUIs  are  virtually  useless.  Learn  tools.  They're  configurable,
scriptable, automatable, cron-able, interoperable, etc. We don't need
no brain-dead winslurping monolithic claptrap.
                               -- Tom Christiansen in 371140df at csnews




More information about the U-Boot mailing list