[U-Boot] [PATCH] spl: consolidate arch/arm/include/asm/arch-*/spl.h

Tom Rini trini at ti.com
Fri Apr 25 20:52:06 CEST 2014


On Wed, Apr 16, 2014 at 03:44:36PM +0900, Masahiro Yamada wrote:

> arch/arm/include/asm/spl.h requires all SoCs to have
> arch/arm/include/asm/arch-*/spl.h.
> 
> But many of them just define BOOT_DEVICE_* macros.
> 
> Those macros are used in the "switch (boot_device) { ... }"
> statement in common/spl/spl.c.
> 
> So they should not be archtecture specific, but described as
> a simpile enumeration.
> 
> This commit merge most of arch/arm/include/asm/arch-*/spl.h
> into arch/arm/include/asm/spl.h.
> 
> With a little more effort, arch-zynq/spl.h and arch-socfpga/spl.h
> will be merged, while I am not sure about OMAP and Exynos.

The problem is that on TI platforms these values have meaning defined by
ROM (which changes occasionally).  When ROM starts us up, we get a
little bit of info that says "I found and loaded you on ...".  So while
we could move towards moving BOOT_DEVICE_FOO into <spl.h> we'd need in
arch/arm/cpu/armv7/omap-common/boot-common.c some logic to translate
from ROM numbers to U-Boot numbers.

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20140425/7dd70725/attachment.pgp>


More information about the U-Boot mailing list