From 4b7ae9cf2c37c66e03889f5edf81b446f8ba2634 Mon Sep 17 00:00:00 2001 From: Kyle McMartin Date: Tue, 29 Jul 2008 00:11:13 -0400 Subject: [PATCH] --- yaml --- r: 116748 b: refs/heads/master c: 089d55289db5d58d938d73b47a415b2b82ee19ac h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/arch/parisc/kernel/head.S | 2 +- trunk/arch/parisc/kernel/setup.c | 27 ++++++++++++++++++++++++++- 3 files changed, 28 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index 8efa0d47d0e7..9f3fdd8448e3 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 24b574d052a1996bac42fbd56715ab602092c291 +refs/heads/master: 089d55289db5d58d938d73b47a415b2b82ee19ac diff --git a/trunk/arch/parisc/kernel/head.S b/trunk/arch/parisc/kernel/head.S index a84e31e82876..0e3d9f9b9e33 100644 --- a/trunk/arch/parisc/kernel/head.S +++ b/trunk/arch/parisc/kernel/head.S @@ -121,7 +121,7 @@ $pgt_fill_loop: copy %r0,%r2 /* And the RFI Target address too */ - load32 start_kernel,%r11 + load32 start_parisc,%r11 /* And the initial task pointer */ load32 init_thread_union,%r6 diff --git a/trunk/arch/parisc/kernel/setup.c b/trunk/arch/parisc/kernel/setup.c index 39e7c5a5946a..a59b71efdbe5 100644 --- a/trunk/arch/parisc/kernel/setup.c +++ b/trunk/arch/parisc/kernel/setup.c @@ -368,6 +368,31 @@ static int __init parisc_init(void) return 0; } - arch_initcall(parisc_init); +void start_parisc(void) +{ + extern void start_kernel(void); + + int ret, cpunum; + struct pdc_coproc_cfg coproc_cfg; + + cpunum = smp_processor_id(); + + set_firmware_width_unlocked(); + + ret = pdc_coproc_cfg_unlocked(&coproc_cfg); + if (ret >= 0 && coproc_cfg.ccr_functional) { + mtctl(coproc_cfg.ccr_functional, 10); + + cpu_data[cpunum].fp_rev = coproc_cfg.revision; + cpu_data[cpunum].fp_model = coproc_cfg.model; + + asm volatile ("fstd %fr0,8(%sp)"); + } else { + panic("must have an fpu to boot linux"); + } + + start_kernel(); + // not reached +}