summaryrefslogtreecommitdiff
path: root/arch/arm/mach-s3c64xx/common.c
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2015-02-27 20:31:51 +0100
committerArnd Bergmann <arnd@arndb.de>2015-12-01 21:50:24 +0100
commita0e157afd0c3ecb2e953eb41da04da2bf0e3d6c3 (patch)
tree7e6b92d70621cfd3771753012a0905da0c1051d7 /arch/arm/mach-s3c64xx/common.c
parent0f20e456bd0542b7bf8cae8f553142405a8ab430 (diff)
ARM: s3c64xx: prepare initcalls for multiplatform
In a multiplatform kernel, each initcall is run regardless of the platform it is meant for, so it must not attempt to access SoC-specific registers. This adds 'if (soc_is_s3c64xx)' to all initcalls that are specific to the s3c64xx platform, to prevent them from breaking other platforms once we can build them into a combined kernel. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Diffstat (limited to 'arch/arm/mach-s3c64xx/common.c')
-rw-r--r--arch/arm/mach-s3c64xx/common.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm/mach-s3c64xx/common.c b/arch/arm/mach-s3c64xx/common.c
index ddb30b8434c5..3dea4a4ef165 100644
--- a/arch/arm/mach-s3c64xx/common.c
+++ b/arch/arm/mach-s3c64xx/common.c
@@ -208,7 +208,7 @@ void __init s3c64xx_init_io(struct map_desc *mach_desc, int size)
static __init int s3c64xx_dev_init(void)
{
/* Not applicable when using DT. */
- if (of_have_populated_dt())
+ if (of_have_populated_dt() || !soc_is_s3c64xx())
return 0;
subsys_system_register(&s3c64xx_subsys, NULL);
@@ -413,7 +413,7 @@ static int __init s3c64xx_init_irq_eint(void)
int irq;
/* On DT-enabled systems EINTs are handled by pinctrl-s3c64xx driver. */
- if (of_have_populated_dt())
+ if (of_have_populated_dt() || !soc_is_s3c64xx())
return -ENODEV;
for (irq = IRQ_EINT(0); irq <= IRQ_EINT(27); irq++) {