All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Retanubun <RichardRetanubun@RuggedCom.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] PPC: Record uboot's relocated address in RAM and show in bdinfo.
Date: Fri, 15 Jan 2010 11:57:02 -0500	[thread overview]
Message-ID: <4B509E5E.8090002@RuggedCom.com> (raw)
In-Reply-To: <m2fx67mjlv.fsf@ohwell.denx.de>

Detlev Zundel wrote:
<snip>
> 
> Please excuse my ignorance, but why not simply remove the #ifdef
> CONFIG_AMIGAONEG3SE in board_init_f?  Actually I was hoping to remove
> the Amigaone special case.
> 
> Cheers
>   Detlev
> 
I prefer getting the data from board_init_r because we really are running from RAM at that point; dest_addr is a passed in function param.

In board_init_f, the addr variable is just what the calculated address is. If we must do the copy there I'd like to move the gd->relocaddr = addr to just before
the call to relocate_code, that way if the calculation code got reworked/refactored, we always copy the correct addr variable.

Plus the line: debug ("Now running in RAM - U-Boot at: %08lx\n", dest_addr); in board_init_r

Is the de-facto place where documentations that I've seen refer to for figuring out where u-boot is relocated, so making the assignment there
makes it clearer.

All these leads to my preference of getting it from board_init_r.

I'll be happy to submit a V2 that takes out the CONFIG_AMIGAONEG3SE copy operation in board_init_f
as well, but I can't confirm if that does not break the AMIGAONE board.

- Richard

  reply	other threads:[~2010-01-15 16:57 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-15 15:25 [U-Boot] [PATCH] PPC: Record uboot's relocated address in RAM and show in bdinfo Richard Retanubun
2010-01-15 16:13 ` Detlev Zundel
2010-01-15 16:57   ` Richard Retanubun [this message]
2010-01-18 10:44     ` Detlev Zundel
2010-01-18 10:50       ` Joakim Tjernlund
2010-01-18 14:12       ` [U-Boot] [PATCH V2] " Richard Retanubun
2010-01-19 14:28         ` Detlev Zundel
     [not found]           ` <4B55C9FF.7060000@RuggedCom.com>
     [not found]             ` <m2iqawg0fj.fsf@ohwell.denx.de>
2010-01-25 18:31               ` [U-Boot] [PATCH V3] " richardretanubun at ruggedcom.com
2010-02-02 17:38                 ` Detlev Zundel
2010-03-11 22:49                 ` Wolfgang Denk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4B509E5E.8090002@RuggedCom.com \
    --to=richardretanubun@ruggedcom.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.