MIPS: DEC: Remove the Halt button interrupt on R4k systems
authorMaciej W. Rozycki <macro@linux-mips.org>
Sun, 6 Apr 2014 21:06:28 +0000 (22:06 +0100)
committerRalf Baechle <ralf@linux-mips.org>
Fri, 30 May 2014 19:01:08 +0000 (21:01 +0200)
On R4k DECstations the Halt button is wired to the NMI processor input
rather than an ordinary interrupt input such as on R3k DECstations.  This
is possible with a different design of the CPU daughtercard that routes
the Halt button line from the baseboard connector.  Additionally the
interrupt input has been reused for a different purpose on the KN04 and
KN05 R4k CPU daughtercards so it is better kept masked.

Signed-off-by: Maciej W. Rozycki <macro@linux-mips.org>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/6705/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/dec/setup.c

index 56e6e2c..41bbffd 100644 (file)
@@ -23,6 +23,7 @@
 #include <asm/bootinfo.h>
 #include <asm/cpu.h>
 #include <asm/cpu-features.h>
+#include <asm/cpu-type.h>
 #include <asm/irq.h>
 #include <asm/irq_cpu.h>
 #include <asm/mipsregs.h>
@@ -748,6 +749,10 @@ void __init arch_init_irq(void)
                cpu_fpu_mask = 0;
                dec_interrupt[DEC_IRQ_FPU] = -1;
        }
+       /* Free the halt interrupt unused on R4k systems.  */
+       if (current_cpu_type() == CPU_R4000SC ||
+           current_cpu_type() == CPU_R4400SC)
+               dec_interrupt[DEC_IRQ_HALT] = -1;
 
        /* Register board interrupts: FPU and cascade. */
        if (dec_interrupt[DEC_IRQ_FPU] >= 0)