aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Mundt <lethal@linux-sh.org>2007-05-13 20:10:01 -0400
committerPaul Mundt <lethal@linux-sh.org>2007-05-13 20:10:01 -0400
commita226d33abccff1959cec911da4143ea06ab22052 (patch)
tree3dc9154f56eb328ae6257e09b02a183de46f4763
parent6b5d1a0a2ff4fc5a26029f62eef033224ce0fa97 (diff)
sh64: Fixups for the irq_regs changes.
A few interrupt handlers were never updated, fix them up. We were missing the irq_regs conversion also, so do that at the same time. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
-rw-r--r--arch/sh64/kernel/irq.c4
-rw-r--r--arch/sh64/kernel/pci_sh5.c5
-rw-r--r--arch/sh64/kernel/time.c16
-rw-r--r--arch/sh64/mach-cayman/irq.c4
-rw-r--r--include/asm-sh64/irq_regs.h1
5 files changed, 18 insertions, 12 deletions
diff --git a/arch/sh64/kernel/irq.c b/arch/sh64/kernel/irq.c
index f68b4f6c9b31..9412b7166700 100644
--- a/arch/sh64/kernel/irq.c
+++ b/arch/sh64/kernel/irq.c
@@ -94,6 +94,7 @@ asmlinkage void do_NMI(unsigned long vector_num, struct pt_regs * regs)
94 */ 94 */
95asmlinkage int do_IRQ(unsigned long vector_num, struct pt_regs * regs) 95asmlinkage int do_IRQ(unsigned long vector_num, struct pt_regs * regs)
96{ 96{
97 struct pt_regs *old_regs = set_irq_regs(regs);
97 int irq; 98 int irq;
98 99
99 irq_enter(); 100 irq_enter();
@@ -101,13 +102,14 @@ asmlinkage int do_IRQ(unsigned long vector_num, struct pt_regs * regs)
101 irq = irq_demux(vector_num); 102 irq = irq_demux(vector_num);
102 103
103 if (irq >= 0) { 104 if (irq >= 0) {
104 __do_IRQ(irq, regs); 105 __do_IRQ(irq);
105 } else { 106 } else {
106 printk("unexpected IRQ trap at vector %03lx\n", vector_num); 107 printk("unexpected IRQ trap at vector %03lx\n", vector_num);
107 } 108 }
108 109
109 irq_exit(); 110 irq_exit();
110 111
112 set_irq_regs(old_regs);
111 return 1; 113 return 1;
112} 114}
113 115
diff --git a/arch/sh64/kernel/pci_sh5.c b/arch/sh64/kernel/pci_sh5.c
index 649b33667748..fb51660847c8 100644
--- a/arch/sh64/kernel/pci_sh5.c
+++ b/arch/sh64/kernel/pci_sh5.c
@@ -340,8 +340,9 @@ static int __init map_cayman_irq(struct pci_dev *dev, u8 slot, u8 pin)
340 return result; 340 return result;
341} 341}
342 342
343irqreturn_t pcish5_err_irq(int irq, void *dev_id, struct pt_regs *regs) 343static irqreturn_t pcish5_err_irq(int irq, void *dev_id)
344{ 344{
345 struct pt_regs *regs = get_irq_regs();
345 unsigned pci_int, pci_air, pci_cir, pci_aint; 346 unsigned pci_int, pci_air, pci_cir, pci_aint;
346 347
347 pci_int = SH5PCI_READ(INT); 348 pci_int = SH5PCI_READ(INT);
@@ -368,7 +369,7 @@ irqreturn_t pcish5_err_irq(int irq, void *dev_id, struct pt_regs *regs)
368 return IRQ_HANDLED; 369 return IRQ_HANDLED;
369} 370}
370 371
371irqreturn_t pcish5_serr_irq(int irq, void *dev_id, struct pt_regs *regs) 372static irqreturn_t pcish5_serr_irq(int irq, void *dev_id)
372{ 373{
373 printk("SERR IRQ\n"); 374 printk("SERR IRQ\n");
374 375
diff --git a/arch/sh64/kernel/time.c b/arch/sh64/kernel/time.c
index bad0f05d1ab1..b37f4f4981d2 100644
--- a/arch/sh64/kernel/time.c
+++ b/arch/sh64/kernel/time.c
@@ -282,7 +282,7 @@ static long last_rtc_update = 0;
282 * timer_interrupt() needs to keep up the real-time clock, 282 * timer_interrupt() needs to keep up the real-time clock,
283 * as well as call the "do_timer()" routine every clocktick 283 * as well as call the "do_timer()" routine every clocktick
284 */ 284 */
285static inline void do_timer_interrupt(int irq, struct pt_regs *regs) 285static inline void do_timer_interrupt(void)
286{ 286{
287 unsigned long long current_ctc; 287 unsigned long long current_ctc;
288 asm ("getcon cr62, %0" : "=r" (current_ctc)); 288 asm ("getcon cr62, %0" : "=r" (current_ctc));
@@ -290,9 +290,10 @@ static inline void do_timer_interrupt(int irq, struct pt_regs *regs)
290 290
291 do_timer(1); 291 do_timer(1);
292#ifndef CONFIG_SMP 292#ifndef CONFIG_SMP
293 update_process_times(user_mode(regs)); 293 update_process_times(user_mode(get_irq_regs()));
294#endif 294#endif
295 profile_tick(CPU_PROFILING, regs); 295 if (current->pid)
296 profile_tick(CPU_PROFILING);
296 297
297#ifdef CONFIG_HEARTBEAT 298#ifdef CONFIG_HEARTBEAT
298 { 299 {
@@ -323,7 +324,7 @@ static inline void do_timer_interrupt(int irq, struct pt_regs *regs)
323 * Time Stamp Counter value at the time of the timer interrupt, so that 324 * Time Stamp Counter value at the time of the timer interrupt, so that
324 * we later on can estimate the time of day more exactly. 325 * we later on can estimate the time of day more exactly.
325 */ 326 */
326static irqreturn_t timer_interrupt(int irq, void *dev_id, struct pt_regs *regs) 327static irqreturn_t timer_interrupt(int irq, void *dev_id)
327{ 328{
328 unsigned long timer_status; 329 unsigned long timer_status;
329 330
@@ -340,7 +341,7 @@ static irqreturn_t timer_interrupt(int irq, void *dev_id, struct pt_regs *regs)
340 * locally disabled. -arca 341 * locally disabled. -arca
341 */ 342 */
342 write_lock(&xtime_lock); 343 write_lock(&xtime_lock);
343 do_timer_interrupt(irq, regs); 344 do_timer_interrupt();
344 write_unlock(&xtime_lock); 345 write_unlock(&xtime_lock);
345 346
346 return IRQ_HANDLED; 347 return IRQ_HANDLED;
@@ -465,9 +466,10 @@ static __init unsigned int get_cpu_hz(void)
465#endif 466#endif
466} 467}
467 468
468static irqreturn_t sh64_rtc_interrupt(int irq, void *dev_id, 469static irqreturn_t sh64_rtc_interrupt(int irq, void *dev_id)
469 struct pt_regs *regs)
470{ 470{
471 struct pt_regs *regs = get_irq_regs();
472
471 ctrl_outb(0, RCR1); /* Disable Carry Interrupts */ 473 ctrl_outb(0, RCR1); /* Disable Carry Interrupts */
472 regs->regs[3] = 1; /* Using r3 */ 474 regs->regs[3] = 1; /* Using r3 */
473 475
diff --git a/arch/sh64/mach-cayman/irq.c b/arch/sh64/mach-cayman/irq.c
index 228ce61c3515..aaad36d37d1f 100644
--- a/arch/sh64/mach-cayman/irq.c
+++ b/arch/sh64/mach-cayman/irq.c
@@ -29,13 +29,13 @@ unsigned long epld_virt;
29/* Note the SMSC SuperIO chip and SMSC LAN chip interrupts are all muxed onto 29/* Note the SMSC SuperIO chip and SMSC LAN chip interrupts are all muxed onto
30 the same SH-5 interrupt */ 30 the same SH-5 interrupt */
31 31
32static irqreturn_t cayman_interrupt_smsc(int irq, void *dev_id, struct pt_regs *regs) 32static irqreturn_t cayman_interrupt_smsc(int irq, void *dev_id)
33{ 33{
34 printk(KERN_INFO "CAYMAN: spurious SMSC interrupt\n"); 34 printk(KERN_INFO "CAYMAN: spurious SMSC interrupt\n");
35 return IRQ_NONE; 35 return IRQ_NONE;
36} 36}
37 37
38static irqreturn_t cayman_interrupt_pci2(int irq, void *dev_id, struct pt_regs *regs) 38static irqreturn_t cayman_interrupt_pci2(int irq, void *dev_id)
39{ 39{
40 printk(KERN_INFO "CAYMAN: spurious PCI interrupt, IRQ %d\n", irq); 40 printk(KERN_INFO "CAYMAN: spurious PCI interrupt, IRQ %d\n", irq);
41 return IRQ_NONE; 41 return IRQ_NONE;
diff --git a/include/asm-sh64/irq_regs.h b/include/asm-sh64/irq_regs.h
new file mode 100644
index 000000000000..3dd9c0b70270
--- /dev/null
+++ b/include/asm-sh64/irq_regs.h
@@ -0,0 +1 @@
#include <asm-generic/irq_regs.h>