diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2007-10-11 18:46:09 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2007-10-11 18:46:09 -0400 |
commit | 7bcf7717b6a047c272410d0cd00213185fe6b99d (patch) | |
tree | 81c5d6bbc2130815713e22bb5408ea80b6e1c499 /arch/mips/qemu | |
parent | 91a2fcc88634663e9e13dcdfad0e4a860e64aeee (diff) |
[MIPS] Implement clockevents for R4000-style cp0 count/compare interrupt
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/qemu')
-rw-r--r-- | arch/mips/qemu/q-irq.c | 4 | ||||
-rw-r--r-- | arch/mips/qemu/q-setup.c | 1 |
2 files changed, 3 insertions, 2 deletions
diff --git a/arch/mips/qemu/q-irq.c b/arch/mips/qemu/q-irq.c index 89891e984b3b..4681757460a1 100644 --- a/arch/mips/qemu/q-irq.c +++ b/arch/mips/qemu/q-irq.c | |||
@@ -2,6 +2,7 @@ | |||
2 | #include <linux/linkage.h> | 2 | #include <linux/linkage.h> |
3 | 3 | ||
4 | #include <asm/i8259.h> | 4 | #include <asm/i8259.h> |
5 | #include <asm/irq_cpu.h> | ||
5 | #include <asm/mipsregs.h> | 6 | #include <asm/mipsregs.h> |
6 | #include <asm/qemu.h> | 7 | #include <asm/qemu.h> |
7 | #include <asm/system.h> | 8 | #include <asm/system.h> |
@@ -12,7 +13,7 @@ asmlinkage void plat_irq_dispatch(void) | |||
12 | unsigned int pending = read_c0_status() & read_c0_cause(); | 13 | unsigned int pending = read_c0_status() & read_c0_cause(); |
13 | 14 | ||
14 | if (pending & 0x8000) { | 15 | if (pending & 0x8000) { |
15 | ll_timer_interrupt(Q_COUNT_COMPARE_IRQ); | 16 | do_IRQ(Q_COUNT_COMPARE_IRQ); |
16 | return; | 17 | return; |
17 | } | 18 | } |
18 | if (pending & 0x0400) { | 19 | if (pending & 0x0400) { |
@@ -29,6 +30,7 @@ void __init arch_init_irq(void) | |||
29 | { | 30 | { |
30 | mips_hpt_frequency = QEMU_C0_COUNTER_CLOCK; /* 100MHz */ | 31 | mips_hpt_frequency = QEMU_C0_COUNTER_CLOCK; /* 100MHz */ |
31 | 32 | ||
33 | mips_cpu_irq_init(); | ||
32 | init_i8259_irqs(); | 34 | init_i8259_irqs(); |
33 | set_c0_status(0x8400); | 35 | set_c0_status(0x8400); |
34 | } | 36 | } |
diff --git a/arch/mips/qemu/q-setup.c b/arch/mips/qemu/q-setup.c index 841394336f00..89a207650ce9 100644 --- a/arch/mips/qemu/q-setup.c +++ b/arch/mips/qemu/q-setup.c | |||
@@ -17,7 +17,6 @@ void __init plat_timer_setup(struct irqaction *irq) | |||
17 | outb_p(0x34,0x43); /* binary, mode 2, LSB/MSB, ch 0 */ | 17 | outb_p(0x34,0x43); /* binary, mode 2, LSB/MSB, ch 0 */ |
18 | outb_p(LATCH & 0xff , 0x40); /* LSB */ | 18 | outb_p(LATCH & 0xff , 0x40); /* LSB */ |
19 | outb(LATCH >> 8 , 0x40); /* MSB */ | 19 | outb(LATCH >> 8 , 0x40); /* MSB */ |
20 | setup_irq(0, irq); | ||
21 | } | 20 | } |
22 | 21 | ||
23 | void __init plat_mem_setup(void) | 22 | void __init plat_mem_setup(void) |