diff options
-rw-r--r-- | arch/sparc64/kernel/cpu.c | 10 | ||||
-rw-r--r-- | arch/sparc64/kernel/entry.h | 15 | ||||
-rw-r--r-- | arch/sparc64/kernel/setup.c | 5 | ||||
-rw-r--r-- | arch/sparc64/mm/init.c | 1 | ||||
-rw-r--r-- | include/asm-sparc64/cpudata.h | 2 |
5 files changed, 26 insertions, 7 deletions
diff --git a/arch/sparc64/kernel/cpu.c b/arch/sparc64/kernel/cpu.c index dd5d28e3d798..0097c08dc600 100644 --- a/arch/sparc64/kernel/cpu.c +++ b/arch/sparc64/kernel/cpu.c | |||
@@ -15,6 +15,8 @@ | |||
15 | #include <asm/spitfire.h> | 15 | #include <asm/spitfire.h> |
16 | #include <asm/oplib.h> | 16 | #include <asm/oplib.h> |
17 | 17 | ||
18 | #include "entry.h" | ||
19 | |||
18 | DEFINE_PER_CPU(cpuinfo_sparc, __cpu_data) = { 0 }; | 20 | DEFINE_PER_CPU(cpuinfo_sparc, __cpu_data) = { 0 }; |
19 | 21 | ||
20 | struct cpu_iu_info { | 22 | struct cpu_iu_info { |
@@ -65,8 +67,6 @@ static struct cpu_iu_info linux_sparc_chips[] = { | |||
65 | char *sparc_cpu_type; | 67 | char *sparc_cpu_type; |
66 | char *sparc_fpu_type; | 68 | char *sparc_fpu_type; |
67 | 69 | ||
68 | unsigned int fsr_storage; | ||
69 | |||
70 | static void __init sun4v_cpu_probe(void) | 70 | static void __init sun4v_cpu_probe(void) |
71 | { | 71 | { |
72 | switch (sun4v_chip_type) { | 72 | switch (sun4v_chip_type) { |
@@ -94,8 +94,10 @@ void __init cpu_probe(void) | |||
94 | unsigned long ver, fpu_vers, manuf, impl, fprs; | 94 | unsigned long ver, fpu_vers, manuf, impl, fprs; |
95 | int i; | 95 | int i; |
96 | 96 | ||
97 | if (tlb_type == hypervisor) | 97 | if (tlb_type == hypervisor) { |
98 | return sun4v_cpu_probe(); | 98 | sun4v_cpu_probe(); |
99 | return; | ||
100 | } | ||
99 | 101 | ||
100 | fprs = fprs_read(); | 102 | fprs = fprs_read(); |
101 | fprs_write(FPRS_FEF); | 103 | fprs_write(FPRS_FEF); |
diff --git a/arch/sparc64/kernel/entry.h b/arch/sparc64/kernel/entry.h new file mode 100644 index 000000000000..bfcd1b8d23dc --- /dev/null +++ b/arch/sparc64/kernel/entry.h | |||
@@ -0,0 +1,15 @@ | |||
1 | #ifndef _ENTRY_H | ||
2 | #define _ENTRY_H | ||
3 | |||
4 | #include <linux/init.h> | ||
5 | |||
6 | extern char *sparc_cpu_type; | ||
7 | extern char *sparc_fpu_type; | ||
8 | |||
9 | extern void __init per_cpu_patch(void); | ||
10 | extern void __init sun4v_patch(void); | ||
11 | extern void __init boot_cpu_id_too_large(int cpu); | ||
12 | extern unsigned int dcache_parity_tl1_occurred; | ||
13 | extern unsigned int icache_parity_tl1_occurred; | ||
14 | |||
15 | #endif /* _ENTRY_H */ | ||
diff --git a/arch/sparc64/kernel/setup.c b/arch/sparc64/kernel/setup.c index d036dbe72864..6acb4c51cfe4 100644 --- a/arch/sparc64/kernel/setup.c +++ b/arch/sparc64/kernel/setup.c | |||
@@ -51,6 +51,8 @@ | |||
51 | #include <net/ipconfig.h> | 51 | #include <net/ipconfig.h> |
52 | #endif | 52 | #endif |
53 | 53 | ||
54 | #include "entry.h" | ||
55 | |||
54 | /* Used to synchronize accesses to NatSemi SUPER I/O chip configure | 56 | /* Used to synchronize accesses to NatSemi SUPER I/O chip configure |
55 | * operations in asm/ns87303.h | 57 | * operations in asm/ns87303.h |
56 | */ | 58 | */ |
@@ -335,9 +337,6 @@ void __init setup_arch(char **cmdline_p) | |||
335 | 337 | ||
336 | /* BUFFER is PAGE_SIZE bytes long. */ | 338 | /* BUFFER is PAGE_SIZE bytes long. */ |
337 | 339 | ||
338 | extern char *sparc_cpu_type; | ||
339 | extern char *sparc_fpu_type; | ||
340 | |||
341 | extern void smp_info(struct seq_file *); | 340 | extern void smp_info(struct seq_file *); |
342 | extern void smp_bogo(struct seq_file *); | 341 | extern void smp_bogo(struct seq_file *); |
343 | extern void mmu_info(struct seq_file *); | 342 | extern void mmu_info(struct seq_file *); |
diff --git a/arch/sparc64/mm/init.c b/arch/sparc64/mm/init.c index 466fd6cffac9..fced6dfe77a8 100644 --- a/arch/sparc64/mm/init.c +++ b/arch/sparc64/mm/init.c | |||
@@ -46,6 +46,7 @@ | |||
46 | #include <asm/prom.h> | 46 | #include <asm/prom.h> |
47 | #include <asm/sstate.h> | 47 | #include <asm/sstate.h> |
48 | #include <asm/mdesc.h> | 48 | #include <asm/mdesc.h> |
49 | #include <asm/cpudata.h> | ||
49 | 50 | ||
50 | #define MAX_PHYS_ADDRESS (1UL << 42UL) | 51 | #define MAX_PHYS_ADDRESS (1UL << 42UL) |
51 | #define KPTE_BITMAP_CHUNK_SZ (256UL * 1024UL * 1024UL) | 52 | #define KPTE_BITMAP_CHUNK_SZ (256UL * 1024UL * 1024UL) |
diff --git a/include/asm-sparc64/cpudata.h b/include/asm-sparc64/cpudata.h index 542421460a12..532975ecfe10 100644 --- a/include/asm-sparc64/cpudata.h +++ b/include/asm-sparc64/cpudata.h | |||
@@ -86,6 +86,8 @@ extern struct trap_per_cpu trap_block[NR_CPUS]; | |||
86 | extern void init_cur_cpu_trap(struct thread_info *); | 86 | extern void init_cur_cpu_trap(struct thread_info *); |
87 | extern void setup_tba(void); | 87 | extern void setup_tba(void); |
88 | extern int ncpus_probed; | 88 | extern int ncpus_probed; |
89 | extern void __init cpu_probe(void); | ||
90 | extern const struct seq_operations cpuinfo_op; | ||
89 | 91 | ||
90 | extern unsigned long real_hard_smp_processor_id(void); | 92 | extern unsigned long real_hard_smp_processor_id(void); |
91 | 93 | ||