aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/setup_32.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc/kernel/setup_32.c')
-rw-r--r--arch/powerpc/kernel/setup_32.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/setup_32.c b/arch/powerpc/kernel/setup_32.c
index 36f6779c88d4..5112a4aa801d 100644
--- a/arch/powerpc/kernel/setup_32.c
+++ b/arch/powerpc/kernel/setup_32.c
@@ -16,6 +16,7 @@
16#include <linux/root_dev.h> 16#include <linux/root_dev.h>
17#include <linux/cpu.h> 17#include <linux/cpu.h>
18#include <linux/console.h> 18#include <linux/console.h>
19#include <linux/lmb.h>
19 20
20#include <asm/io.h> 21#include <asm/io.h>
21#include <asm/prom.h> 22#include <asm/prom.h>
@@ -229,6 +230,24 @@ int __init ppc_init(void)
229 230
230arch_initcall(ppc_init); 231arch_initcall(ppc_init);
231 232
233#ifdef CONFIG_IRQSTACKS
234static void __init irqstack_early_init(void)
235{
236 unsigned int i;
237
238 /* interrupt stacks must be in lowmem, we get that for free on ppc32
239 * as the lmb is limited to lowmem by LMB_REAL_LIMIT */
240 for_each_possible_cpu(i) {
241 softirq_ctx[i] = (struct thread_info *)
242 __va(lmb_alloc(THREAD_SIZE, THREAD_SIZE));
243 hardirq_ctx[i] = (struct thread_info *)
244 __va(lmb_alloc(THREAD_SIZE, THREAD_SIZE));
245 }
246}
247#else
248#define irqstack_early_init()
249#endif
250
232/* Warning, IO base is not yet inited */ 251/* Warning, IO base is not yet inited */
233void __init setup_arch(char **cmdline_p) 252void __init setup_arch(char **cmdline_p)
234{ 253{
@@ -286,6 +305,8 @@ void __init setup_arch(char **cmdline_p)
286 init_mm.end_data = (unsigned long) _edata; 305 init_mm.end_data = (unsigned long) _edata;
287 init_mm.brk = klimit; 306 init_mm.brk = klimit;
288 307
308 irqstack_early_init();
309
289 /* set up the bootmem stuff with available memory */ 310 /* set up the bootmem stuff with available memory */
290 do_init_bootmem(); 311 do_init_bootmem();
291 if ( ppc_md.progress ) ppc_md.progress("setup_arch: bootmem", 0x3eab); 312 if ( ppc_md.progress ) ppc_md.progress("setup_arch: bootmem", 0x3eab);