]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ARM: socfpga: hide unused functions
authorArnd Bergmann <arnd@arndb.de>
Tue, 23 Feb 2016 14:08:42 +0000 (15:08 +0100)
committerArnd Bergmann <arnd@arndb.de>
Fri, 26 Feb 2016 16:44:54 +0000 (17:44 +0100)
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 <arnd@arndb.de>
Acked-by: Dinh Nguyen <dinguyen@opensource.altera.com>
arch/arm/mach-socfpga/platsmp.c

index cbb0a54df80ac6e4eff2d463b7ae7634f363959f..07945748b57141f2c216d729a6f895d36227be7a 100644 (file)
@@ -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
  *
@@ -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,