aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
Diffstat (limited to 'arch')
-rw-r--r--arch/x86/kernel/smpboot.c28
-rw-r--r--arch/x86/kernel/smpboot_32.c27
-rw-r--r--arch/x86/kernel/smpboot_64.c33
3 files changed, 28 insertions, 60 deletions
diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c
index bffe10861390..40a3b56952ef 100644
--- a/arch/x86/kernel/smpboot.c
+++ b/arch/x86/kernel/smpboot.c
@@ -1,6 +1,34 @@
1#include <linux/init.h> 1#include <linux/init.h>
2#include <linux/smp.h> 2#include <linux/smp.h>
3#include <linux/module.h>
3 4
5/* Number of siblings per CPU package */
6int smp_num_siblings = 1;
7EXPORT_SYMBOL(smp_num_siblings);
8
9/* Last level cache ID of each logical CPU */
10DEFINE_PER_CPU(u16, cpu_llc_id) = BAD_APICID;
11
12/* bitmap of online cpus */
13cpumask_t cpu_online_map __read_mostly;
14EXPORT_SYMBOL(cpu_online_map);
15
16cpumask_t cpu_callin_map;
17cpumask_t cpu_callout_map;
18cpumask_t cpu_possible_map;
19EXPORT_SYMBOL(cpu_possible_map);
20
21/* representing HT siblings of each logical CPU */
22DEFINE_PER_CPU(cpumask_t, cpu_sibling_map);
23EXPORT_PER_CPU_SYMBOL(cpu_sibling_map);
24
25/* representing HT and core siblings of each logical CPU */
26DEFINE_PER_CPU(cpumask_t, cpu_core_map);
27EXPORT_PER_CPU_SYMBOL(cpu_core_map);
28
29/* Per CPU bogomips and other parameters */
30DEFINE_PER_CPU_SHARED_ALIGNED(struct cpuinfo_x86, cpu_info);
31EXPORT_PER_CPU_SYMBOL(cpu_info);
4#ifdef CONFIG_HOTPLUG_CPU 32#ifdef CONFIG_HOTPLUG_CPU
5 33
6int additional_cpus __initdata = -1; 34int additional_cpus __initdata = -1;
diff --git a/arch/x86/kernel/smpboot_32.c b/arch/x86/kernel/smpboot_32.c
index 5a446f079b33..0fbc98163b4e 100644
--- a/arch/x86/kernel/smpboot_32.c
+++ b/arch/x86/kernel/smpboot_32.c
@@ -62,35 +62,8 @@
62/* Set if we find a B stepping CPU */ 62/* Set if we find a B stepping CPU */
63static int __cpuinitdata smp_b_stepping; 63static int __cpuinitdata smp_b_stepping;
64 64
65/* Number of siblings per CPU package */
66int smp_num_siblings = 1;
67EXPORT_SYMBOL(smp_num_siblings);
68
69/* Last level cache ID of each logical CPU */
70DEFINE_PER_CPU(u16, cpu_llc_id) = BAD_APICID;
71
72/* representing HT siblings of each logical CPU */
73DEFINE_PER_CPU(cpumask_t, cpu_sibling_map);
74EXPORT_PER_CPU_SYMBOL(cpu_sibling_map);
75
76/* representing HT and core siblings of each logical CPU */
77DEFINE_PER_CPU(cpumask_t, cpu_core_map);
78EXPORT_PER_CPU_SYMBOL(cpu_core_map);
79
80/* bitmap of online cpus */
81cpumask_t cpu_online_map __read_mostly;
82EXPORT_SYMBOL(cpu_online_map);
83
84cpumask_t cpu_callin_map;
85cpumask_t cpu_callout_map;
86cpumask_t cpu_possible_map;
87EXPORT_SYMBOL(cpu_possible_map);
88static cpumask_t smp_commenced_mask; 65static cpumask_t smp_commenced_mask;
89 66
90/* Per CPU bogomips and other parameters */
91DEFINE_PER_CPU_SHARED_ALIGNED(struct cpuinfo_x86, cpu_info);
92EXPORT_PER_CPU_SYMBOL(cpu_info);
93
94/* which logical CPU number maps to which CPU (physical APIC ID) */ 67/* which logical CPU number maps to which CPU (physical APIC ID) */
95u16 x86_cpu_to_apicid_init[NR_CPUS] __initdata = 68u16 x86_cpu_to_apicid_init[NR_CPUS] __initdata =
96 { [0 ... NR_CPUS-1] = BAD_APICID }; 69 { [0 ... NR_CPUS-1] = BAD_APICID };
diff --git a/arch/x86/kernel/smpboot_64.c b/arch/x86/kernel/smpboot_64.c
index 953b0ff72b65..c51279f05316 100644
--- a/arch/x86/kernel/smpboot_64.c
+++ b/arch/x86/kernel/smpboot_64.c
@@ -60,42 +60,9 @@
60#include <asm/hw_irq.h> 60#include <asm/hw_irq.h>
61#include <asm/numa.h> 61#include <asm/numa.h>
62 62
63/* Number of siblings per CPU package */
64int smp_num_siblings = 1;
65EXPORT_SYMBOL(smp_num_siblings);
66
67/* Last level cache ID of each logical CPU */
68DEFINE_PER_CPU(u16, cpu_llc_id) = BAD_APICID;
69
70/* Bitmask of currently online CPUs */
71cpumask_t cpu_online_map __read_mostly;
72
73EXPORT_SYMBOL(cpu_online_map);
74
75/*
76 * Private maps to synchronize booting between AP and BP.
77 * Probably not needed anymore, but it makes for easier debugging. -AK
78 */
79cpumask_t cpu_callin_map;
80cpumask_t cpu_callout_map;
81cpumask_t cpu_possible_map;
82EXPORT_SYMBOL(cpu_possible_map);
83
84/* Per CPU bogomips and other parameters */
85DEFINE_PER_CPU_SHARED_ALIGNED(struct cpuinfo_x86, cpu_info);
86EXPORT_PER_CPU_SYMBOL(cpu_info);
87
88/* Set when the idlers are all forked */ 63/* Set when the idlers are all forked */
89int smp_threads_ready; 64int smp_threads_ready;
90 65
91/* representing HT siblings of each logical CPU */
92DEFINE_PER_CPU(cpumask_t, cpu_sibling_map);
93EXPORT_PER_CPU_SYMBOL(cpu_sibling_map);
94
95/* representing HT and core siblings of each logical CPU */
96DEFINE_PER_CPU(cpumask_t, cpu_core_map);
97EXPORT_PER_CPU_SYMBOL(cpu_core_map);
98
99/* 66/*
100 * Trampoline 80x86 program as an array. 67 * Trampoline 80x86 program as an array.
101 */ 68 */