diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2006-10-07 14:44:33 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2006-10-07 21:38:28 -0400 |
commit | 937a801576f954bd030d7c4a5a94571710d87c0b (patch) | |
tree | 48d3440f765b56cf32a89b4b8193dd033d8227a8 /arch/mips/au1000 | |
parent | 31aa36658a123263a9a69896e348b9600e050679 (diff) |
[MIPS] Complete fixes after removal of pt_regs argument to int handlers.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/au1000')
-rw-r--r-- | arch/mips/au1000/common/dma.c | 2 | ||||
-rw-r--r-- | arch/mips/au1000/common/irq.c | 52 | ||||
-rw-r--r-- | arch/mips/au1000/common/time.c | 13 | ||||
-rw-r--r-- | arch/mips/au1000/common/usbdev.c | 9 | ||||
-rw-r--r-- | arch/mips/au1000/pb1200/irqmap.c | 5 |
5 files changed, 40 insertions, 41 deletions
diff --git a/arch/mips/au1000/common/dma.c b/arch/mips/au1000/common/dma.c index fb7c47c1585d..c3019b9c91b1 100644 --- a/arch/mips/au1000/common/dma.c +++ b/arch/mips/au1000/common/dma.c | |||
@@ -160,7 +160,7 @@ void dump_au1000_dma_channel(unsigned int dmanr) | |||
160 | * Requests the DMA done IRQ if irqhandler != NULL. | 160 | * Requests the DMA done IRQ if irqhandler != NULL. |
161 | */ | 161 | */ |
162 | int request_au1000_dma(int dev_id, const char *dev_str, | 162 | int request_au1000_dma(int dev_id, const char *dev_str, |
163 | irqreturn_t (*irqhandler)(int, void *, struct pt_regs *), | 163 | irqreturn_t (*irqhandler)(int, void *), |
164 | unsigned long irqflags, | 164 | unsigned long irqflags, |
165 | void *irq_dev_id) | 165 | void *irq_dev_id) |
166 | { | 166 | { |
diff --git a/arch/mips/au1000/common/irq.c b/arch/mips/au1000/common/irq.c index 316722ee8cf5..b32597e05a69 100644 --- a/arch/mips/au1000/common/irq.c +++ b/arch/mips/au1000/common/irq.c | |||
@@ -67,7 +67,7 @@ | |||
67 | 67 | ||
68 | extern void set_debug_traps(void); | 68 | extern void set_debug_traps(void); |
69 | extern irq_cpustat_t irq_stat [NR_CPUS]; | 69 | extern irq_cpustat_t irq_stat [NR_CPUS]; |
70 | extern void mips_timer_interrupt(struct pt_regs *regs); | 70 | extern void mips_timer_interrupt(void); |
71 | 71 | ||
72 | static void setup_local_irq(unsigned int irq, int type, int int_req); | 72 | static void setup_local_irq(unsigned int irq, int type, int int_req); |
73 | static unsigned int startup_irq(unsigned int irq); | 73 | static unsigned int startup_irq(unsigned int irq); |
@@ -81,10 +81,6 @@ inline void local_disable_irq(unsigned int irq_nr); | |||
81 | 81 | ||
82 | void (*board_init_irq)(void); | 82 | void (*board_init_irq)(void); |
83 | 83 | ||
84 | #ifdef CONFIG_PM | ||
85 | extern irqreturn_t counter0_irq(int irq, void *dev_id, struct pt_regs *regs); | ||
86 | #endif | ||
87 | |||
88 | static DEFINE_SPINLOCK(irq_lock); | 84 | static DEFINE_SPINLOCK(irq_lock); |
89 | 85 | ||
90 | 86 | ||
@@ -292,7 +288,7 @@ static struct irq_chip level_irq_type = { | |||
292 | }; | 288 | }; |
293 | 289 | ||
294 | #ifdef CONFIG_PM | 290 | #ifdef CONFIG_PM |
295 | void startup_match20_interrupt(irqreturn_t (*handler)(int, void *, struct pt_regs *)) | 291 | void startup_match20_interrupt(irqreturn_t (*handler)(int, void *)) |
296 | { | 292 | { |
297 | struct irq_desc *desc = &irq_desc[AU1000_TOY_MATCH2_INT]; | 293 | struct irq_desc *desc = &irq_desc[AU1000_TOY_MATCH2_INT]; |
298 | 294 | ||
@@ -501,14 +497,15 @@ void __init arch_init_irq(void) | |||
501 | * intcX_reqX_irqdispatch(). | 497 | * intcX_reqX_irqdispatch(). |
502 | */ | 498 | */ |
503 | 499 | ||
504 | void intc0_req0_irqdispatch(struct pt_regs *regs) | 500 | static void intc0_req0_irqdispatch(void) |
505 | { | 501 | { |
506 | int irq = 0; | 502 | int irq = 0; |
507 | static unsigned long intc0_req0 = 0; | 503 | static unsigned long intc0_req0 = 0; |
508 | 504 | ||
509 | intc0_req0 |= au_readl(IC0_REQ0INT); | 505 | intc0_req0 |= au_readl(IC0_REQ0INT); |
510 | 506 | ||
511 | if (!intc0_req0) return; | 507 | if (!intc0_req0) |
508 | return; | ||
512 | #ifdef AU1000_USB_DEV_REQ_INT | 509 | #ifdef AU1000_USB_DEV_REQ_INT |
513 | /* | 510 | /* |
514 | * Because of the tight timing of SETUP token to reply | 511 | * Because of the tight timing of SETUP token to reply |
@@ -517,28 +514,29 @@ void intc0_req0_irqdispatch(struct pt_regs *regs) | |||
517 | */ | 514 | */ |
518 | if ((intc0_req0 & (1<<AU1000_USB_DEV_REQ_INT))) { | 515 | if ((intc0_req0 & (1<<AU1000_USB_DEV_REQ_INT))) { |
519 | intc0_req0 &= ~(1<<AU1000_USB_DEV_REQ_INT); | 516 | intc0_req0 &= ~(1<<AU1000_USB_DEV_REQ_INT); |
520 | do_IRQ(AU1000_USB_DEV_REQ_INT, regs); | 517 | do_IRQ(AU1000_USB_DEV_REQ_INT); |
521 | return; | 518 | return; |
522 | } | 519 | } |
523 | #endif | 520 | #endif |
524 | irq = au_ffs(intc0_req0) - 1; | 521 | irq = au_ffs(intc0_req0) - 1; |
525 | intc0_req0 &= ~(1<<irq); | 522 | intc0_req0 &= ~(1<<irq); |
526 | do_IRQ(irq, regs); | 523 | do_IRQ(irq); |
527 | } | 524 | } |
528 | 525 | ||
529 | 526 | ||
530 | void intc0_req1_irqdispatch(struct pt_regs *regs) | 527 | static void intc0_req1_irqdispatch(void) |
531 | { | 528 | { |
532 | int irq = 0; | 529 | int irq = 0; |
533 | static unsigned long intc0_req1 = 0; | 530 | static unsigned long intc0_req1 = 0; |
534 | 531 | ||
535 | intc0_req1 |= au_readl(IC0_REQ1INT); | 532 | intc0_req1 |= au_readl(IC0_REQ1INT); |
536 | 533 | ||
537 | if (!intc0_req1) return; | 534 | if (!intc0_req1) |
535 | return; | ||
538 | 536 | ||
539 | irq = au_ffs(intc0_req1) - 1; | 537 | irq = au_ffs(intc0_req1) - 1; |
540 | intc0_req1 &= ~(1<<irq); | 538 | intc0_req1 &= ~(1<<irq); |
541 | do_IRQ(irq, regs); | 539 | do_IRQ(irq); |
542 | } | 540 | } |
543 | 541 | ||
544 | 542 | ||
@@ -546,35 +544,37 @@ void intc0_req1_irqdispatch(struct pt_regs *regs) | |||
546 | * Interrupt Controller 1: | 544 | * Interrupt Controller 1: |
547 | * interrupts 32 - 63 | 545 | * interrupts 32 - 63 |
548 | */ | 546 | */ |
549 | void intc1_req0_irqdispatch(struct pt_regs *regs) | 547 | static void intc1_req0_irqdispatch(void) |
550 | { | 548 | { |
551 | int irq = 0; | 549 | int irq = 0; |
552 | static unsigned long intc1_req0 = 0; | 550 | static unsigned long intc1_req0 = 0; |
553 | 551 | ||
554 | intc1_req0 |= au_readl(IC1_REQ0INT); | 552 | intc1_req0 |= au_readl(IC1_REQ0INT); |
555 | 553 | ||
556 | if (!intc1_req0) return; | 554 | if (!intc1_req0) |
555 | return; | ||
557 | 556 | ||
558 | irq = au_ffs(intc1_req0) - 1; | 557 | irq = au_ffs(intc1_req0) - 1; |
559 | intc1_req0 &= ~(1<<irq); | 558 | intc1_req0 &= ~(1<<irq); |
560 | irq += 32; | 559 | irq += 32; |
561 | do_IRQ(irq, regs); | 560 | do_IRQ(irq); |
562 | } | 561 | } |
563 | 562 | ||
564 | 563 | ||
565 | void intc1_req1_irqdispatch(struct pt_regs *regs) | 564 | static void intc1_req1_irqdispatch(void) |
566 | { | 565 | { |
567 | int irq = 0; | 566 | int irq = 0; |
568 | static unsigned long intc1_req1 = 0; | 567 | static unsigned long intc1_req1 = 0; |
569 | 568 | ||
570 | intc1_req1 |= au_readl(IC1_REQ1INT); | 569 | intc1_req1 |= au_readl(IC1_REQ1INT); |
571 | 570 | ||
572 | if (!intc1_req1) return; | 571 | if (!intc1_req1) |
572 | return; | ||
573 | 573 | ||
574 | irq = au_ffs(intc1_req1) - 1; | 574 | irq = au_ffs(intc1_req1) - 1; |
575 | intc1_req1 &= ~(1<<irq); | 575 | intc1_req1 &= ~(1<<irq); |
576 | irq += 32; | 576 | irq += 32; |
577 | do_IRQ(irq, regs); | 577 | do_IRQ(irq); |
578 | } | 578 | } |
579 | 579 | ||
580 | #ifdef CONFIG_PM | 580 | #ifdef CONFIG_PM |
@@ -660,20 +660,20 @@ restore_au1xxx_intctl(void) | |||
660 | } | 660 | } |
661 | #endif /* CONFIG_PM */ | 661 | #endif /* CONFIG_PM */ |
662 | 662 | ||
663 | asmlinkage void plat_irq_dispatch(struct pt_regs *regs) | 663 | asmlinkage void plat_irq_dispatch(void) |
664 | { | 664 | { |
665 | unsigned int pending = read_c0_status() & read_c0_cause() & ST0_IM; | 665 | unsigned int pending = read_c0_status() & read_c0_cause() & ST0_IM; |
666 | 666 | ||
667 | if (pending & CAUSEF_IP7) | 667 | if (pending & CAUSEF_IP7) |
668 | mips_timer_interrupt(regs); | 668 | mips_timer_interrupt(); |
669 | else if (pending & CAUSEF_IP2) | 669 | else if (pending & CAUSEF_IP2) |
670 | intc0_req0_irqdispatch(regs); | 670 | intc0_req0_irqdispatch(); |
671 | else if (pending & CAUSEF_IP3) | 671 | else if (pending & CAUSEF_IP3) |
672 | intc0_req1_irqdispatch(regs); | 672 | intc0_req1_irqdispatch(); |
673 | else if (pending & CAUSEF_IP4) | 673 | else if (pending & CAUSEF_IP4) |
674 | intc1_req0_irqdispatch(regs); | 674 | intc1_req0_irqdispatch(); |
675 | else if (pending & CAUSEF_IP5) | 675 | else if (pending & CAUSEF_IP5) |
676 | intc1_req1_irqdispatch(regs); | 676 | intc1_req1_irqdispatch(); |
677 | else | 677 | else |
678 | spurious_interrupt(regs); | 678 | spurious_interrupt(); |
679 | } | 679 | } |
diff --git a/arch/mips/au1000/common/time.c b/arch/mips/au1000/common/time.c index 0a067f3113a5..1989d56139c8 100644 --- a/arch/mips/au1000/common/time.c +++ b/arch/mips/au1000/common/time.c | |||
@@ -62,7 +62,7 @@ static unsigned int timerhi = 0, timerlo = 0; | |||
62 | #error "unsupported HZ value! Must be in [100,1000]" | 62 | #error "unsupported HZ value! Must be in [100,1000]" |
63 | #endif | 63 | #endif |
64 | #define MATCH20_INC (328*100/HZ) /* magic number 328 is for HZ=100... */ | 64 | #define MATCH20_INC (328*100/HZ) /* magic number 328 is for HZ=100... */ |
65 | extern void startup_match20_interrupt(irqreturn_t (*handler)(int, void *, struct pt_regs *)); | 65 | extern void startup_match20_interrupt(irqreturn_t (*handler)(int, void *)); |
66 | static unsigned long last_pc0, last_match20; | 66 | static unsigned long last_pc0, last_match20; |
67 | #endif | 67 | #endif |
68 | 68 | ||
@@ -79,7 +79,8 @@ static inline void ack_r4ktimer(unsigned long newval) | |||
79 | * is provably more robust. | 79 | * is provably more robust. |
80 | */ | 80 | */ |
81 | unsigned long wtimer; | 81 | unsigned long wtimer; |
82 | void mips_timer_interrupt(struct pt_regs *regs) | 82 | |
83 | void mips_timer_interrupt(void) | ||
83 | { | 84 | { |
84 | int irq = 63; | 85 | int irq = 63; |
85 | unsigned long count; | 86 | unsigned long count; |
@@ -98,7 +99,7 @@ void mips_timer_interrupt(struct pt_regs *regs) | |||
98 | kstat_this_cpu.irqs[irq]++; | 99 | kstat_this_cpu.irqs[irq]++; |
99 | do_timer(1); | 100 | do_timer(1); |
100 | #ifndef CONFIG_SMP | 101 | #ifndef CONFIG_SMP |
101 | update_process_times(user_mode(regs)); | 102 | update_process_times(user_mode(get_irq_regs())); |
102 | #endif | 103 | #endif |
103 | r4k_cur += r4k_offset; | 104 | r4k_cur += r4k_offset; |
104 | ack_r4ktimer(r4k_cur); | 105 | ack_r4ktimer(r4k_cur); |
@@ -115,7 +116,7 @@ null: | |||
115 | } | 116 | } |
116 | 117 | ||
117 | #ifdef CONFIG_PM | 118 | #ifdef CONFIG_PM |
118 | irqreturn_t counter0_irq(int irq, void *dev_id, struct pt_regs *regs) | 119 | irqreturn_t counter0_irq(int irq, void *dev_id) |
119 | { | 120 | { |
120 | unsigned long pc0; | 121 | unsigned long pc0; |
121 | int time_elapsed; | 122 | int time_elapsed; |
@@ -139,7 +140,7 @@ irqreturn_t counter0_irq(int irq, void *dev_id, struct pt_regs *regs) | |||
139 | while (time_elapsed > 0) { | 140 | while (time_elapsed > 0) { |
140 | do_timer(1); | 141 | do_timer(1); |
141 | #ifndef CONFIG_SMP | 142 | #ifndef CONFIG_SMP |
142 | update_process_times(user_mode(regs)); | 143 | update_process_times(user_mode(get_irq_regs())); |
143 | #endif | 144 | #endif |
144 | time_elapsed -= MATCH20_INC; | 145 | time_elapsed -= MATCH20_INC; |
145 | last_match20 += MATCH20_INC; | 146 | last_match20 += MATCH20_INC; |
@@ -158,7 +159,7 @@ irqreturn_t counter0_irq(int irq, void *dev_id, struct pt_regs *regs) | |||
158 | jiffie_drift -= 999; | 159 | jiffie_drift -= 999; |
159 | do_timer(1); /* increment jiffies by one */ | 160 | do_timer(1); /* increment jiffies by one */ |
160 | #ifndef CONFIG_SMP | 161 | #ifndef CONFIG_SMP |
161 | update_process_times(user_mode(regs)); | 162 | update_process_times(user_mode(get_irq_regs())); |
162 | #endif | 163 | #endif |
163 | } | 164 | } |
164 | 165 | ||
diff --git a/arch/mips/au1000/common/usbdev.c b/arch/mips/au1000/common/usbdev.c index 63bcb3a95dc7..70dc82e536cd 100644 --- a/arch/mips/au1000/common/usbdev.c +++ b/arch/mips/au1000/common/usbdev.c | |||
@@ -1031,8 +1031,7 @@ process_ep_receive (struct usb_dev* dev, endpoint_t *ep) | |||
1031 | 1031 | ||
1032 | 1032 | ||
1033 | /* This ISR handles the receive complete and suspend events */ | 1033 | /* This ISR handles the receive complete and suspend events */ |
1034 | static void | 1034 | static void req_sus_intr (int irq, void *dev_id) |
1035 | req_sus_intr (int irq, void *dev_id, struct pt_regs *regs) | ||
1036 | { | 1035 | { |
1037 | struct usb_dev *dev = (struct usb_dev *) dev_id; | 1036 | struct usb_dev *dev = (struct usb_dev *) dev_id; |
1038 | u32 status; | 1037 | u32 status; |
@@ -1050,8 +1049,7 @@ req_sus_intr (int irq, void *dev_id, struct pt_regs *regs) | |||
1050 | 1049 | ||
1051 | 1050 | ||
1052 | /* This ISR handles the DMA done events on EP0 */ | 1051 | /* This ISR handles the DMA done events on EP0 */ |
1053 | static void | 1052 | static void dma_done_ep0_intr(int irq, void *dev_id) |
1054 | dma_done_ep0_intr(int irq, void *dev_id, struct pt_regs *regs) | ||
1055 | { | 1053 | { |
1056 | struct usb_dev *dev = (struct usb_dev *) dev_id; | 1054 | struct usb_dev *dev = (struct usb_dev *) dev_id; |
1057 | usbdev_pkt_t* pkt; | 1055 | usbdev_pkt_t* pkt; |
@@ -1094,8 +1092,7 @@ dma_done_ep0_intr(int irq, void *dev_id, struct pt_regs *regs) | |||
1094 | } | 1092 | } |
1095 | 1093 | ||
1096 | /* This ISR handles the DMA done events on endpoints 2,3,4,5 */ | 1094 | /* This ISR handles the DMA done events on endpoints 2,3,4,5 */ |
1097 | static void | 1095 | static void dma_done_ep_intr(int irq, void *dev_id) |
1098 | dma_done_ep_intr(int irq, void *dev_id, struct pt_regs *regs) | ||
1099 | { | 1096 | { |
1100 | struct usb_dev *dev = (struct usb_dev *) dev_id; | 1097 | struct usb_dev *dev = (struct usb_dev *) dev_id; |
1101 | int i; | 1098 | int i; |
diff --git a/arch/mips/au1000/pb1200/irqmap.c b/arch/mips/au1000/pb1200/irqmap.c index f66779f0d4cd..91983ba407c4 100644 --- a/arch/mips/au1000/pb1200/irqmap.c +++ b/arch/mips/au1000/pb1200/irqmap.c | |||
@@ -65,7 +65,7 @@ int __initdata au1xxx_nr_irqs = ARRAY_SIZE(au1xxx_irq_map); | |||
65 | */ | 65 | */ |
66 | static volatile int pb1200_cascade_en=0; | 66 | static volatile int pb1200_cascade_en=0; |
67 | 67 | ||
68 | irqreturn_t pb1200_cascade_handler( int irq, void *dev_id, struct pt_regs *regs) | 68 | irqreturn_t pb1200_cascade_handler( int irq, void *dev_id) |
69 | { | 69 | { |
70 | unsigned short bisr = bcsr->int_status; | 70 | unsigned short bisr = bcsr->int_status; |
71 | int extirq_nr = 0; | 71 | int extirq_nr = 0; |
@@ -76,8 +76,9 @@ irqreturn_t pb1200_cascade_handler( int irq, void *dev_id, struct pt_regs *regs) | |||
76 | { | 76 | { |
77 | extirq_nr = (PB1200_INT_BEGIN-1) + au_ffs(bisr); | 77 | extirq_nr = (PB1200_INT_BEGIN-1) + au_ffs(bisr); |
78 | /* Ack and dispatch IRQ */ | 78 | /* Ack and dispatch IRQ */ |
79 | do_IRQ(extirq_nr,regs); | 79 | do_IRQ(extirq_nr); |
80 | } | 80 | } |
81 | |||
81 | return IRQ_RETVAL(1); | 82 | return IRQ_RETVAL(1); |
82 | } | 83 | } |
83 | 84 | ||