[U-Boot] [PATCH v2 7/7] am335x_evm: Add support to boot from NOR.
Kipisz, Steven
s-kipisz2 at ti.com
Mon Jun 17 19:04:59 CEST 2013
> -----Original Message-----
> From: Mark Jackson [mailto:mpfj-list at newflow.co.uk]
> Sent: Monday, June 17, 2013 11:10 AM
> To: Stefan Roese
> Cc: Rini, Tom; Kipisz, Steven; u-boot at lists.denx.de
> Subject: Re: [U-Boot] [PATCH v2 7/7] am335x_evm: Add support to boot
> from NOR.
>
> On 17/06/13 17:01, Stefan Roese wrote:
> > Hi Mark,
> >
> > On 17.06.2013 17:23, Mark Jackson wrote:
>
> <snip>
>
> >> One question ... the SPL code has:-
> >>
> >> ...
> >> gd = &gdata;
> >> ...
> >>
> >> But there seems to be no similar assignment when in NOR boot mode.
> >> I'm no expert in the internal workings of u-boot, so I thought I'd
> >> check, just in case !?!
> >
> > I just noticed you mentioning "gd" here and wanted to point you to a
> > patch that fixed a gd-related boot issue for me on OMAP3:
> >
> > [U-Boot] [PATCH 1/3] arm: spl: Fix SPL booting for OMAP3
> >
> > (sorry, I can't find a link to this patch right now and I'm in a
> > hurry)
> >
> > Not sure if this has something to do with your problem (I don't have
> > the time to dig into this mail thread today as I'm leaving right now).
>
> I'll look at that thanks.
>
> But I've taken a slightly different approach, and added the following to the
> start of s_init() ...
>
>
>
> void s_init(void)
> {
> unsigned short *p = (unsigned short*)0x08000000;
> while (1)
> {
> int i;
> for (i = 0; i < (1 * 1024); i++)
> {
> unsigned short d = p[i];
> d++;
> *p = d;
> }
> }
> ...
>
> AFAICT, that should just spin on reading/writing the NOR device, but I still get
> only an initial 350us burst on the CS0 line, and then nothing.
>
> So I can only assume that the boot code isn't getting as far as
> s_init() at all !!
>
> In start.S and low_levelinit.c, there are various uses of:-
>
> #ifdef CONFIG_SPL_BUILD
>
> Do any of these also need referencing with a CONFIG_NOR_BOOT ?
>
> Mark J.
Do you have a u-boot.lds in board/ti/am335x? That should put s_init() earlier in the boot. Also, include/configs/am335x_evm.h should have
/* Custom script for NOR */
#define CONFIG_SYS_LDSCRIPT "board/ti/am335x/u-boot.lds"
Before using JTAG, take a look in System.map where s_init is located. For a multiplex NOR it should be in the first 64K of address space.
Steve K.
More information about the U-Boot
mailing list