[U-Boot] [PATCH v3 12/14] tegra20: Remove armv4t build flags

Simon Glass
2012-06-09T19:23:06Z

Hi Allen,

On Fri, Jun 8, 2012 at 11:34 PM, Allen Martin <amartin@nvidia.com> wrote:

> On Fri, Jun 08, 2012 at 10:24:42PM -0700, Stephen Warren wrote:
> > On 06/08/2012 03:16 PM, Allen Martin wrote:
> > > These flags were necessary when building tegra20 as a single binary
> > > that supported ARM7TDMI and Cortex A9. Now that the ARM7TDMI support
> > > is split into a separate SPL, this is no longer necessary.
> >
> > > diff --git a/arch/arm/cpu/tegra20-common/Makefile
> b/arch/arm/cpu/tegra20-common/Makefile
> >
> > > -CFLAGS_arch/arm/cpu/tegra20-common/ap20.o += -march=armv4t
> > > -CFLAGS_arch/arm/cpu/tegra20-common/clock.o += -march=armv4t
> > > CFLAGS_arch/arm/cpu/tegra20-common/warmboot_avp.o += -march=armv4t
> >
> > You mentioned in the cover letter that warmboot_avp.o is special, and
> > that's the reason that the flags aren't removed from that file. Can you
> > explain that a bit more? I guess it's because this code is saved for the
> > AVP to run on resume from LP0, so the code needs to be compiled for AVP.
> > I"m mainly looking for the commit description to at least briefly
> > mention this.
>
> Yes, this is AVP code that gets saved off by the A9. It would be nice
> if this function could live inside the SPL and get copied out by the
> normal u-boot, but there's really no interface for passing things up
> from the SPL to u-boot. I guess I could stick a pointer to the
> function in the PMU scratch register that's already allocated for this
> and just have u-boot relocate it. I'll work on this some more.
>

You could, although it seems a bit clumsy. What if people just load U-Boot
and don't run SPL at all? We sitll need to support that flow I think. Since
there is no communication method from SPL to U-Boot it probably makes sense
to do the minimum in SPL.

I'm still a little unclear where/how your SPL actually does secondary
program load, but in any case, it seem to me that your patch here is the
best solution to the problem.

>
> -Allen
> --
> nvpublic
>

Regards,
Simon