public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Wolfgang Denk <wd@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] how can i change u-boot load address?
Date: Tue, 07 Oct 2008 11:01:33 +0200	[thread overview]
Message-ID: <20081007090133.2F87C85D90E5@gemini.denx.de> (raw)
In-Reply-To: <19853320.post@talk.nabble.com>

Dear Hebbar,

In message <19853320.post@talk.nabble.com> you wrote:
> 
> If you can tell me what exactly is wrong with ARM startup, i will try to
> find a solution. Can u point the platform and its startup functions where it
> is been done correctly. Then i will try to fixup th error in ARM.

The fundamental problem with the ARM port is that on ARM, U-Boot gets
linked to a fixed address in RAM.

We inherited this deficiency from the ARMBoot port  -  when  the  old
PPCBoot (PowerPC only) got ported to ARM, the developers thought that
the  whole  relocation  as implemented in PPCBoot was too complicated
and just not worth the effort, so they did what they did. BTW: later,
the MIPS port copied the ARM implementation, unfortunately.

The advantage of the PowerPC implementation with relocation  is  that
we  can  measure  the actual size of memory present on the board, and
then relocate U-Boot to the very end of the RAM,  leaving  nearly  th
whole  RAM  usable as one big contiguous area for "applications" like
loading Linux kernel, ramdisk, etc.

The problem with the ARM implementation is that the link  address  is
fixed,  i. e. it cannot be adjusted to varying RAM sizes. If you have
a board which can be fit with either 32 or with 64  MB  of  RAM,  you
have  to  link  U-Boot  so that it sits at the end of the 32 MB area.
Which means that on a 64 MB system it will sit right in the middle of
the RAM, splitting the RAM in two small chunks. Try to explain  to  a
customer  why  he  has  some  60+ MB of free RAM on the system but he
still cannot load a 33 MB ramdisk image...

There are more consequences from this design  -  on  PowerPC  we  can
implement  "protected  RAM",  framebuffer  memory  we  can share with
Linux, log buffer memory we can share with Linux, etc.  -  all  these
need  to sit at the end of the available physical RAM. On PowerPC, it
goes without saying that all this works perfectly fine with  variable
RAM  sizes  (so we can have one U-Boot image working for example with
different DIMM modules). On ARM, you have to configure U-Boot  for  a
fixed memory size.

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
Respect is a rational process
	-- McCoy, "The Galileo Seven", stardate 2822.3

  reply	other threads:[~2008-10-07  9:01 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-06 12:13 [U-Boot] how can i change u-boot load address? sahar mustafa
2008-10-06 15:13 ` Andrew Dyer
2008-10-06 23:36   ` Roman Mashak
2008-10-07  2:06     ` Roman Mashak
2008-10-07  7:36     ` Wolfgang Denk
2008-10-07  8:11       ` Hebbar
2008-10-07  9:01         ` Wolfgang Denk [this message]
2008-10-07 12:36       ` Roman Mashak
2008-10-07 14:02         ` Wolfgang Denk
2008-10-08  2:22           ` Roman Mashak
     [not found] <mailman.1056.1223364979.2783.u-boot@lists.denx.de>
2008-10-07  8:38 ` Gururaja Hebbar K R
2008-10-07  9:04   ` Wolfgang Denk
2008-10-07  9:39     ` Gururaja Hebbar K R

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=20081007090133.2F87C85D90E5@gemini.denx.de \
    --to=wd@denx.de \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox