diff options
Diffstat (limited to 'arch/m68k/mac')
-rw-r--r-- | arch/m68k/mac/baboon.c | 3 | ||||
-rw-r--r-- | arch/m68k/mac/config.c | 12 | ||||
-rw-r--r-- | arch/m68k/mac/debug.c | 1 | ||||
-rw-r--r-- | arch/m68k/mac/iop.c | 10 | ||||
-rw-r--r-- | arch/m68k/mac/macints.c | 15 | ||||
-rw-r--r-- | arch/m68k/mac/misc.c | 1 | ||||
-rw-r--r-- | arch/m68k/mac/oss.c | 25 | ||||
-rw-r--r-- | arch/m68k/mac/psc.c | 12 | ||||
-rw-r--r-- | arch/m68k/mac/via.c | 35 |
9 files changed, 56 insertions, 58 deletions
diff --git a/arch/m68k/mac/baboon.c b/arch/m68k/mac/baboon.c index 245d16d078ad..2a96bebd8969 100644 --- a/arch/m68k/mac/baboon.c +++ b/arch/m68k/mac/baboon.c | |||
@@ -92,7 +92,8 @@ static irqreturn_t baboon_irq(int irq, void *dev_id) | |||
92 | void __init baboon_register_interrupts(void) | 92 | void __init baboon_register_interrupts(void) |
93 | { | 93 | { |
94 | baboon_disabled = 0; | 94 | baboon_disabled = 0; |
95 | request_irq(IRQ_NUBUS_C, baboon_irq, 0, "baboon", (void *)baboon); | 95 | if (request_irq(IRQ_NUBUS_C, baboon_irq, 0, "baboon", (void *)baboon)) |
96 | pr_err("Couldn't register baboon interrupt\n"); | ||
96 | } | 97 | } |
97 | 98 | ||
98 | /* | 99 | /* |
diff --git a/arch/m68k/mac/config.c b/arch/m68k/mac/config.c index 8819b97be324..98b6bcfb37bf 100644 --- a/arch/m68k/mac/config.c +++ b/arch/m68k/mac/config.c | |||
@@ -47,13 +47,6 @@ | |||
47 | 47 | ||
48 | struct mac_booter_data mac_bi_data; | 48 | struct mac_booter_data mac_bi_data; |
49 | 49 | ||
50 | /* New m68k bootinfo stuff and videobase */ | ||
51 | |||
52 | extern int m68k_num_memory; | ||
53 | extern struct mem_info m68k_memory[NUM_MEMINFO]; | ||
54 | |||
55 | extern struct mem_info m68k_ramdisk; | ||
56 | |||
57 | /* The phys. video addr. - might be bogus on some machines */ | 50 | /* The phys. video addr. - might be bogus on some machines */ |
58 | static unsigned long mac_orig_videoaddr; | 51 | static unsigned long mac_orig_videoaddr; |
59 | 52 | ||
@@ -61,7 +54,6 @@ static unsigned long mac_orig_videoaddr; | |||
61 | extern unsigned long mac_gettimeoffset(void); | 54 | extern unsigned long mac_gettimeoffset(void); |
62 | extern int mac_hwclk(int, struct rtc_time *); | 55 | extern int mac_hwclk(int, struct rtc_time *); |
63 | extern int mac_set_clock_mmss(unsigned long); | 56 | extern int mac_set_clock_mmss(unsigned long); |
64 | extern int show_mac_interrupts(struct seq_file *, void *); | ||
65 | extern void iop_preinit(void); | 57 | extern void iop_preinit(void); |
66 | extern void iop_init(void); | 58 | extern void iop_init(void); |
67 | extern void via_init(void); | 59 | extern void via_init(void); |
@@ -805,10 +797,6 @@ static void __init mac_identify(void) | |||
805 | mac_bi_data.boottime, mac_bi_data.gmtbias); | 797 | mac_bi_data.boottime, mac_bi_data.gmtbias); |
806 | printk(KERN_DEBUG " Machine ID: %ld CPUid: 0x%lx memory size: 0x%lx \n", | 798 | printk(KERN_DEBUG " Machine ID: %ld CPUid: 0x%lx memory size: 0x%lx \n", |
807 | mac_bi_data.id, mac_bi_data.cpuid, mac_bi_data.memsize); | 799 | mac_bi_data.id, mac_bi_data.cpuid, mac_bi_data.memsize); |
808 | #if 0 | ||
809 | printk("Ramdisk: addr 0x%lx size 0x%lx\n", | ||
810 | m68k_ramdisk.addr, m68k_ramdisk.size); | ||
811 | #endif | ||
812 | 800 | ||
813 | iop_init(); | 801 | iop_init(); |
814 | via_init(); | 802 | via_init(); |
diff --git a/arch/m68k/mac/debug.c b/arch/m68k/mac/debug.c index 65dd77a742a3..bce074ceb768 100644 --- a/arch/m68k/mac/debug.c +++ b/arch/m68k/mac/debug.c | |||
@@ -27,7 +27,6 @@ | |||
27 | #include <asm/macints.h> | 27 | #include <asm/macints.h> |
28 | 28 | ||
29 | extern unsigned long mac_videobase; | 29 | extern unsigned long mac_videobase; |
30 | extern unsigned long mac_videodepth; | ||
31 | extern unsigned long mac_rowbytes; | 30 | extern unsigned long mac_rowbytes; |
32 | 31 | ||
33 | extern void mac_serial_print(const char *); | 32 | extern void mac_serial_print(const char *); |
diff --git a/arch/m68k/mac/iop.c b/arch/m68k/mac/iop.c index 326fb9978094..1ad4e9d80eba 100644 --- a/arch/m68k/mac/iop.c +++ b/arch/m68k/mac/iop.c | |||
@@ -305,14 +305,16 @@ void __init iop_register_interrupts(void) | |||
305 | { | 305 | { |
306 | if (iop_ism_present) { | 306 | if (iop_ism_present) { |
307 | if (oss_present) { | 307 | if (oss_present) { |
308 | request_irq(OSS_IRQLEV_IOPISM, iop_ism_irq, | 308 | if (request_irq(OSS_IRQLEV_IOPISM, iop_ism_irq, |
309 | IRQ_FLG_LOCK, "ISM IOP", | 309 | IRQ_FLG_LOCK, "ISM IOP", |
310 | (void *) IOP_NUM_ISM); | 310 | (void *) IOP_NUM_ISM)) |
311 | pr_err("Couldn't register ISM IOP interrupt\n"); | ||
311 | oss_irq_enable(IRQ_MAC_ADB); | 312 | oss_irq_enable(IRQ_MAC_ADB); |
312 | } else { | 313 | } else { |
313 | request_irq(IRQ_VIA2_0, iop_ism_irq, | 314 | if (request_irq(IRQ_VIA2_0, iop_ism_irq, |
314 | IRQ_FLG_LOCK|IRQ_FLG_FAST, "ISM IOP", | 315 | IRQ_FLG_LOCK|IRQ_FLG_FAST, "ISM IOP", |
315 | (void *) IOP_NUM_ISM); | 316 | (void *) IOP_NUM_ISM)) |
317 | pr_err("Couldn't register ISM IOP interrupt\n"); | ||
316 | } | 318 | } |
317 | if (!iop_alive(iop_base[IOP_NUM_ISM])) { | 319 | if (!iop_alive(iop_base[IOP_NUM_ISM])) { |
318 | printk("IOP: oh my god, they killed the ISM IOP!\n"); | 320 | printk("IOP: oh my god, they killed the ISM IOP!\n"); |
diff --git a/arch/m68k/mac/macints.c b/arch/m68k/mac/macints.c index 82e560c076ce..23711074e0e2 100644 --- a/arch/m68k/mac/macints.c +++ b/arch/m68k/mac/macints.c | |||
@@ -134,6 +134,7 @@ | |||
134 | #include <asm/errno.h> | 134 | #include <asm/errno.h> |
135 | #include <asm/macints.h> | 135 | #include <asm/macints.h> |
136 | #include <asm/irq_regs.h> | 136 | #include <asm/irq_regs.h> |
137 | #include <asm/mac_oss.h> | ||
137 | 138 | ||
138 | #define DEBUG_SPURIOUS | 139 | #define DEBUG_SPURIOUS |
139 | #define SHUTUP_SONIC | 140 | #define SHUTUP_SONIC |
@@ -146,7 +147,6 @@ static int scc_mask; | |||
146 | * VIA/RBV hooks | 147 | * VIA/RBV hooks |
147 | */ | 148 | */ |
148 | 149 | ||
149 | extern void via_init(void); | ||
150 | extern void via_register_interrupts(void); | 150 | extern void via_register_interrupts(void); |
151 | extern void via_irq_enable(int); | 151 | extern void via_irq_enable(int); |
152 | extern void via_irq_disable(int); | 152 | extern void via_irq_disable(int); |
@@ -157,9 +157,6 @@ extern int via_irq_pending(int); | |||
157 | * OSS hooks | 157 | * OSS hooks |
158 | */ | 158 | */ |
159 | 159 | ||
160 | extern int oss_present; | ||
161 | |||
162 | extern void oss_init(void); | ||
163 | extern void oss_register_interrupts(void); | 160 | extern void oss_register_interrupts(void); |
164 | extern void oss_irq_enable(int); | 161 | extern void oss_irq_enable(int); |
165 | extern void oss_irq_disable(int); | 162 | extern void oss_irq_disable(int); |
@@ -170,9 +167,6 @@ extern int oss_irq_pending(int); | |||
170 | * PSC hooks | 167 | * PSC hooks |
171 | */ | 168 | */ |
172 | 169 | ||
173 | extern int psc_present; | ||
174 | |||
175 | extern void psc_init(void); | ||
176 | extern void psc_register_interrupts(void); | 170 | extern void psc_register_interrupts(void); |
177 | extern void psc_irq_enable(int); | 171 | extern void psc_irq_enable(int); |
178 | extern void psc_irq_disable(int); | 172 | extern void psc_irq_disable(int); |
@@ -191,12 +185,10 @@ extern void iop_register_interrupts(void); | |||
191 | 185 | ||
192 | extern int baboon_present; | 186 | extern int baboon_present; |
193 | 187 | ||
194 | extern void baboon_init(void); | ||
195 | extern void baboon_register_interrupts(void); | 188 | extern void baboon_register_interrupts(void); |
196 | extern void baboon_irq_enable(int); | 189 | extern void baboon_irq_enable(int); |
197 | extern void baboon_irq_disable(int); | 190 | extern void baboon_irq_disable(int); |
198 | extern void baboon_irq_clear(int); | 191 | extern void baboon_irq_clear(int); |
199 | extern int baboon_irq_pending(int); | ||
200 | 192 | ||
201 | /* | 193 | /* |
202 | * SCC interrupt routines | 194 | * SCC interrupt routines |
@@ -258,8 +250,9 @@ void __init mac_init_IRQ(void) | |||
258 | if (baboon_present) | 250 | if (baboon_present) |
259 | baboon_register_interrupts(); | 251 | baboon_register_interrupts(); |
260 | iop_register_interrupts(); | 252 | iop_register_interrupts(); |
261 | request_irq(IRQ_AUTO_7, mac_nmi_handler, 0, "NMI", | 253 | if (request_irq(IRQ_AUTO_7, mac_nmi_handler, 0, "NMI", |
262 | mac_nmi_handler); | 254 | mac_nmi_handler)) |
255 | pr_err("Couldn't register NMI\n"); | ||
263 | #ifdef DEBUG_MACINTS | 256 | #ifdef DEBUG_MACINTS |
264 | printk("mac_init_IRQ(): Done!\n"); | 257 | printk("mac_init_IRQ(): Done!\n"); |
265 | #endif | 258 | #endif |
diff --git a/arch/m68k/mac/misc.c b/arch/m68k/mac/misc.c index a44c7086ab39..5d818568b343 100644 --- a/arch/m68k/mac/misc.c +++ b/arch/m68k/mac/misc.c | |||
@@ -35,7 +35,6 @@ | |||
35 | 35 | ||
36 | #define RTC_OFFSET 2082844800 | 36 | #define RTC_OFFSET 2082844800 |
37 | 37 | ||
38 | extern struct mac_booter_data mac_bi_data; | ||
39 | static void (*rom_reset)(void); | 38 | static void (*rom_reset)(void); |
40 | 39 | ||
41 | #ifdef CONFIG_ADB_CUDA | 40 | #ifdef CONFIG_ADB_CUDA |
diff --git a/arch/m68k/mac/oss.c b/arch/m68k/mac/oss.c index 8426501119ca..f3d23d6ebcf8 100644 --- a/arch/m68k/mac/oss.c +++ b/arch/m68k/mac/oss.c | |||
@@ -66,16 +66,21 @@ void __init oss_init(void) | |||
66 | 66 | ||
67 | void __init oss_register_interrupts(void) | 67 | void __init oss_register_interrupts(void) |
68 | { | 68 | { |
69 | request_irq(OSS_IRQLEV_SCSI, oss_irq, IRQ_FLG_LOCK, | 69 | if (request_irq(OSS_IRQLEV_SCSI, oss_irq, IRQ_FLG_LOCK, |
70 | "scsi", (void *) oss); | 70 | "scsi", (void *) oss)) |
71 | request_irq(OSS_IRQLEV_IOPSCC, mac_scc_dispatch, IRQ_FLG_LOCK, | 71 | pr_err("Couldn't register %s interrupt\n", "scsi"); |
72 | "scc", mac_scc_dispatch); | 72 | if (request_irq(OSS_IRQLEV_IOPSCC, mac_scc_dispatch, IRQ_FLG_LOCK, |
73 | request_irq(OSS_IRQLEV_NUBUS, oss_nubus_irq, IRQ_FLG_LOCK, | 73 | "scc", mac_scc_dispatch)) |
74 | "nubus", (void *) oss); | 74 | pr_err("Couldn't register %s interrupt\n", "scc"); |
75 | request_irq(OSS_IRQLEV_SOUND, oss_irq, IRQ_FLG_LOCK, | 75 | if (request_irq(OSS_IRQLEV_NUBUS, oss_nubus_irq, IRQ_FLG_LOCK, |
76 | "sound", (void *) oss); | 76 | "nubus", (void *) oss)) |
77 | request_irq(OSS_IRQLEV_VIA1, via1_irq, IRQ_FLG_LOCK, | 77 | pr_err("Couldn't register %s interrupt\n", "nubus"); |
78 | "via1", (void *) via1); | 78 | if (request_irq(OSS_IRQLEV_SOUND, oss_irq, IRQ_FLG_LOCK, |
79 | "sound", (void *) oss)) | ||
80 | pr_err("Couldn't register %s interrupt\n", "sound"); | ||
81 | if (request_irq(OSS_IRQLEV_VIA1, via1_irq, IRQ_FLG_LOCK, | ||
82 | "via1", (void *) via1)) | ||
83 | pr_err("Couldn't register %s interrupt\n", "via1"); | ||
79 | } | 84 | } |
80 | 85 | ||
81 | /* | 86 | /* |
diff --git a/arch/m68k/mac/psc.c b/arch/m68k/mac/psc.c index f84a4dd64f94..ba6ccab64018 100644 --- a/arch/m68k/mac/psc.c +++ b/arch/m68k/mac/psc.c | |||
@@ -117,10 +117,14 @@ void __init psc_init(void) | |||
117 | 117 | ||
118 | void __init psc_register_interrupts(void) | 118 | void __init psc_register_interrupts(void) |
119 | { | 119 | { |
120 | request_irq(IRQ_AUTO_3, psc_irq, 0, "psc3", (void *) 0x30); | 120 | if (request_irq(IRQ_AUTO_3, psc_irq, 0, "psc3", (void *) 0x30)) |
121 | request_irq(IRQ_AUTO_4, psc_irq, 0, "psc4", (void *) 0x40); | 121 | pr_err("Couldn't register psc%d interrupt\n", 3); |
122 | request_irq(IRQ_AUTO_5, psc_irq, 0, "psc5", (void *) 0x50); | 122 | if (request_irq(IRQ_AUTO_4, psc_irq, 0, "psc4", (void *) 0x40)) |
123 | request_irq(IRQ_AUTO_6, psc_irq, 0, "psc6", (void *) 0x60); | 123 | pr_err("Couldn't register psc%d interrupt\n", 4); |
124 | if (request_irq(IRQ_AUTO_5, psc_irq, 0, "psc5", (void *) 0x50)) | ||
125 | pr_err("Couldn't register psc%d interrupt\n", 5); | ||
126 | if (request_irq(IRQ_AUTO_6, psc_irq, 0, "psc6", (void *) 0x60)) | ||
127 | pr_err("Couldn't register psc%d interrupt\n", 6); | ||
124 | } | 128 | } |
125 | 129 | ||
126 | /* | 130 | /* |
diff --git a/arch/m68k/mac/via.c b/arch/m68k/mac/via.c index f01d418e64fe..7d97ba54536e 100644 --- a/arch/m68k/mac/via.c +++ b/arch/m68k/mac/via.c | |||
@@ -34,6 +34,7 @@ | |||
34 | #include <asm/macints.h> | 34 | #include <asm/macints.h> |
35 | #include <asm/mac_via.h> | 35 | #include <asm/mac_via.h> |
36 | #include <asm/mac_psc.h> | 36 | #include <asm/mac_psc.h> |
37 | #include <asm/mac_oss.h> | ||
37 | 38 | ||
38 | volatile __u8 *via1, *via2; | 39 | volatile __u8 *via1, *via2; |
39 | int rbv_present; | 40 | int rbv_present; |
@@ -84,7 +85,6 @@ void via_irq_disable(int irq); | |||
84 | void via_irq_clear(int irq); | 85 | void via_irq_clear(int irq); |
85 | 86 | ||
86 | extern irqreturn_t mac_scc_dispatch(int, void *); | 87 | extern irqreturn_t mac_scc_dispatch(int, void *); |
87 | extern int oss_present; | ||
88 | 88 | ||
89 | /* | 89 | /* |
90 | * Initialize the VIAs | 90 | * Initialize the VIAs |
@@ -283,7 +283,8 @@ void __init via_init_clock(irq_handler_t func) | |||
283 | via1[vT1CL] = MAC_CLOCK_LOW; | 283 | via1[vT1CL] = MAC_CLOCK_LOW; |
284 | via1[vT1CH] = MAC_CLOCK_HIGH; | 284 | via1[vT1CH] = MAC_CLOCK_HIGH; |
285 | 285 | ||
286 | request_irq(IRQ_MAC_TIMER_1, func, IRQ_FLG_LOCK, "timer", func); | 286 | if (request_irq(IRQ_MAC_TIMER_1, func, IRQ_FLG_LOCK, "timer", func)) |
287 | pr_err("Couldn't register %s interrupt\n", "timer"); | ||
287 | } | 288 | } |
288 | 289 | ||
289 | /* | 290 | /* |
@@ -293,25 +294,31 @@ void __init via_init_clock(irq_handler_t func) | |||
293 | void __init via_register_interrupts(void) | 294 | void __init via_register_interrupts(void) |
294 | { | 295 | { |
295 | if (via_alt_mapping) { | 296 | if (via_alt_mapping) { |
296 | request_irq(IRQ_AUTO_1, via1_irq, | 297 | if (request_irq(IRQ_AUTO_1, via1_irq, |
297 | IRQ_FLG_LOCK|IRQ_FLG_FAST, "software", | 298 | IRQ_FLG_LOCK|IRQ_FLG_FAST, "software", |
298 | (void *) via1); | 299 | (void *) via1)) |
299 | request_irq(IRQ_AUTO_6, via1_irq, | 300 | pr_err("Couldn't register %s interrupt\n", "software"); |
301 | if (request_irq(IRQ_AUTO_6, via1_irq, | ||
300 | IRQ_FLG_LOCK|IRQ_FLG_FAST, "via1", | 302 | IRQ_FLG_LOCK|IRQ_FLG_FAST, "via1", |
301 | (void *) via1); | 303 | (void *) via1)) |
304 | pr_err("Couldn't register %s interrupt\n", "via1"); | ||
302 | } else { | 305 | } else { |
303 | request_irq(IRQ_AUTO_1, via1_irq, | 306 | if (request_irq(IRQ_AUTO_1, via1_irq, |
304 | IRQ_FLG_LOCK|IRQ_FLG_FAST, "via1", | 307 | IRQ_FLG_LOCK|IRQ_FLG_FAST, "via1", |
305 | (void *) via1); | 308 | (void *) via1)) |
309 | pr_err("Couldn't register %s interrupt\n", "via1"); | ||
306 | } | 310 | } |
307 | request_irq(IRQ_AUTO_2, via2_irq, IRQ_FLG_LOCK|IRQ_FLG_FAST, | 311 | if (request_irq(IRQ_AUTO_2, via2_irq, IRQ_FLG_LOCK|IRQ_FLG_FAST, |
308 | "via2", (void *) via2); | 312 | "via2", (void *) via2)) |
313 | pr_err("Couldn't register %s interrupt\n", "via2"); | ||
309 | if (!psc_present) { | 314 | if (!psc_present) { |
310 | request_irq(IRQ_AUTO_4, mac_scc_dispatch, IRQ_FLG_LOCK, | 315 | if (request_irq(IRQ_AUTO_4, mac_scc_dispatch, IRQ_FLG_LOCK, |
311 | "scc", mac_scc_dispatch); | 316 | "scc", mac_scc_dispatch)) |
317 | pr_err("Couldn't register %s interrupt\n", "scc"); | ||
312 | } | 318 | } |
313 | request_irq(IRQ_MAC_NUBUS, via_nubus_irq, IRQ_FLG_LOCK|IRQ_FLG_FAST, | 319 | if (request_irq(IRQ_MAC_NUBUS, via_nubus_irq, |
314 | "nubus", (void *) via2); | 320 | IRQ_FLG_LOCK|IRQ_FLG_FAST, "nubus", (void *) via2)) |
321 | pr_err("Couldn't register %s interrupt\n", "nubus"); | ||
315 | } | 322 | } |
316 | 323 | ||
317 | /* | 324 | /* |