aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/mips-boards
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2006-10-07 14:44:33 -0400
committerRalf Baechle <ralf@linux-mips.org>2006-10-07 21:38:28 -0400
commit937a801576f954bd030d7c4a5a94571710d87c0b (patch)
tree48d3440f765b56cf32a89b4b8193dd033d8227a8 /arch/mips/mips-boards
parent31aa36658a123263a9a69896e348b9600e050679 (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/mips-boards')
-rw-r--r--arch/mips/mips-boards/atlas/atlas_int.c12
-rw-r--r--arch/mips/mips-boards/generic/time.c22
-rw-r--r--arch/mips/mips-boards/malta/malta_int.c26
-rw-r--r--arch/mips/mips-boards/sead/sead_int.c4
-rw-r--r--arch/mips/mips-boards/sim/sim_int.c11
-rw-r--r--arch/mips/mips-boards/sim/sim_time.c14
6 files changed, 44 insertions, 45 deletions
diff --git a/arch/mips/mips-boards/atlas/atlas_int.c b/arch/mips/mips-boards/atlas/atlas_int.c
index a020a3cb4f4b..be624b8c3b0e 100644
--- a/arch/mips/mips-boards/atlas/atlas_int.c
+++ b/arch/mips/mips-boards/atlas/atlas_int.c
@@ -101,7 +101,7 @@ static inline int ls1bit32(unsigned int x)
101 return b; 101 return b;
102} 102}
103 103
104static inline void atlas_hw0_irqdispatch(struct pt_regs *regs) 104static inline void atlas_hw0_irqdispatch(void)
105{ 105{
106 unsigned long int_status; 106 unsigned long int_status;
107 int irq; 107 int irq;
@@ -116,7 +116,7 @@ static inline void atlas_hw0_irqdispatch(struct pt_regs *regs)
116 116
117 DEBUG_INT("atlas_hw0_irqdispatch: irq=%d\n", irq); 117 DEBUG_INT("atlas_hw0_irqdispatch: irq=%d\n", irq);
118 118
119 do_IRQ(irq, regs); 119 do_IRQ(irq);
120} 120}
121 121
122static inline int clz(unsigned long x) 122static inline int clz(unsigned long x)
@@ -188,7 +188,7 @@ static inline unsigned int irq_ffs(unsigned int pending)
188 * then we just return, if multiple IRQs are pending then we will just take 188 * then we just return, if multiple IRQs are pending then we will just take
189 * another exception, big deal. 189 * another exception, big deal.
190 */ 190 */
191asmlinkage void plat_irq_dispatch(struct pt_regs *regs) 191asmlinkage void plat_irq_dispatch(void)
192{ 192{
193 unsigned int pending = read_c0_cause() & read_c0_status() & ST0_IM; 193 unsigned int pending = read_c0_cause() & read_c0_status() & ST0_IM;
194 int irq; 194 int irq;
@@ -196,11 +196,11 @@ asmlinkage void plat_irq_dispatch(struct pt_regs *regs)
196 irq = irq_ffs(pending); 196 irq = irq_ffs(pending);
197 197
198 if (irq == MIPSCPU_INT_ATLAS) 198 if (irq == MIPSCPU_INT_ATLAS)
199 atlas_hw0_irqdispatch(regs); 199 atlas_hw0_irqdispatch();
200 else if (irq >= 0) 200 else if (irq >= 0)
201 do_IRQ(MIPSCPU_INT_BASE + irq, regs); 201 do_IRQ(MIPSCPU_INT_BASE + irq);
202 else 202 else
203 spurious_interrupt(regs); 203 spurious_interrupt();
204} 204}
205 205
206static inline void init_atlas_irqs (int base) 206static inline void init_atlas_irqs (int base)
diff --git a/arch/mips/mips-boards/generic/time.c b/arch/mips/mips-boards/generic/time.c
index 8d15861fce61..d379000162f3 100644
--- a/arch/mips/mips-boards/generic/time.c
+++ b/arch/mips/mips-boards/generic/time.c
@@ -82,19 +82,19 @@ static inline void scroll_display_message(void)
82 } 82 }
83} 83}
84 84
85static void mips_timer_dispatch (struct pt_regs *regs) 85static void mips_timer_dispatch(void)
86{ 86{
87 do_IRQ (mips_cpu_timer_irq, regs); 87 do_IRQ(mips_cpu_timer_irq);
88} 88}
89 89
90/* 90/*
91 * Redeclare until I get around mopping the timer code insanity on MIPS. 91 * Redeclare until I get around mopping the timer code insanity on MIPS.
92 */ 92 */
93extern int null_perf_irq(struct pt_regs *regs); 93extern int null_perf_irq(void);
94 94
95extern int (*perf_irq)(struct pt_regs *regs); 95extern int (*perf_irq)(void);
96 96
97irqreturn_t mips_timer_interrupt(int irq, void *dev_id, struct pt_regs *regs) 97irqreturn_t mips_timer_interrupt(int irq, void *dev_id)
98{ 98{
99 int cpu = smp_processor_id(); 99 int cpu = smp_processor_id();
100 100
@@ -119,7 +119,7 @@ irqreturn_t mips_timer_interrupt(int irq, void *dev_id, struct pt_regs *regs)
119 * perf counter overflow, or both. 119 * perf counter overflow, or both.
120 */ 120 */
121 if (read_c0_cause() & (1 << 26)) 121 if (read_c0_cause() & (1 << 26))
122 perf_irq(regs); 122 perf_irq();
123 123
124 if (read_c0_cause() & (1 << 30)) { 124 if (read_c0_cause() & (1 << 30)) {
125 /* If timer interrupt, make it de-assert */ 125 /* If timer interrupt, make it de-assert */
@@ -139,13 +139,13 @@ irqreturn_t mips_timer_interrupt(int irq, void *dev_id, struct pt_regs *regs)
139 * the tick on VPE 0 to run the full timer_interrupt(). 139 * the tick on VPE 0 to run the full timer_interrupt().
140 */ 140 */
141 if (cpu_data[cpu].vpe_id == 0) { 141 if (cpu_data[cpu].vpe_id == 0) {
142 timer_interrupt(irq, NULL, regs); 142 timer_interrupt(irq, NULL);
143 smtc_timer_broadcast(cpu_data[cpu].vpe_id); 143 smtc_timer_broadcast(cpu_data[cpu].vpe_id);
144 scroll_display_message(); 144 scroll_display_message();
145 } else { 145 } else {
146 write_c0_compare(read_c0_count() + 146 write_c0_compare(read_c0_count() +
147 (mips_hpt_frequency/HZ)); 147 (mips_hpt_frequency/HZ));
148 local_timer_interrupt(irq, dev_id, regs); 148 local_timer_interrupt(irq, dev_id);
149 smtc_timer_broadcast(cpu_data[cpu].vpe_id); 149 smtc_timer_broadcast(cpu_data[cpu].vpe_id);
150 } 150 }
151 } 151 }
@@ -159,12 +159,12 @@ irqreturn_t mips_timer_interrupt(int irq, void *dev_id, struct pt_regs *regs)
159 * timer int. 159 * timer int.
160 */ 160 */
161 if (!r2 || (read_c0_cause() & (1 << 26))) 161 if (!r2 || (read_c0_cause() & (1 << 26)))
162 if (perf_irq(regs)) 162 if (perf_irq())
163 goto out; 163 goto out;
164 164
165 /* we keep interrupt disabled all the time */ 165 /* we keep interrupt disabled all the time */
166 if (!r2 || (read_c0_cause() & (1 << 30))) 166 if (!r2 || (read_c0_cause() & (1 << 30)))
167 timer_interrupt(irq, NULL, regs); 167 timer_interrupt(irq, NULL);
168 168
169 scroll_display_message(); 169 scroll_display_message();
170 } else { 170 } else {
@@ -180,7 +180,7 @@ irqreturn_t mips_timer_interrupt(int irq, void *dev_id, struct pt_regs *regs)
180 /* 180 /*
181 * Other CPUs should do profiling and process accounting 181 * Other CPUs should do profiling and process accounting
182 */ 182 */
183 local_timer_interrupt(irq, dev_id, regs); 183 local_timer_interrupt(irq, dev_id);
184 } 184 }
185out: 185out:
186#endif /* CONFIG_MIPS_MT_SMTC */ 186#endif /* CONFIG_MIPS_MT_SMTC */
diff --git a/arch/mips/mips-boards/malta/malta_int.c b/arch/mips/mips-boards/malta/malta_int.c
index 7cc0ba4f553a..ed221dc7f6ac 100644
--- a/arch/mips/mips-boards/malta/malta_int.c
+++ b/arch/mips/mips-boards/malta/malta_int.c
@@ -114,7 +114,7 @@ static inline int get_int(void)
114 return irq; 114 return irq;
115} 115}
116 116
117static void malta_hw0_irqdispatch(struct pt_regs *regs) 117static void malta_hw0_irqdispatch(void)
118{ 118{
119 int irq; 119 int irq;
120 120
@@ -123,17 +123,21 @@ static void malta_hw0_irqdispatch(struct pt_regs *regs)
123 return; /* interrupt has already been cleared */ 123 return; /* interrupt has already been cleared */
124 } 124 }
125 125
126 do_IRQ(MALTA_INT_BASE+irq, regs); 126 do_IRQ(MALTA_INT_BASE + irq);
127} 127}
128 128
129void corehi_irqdispatch(struct pt_regs *regs) 129static void corehi_irqdispatch(void)
130{ 130{
131 unsigned int intedge, intsteer, pcicmd, pcibadaddr;
132 unsigned int pcimstat, intisr, inten, intpol;
131 unsigned int intrcause,datalo,datahi; 133 unsigned int intrcause,datalo,datahi;
132 unsigned int pcimstat, intisr, inten, intpol, intedge, intsteer, pcicmd, pcibadaddr; 134 struct pt_regs *regs;
133 135
134 printk("CoreHI interrupt, shouldn't happen, so we die here!!!\n"); 136 printk("CoreHI interrupt, shouldn't happen, so we die here!!!\n");
135 printk("epc : %08lx\nStatus: %08lx\nCause : %08lx\nbadVaddr : %08lx\n" 137 printk("epc : %08lx\nStatus: %08lx\n"
136, regs->cp0_epc, regs->cp0_status, regs->cp0_cause, regs->cp0_badvaddr); 138 "Cause : %08lx\nbadVaddr : %08lx\n",
139 regs->cp0_epc, regs->cp0_status,
140 regs->cp0_cause, regs->cp0_badvaddr);
137 141
138 /* Read all the registers and then print them as there is a 142 /* Read all the registers and then print them as there is a
139 problem with interspersed printk's upsetting the Bonito controller. 143 problem with interspersed printk's upsetting the Bonito controller.
@@ -146,7 +150,7 @@ void corehi_irqdispatch(struct pt_regs *regs)
146 case MIPS_REVISION_CORID_CORE_FPGA3: 150 case MIPS_REVISION_CORID_CORE_FPGA3:
147 case MIPS_REVISION_CORID_CORE_24K: 151 case MIPS_REVISION_CORID_CORE_24K:
148 case MIPS_REVISION_CORID_CORE_EMUL_MSC: 152 case MIPS_REVISION_CORID_CORE_EMUL_MSC:
149 ll_msc_irq(regs); 153 ll_msc_irq();
150 break; 154 break;
151 case MIPS_REVISION_CORID_QED_RM5261: 155 case MIPS_REVISION_CORID_QED_RM5261:
152 case MIPS_REVISION_CORID_CORE_LV: 156 case MIPS_REVISION_CORID_CORE_LV:
@@ -255,7 +259,7 @@ static inline unsigned int irq_ffs(unsigned int pending)
255 * another exception, big deal. 259 * another exception, big deal.
256 */ 260 */
257 261
258asmlinkage void plat_irq_dispatch(struct pt_regs *regs) 262asmlinkage void plat_irq_dispatch(void)
259{ 263{
260 unsigned int pending = read_c0_cause() & read_c0_status() & ST0_IM; 264 unsigned int pending = read_c0_cause() & read_c0_status() & ST0_IM;
261 int irq; 265 int irq;
@@ -263,11 +267,11 @@ asmlinkage void plat_irq_dispatch(struct pt_regs *regs)
263 irq = irq_ffs(pending); 267 irq = irq_ffs(pending);
264 268
265 if (irq == MIPSCPU_INT_I8259A) 269 if (irq == MIPSCPU_INT_I8259A)
266 malta_hw0_irqdispatch(regs); 270 malta_hw0_irqdispatch();
267 else if (irq > 0) 271 else if (irq > 0)
268 do_IRQ(MIPSCPU_INT_BASE + irq, regs); 272 do_IRQ(MIPSCPU_INT_BASE + irq);
269 else 273 else
270 spurious_interrupt(regs); 274 spurious_interrupt();
271} 275}
272 276
273static struct irqaction i8259irq = { 277static struct irqaction i8259irq = {
diff --git a/arch/mips/mips-boards/sead/sead_int.c b/arch/mips/mips-boards/sead/sead_int.c
index 9168d934c661..f445fcddfdfd 100644
--- a/arch/mips/mips-boards/sead/sead_int.c
+++ b/arch/mips/mips-boards/sead/sead_int.c
@@ -98,7 +98,7 @@ static inline unsigned int irq_ffs(unsigned int pending)
98 * then we just return, if multiple IRQs are pending then we will just take 98 * then we just return, if multiple IRQs are pending then we will just take
99 * another exception, big deal. 99 * another exception, big deal.
100 */ 100 */
101asmlinkage void plat_irq_dispatch(struct pt_regs *regs) 101asmlinkage void plat_irq_dispatch(void)
102{ 102{
103 unsigned int pending = read_c0_cause() & read_c0_status() & ST0_IM; 103 unsigned int pending = read_c0_cause() & read_c0_status() & ST0_IM;
104 int irq; 104 int irq;
@@ -106,7 +106,7 @@ asmlinkage void plat_irq_dispatch(struct pt_regs *regs)
106 irq = irq_ffs(pending); 106 irq = irq_ffs(pending);
107 107
108 if (irq >= 0) 108 if (irq >= 0)
109 do_IRQ(MIPSCPU_INT_BASE + irq, regs); 109 do_IRQ(MIPSCPU_INT_BASE + irq);
110 else 110 else
111 spurious_interrupt(regs); 111 spurious_interrupt(regs);
112} 112}
diff --git a/arch/mips/mips-boards/sim/sim_int.c b/arch/mips/mips-boards/sim/sim_int.c
index 2c15c8efec4e..2ce449dce6f2 100644
--- a/arch/mips/mips-boards/sim/sim_int.c
+++ b/arch/mips/mips-boards/sim/sim_int.c
@@ -71,12 +71,7 @@ static inline unsigned int irq_ffs(unsigned int pending)
71#endif 71#endif
72} 72}
73 73
74static inline void sim_hw0_irqdispatch(struct pt_regs *regs) 74asmlinkage void plat_irq_dispatch(void)
75{
76 do_IRQ(2, regs);
77}
78
79asmlinkage void plat_irq_dispatch(struct pt_regs *regs)
80{ 75{
81 unsigned int pending = read_c0_cause() & read_c0_status() & ST0_IM; 76 unsigned int pending = read_c0_cause() & read_c0_status() & ST0_IM;
82 int irq; 77 int irq;
@@ -84,9 +79,9 @@ asmlinkage void plat_irq_dispatch(struct pt_regs *regs)
84 irq = irq_ffs(pending); 79 irq = irq_ffs(pending);
85 80
86 if (irq > 0) 81 if (irq > 0)
87 do_IRQ(MIPSCPU_INT_BASE + irq, regs); 82 do_IRQ(MIPSCPU_INT_BASE + irq);
88 else 83 else
89 spurious_interrupt(regs); 84 spurious_interrupt();
90} 85}
91 86
92void __init arch_init_irq(void) 87void __init arch_init_irq(void)
diff --git a/arch/mips/mips-boards/sim/sim_time.c b/arch/mips/mips-boards/sim/sim_time.c
index 230929ecd57f..acd83a379559 100644
--- a/arch/mips/mips-boards/sim/sim_time.c
+++ b/arch/mips/mips-boards/sim/sim_time.c
@@ -33,7 +33,7 @@
33 33
34unsigned long cpu_khz; 34unsigned long cpu_khz;
35 35
36irqreturn_t sim_timer_interrupt(int irq, void *dev_id, struct pt_regs *regs) 36irqreturn_t sim_timer_interrupt(int irq, void *dev_id)
37{ 37{
38#ifdef CONFIG_SMP 38#ifdef CONFIG_SMP
39 int cpu = smp_processor_id(); 39 int cpu = smp_processor_id();
@@ -44,7 +44,7 @@ irqreturn_t sim_timer_interrupt(int irq, void *dev_id, struct pt_regs *regs)
44 */ 44 */
45#ifndef CONFIG_MIPS_MT_SMTC 45#ifndef CONFIG_MIPS_MT_SMTC
46 if (cpu == 0) { 46 if (cpu == 0) {
47 timer_interrupt(irq, dev_id, regs); 47 timer_interrupt(irq, dev_id);
48 } 48 }
49 else { 49 else {
50 /* Everyone else needs to reset the timer int here as 50 /* Everyone else needs to reset the timer int here as
@@ -84,7 +84,7 @@ irqreturn_t sim_timer_interrupt(int irq, void *dev_id, struct pt_regs *regs)
84 irq_enable_hazard(); 84 irq_enable_hazard();
85 evpe(vpflags); 85 evpe(vpflags);
86 86
87 if(cpu_data[cpu].vpe_id == 0) timer_interrupt(irq, dev_id, regs); 87 if(cpu_data[cpu].vpe_id == 0) timer_interrupt(irq, dev_id);
88 else write_c0_compare (read_c0_count() + ( mips_hpt_frequency/HZ)); 88 else write_c0_compare (read_c0_count() + ( mips_hpt_frequency/HZ));
89 smtc_timer_broadcast(cpu_data[cpu].vpe_id); 89 smtc_timer_broadcast(cpu_data[cpu].vpe_id);
90 90
@@ -93,10 +93,10 @@ irqreturn_t sim_timer_interrupt(int irq, void *dev_id, struct pt_regs *regs)
93 /* 93 /*
94 * every CPU should do profiling and process accounting 94 * every CPU should do profiling and process accounting
95 */ 95 */
96 local_timer_interrupt (irq, dev_id, regs); 96 local_timer_interrupt (irq, dev_id);
97 return IRQ_HANDLED; 97 return IRQ_HANDLED;
98#else 98#else
99 return timer_interrupt (irq, dev_id, regs); 99 return timer_interrupt (irq, dev_id);
100#endif 100#endif
101} 101}
102 102
@@ -177,9 +177,9 @@ void __init sim_time_init(void)
177 177
178static int mips_cpu_timer_irq; 178static int mips_cpu_timer_irq;
179 179
180static void mips_timer_dispatch (struct pt_regs *regs) 180static void mips_timer_dispatch(void)
181{ 181{
182 do_IRQ (mips_cpu_timer_irq, regs); 182 do_IRQ(mips_cpu_timer_irq);
183} 183}
184 184
185 185