ARM: shmobile: fix smp build
authorArnd Bergmann <arnd@arndb.de>
Tue, 15 May 2012 15:30:17 +0000 (15:30 +0000)
committerArnd Bergmann <arnd@arndb.de>
Wed, 16 May 2012 20:16:30 +0000 (22:16 +0200)
I got build errors with the new version now because machine_is_kzm9g is no longer
defined:

arch/arm/mach-shmobile/platsmp.c: In function 'shmobile_smp_get_core_count':
arch/arm/mach-shmobile/platsmp.c:29:2: error: implicit declaration of function 'of_machine_is_compatible'

Replace the missing function with a call to of_machine_is_compatible.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: "Rafael J. Wysocki" <rjw@sisk.pl>
Acked-by: Magnus Damm <magnus.damm@gmail.com>
arch/arm/boot/dts/sh73a0-kzm9g.dts
arch/arm/mach-shmobile/platsmp.c

index ed1bae5a24f1b3e07e64ee92c5b04664ea96bd14..bcb911951978c77cf3a3c9c81ba3e4b588612e37 100644 (file)
@@ -13,7 +13,7 @@
 
 / {
        model = "KZM-A9-GT";
-       compatible = "renesas,kzm9g";
+       compatible = "renesas,kzm9g", "renesas,sh73a0";
 
        memory {
                device_type = "memory";
index d959f07d1ef0fec6f382938aecee5bf58ecb2ad8..5a2b69cf5ba6d662851bb18e84a5b26670947dda 100644 (file)
 #include <linux/device.h>
 #include <linux/smp.h>
 #include <linux/io.h>
+#include <linux/of.h>
 #include <asm/hardware/gic.h>
 #include <asm/mach-types.h>
 #include <mach/common.h>
 
-#define is_sh73a0() (machine_is_ag5evm() || machine_is_kota2() || machine_is_kzm9g())
+#define is_sh73a0() (machine_is_ag5evm() || machine_is_kota2() || \
+                       of_machine_is_compatible("renesas,sh73a0"))
 #define is_r8a7779() machine_is_marzen()
 
 static unsigned int __init shmobile_smp_get_core_count(void)