diff options
| -rw-r--r-- | arch/arm/cpu/armv7/omap-common/lowlevel_init.S | 10 | ||||
| -rw-r--r-- | arch/arm/include/asm/arch-am33xx/spl.h | 3 | ||||
| -rw-r--r-- | arch/arm/include/asm/arch-omap3/spl.h | 3 | ||||
| -rw-r--r-- | arch/arm/include/asm/arch-omap4/spl.h | 2 | ||||
| -rw-r--r-- | arch/arm/include/asm/arch-omap5/spl.h | 2 | 
5 files changed, 17 insertions, 3 deletions
| diff --git a/arch/arm/cpu/armv7/omap-common/lowlevel_init.S b/arch/arm/cpu/armv7/omap-common/lowlevel_init.S index b933fe843..90b3c8aea 100644 --- a/arch/arm/cpu/armv7/omap-common/lowlevel_init.S +++ b/arch/arm/cpu/armv7/omap-common/lowlevel_init.S @@ -60,10 +60,14 @@ ENTRY(save_boot_params)  	ldr	r3, =boot_params  	strb	r2, [r3, #BOOT_DEVICE_OFFSET]	@ spl_boot_device <- r1 -	/* boot mode is passed only for devices that can raw/fat mode */ -	cmp	r2, #BOOT_DEVICE_XIP +	/* +	 * boot mode is only valid for device that can be raw or FAT booted. +	 * in other cases it may be fatal to look.  While platforms differ +	 * in the values used for each MMC slot, they are contiguous. +	 */ +	cmp	r2, #MMC_BOOT_DEVICES_START  	blt	2f -	cmp	r2, #BOOT_DEVICE_MMC2 +	cmp	r2, #MMC_BOOT_DEVICES_END  	bgt	2f  	/* Store the boot mode (raw/FAT) in omap_bootmode */  	ldr	r2, [r0, #DEV_DESC_PTR_OFFSET]	@ get the device descriptor ptr diff --git a/arch/arm/include/asm/arch-am33xx/spl.h b/arch/arm/include/asm/arch-am33xx/spl.h index f60b08636..14a2c7c28 100644 --- a/arch/arm/include/asm/arch-am33xx/spl.h +++ b/arch/arm/include/asm/arch-am33xx/spl.h @@ -37,4 +37,7 @@  #define BOOT_DEVICE_USBETH	68  #define BOOT_DEVICE_CPGMAC	70  #define BOOT_DEVICE_MMC2_2      0xFF + +#define MMC_BOOT_DEVICES_START	BOOT_DEVICE_MMC1 +#define MMC_BOOT_DEVICES_END	BOOT_DEVICE_MMC2  #endif diff --git a/arch/arm/include/asm/arch-omap3/spl.h b/arch/arm/include/asm/arch-omap3/spl.h index dec4dacba..84e6d7bcb 100644 --- a/arch/arm/include/asm/arch-omap3/spl.h +++ b/arch/arm/include/asm/arch-omap3/spl.h @@ -31,4 +31,7 @@  #define BOOT_DEVICE_MMC1	6  #define BOOT_DEVICE_XIPWAIT	7  #define BOOT_DEVICE_MMC2_2      0xFF + +#define MMC_BOOT_DEVICES_START	BOOT_DEVICE_MMC2 +#define MMC_BOOT_DEVICES_END	BOOT_DEVICE_MMC1  #endif diff --git a/arch/arm/include/asm/arch-omap4/spl.h b/arch/arm/include/asm/arch-omap4/spl.h index 4e094f9c6..f61627ff5 100644 --- a/arch/arm/include/asm/arch-omap4/spl.h +++ b/arch/arm/include/asm/arch-omap4/spl.h @@ -32,4 +32,6 @@  #define BOOT_DEVICE_MMC2	6  #define BOOT_DEVICE_MMC2_2	0xFF +#define MMC_BOOT_DEVICES_START	BOOT_DEVICE_MMC1 +#define MMC_BOOT_DEVICES_END	BOOT_DEVICE_MMC2  #endif diff --git a/arch/arm/include/asm/arch-omap5/spl.h b/arch/arm/include/asm/arch-omap5/spl.h index 323cd6355..d4d353c80 100644 --- a/arch/arm/include/asm/arch-omap5/spl.h +++ b/arch/arm/include/asm/arch-omap5/spl.h @@ -32,4 +32,6 @@  #define BOOT_DEVICE_MMC2        6  #define BOOT_DEVICE_MMC2_2	7 +#define MMC_BOOT_DEVICES_START	BOOT_DEVICE_MMC1 +#define MMC_BOOT_DEVICES_END	BOOT_DEVICE_MMC2_2  #endif |