[RFC PATCH 09/11] x86/percpu: Remove pcpu_hot

Brian Gerst posted 11 patches 11 months, 2 weeks ago
[RFC PATCH 09/11] x86/percpu: Remove pcpu_hot
Posted by Brian Gerst 11 months, 2 weeks ago
All fields have been moved to the percpu hot section.

Signed-off-by: Brian Gerst <brgerst@gmail.com>
---
 arch/x86/include/asm/current.h | 11 -----------
 arch/x86/kernel/cpu/common.c   |  4 ----
 arch/x86/kernel/vmlinux.lds.S  |  1 -
 3 files changed, 16 deletions(-)

diff --git a/arch/x86/include/asm/current.h b/arch/x86/include/asm/current.h
index 043888c258bd..b6d1adb5538f 100644
--- a/arch/x86/include/asm/current.h
+++ b/arch/x86/include/asm/current.h
@@ -12,17 +12,6 @@
 
 struct task_struct;
 
-struct pcpu_hot {
-		u8	pad[64];
-};
-static_assert(sizeof(struct pcpu_hot) == 64);
-
-DECLARE_PER_CPU_ALIGNED(struct pcpu_hot, pcpu_hot);
-
-/* const-qualified alias to pcpu_hot, aliased by linker. */
-DECLARE_PER_CPU_ALIGNED(const struct pcpu_hot __percpu_seg_override,
-			const_pcpu_hot);
-
 DECLARE_PER_CPU_HOT(struct task_struct *, current_task);
 /* const-qualified alias provided by the linker. */
 DECLARE_PER_CPU_HOT(struct task_struct * const, const_current_task);
diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c
index f4ec6bcb2a5e..ba78ee8fdb21 100644
--- a/arch/x86/kernel/cpu/common.c
+++ b/arch/x86/kernel/cpu/common.c
@@ -2014,10 +2014,6 @@ static __init int setup_clearcpuid(char *arg)
 }
 __setup("clearcpuid=", setup_clearcpuid);
 
-DEFINE_PER_CPU_ALIGNED(struct pcpu_hot, pcpu_hot);
-EXPORT_PER_CPU_SYMBOL(pcpu_hot);
-EXPORT_PER_CPU_SYMBOL(const_pcpu_hot);
-
 DEFINE_PER_CPU_HOT(struct task_struct *, current_task) = &init_task;
 EXPORT_PER_CPU_SYMBOL(current_task);
 EXPORT_PER_CPU_SYMBOL(const_current_task);
diff --git a/arch/x86/kernel/vmlinux.lds.S b/arch/x86/kernel/vmlinux.lds.S
index 3c87bb620434..0cfdaa0e05a0 100644
--- a/arch/x86/kernel/vmlinux.lds.S
+++ b/arch/x86/kernel/vmlinux.lds.S
@@ -43,7 +43,6 @@ ENTRY(phys_startup_64)
 #endif
 
 jiffies = jiffies_64;
-const_pcpu_hot = pcpu_hot;
 const_current_task = current_task;
 const_cpu_current_top_of_stack = cpu_current_top_of_stack;
 
-- 
2.48.1