diff options
author | Chenhui Zhao <chenhui.zhao@freescale.com> | 2014-11-13 10:44:57 (GMT) |
---|---|---|
committer | Matthew Weigel <Matthew.Weigel@freescale.com> | 2014-12-11 18:40:51 (GMT) |
commit | 041dfe28b40efafb00a73e7cf35ed28ffc0c4c14 (patch) | |
tree | 769538d562f3cf12e3c4c767ddd959544e4f8903 | |
parent | 64a295a952381bdd7f8064376a5034b4c0d5f9da (diff) | |
download | linux-fsl-qoriq-041dfe28b40efafb00a73e7cf35ed28ffc0c4c14.tar.xz |
powerpc/rcpm: fix compile error with non-SMP mode
Add asm/smp.h, and only compile the cluster related code
when CPU hotplug is enabled.
Change-Id: I264ff297ca1ee29bf8c477b09bce98eeb27140ee
Signed-off-by: Chenhui Zhao <chenhui.zhao@freescale.com>
Reviewed-on: http://git.am.freescale.net:8181/23752
Reviewed-by: Yang Li <LeoLi@freescale.com>
Reviewed-by: Zhuoyu Zhang <Zhuoyu.Zhang@freescale.com>
Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com>
Reviewed-by: Matthew Weigel <Matthew.Weigel@freescale.com>
-rw-r--r-- | arch/powerpc/sysdev/fsl_rcpm.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/powerpc/sysdev/fsl_rcpm.c b/arch/powerpc/sysdev/fsl_rcpm.c index 6621346..d410b9a 100644 --- a/arch/powerpc/sysdev/fsl_rcpm.c +++ b/arch/powerpc/sysdev/fsl_rcpm.c @@ -20,6 +20,7 @@ #include <asm/cputhreads.h> #include <asm/fsl_pm.h> #include <asm/machdep.h> +#include <asm/smp.h> #include <platforms/85xx/smp.h> @@ -242,6 +243,7 @@ static void rcpm_v2_cpu_exit_state(int cpu, int state) } } +#ifdef CONFIG_HOTPLUG_CPU static void rcpm_v2_cluster_enter_state(int cpu, int state) { int hw_cpu; @@ -278,6 +280,7 @@ static void rcpm_v2_cluster_exit_state(int cpu, int state) pr_err("%s: Unknown cluster PM state (%d)\n", __func__, state); } } +#endif static int rcpm_v2_plat_enter_state(int state) @@ -354,6 +357,7 @@ bool rcpm_v2_cpu_ready(unsigned int cpu, int state) if (in_be32(&rcpm_v2_regs->pcph30sr) & mask) ret = true; break; +#ifdef CONFIG_HOTPLUG_CPU case E500_PM_PCL10: /* PCL10 state is only supported on e6500 for now. */ mask = 1 << (hw_cpu / THREAD_IN_CLUSTER); @@ -361,6 +365,7 @@ bool rcpm_v2_cpu_ready(unsigned int cpu, int state) if (in_be32(&rcpm_v2_regs->clpcl10sr) & mask) ret = true; break; +#endif default: pr_err("%s: Unknown platform PM state (%d)\n", __func__, state); @@ -386,8 +391,10 @@ static const struct fsl_pm_ops qoriq_rcpm_v2_ops = { .irq_unmask = rcpm_v2_irq_unmask, .cpu_enter_state = rcpm_v2_cpu_enter_state, .cpu_exit_state = rcpm_v2_cpu_exit_state, +#ifdef CONFIG_HOTPLUG_CPU .cluster_enter_state = rcpm_v2_cluster_enter_state, .cluster_exit_state = rcpm_v2_cluster_exit_state, +#endif .plat_enter_state = rcpm_v2_plat_enter_state, .set_ip_power = rcpm_v2_set_ip_power, .freeze_time_base = rcpm_v2_freeze_time_base, |