diff options
-rw-r--r-- | arch/sh/kernel/cpu/sh2/entry.S | 1 | ||||
-rw-r--r-- | arch/sh/kernel/cpu/sh3/entry.S | 5 | ||||
-rw-r--r-- | arch/sh/kernel/irq.c | 15 | ||||
-rw-r--r-- | include/asm-sh/irq.h | 5 |
4 files changed, 12 insertions, 14 deletions
diff --git a/arch/sh/kernel/cpu/sh2/entry.S b/arch/sh/kernel/cpu/sh2/entry.S index 7f7d292f36ec..c16dc8fec489 100644 --- a/arch/sh/kernel/cpu/sh2/entry.S +++ b/arch/sh/kernel/cpu/sh2/entry.S | |||
@@ -165,6 +165,7 @@ ENTRY(exception_handler) | |||
165 | 165 | ||
166 | interrupt_entry: | 166 | interrupt_entry: |
167 | mov r9,r4 | 167 | mov r9,r4 |
168 | mov r15,r5 | ||
168 | mov.l 6f,r9 | 169 | mov.l 6f,r9 |
169 | mov.l 7f,r8 | 170 | mov.l 7f,r8 |
170 | jmp @r8 | 171 | jmp @r8 |
diff --git a/arch/sh/kernel/cpu/sh3/entry.S b/arch/sh/kernel/cpu/sh3/entry.S index c19205b0f2c0..f3e827f29a46 100644 --- a/arch/sh/kernel/cpu/sh3/entry.S +++ b/arch/sh/kernel/cpu/sh3/entry.S | |||
@@ -514,13 +514,16 @@ skip_save: | |||
514 | 514 | ||
515 | interrupt_exception: | 515 | interrupt_exception: |
516 | mov.l 1f, r9 | 516 | mov.l 1f, r9 |
517 | mov.l 2f, r4 | ||
518 | mov.l @r4, r4 | ||
517 | jmp @r9 | 519 | jmp @r9 |
518 | nop | 520 | mov r15, r5 |
519 | rts | 521 | rts |
520 | nop | 522 | nop |
521 | 523 | ||
522 | .align 2 | 524 | .align 2 |
523 | 1: .long do_IRQ | 525 | 1: .long do_IRQ |
526 | 2: .long INTEVT | ||
524 | 527 | ||
525 | .align 2 | 528 | .align 2 |
526 | ENTRY(exception_none) | 529 | ENTRY(exception_none) |
diff --git a/arch/sh/kernel/irq.c b/arch/sh/kernel/irq.c index 67be2b6e8cd1..9bdd8a00cd4a 100644 --- a/arch/sh/kernel/irq.c +++ b/arch/sh/kernel/irq.c | |||
@@ -11,7 +11,6 @@ | |||
11 | #include <linux/module.h> | 11 | #include <linux/module.h> |
12 | #include <linux/kernel_stat.h> | 12 | #include <linux/kernel_stat.h> |
13 | #include <linux/seq_file.h> | 13 | #include <linux/seq_file.h> |
14 | #include <linux/io.h> | ||
15 | #include <linux/irq.h> | 14 | #include <linux/irq.h> |
16 | #include <asm/processor.h> | 15 | #include <asm/processor.h> |
17 | #include <asm/uaccess.h> | 16 | #include <asm/uaccess.h> |
@@ -82,13 +81,9 @@ static union irq_ctx *hardirq_ctx[NR_CPUS] __read_mostly; | |||
82 | static union irq_ctx *softirq_ctx[NR_CPUS] __read_mostly; | 81 | static union irq_ctx *softirq_ctx[NR_CPUS] __read_mostly; |
83 | #endif | 82 | #endif |
84 | 83 | ||
85 | asmlinkage int do_IRQ(unsigned long r4, unsigned long r5, | 84 | asmlinkage int do_IRQ(unsigned int irq, struct pt_regs *regs) |
86 | unsigned long r6, unsigned long r7, | ||
87 | struct pt_regs __regs) | ||
88 | { | 85 | { |
89 | struct pt_regs *regs = RELOC_HIDE(&__regs, 0); | ||
90 | struct pt_regs *old_regs = set_irq_regs(regs); | 86 | struct pt_regs *old_regs = set_irq_regs(regs); |
91 | int irq; | ||
92 | #ifdef CONFIG_4KSTACKS | 87 | #ifdef CONFIG_4KSTACKS |
93 | union irq_ctx *curctx, *irqctx; | 88 | union irq_ctx *curctx, *irqctx; |
94 | #endif | 89 | #endif |
@@ -111,13 +106,7 @@ asmlinkage int do_IRQ(unsigned long r4, unsigned long r5, | |||
111 | } | 106 | } |
112 | #endif | 107 | #endif |
113 | 108 | ||
114 | #ifdef CONFIG_CPU_HAS_INTEVT | 109 | irq = irq_demux(evt2irq(irq)); |
115 | irq = evt2irq(ctrl_inl(INTEVT)); | ||
116 | #else | ||
117 | irq = r4; | ||
118 | #endif | ||
119 | |||
120 | irq = irq_demux(irq); | ||
121 | 110 | ||
122 | #ifdef CONFIG_4KSTACKS | 111 | #ifdef CONFIG_4KSTACKS |
123 | curctx = (union irq_ctx *)current_thread_info(); | 112 | curctx = (union irq_ctx *)current_thread_info(); |
diff --git a/include/asm-sh/irq.h b/include/asm-sh/irq.h index 8ccf7ae593ef..afe188f0ad5f 100644 --- a/include/asm-sh/irq.h +++ b/include/asm-sh/irq.h | |||
@@ -94,8 +94,13 @@ | |||
94 | /* | 94 | /* |
95 | * Convert back and forth between INTEVT and IRQ values. | 95 | * Convert back and forth between INTEVT and IRQ values. |
96 | */ | 96 | */ |
97 | #ifdef CONFIG_CPU_HAS_INTEVT | ||
97 | #define evt2irq(evt) (((evt) >> 5) - 16) | 98 | #define evt2irq(evt) (((evt) >> 5) - 16) |
98 | #define irq2evt(irq) (((irq) + 16) << 5) | 99 | #define irq2evt(irq) (((irq) + 16) << 5) |
100 | #else | ||
101 | #define evt2irq(evt) (evt) | ||
102 | #define irq2evt(irq) (irq) | ||
103 | #endif | ||
99 | 104 | ||
100 | /* | 105 | /* |
101 | * Simple Mask Register Support | 106 | * Simple Mask Register Support |