From: Heiko Schocher <hs@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] ARM: atmel: at91sam9m10g45ek: enable SPL
Date: Mon, 19 Jan 2015 07:15:00 +0100 [thread overview]
Message-ID: <54BCA0E4.3040608@denx.de> (raw)
In-Reply-To: <54BC60D0.8020104@atmel.com>
Hello Bo,
added Simon to cc ...
Am 19.01.2015 02:41, schrieb Bo Shen:
> Hi Andreas,
>
> On 01/16/2015 06:16 PM, Andreas Bie?mann wrote:
>> Hi Bo,
>>
>> On 01/16/2015 10:30 AM, Bo Shen wrote:
>>> On 01/16/2015 05:10 PM, Andreas Bie?mann wrote:
>>>> On 01/16/2015 03:53 AM, Bo Shen wrote:
>>
>>>>> --- a/arch/arm/cpu/arm926ejs/at91/Makefile
>>>>> +++ b/arch/arm/cpu/arm926ejs/at91/Makefile
>>>>> @@ -25,5 +25,9 @@ obj-y += reset.o
>>>>> obj-y += timer.o
>>>>>
>>>>> ifndef CONFIG_SKIP_LOWLEVEL_INIT
>>>>> +ifdef CONFIG_SPL_BUILD
>>>>> +obj-y += spl_lowlevel_init.o
>>>>> +else
>>>>> obj-y += lowlevel_init.o
>>>>> endif
>>>>> +endif
>>>>
>>>> I'm fine with having two variants of lowlevel_init for a time, but we
>>>> should consolidate this and use C-style initialisation of SDRAM and
>>>> stuff for the other armv5 at91 devices in future. AFAIK the
>>>> a/a/c/arm926ejs/at91/lowlevel_init.S is mainly used for NOR Flash boots,
>>>> so using the SPL code (but not necessarily the two binary mechanism) for
>>>> the NOR Flash boots in future is appreciated.
>>>
>>> OK, when all the arm9 at91 related board has SPL support, then I will do
>>> this.
>>
>> Can we achieve this in this MW?
>
> I will try, but not sure. As I don't have this kind of board :(
> I need to check whether we still have this kind of board.
>
>>>>> +ENTRY(lowlevel_init)
>>>>> + /*
>>>>> + * Setup a temporary stack
>>>>> + */
>>>>> + ldr sp, =CONFIG_SYS_INIT_SP_ADDR
>>>>> + bic sp, sp, #7 /* 8-byte alignment for ABI compliance */
>>>>> +
>>>>> + ldr r9, =gdata
>>>>
>>>> I remember some patches removing the SPL gdata stuff, is that true?
>>>
>>> Thanks.
>>>
>>> Yes, just search for it, the following patch do this.
>>> http://patchwork.ozlabs.org/patch/423789/ (arm: Reduce the scope of
>>> lowlevel_init())
>>
>> I think we should use the function provided there. What do you think?
>
> OK. I will do it in next version.
> Thanks.
Hmm... looking into this patch [1] ... it says:
+ * Call the very early init function. This should do only the
+ * absolute bare minimum to get started. It should not:
+ *
+ * - set up DRAM
+ * - use global_data
+ * - clear BSS
+ * - try to start a console
but if we have small init ram for SPL (like on the sam9260 with 4k sram)
we should init here SDRAM, so we could set bss and stack into RAM
in board_init_f, which is called after this function.
So we should rework the comment here ... or?
bye,
Heiko
[1] http://patchwork.ozlabs.org/patch/423789/
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
next prev parent reply other threads:[~2015-01-19 6:15 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-16 2:53 [U-Boot] [PATCH] ARM: atmel: at91sam9m10g45ek: enable SPL Bo Shen
2015-01-16 9:10 ` Andreas Bießmann
2015-01-16 9:30 ` Bo Shen
2015-01-16 10:16 ` Andreas Bießmann
2015-01-19 1:41 ` Bo Shen
2015-01-19 6:15 ` Heiko Schocher [this message]
2015-01-19 19:32 ` Simon Glass
2015-01-16 11:35 ` Heiko Schocher
2015-01-19 1:38 ` Bo Shen
2015-01-19 6:07 ` Heiko Schocher
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=54BCA0E4.3040608@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox