diff options
Diffstat (limited to 'arch/mips/ite-boards/generic/irq.c')
| -rw-r--r-- | arch/mips/ite-boards/generic/irq.c | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/arch/mips/ite-boards/generic/irq.c b/arch/mips/ite-boards/generic/irq.c index e67f96129491..77be7216bdd0 100644 --- a/arch/mips/ite-boards/generic/irq.c +++ b/arch/mips/ite-boards/generic/irq.c | |||
| @@ -62,12 +62,8 @@ | |||
| 62 | 62 | ||
| 63 | #define ALLINTS_NOTIMER (IE_IRQ0 | IE_IRQ1 | IE_IRQ2 | IE_IRQ3 | IE_IRQ4) | 63 | #define ALLINTS_NOTIMER (IE_IRQ0 | IE_IRQ1 | IE_IRQ2 | IE_IRQ3 | IE_IRQ4) |
| 64 | 64 | ||
| 65 | void disable_it8172_irq(unsigned int irq_nr); | ||
| 66 | void enable_it8172_irq(unsigned int irq_nr); | ||
| 67 | |||
| 68 | extern void set_debug_traps(void); | 65 | extern void set_debug_traps(void); |
| 69 | extern void mips_timer_interrupt(int irq, struct pt_regs *regs); | 66 | extern void mips_timer_interrupt(int irq, struct pt_regs *regs); |
| 70 | extern asmlinkage void it8172_IRQ(void); | ||
| 71 | 67 | ||
| 72 | struct it8172_intc_regs volatile *it8172_hw0_icregs = | 68 | struct it8172_intc_regs volatile *it8172_hw0_icregs = |
| 73 | (struct it8172_intc_regs volatile *)(KSEG1ADDR(IT8172_PCI_IO_BASE + IT_INTC_BASE)); | 69 | (struct it8172_intc_regs volatile *)(KSEG1ADDR(IT8172_PCI_IO_BASE + IT_INTC_BASE)); |
| @@ -181,8 +177,6 @@ void __init arch_init_irq(void) | |||
| 181 | int i; | 177 | int i; |
| 182 | unsigned long flags; | 178 | unsigned long flags; |
| 183 | 179 | ||
| 184 | set_except_vector(0, it8172_IRQ); | ||
| 185 | |||
| 186 | /* mask all interrupts */ | 180 | /* mask all interrupts */ |
| 187 | it8172_hw0_icregs->lb_mask = 0xffff; | 181 | it8172_hw0_icregs->lb_mask = 0xffff; |
| 188 | it8172_hw0_icregs->lpc_mask = 0xffff; | 182 | it8172_hw0_icregs->lpc_mask = 0xffff; |
| @@ -282,6 +276,18 @@ void it8172_hw0_irqdispatch(struct pt_regs *regs) | |||
| 282 | do_IRQ(irq, regs); | 276 | do_IRQ(irq, regs); |
| 283 | } | 277 | } |
| 284 | 278 | ||
| 279 | asmlinkage void plat_irq_dispatch(struct pt_regs *regs) | ||
| 280 | { | ||
| 281 | unsigned int pending = read_c0_cause() & read_c0_status() & ST0_IM; | ||
| 282 | |||
| 283 | if (!pending) | ||
| 284 | mips_spurious_interrupt(regs); | ||
| 285 | else if (pending & CAUSEF_IP7) | ||
| 286 | ll_timer_interrupt(127, regs); | ||
| 287 | else if (pending & CAUSEF_IP2) | ||
| 288 | it8172_hw0_irqdispatch(regs); | ||
| 289 | } | ||
| 290 | |||
| 285 | void show_pending_irqs(void) | 291 | void show_pending_irqs(void) |
| 286 | { | 292 | { |
| 287 | fputs("intstatus: "); | 293 | fputs("intstatus: "); |
