summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorMarek Szyprowski <m.szyprowski@samsung.com>2019-09-06 13:43:57 +0200
committerMarek Szyprowski <m.szyprowski@samsung.com>2019-09-06 13:44:31 +0200
commit46247a9428026c731d387344e96d0d14058d3bd8 (patch)
tree984fffd9edce38c97ea7afaab00d2b2d9f141842 /arch
parente232aca0b617daa46cbac74c3502d61d05cf85a8 (diff)
downloadlinux-exynos-46247a9428026c731d387344e96d0d14058d3bd8.tar.gz
linux-exynos-46247a9428026c731d387344e96d0d14058d3bd8.tar.bz2
linux-exynos-46247a9428026c731d387344e96d0d14058d3bd8.zip
ARM: exynos: Fix boot with CONFIG_SUSPEND disabled
Exynos SMP code relies on PMU registers to be mapped via pmu_base_addr. Those mapping is done in suspend.c:exynos_pmu_irq_init(), which is not called if CONFIG_SUSPEND is disabled. Fix this by moving PMU mapping creation to exynos.c:exynos_map_pmu(), which is called in all cases. Reported-by: Seung-Woo Kim <sw0312.kim@samsung.com> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Change-Id: Ic9dc37b18b63827b612fbc91e0f84509d4e8723b
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-exynos/exynos.c11
-rw-r--r--arch/arm/mach-exynos/suspend.c12
2 files changed, 8 insertions, 15 deletions
diff --git a/arch/arm/mach-exynos/exynos.c b/arch/arm/mach-exynos/exynos.c
index 1067d2f5425f..2026be578e4a 100644
--- a/arch/arm/mach-exynos/exynos.c
+++ b/arch/arm/mach-exynos/exynos.c
@@ -129,13 +129,16 @@ void exynos_set_delayed_reset_assertion(bool enable)
}
/*
- * Apparently, these SoCs are not able to wake-up from suspend using
- * the PMU. Too bad. Should they suddenly become capable of such a
- * feat, the matches below should be moved to suspend.c.
+ * Map PMU registers for smp code
*/
static const struct of_device_id exynos_dt_pmu_match[] = {
- { .compatible = "samsung,exynos5260-pmu" },
+ { .compatible = "samsung,exynos3250-pmu" },
+ { .compatible = "samsung,exynos4210-pmu" },
+ { .compatible = "samsung,exynos4412-pmu" },
{ .compatible = "samsung,exynos5410-pmu" },
+ { .compatible = "samsung,exynos5250-pmu" },
+ { .compatible = "samsung,exynos5260-pmu" },
+ { .compatible = "samsung,exynos5420-pmu" },
{ /*sentinel*/ },
};
diff --git a/arch/arm/mach-exynos/suspend.c b/arch/arm/mach-exynos/suspend.c
index 49bb92152fc3..ae5a67d7bfed 100644
--- a/arch/arm/mach-exynos/suspend.c
+++ b/arch/arm/mach-exynos/suspend.c
@@ -208,21 +208,11 @@ static int __init exynos_pmu_irq_init(struct device_node *node,
return -ENXIO;
}
- pmu_base_addr = of_iomap(node, 0);
-
- if (!pmu_base_addr) {
- pr_err("%pOF: failed to find exynos pmu register\n", node);
- return -ENOMEM;
- }
-
domain = irq_domain_add_hierarchy(parent_domain, 0, 0,
node, &exynos_pmu_domain_ops,
NULL);
- if (!domain) {
- iounmap(pmu_base_addr);
- pmu_base_addr = NULL;
+ if (!domain)
return -ENOMEM;
- }
/*
* Clear the OF_POPULATED flag set in of_irq_init so that