Skip to content

Commit

Permalink
ARM: socfpga: hide unused functions
Browse files Browse the repository at this point in the history
The cpu_die and cpu_kill callbacks are only used when CONFIG_HOTPLUG_CPU
is enabled, otherwise we get a warning about them:

arch/arm/mach-socfpga/platsmp.c:102:13: error: 'socfpga_cpu_die' defined but not used [-Werror=unused-function]
arch/arm/mach-socfpga/platsmp.c:115:12: error: 'socfpga_cpu_kill' defined but not used [-Werror=unused-function]

This adds the appropriate #ifdef.

Signed-off-by: Arnd Bergmann <[email protected]>
Acked-by: Dinh Nguyen <[email protected]>
  • Loading branch information
arndb committed Feb 26, 2016
1 parent 302cff1 commit 5d37e80
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions arch/arm/mach-socfpga/platsmp.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ static void __init socfpga_smp_prepare_cpus(unsigned int max_cpus)
scu_enable(socfpga_scu_base_addr);
}

#ifdef CONFIG_HOTPLUG_CPU
/*
* platform-specific code to shutdown a CPU
*
Expand All @@ -116,6 +117,7 @@ static int socfpga_cpu_kill(unsigned int cpu)
{
return 1;
}
#endif

static const struct smp_operations socfpga_smp_ops __initconst = {
.smp_prepare_cpus = socfpga_smp_prepare_cpus,
Expand Down

0 comments on commit 5d37e80

Please sign in to comment.