From: Jarkko Nikula Date: Thu, 21 Aug 2008 08:20:09 +0000 (+0300) Subject: ARM: OMAP2: Fix SPI driver failure on 2420 when running multi-omap config X-Git-Tag: v2.6.27-omap1~289 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=651f3345fa1547784e1493ee1dbd80bd93978239;p=linux-2.6-omap-h63xx.git ARM: OMAP2: Fix SPI driver failure on 2420 when running multi-omap config SPI driver will do unhandled fault on OMAP2420 if trying to probe non-existing SPI busses. Register those additional busses runtime only for cpus having them. Signed-off-by: Jarkko Nikula Signed-off-by: Tony Lindgren --- diff --git a/arch/arm/mach-omap2/devices.c b/arch/arm/mach-omap2/devices.c index cc5c294b9dc..bd49a0f152c 100644 --- a/arch/arm/mach-omap2/devices.c +++ b/arch/arm/mach-omap2/devices.c @@ -255,10 +255,12 @@ static void omap_init_mcspi(void) platform_device_register(&omap2_mcspi1); platform_device_register(&omap2_mcspi2); #if defined(CONFIG_ARCH_OMAP2430) || defined(CONFIG_ARCH_OMAP3) - platform_device_register(&omap2_mcspi3); + if (cpu_is_omap2430() || cpu_is_omap343x()) + platform_device_register(&omap2_mcspi3); #endif #ifdef CONFIG_ARCH_OMAP3 - platform_device_register(&omap2_mcspi4); + if (cpu_is_omap343x()) + platform_device_register(&omap2_mcspi4); #endif }