Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ARM: hisi: do not export smp_operations structures

These three structures are only defined and referenced in
mach-hisi/platsmp.c.

Drop the declarations from the header and add static qualifier
to the definitions.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Wei Xu <xuwei5@hisilicon.com>

authored by

Masahiro Yamada and committed by
Arnd Bergmann
635e958d 31ade3b8

+3 -6
-3
arch/arm/mach-hisi/core.h
··· 6 6 extern void hi3xxx_set_cpu_jump(int cpu, void *jump_addr); 7 7 extern int hi3xxx_get_cpu_jump(int cpu); 8 8 extern void secondary_startup(void); 9 - extern struct smp_operations hi3xxx_smp_ops; 10 9 11 10 extern void hi3xxx_cpu_die(unsigned int cpu); 12 11 extern int hi3xxx_cpu_kill(unsigned int cpu); 13 12 extern void hi3xxx_set_cpu(int cpu, bool enable); 14 13 15 - extern struct smp_operations hix5hd2_smp_ops; 16 14 extern void hix5hd2_set_cpu(int cpu, bool enable); 17 15 extern void hix5hd2_cpu_die(unsigned int cpu); 18 16 19 - extern struct smp_operations hip01_smp_ops; 20 17 extern void hip01_set_cpu(int cpu, bool enable); 21 18 extern void hip01_cpu_die(unsigned int cpu); 22 19 #endif
+3 -3
arch/arm/mach-hisi/platsmp.c
··· 89 89 return 0; 90 90 } 91 91 92 - struct smp_operations hi3xxx_smp_ops __initdata = { 92 + static struct smp_operations hi3xxx_smp_ops __initdata = { 93 93 .smp_prepare_cpus = hi3xxx_smp_prepare_cpus, 94 94 .smp_boot_secondary = hi3xxx_boot_secondary, 95 95 #ifdef CONFIG_HOTPLUG_CPU ··· 126 126 } 127 127 128 128 129 - struct smp_operations hix5hd2_smp_ops __initdata = { 129 + static struct smp_operations hix5hd2_smp_ops __initdata = { 130 130 .smp_prepare_cpus = hisi_common_smp_prepare_cpus, 131 131 .smp_boot_secondary = hix5hd2_boot_secondary, 132 132 #ifdef CONFIG_HOTPLUG_CPU ··· 176 176 return 0; 177 177 } 178 178 179 - struct smp_operations hip01_smp_ops __initdata = { 179 + static struct smp_operations hip01_smp_ops __initdata = { 180 180 .smp_prepare_cpus = hisi_common_smp_prepare_cpus, 181 181 .smp_boot_secondary = hip01_boot_secondary, 182 182 };