x86/CPU: Move cpu local function declarations to local header
authorThomas Gleixner <tglx@linutronix.de>
Sun, 13 May 2018 09:29:07 +0000 (11:29 +0200)
committerThomas Gleixner <tglx@linutronix.de>
Sun, 13 May 2018 10:06:12 +0000 (12:06 +0200)
No point in exposing all these functions globaly as they are strict local
to the cpu management code.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
arch/x86/include/asm/processor.h
arch/x86/kernel/cpu/cacheinfo.c
arch/x86/kernel/cpu/cpu.h

index 7aa2caa82b2d119b192052d8ba7bb2aba4f96438..d68554613ecded8fd2f136f526ebfdad52d07575 100644 (file)
@@ -186,15 +186,6 @@ extern void identify_boot_cpu(void);
 extern void identify_secondary_cpu(struct cpuinfo_x86 *);
 extern void print_cpu_info(struct cpuinfo_x86 *);
 void print_cpu_msr(struct cpuinfo_x86 *);
-extern void init_scattered_cpuid_features(struct cpuinfo_x86 *c);
-extern u32 get_scattered_cpuid_leaf(unsigned int level,
-                                   unsigned int sub_leaf,
-                                   enum cpuid_regs_idx reg);
-extern unsigned int init_intel_cacheinfo(struct cpuinfo_x86 *c);
-extern void init_amd_cacheinfo(struct cpuinfo_x86 *c);
-
-extern int detect_extended_topology(struct cpuinfo_x86 *c);
-extern void detect_ht(struct cpuinfo_x86 *c);
 
 #ifdef CONFIG_X86_32
 extern int have_cpuid_p(void);
index a2e03c9401a126f72b82291ae0e6444dfc85577d..58d472c84ba256d264671100c6b3de061f822a1c 100644 (file)
@@ -20,6 +20,8 @@
 #include <asm/amd_nb.h>
 #include <asm/smp.h>
 
+#include "cpu.h"
+
 #define LVL_1_INST     1
 #define LVL_1_DATA     2
 #define LVL_2          3
index e806b11a99af4c72c5868731c7a8555cfb3957d9..c415f99e959980aeceffc64b691fffb6be7a3c87 100644 (file)
@@ -47,6 +47,15 @@ extern const struct cpu_dev *const __x86_cpu_dev_start[],
 
 extern void get_cpu_cap(struct cpuinfo_x86 *c);
 extern void cpu_detect_cache_sizes(struct cpuinfo_x86 *c);
+extern void init_scattered_cpuid_features(struct cpuinfo_x86 *c);
+extern u32 get_scattered_cpuid_leaf(unsigned int level,
+                                   unsigned int sub_leaf,
+                                   enum cpuid_regs_idx reg);
+extern unsigned int init_intel_cacheinfo(struct cpuinfo_x86 *c);
+extern void init_amd_cacheinfo(struct cpuinfo_x86 *c);
+
+extern int detect_extended_topology(struct cpuinfo_x86 *c);
+extern void detect_ht(struct cpuinfo_x86 *c);
 
 unsigned int aperfmperf_get_khz(int cpu);