[U-Boot] calling pci_init before relocation?

Wolfgang Denk wd at denx.de
Mon Jan 31 11:42:54 CET 2011


Dear Michael Schwingen,

In message <4D45EA43.3070108 at discworld.dascon.de> you wrote:
>
> The system hangs during early init, and does not get past relocation.

That is to be expected when you use this before relocation. Don't do
that, then.

> If I interpret the code correct, the PCI code is called from
> board_init_r on PowerPC platforms.

So what? board_init_r() is (quoting the comment) "the  next  part  if
the  initialization  sequence: we are now running from RAM and have a
"normal" C environment, i. e. global data can  be  written,  BSS  has
been cleared, the stack size in not that critical any more, etc."

So it's perfectly safe and clean to run pci_init() there.

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: wd at denx.de
"The whole problem with the world is  that  fools  and  fanatics  are
always so certain of themselves, but wiser people so full of doubts."
- Bertrand Russell


More information about the U-Boot mailing list