From: Heiko Schocher <hs@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/2] mx51evk: support new relocation scheme
Date: Tue, 26 Oct 2010 10:39:13 +0200 [thread overview]
Message-ID: <4CC693B1.3050009@denx.de> (raw)
In-Reply-To: <AANLkTi=TRw=bNchd2HU47DmuStEWqdEybk7J_z+Mspy4@mail.gmail.com>
Hello Shawn,
Shawn Guo wrote:
> Hi Heiko,
>
> On Tue, Oct 26, 2010 at 4:25 PM, Heiko Schocher <hs@denx.de> wrote:
>> Hello Stefano,
>>
>> Stefano Babic wrote:
>>> On 10/26/2010 10:05 AM, Shawn Guo wrote:
>>>> Hi Stefano,
>>>>
>>>> On Tue, Oct 26, 2010 at 3:59 PM, Stefano Babic <sbabic@denx.de> wrote:
>>>>> On 10/25/2010 05:14 PM, Shawn Guo wrote:
>>>>>
>>>>>> +#define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM_1
>>>>>> +#define CONFIG_SYS_INIT_SP_ADDR (IRAM_BASE_ADDR + 0x1000)
>>>>> What is the meaning of the offset at 0x1000 ? Is there something at
>>>>> IRAM_BASE_ADDR ?
>>>>>
>>>> I thought CONFIG_SYS_INIT_SP_ADDR is assigned to stack pointer (sp)
>>>> which decrease the address. Is it not the case?
>>>>
>>> Yes, my doubt is due to the fact that we do not set the SP at the end of
>>> the IRAM and we set it to an arbitrary address in between.
>> We should set the CONFIG_SYS_INIT_SP_ADDR @ (IRAM_BASE_ADDR + IRAM_BASE_SIZE
>> - CONFIG_SYS_GBL_DATA_SIZE)
>>
> Since u-boot is running in external memory, shouldn't
> CONFIG_SYS_GBL_DATA_SIZE be using the external memory space other than
> IRAM?
U-Boot uses only before relocation the sp @CONFIG_SYS_INIT_SP_ADDR.
This is for example for boards, which boots from NOR flash, and they
have no working RAM before relocation. So Stackpointer should be setup
in some none SDRAM. After relocation, Stackpointer is setup in SDRAM,
and CONFIG_SYS_INIT_SP_ADDR is not longer used.
bye,
Heiko
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
next prev parent reply other threads:[~2010-10-26 8:39 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-25 15:14 [U-Boot] [PATCH] mx51evk: support new relocation scheme Shawn Guo
2010-10-25 15:14 ` [U-Boot] [PATCH 1/2] " Shawn Guo
2010-10-26 7:59 ` Stefano Babic
2010-10-26 8:05 ` Shawn Guo
2010-10-26 8:14 ` Stefano Babic
2010-10-26 8:17 ` Shawn Guo
2010-10-26 9:38 ` Wolfgang Denk
2010-10-26 8:25 ` Heiko Schocher
2010-10-26 8:31 ` Shawn Guo
2010-10-26 8:39 ` Heiko Schocher [this message]
2010-10-26 8:34 ` Stefano Babic
2010-10-26 8:40 ` Heiko Schocher
2010-10-26 9:42 ` Wolfgang Denk
2010-10-26 10:03 ` Heiko Schocher
2010-10-26 10:12 ` Stefano Babic
2010-10-26 10:15 ` Wolfgang Denk
2010-10-26 8:42 ` Shawn Guo
2010-10-26 9:04 ` Reinhard Meyer
2010-10-26 9:09 ` Shawn Guo
2010-10-26 9:43 ` Wolfgang Denk
2010-10-26 9:43 ` Wolfgang Denk
2010-10-26 9:36 ` Wolfgang Denk
2010-10-25 15:14 ` [U-Boot] [PATCH 2/2] mx51evk: correct internal RAM base address Shawn Guo
2010-10-25 17:02 ` Jason Liu
2010-10-26 8:07 ` Stefano Babic
2010-10-26 8:13 ` Shawn Guo
2010-10-26 2:13 ` [U-Boot] [PATCH v2 " Shawn Guo
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=4CC693B1.3050009@denx.de \
--to=hs@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 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.