OpenCores
URL https://opencores.org/ocsvn/aor3000/aor3000/trunk

Subversion Repositories aor3000

[/] [aor3000/] [trunk/] [linux/] [arch/] [mips/] [aor3000/] [irq.c] - Blame information for rev 2

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 alfik
/*
2
 * This file is subject to the terms and conditions of the GNU General Public
3
 * License.  See the file "COPYING" in the main directory of this archive
4
 * for more details.
5
 *
6
 * Copyright (C) 2014 Aleksander Osman
7
 */
8
 
9
#include <linux/interrupt.h>
10
 
11
#include <asm/irq_cpu.h>
12
#include <asm/mipsregs.h>
13
 
14
asmlinkage void plat_irq_dispatch(void)
15
{
16
    unsigned int pending;
17
 
18
    pending = read_c0_cause() & read_c0_status() & ST0_IM;
19
 
20
    if (pending & CAUSEF_IP2)
21
        do_IRQ(2);
22
    else if (pending & CAUSEF_IP3)
23
        do_IRQ(3);
24
    else if (pending & CAUSEF_IP4)
25
        do_IRQ(4);
26
    else if (pending & CAUSEF_IP5)
27
        do_IRQ(5);
28
    else if (pending & CAUSEF_IP6)
29
        do_IRQ(6);
30
    else if (pending & CAUSEF_IP7)
31
        do_IRQ(7);
32
    else
33
        spurious_interrupt();
34
}
35
 
36
void __init arch_init_irq(void)
37
{
38
        mips_cpu_irq_init();
39
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.