setup.c 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788
  1. /*
  2. * System-specific setup, especially interrupts.
  3. *
  4. * This file is subject to the terms and conditions of the GNU General Public
  5. * License. See the file "COPYING" in the main directory of this archive
  6. * for more details.
  7. *
  8. * Copyright (C) 1998 Harald Koerfgen
  9. * Copyright (C) 2000, 2001, 2002, 2003, 2005 Maciej W. Rozycki
  10. */
  11. #include <linux/console.h>
  12. #include <linux/init.h>
  13. #include <linux/interrupt.h>
  14. #include <linux/ioport.h>
  15. #include <linux/irq.h>
  16. #include <linux/irqnr.h>
  17. #include <linux/module.h>
  18. #include <linux/param.h>
  19. #include <linux/percpu-defs.h>
  20. #include <linux/sched.h>
  21. #include <linux/spinlock.h>
  22. #include <linux/types.h>
  23. #include <linux/pm.h>
  24. #include <asm/bootinfo.h>
  25. #include <asm/cpu.h>
  26. #include <asm/cpu-features.h>
  27. #include <asm/cpu-type.h>
  28. #include <asm/irq.h>
  29. #include <asm/irq_cpu.h>
  30. #include <asm/mipsregs.h>
  31. #include <asm/reboot.h>
  32. #include <asm/time.h>
  33. #include <asm/traps.h>
  34. #include <asm/wbflush.h>
  35. #include <asm/dec/interrupts.h>
  36. #include <asm/dec/ioasic.h>
  37. #include <asm/dec/ioasic_addrs.h>
  38. #include <asm/dec/ioasic_ints.h>
  39. #include <asm/dec/kn01.h>
  40. #include <asm/dec/kn02.h>
  41. #include <asm/dec/kn02ba.h>
  42. #include <asm/dec/kn02ca.h>
  43. #include <asm/dec/kn03.h>
  44. #include <asm/dec/kn230.h>
  45. #include <asm/dec/system.h>
  46. extern void dec_machine_restart(char *command);
  47. extern void dec_machine_halt(void);
  48. extern void dec_machine_power_off(void);
  49. extern irqreturn_t dec_intr_halt(int irq, void *dev_id);
  50. unsigned long dec_kn_slot_base, dec_kn_slot_size;
  51. EXPORT_SYMBOL(dec_kn_slot_base);
  52. EXPORT_SYMBOL(dec_kn_slot_size);
  53. int dec_tc_bus;
  54. DEFINE_SPINLOCK(ioasic_ssr_lock);
  55. EXPORT_SYMBOL(ioasic_ssr_lock);
  56. volatile u32 *ioasic_base;
  57. EXPORT_SYMBOL(ioasic_base);
  58. /*
  59. * IRQ routing and priority tables. Priorites are set as follows:
  60. *
  61. * KN01 KN230 KN02 KN02-BA KN02-CA KN03
  62. *
  63. * MEMORY CPU CPU CPU ASIC CPU CPU
  64. * RTC CPU CPU CPU ASIC CPU CPU
  65. * DMA - - - ASIC ASIC ASIC
  66. * SERIAL0 CPU CPU CSR ASIC ASIC ASIC
  67. * SERIAL1 - - - ASIC - ASIC
  68. * SCSI CPU CPU CSR ASIC ASIC ASIC
  69. * ETHERNET CPU * CSR ASIC ASIC ASIC
  70. * other - - - ASIC - -
  71. * TC2 - - CSR CPU ASIC ASIC
  72. * TC1 - - CSR CPU ASIC ASIC
  73. * TC0 - - CSR CPU ASIC ASIC
  74. * other - CPU - CPU ASIC ASIC
  75. * other - - - - CPU CPU
  76. *
  77. * * -- shared with SCSI
  78. */
  79. int dec_interrupt[DEC_NR_INTS] = {
  80. [0 ... DEC_NR_INTS - 1] = -1
  81. };
  82. EXPORT_SYMBOL(dec_interrupt);
  83. int_ptr cpu_mask_nr_tbl[DEC_MAX_CPU_INTS][2] = {
  84. { { .i = ~0 }, { .p = dec_intr_unimplemented } },
  85. };
  86. int_ptr asic_mask_nr_tbl[DEC_MAX_ASIC_INTS][2] = {
  87. { { .i = ~0 }, { .p = asic_intr_unimplemented } },
  88. };
  89. int cpu_fpu_mask = DEC_CPU_IRQ_MASK(DEC_CPU_INR_FPU);
  90. int *fpu_kstat_irq;
  91. static struct irqaction ioirq = {
  92. .handler = no_action,
  93. .name = "cascade",
  94. .flags = IRQF_NO_THREAD,
  95. };
  96. static struct irqaction fpuirq = {
  97. .handler = no_action,
  98. .name = "fpu",
  99. .flags = IRQF_NO_THREAD,
  100. };
  101. static struct irqaction busirq = {
  102. .name = "bus error",
  103. .flags = IRQF_NO_THREAD,
  104. };
  105. static struct irqaction haltirq = {
  106. .handler = dec_intr_halt,
  107. .name = "halt",
  108. .flags = IRQF_NO_THREAD,
  109. };
  110. /*
  111. * Bus error (DBE/IBE exceptions and bus interrupts) handling setup.
  112. */
  113. static void __init dec_be_init(void)
  114. {
  115. switch (mips_machtype) {
  116. case MACH_DS23100: /* DS2100/DS3100 Pmin/Pmax */
  117. board_be_handler = dec_kn01_be_handler;
  118. busirq.handler = dec_kn01_be_interrupt;
  119. busirq.flags |= IRQF_SHARED;
  120. dec_kn01_be_init();
  121. break;
  122. case MACH_DS5000_1XX: /* DS5000/1xx 3min */
  123. case MACH_DS5000_XX: /* DS5000/xx Maxine */
  124. board_be_handler = dec_kn02xa_be_handler;
  125. busirq.handler = dec_kn02xa_be_interrupt;
  126. dec_kn02xa_be_init();
  127. break;
  128. case MACH_DS5000_200: /* DS5000/200 3max */
  129. case MACH_DS5000_2X0: /* DS5000/240 3max+ */
  130. case MACH_DS5900: /* DS5900 bigmax */
  131. board_be_handler = dec_ecc_be_handler;
  132. busirq.handler = dec_ecc_be_interrupt;
  133. dec_ecc_be_init();
  134. break;
  135. }
  136. }
  137. void __init plat_mem_setup(void)
  138. {
  139. board_be_init = dec_be_init;
  140. wbflush_setup();
  141. _machine_restart = dec_machine_restart;
  142. _machine_halt = dec_machine_halt;
  143. pm_power_off = dec_machine_power_off;
  144. ioport_resource.start = ~0UL;
  145. ioport_resource.end = 0UL;
  146. }
  147. /*
  148. * Machine-specific initialisation for KN01, aka DS2100 (aka Pmin)
  149. * or DS3100 (aka Pmax).
  150. */
  151. static int kn01_interrupt[DEC_NR_INTS] __initdata = {
  152. [DEC_IRQ_CASCADE] = -1,
  153. [DEC_IRQ_AB_RECV] = -1,
  154. [DEC_IRQ_AB_XMIT] = -1,
  155. [DEC_IRQ_DZ11] = DEC_CPU_IRQ_NR(KN01_CPU_INR_DZ11),
  156. [DEC_IRQ_ASC] = -1,
  157. [DEC_IRQ_FLOPPY] = -1,
  158. [DEC_IRQ_FPU] = DEC_CPU_IRQ_NR(DEC_CPU_INR_FPU),
  159. [DEC_IRQ_HALT] = -1,
  160. [DEC_IRQ_ISDN] = -1,
  161. [DEC_IRQ_LANCE] = DEC_CPU_IRQ_NR(KN01_CPU_INR_LANCE),
  162. [DEC_IRQ_BUS] = DEC_CPU_IRQ_NR(KN01_CPU_INR_BUS),
  163. [DEC_IRQ_PSU] = -1,
  164. [DEC_IRQ_RTC] = DEC_CPU_IRQ_NR(KN01_CPU_INR_RTC),
  165. [DEC_IRQ_SCC0] = -1,
  166. [DEC_IRQ_SCC1] = -1,
  167. [DEC_IRQ_SII] = DEC_CPU_IRQ_NR(KN01_CPU_INR_SII),
  168. [DEC_IRQ_TC0] = -1,
  169. [DEC_IRQ_TC1] = -1,
  170. [DEC_IRQ_TC2] = -1,
  171. [DEC_IRQ_TIMER] = -1,
  172. [DEC_IRQ_VIDEO] = DEC_CPU_IRQ_NR(KN01_CPU_INR_VIDEO),
  173. [DEC_IRQ_ASC_MERR] = -1,
  174. [DEC_IRQ_ASC_ERR] = -1,
  175. [DEC_IRQ_ASC_DMA] = -1,
  176. [DEC_IRQ_FLOPPY_ERR] = -1,
  177. [DEC_IRQ_ISDN_ERR] = -1,
  178. [DEC_IRQ_ISDN_RXDMA] = -1,
  179. [DEC_IRQ_ISDN_TXDMA] = -1,
  180. [DEC_IRQ_LANCE_MERR] = -1,
  181. [DEC_IRQ_SCC0A_RXERR] = -1,
  182. [DEC_IRQ_SCC0A_RXDMA] = -1,
  183. [DEC_IRQ_SCC0A_TXERR] = -1,
  184. [DEC_IRQ_SCC0A_TXDMA] = -1,
  185. [DEC_IRQ_AB_RXERR] = -1,
  186. [DEC_IRQ_AB_RXDMA] = -1,
  187. [DEC_IRQ_AB_TXERR] = -1,
  188. [DEC_IRQ_AB_TXDMA] = -1,
  189. [DEC_IRQ_SCC1A_RXERR] = -1,
  190. [DEC_IRQ_SCC1A_RXDMA] = -1,
  191. [DEC_IRQ_SCC1A_TXERR] = -1,
  192. [DEC_IRQ_SCC1A_TXDMA] = -1,
  193. };
  194. static int_ptr kn01_cpu_mask_nr_tbl[][2] __initdata = {
  195. { { .i = DEC_CPU_IRQ_MASK(KN01_CPU_INR_BUS) },
  196. { .i = DEC_CPU_IRQ_NR(KN01_CPU_INR_BUS) } },
  197. { { .i = DEC_CPU_IRQ_MASK(KN01_CPU_INR_RTC) },
  198. { .i = DEC_CPU_IRQ_NR(KN01_CPU_INR_RTC) } },
  199. { { .i = DEC_CPU_IRQ_MASK(KN01_CPU_INR_DZ11) },
  200. { .i = DEC_CPU_IRQ_NR(KN01_CPU_INR_DZ11) } },
  201. { { .i = DEC_CPU_IRQ_MASK(KN01_CPU_INR_SII) },
  202. { .i = DEC_CPU_IRQ_NR(KN01_CPU_INR_SII) } },
  203. { { .i = DEC_CPU_IRQ_MASK(KN01_CPU_INR_LANCE) },
  204. { .i = DEC_CPU_IRQ_NR(KN01_CPU_INR_LANCE) } },
  205. { { .i = DEC_CPU_IRQ_ALL },
  206. { .p = cpu_all_int } },
  207. };
  208. static void __init dec_init_kn01(void)
  209. {
  210. /* IRQ routing. */
  211. memcpy(&dec_interrupt, &kn01_interrupt,
  212. sizeof(kn01_interrupt));
  213. /* CPU IRQ priorities. */
  214. memcpy(&cpu_mask_nr_tbl, &kn01_cpu_mask_nr_tbl,
  215. sizeof(kn01_cpu_mask_nr_tbl));
  216. mips_cpu_irq_init();
  217. } /* dec_init_kn01 */
  218. /*
  219. * Machine-specific initialisation for KN230, aka DS5100, aka MIPSmate.
  220. */
  221. static int kn230_interrupt[DEC_NR_INTS] __initdata = {
  222. [DEC_IRQ_CASCADE] = -1,
  223. [DEC_IRQ_AB_RECV] = -1,
  224. [DEC_IRQ_AB_XMIT] = -1,
  225. [DEC_IRQ_DZ11] = DEC_CPU_IRQ_NR(KN230_CPU_INR_DZ11),
  226. [DEC_IRQ_ASC] = -1,
  227. [DEC_IRQ_FLOPPY] = -1,
  228. [DEC_IRQ_FPU] = DEC_CPU_IRQ_NR(DEC_CPU_INR_FPU),
  229. [DEC_IRQ_HALT] = DEC_CPU_IRQ_NR(KN230_CPU_INR_HALT),
  230. [DEC_IRQ_ISDN] = -1,
  231. [DEC_IRQ_LANCE] = DEC_CPU_IRQ_NR(KN230_CPU_INR_LANCE),
  232. [DEC_IRQ_BUS] = DEC_CPU_IRQ_NR(KN230_CPU_INR_BUS),
  233. [DEC_IRQ_PSU] = -1,
  234. [DEC_IRQ_RTC] = DEC_CPU_IRQ_NR(KN230_CPU_INR_RTC),
  235. [DEC_IRQ_SCC0] = -1,
  236. [DEC_IRQ_SCC1] = -1,
  237. [DEC_IRQ_SII] = DEC_CPU_IRQ_NR(KN230_CPU_INR_SII),
  238. [DEC_IRQ_TC0] = -1,
  239. [DEC_IRQ_TC1] = -1,
  240. [DEC_IRQ_TC2] = -1,
  241. [DEC_IRQ_TIMER] = -1,
  242. [DEC_IRQ_VIDEO] = -1,
  243. [DEC_IRQ_ASC_MERR] = -1,
  244. [DEC_IRQ_ASC_ERR] = -1,
  245. [DEC_IRQ_ASC_DMA] = -1,
  246. [DEC_IRQ_FLOPPY_ERR] = -1,
  247. [DEC_IRQ_ISDN_ERR] = -1,
  248. [DEC_IRQ_ISDN_RXDMA] = -1,
  249. [DEC_IRQ_ISDN_TXDMA] = -1,
  250. [DEC_IRQ_LANCE_MERR] = -1,
  251. [DEC_IRQ_SCC0A_RXERR] = -1,
  252. [DEC_IRQ_SCC0A_RXDMA] = -1,
  253. [DEC_IRQ_SCC0A_TXERR] = -1,
  254. [DEC_IRQ_SCC0A_TXDMA] = -1,
  255. [DEC_IRQ_AB_RXERR] = -1,
  256. [DEC_IRQ_AB_RXDMA] = -1,
  257. [DEC_IRQ_AB_TXERR] = -1,
  258. [DEC_IRQ_AB_TXDMA] = -1,
  259. [DEC_IRQ_SCC1A_RXERR] = -1,
  260. [DEC_IRQ_SCC1A_RXDMA] = -1,
  261. [DEC_IRQ_SCC1A_TXERR] = -1,
  262. [DEC_IRQ_SCC1A_TXDMA] = -1,
  263. };
  264. static int_ptr kn230_cpu_mask_nr_tbl[][2] __initdata = {
  265. { { .i = DEC_CPU_IRQ_MASK(KN230_CPU_INR_BUS) },
  266. { .i = DEC_CPU_IRQ_NR(KN230_CPU_INR_BUS) } },
  267. { { .i = DEC_CPU_IRQ_MASK(KN230_CPU_INR_RTC) },
  268. { .i = DEC_CPU_IRQ_NR(KN230_CPU_INR_RTC) } },
  269. { { .i = DEC_CPU_IRQ_MASK(KN230_CPU_INR_DZ11) },
  270. { .i = DEC_CPU_IRQ_NR(KN230_CPU_INR_DZ11) } },
  271. { { .i = DEC_CPU_IRQ_MASK(KN230_CPU_INR_SII) },
  272. { .i = DEC_CPU_IRQ_NR(KN230_CPU_INR_SII) } },
  273. { { .i = DEC_CPU_IRQ_ALL },
  274. { .p = cpu_all_int } },
  275. };
  276. static void __init dec_init_kn230(void)
  277. {
  278. /* IRQ routing. */
  279. memcpy(&dec_interrupt, &kn230_interrupt,
  280. sizeof(kn230_interrupt));
  281. /* CPU IRQ priorities. */
  282. memcpy(&cpu_mask_nr_tbl, &kn230_cpu_mask_nr_tbl,
  283. sizeof(kn230_cpu_mask_nr_tbl));
  284. mips_cpu_irq_init();
  285. } /* dec_init_kn230 */
  286. /*
  287. * Machine-specific initialisation for KN02, aka DS5000/200, aka 3max.
  288. */
  289. static int kn02_interrupt[DEC_NR_INTS] __initdata = {
  290. [DEC_IRQ_CASCADE] = DEC_CPU_IRQ_NR(KN02_CPU_INR_CASCADE),
  291. [DEC_IRQ_AB_RECV] = -1,
  292. [DEC_IRQ_AB_XMIT] = -1,
  293. [DEC_IRQ_DZ11] = KN02_IRQ_NR(KN02_CSR_INR_DZ11),
  294. [DEC_IRQ_ASC] = KN02_IRQ_NR(KN02_CSR_INR_ASC),
  295. [DEC_IRQ_FLOPPY] = -1,
  296. [DEC_IRQ_FPU] = DEC_CPU_IRQ_NR(DEC_CPU_INR_FPU),
  297. [DEC_IRQ_HALT] = -1,
  298. [DEC_IRQ_ISDN] = -1,
  299. [DEC_IRQ_LANCE] = KN02_IRQ_NR(KN02_CSR_INR_LANCE),
  300. [DEC_IRQ_BUS] = DEC_CPU_IRQ_NR(KN02_CPU_INR_BUS),
  301. [DEC_IRQ_PSU] = -1,
  302. [DEC_IRQ_RTC] = DEC_CPU_IRQ_NR(KN02_CPU_INR_RTC),
  303. [DEC_IRQ_SCC0] = -1,
  304. [DEC_IRQ_SCC1] = -1,
  305. [DEC_IRQ_SII] = -1,
  306. [DEC_IRQ_TC0] = KN02_IRQ_NR(KN02_CSR_INR_TC0),
  307. [DEC_IRQ_TC1] = KN02_IRQ_NR(KN02_CSR_INR_TC1),
  308. [DEC_IRQ_TC2] = KN02_IRQ_NR(KN02_CSR_INR_TC2),
  309. [DEC_IRQ_TIMER] = -1,
  310. [DEC_IRQ_VIDEO] = -1,
  311. [DEC_IRQ_ASC_MERR] = -1,
  312. [DEC_IRQ_ASC_ERR] = -1,
  313. [DEC_IRQ_ASC_DMA] = -1,
  314. [DEC_IRQ_FLOPPY_ERR] = -1,
  315. [DEC_IRQ_ISDN_ERR] = -1,
  316. [DEC_IRQ_ISDN_RXDMA] = -1,
  317. [DEC_IRQ_ISDN_TXDMA] = -1,
  318. [DEC_IRQ_LANCE_MERR] = -1,
  319. [DEC_IRQ_SCC0A_RXERR] = -1,
  320. [DEC_IRQ_SCC0A_RXDMA] = -1,
  321. [DEC_IRQ_SCC0A_TXERR] = -1,
  322. [DEC_IRQ_SCC0A_TXDMA] = -1,
  323. [DEC_IRQ_AB_RXERR] = -1,
  324. [DEC_IRQ_AB_RXDMA] = -1,
  325. [DEC_IRQ_AB_TXERR] = -1,
  326. [DEC_IRQ_AB_TXDMA] = -1,
  327. [DEC_IRQ_SCC1A_RXERR] = -1,
  328. [DEC_IRQ_SCC1A_RXDMA] = -1,
  329. [DEC_IRQ_SCC1A_TXERR] = -1,
  330. [DEC_IRQ_SCC1A_TXDMA] = -1,
  331. };
  332. static int_ptr kn02_cpu_mask_nr_tbl[][2] __initdata = {
  333. { { .i = DEC_CPU_IRQ_MASK(KN02_CPU_INR_BUS) },
  334. { .i = DEC_CPU_IRQ_NR(KN02_CPU_INR_BUS) } },
  335. { { .i = DEC_CPU_IRQ_MASK(KN02_CPU_INR_RTC) },
  336. { .i = DEC_CPU_IRQ_NR(KN02_CPU_INR_RTC) } },
  337. { { .i = DEC_CPU_IRQ_MASK(KN02_CPU_INR_CASCADE) },
  338. { .p = kn02_io_int } },
  339. { { .i = DEC_CPU_IRQ_ALL },
  340. { .p = cpu_all_int } },
  341. };
  342. static int_ptr kn02_asic_mask_nr_tbl[][2] __initdata = {
  343. { { .i = KN02_IRQ_MASK(KN02_CSR_INR_DZ11) },
  344. { .i = KN02_IRQ_NR(KN02_CSR_INR_DZ11) } },
  345. { { .i = KN02_IRQ_MASK(KN02_CSR_INR_ASC) },
  346. { .i = KN02_IRQ_NR(KN02_CSR_INR_ASC) } },
  347. { { .i = KN02_IRQ_MASK(KN02_CSR_INR_LANCE) },
  348. { .i = KN02_IRQ_NR(KN02_CSR_INR_LANCE) } },
  349. { { .i = KN02_IRQ_MASK(KN02_CSR_INR_TC2) },
  350. { .i = KN02_IRQ_NR(KN02_CSR_INR_TC2) } },
  351. { { .i = KN02_IRQ_MASK(KN02_CSR_INR_TC1) },
  352. { .i = KN02_IRQ_NR(KN02_CSR_INR_TC1) } },
  353. { { .i = KN02_IRQ_MASK(KN02_CSR_INR_TC0) },
  354. { .i = KN02_IRQ_NR(KN02_CSR_INR_TC0) } },
  355. { { .i = KN02_IRQ_ALL },
  356. { .p = kn02_all_int } },
  357. };
  358. static void __init dec_init_kn02(void)
  359. {
  360. /* IRQ routing. */
  361. memcpy(&dec_interrupt, &kn02_interrupt,
  362. sizeof(kn02_interrupt));
  363. /* CPU IRQ priorities. */
  364. memcpy(&cpu_mask_nr_tbl, &kn02_cpu_mask_nr_tbl,
  365. sizeof(kn02_cpu_mask_nr_tbl));
  366. /* KN02 CSR IRQ priorities. */
  367. memcpy(&asic_mask_nr_tbl, &kn02_asic_mask_nr_tbl,
  368. sizeof(kn02_asic_mask_nr_tbl));
  369. mips_cpu_irq_init();
  370. init_kn02_irqs(KN02_IRQ_BASE);
  371. } /* dec_init_kn02 */
  372. /*
  373. * Machine-specific initialisation for KN02-BA, aka DS5000/1xx
  374. * (xx = 20, 25, 33), aka 3min. Also applies to KN04(-BA), aka
  375. * DS5000/150, aka 4min.
  376. */
  377. static int kn02ba_interrupt[DEC_NR_INTS] __initdata = {
  378. [DEC_IRQ_CASCADE] = DEC_CPU_IRQ_NR(KN02BA_CPU_INR_CASCADE),
  379. [DEC_IRQ_AB_RECV] = -1,
  380. [DEC_IRQ_AB_XMIT] = -1,
  381. [DEC_IRQ_DZ11] = -1,
  382. [DEC_IRQ_ASC] = IO_IRQ_NR(KN02BA_IO_INR_ASC),
  383. [DEC_IRQ_FLOPPY] = -1,
  384. [DEC_IRQ_FPU] = DEC_CPU_IRQ_NR(DEC_CPU_INR_FPU),
  385. [DEC_IRQ_HALT] = DEC_CPU_IRQ_NR(KN02BA_CPU_INR_HALT),
  386. [DEC_IRQ_ISDN] = -1,
  387. [DEC_IRQ_LANCE] = IO_IRQ_NR(KN02BA_IO_INR_LANCE),
  388. [DEC_IRQ_BUS] = IO_IRQ_NR(KN02BA_IO_INR_BUS),
  389. [DEC_IRQ_PSU] = IO_IRQ_NR(KN02BA_IO_INR_PSU),
  390. [DEC_IRQ_RTC] = IO_IRQ_NR(KN02BA_IO_INR_RTC),
  391. [DEC_IRQ_SCC0] = IO_IRQ_NR(KN02BA_IO_INR_SCC0),
  392. [DEC_IRQ_SCC1] = IO_IRQ_NR(KN02BA_IO_INR_SCC1),
  393. [DEC_IRQ_SII] = -1,
  394. [DEC_IRQ_TC0] = DEC_CPU_IRQ_NR(KN02BA_CPU_INR_TC0),
  395. [DEC_IRQ_TC1] = DEC_CPU_IRQ_NR(KN02BA_CPU_INR_TC1),
  396. [DEC_IRQ_TC2] = DEC_CPU_IRQ_NR(KN02BA_CPU_INR_TC2),
  397. [DEC_IRQ_TIMER] = -1,
  398. [DEC_IRQ_VIDEO] = -1,
  399. [DEC_IRQ_ASC_MERR] = IO_IRQ_NR(IO_INR_ASC_MERR),
  400. [DEC_IRQ_ASC_ERR] = IO_IRQ_NR(IO_INR_ASC_ERR),
  401. [DEC_IRQ_ASC_DMA] = IO_IRQ_NR(IO_INR_ASC_DMA),
  402. [DEC_IRQ_FLOPPY_ERR] = -1,
  403. [DEC_IRQ_ISDN_ERR] = -1,
  404. [DEC_IRQ_ISDN_RXDMA] = -1,
  405. [DEC_IRQ_ISDN_TXDMA] = -1,
  406. [DEC_IRQ_LANCE_MERR] = IO_IRQ_NR(IO_INR_LANCE_MERR),
  407. [DEC_IRQ_SCC0A_RXERR] = IO_IRQ_NR(IO_INR_SCC0A_RXERR),
  408. [DEC_IRQ_SCC0A_RXDMA] = IO_IRQ_NR(IO_INR_SCC0A_RXDMA),
  409. [DEC_IRQ_SCC0A_TXERR] = IO_IRQ_NR(IO_INR_SCC0A_TXERR),
  410. [DEC_IRQ_SCC0A_TXDMA] = IO_IRQ_NR(IO_INR_SCC0A_TXDMA),
  411. [DEC_IRQ_AB_RXERR] = -1,
  412. [DEC_IRQ_AB_RXDMA] = -1,
  413. [DEC_IRQ_AB_TXERR] = -1,
  414. [DEC_IRQ_AB_TXDMA] = -1,
  415. [DEC_IRQ_SCC1A_RXERR] = IO_IRQ_NR(IO_INR_SCC1A_RXERR),
  416. [DEC_IRQ_SCC1A_RXDMA] = IO_IRQ_NR(IO_INR_SCC1A_RXDMA),
  417. [DEC_IRQ_SCC1A_TXERR] = IO_IRQ_NR(IO_INR_SCC1A_TXERR),
  418. [DEC_IRQ_SCC1A_TXDMA] = IO_IRQ_NR(IO_INR_SCC1A_TXDMA),
  419. };
  420. static int_ptr kn02ba_cpu_mask_nr_tbl[][2] __initdata = {
  421. { { .i = DEC_CPU_IRQ_MASK(KN02BA_CPU_INR_CASCADE) },
  422. { .p = kn02xa_io_int } },
  423. { { .i = DEC_CPU_IRQ_MASK(KN02BA_CPU_INR_TC2) },
  424. { .i = DEC_CPU_IRQ_NR(KN02BA_CPU_INR_TC2) } },
  425. { { .i = DEC_CPU_IRQ_MASK(KN02BA_CPU_INR_TC1) },
  426. { .i = DEC_CPU_IRQ_NR(KN02BA_CPU_INR_TC1) } },
  427. { { .i = DEC_CPU_IRQ_MASK(KN02BA_CPU_INR_TC0) },
  428. { .i = DEC_CPU_IRQ_NR(KN02BA_CPU_INR_TC0) } },
  429. { { .i = DEC_CPU_IRQ_ALL },
  430. { .p = cpu_all_int } },
  431. };
  432. static int_ptr kn02ba_asic_mask_nr_tbl[][2] __initdata = {
  433. { { .i = IO_IRQ_MASK(KN02BA_IO_INR_BUS) },
  434. { .i = IO_IRQ_NR(KN02BA_IO_INR_BUS) } },
  435. { { .i = IO_IRQ_MASK(KN02BA_IO_INR_RTC) },
  436. { .i = IO_IRQ_NR(KN02BA_IO_INR_RTC) } },
  437. { { .i = IO_IRQ_DMA },
  438. { .p = asic_dma_int } },
  439. { { .i = IO_IRQ_MASK(KN02BA_IO_INR_SCC0) },
  440. { .i = IO_IRQ_NR(KN02BA_IO_INR_SCC0) } },
  441. { { .i = IO_IRQ_MASK(KN02BA_IO_INR_SCC1) },
  442. { .i = IO_IRQ_NR(KN02BA_IO_INR_SCC1) } },
  443. { { .i = IO_IRQ_MASK(KN02BA_IO_INR_ASC) },
  444. { .i = IO_IRQ_NR(KN02BA_IO_INR_ASC) } },
  445. { { .i = IO_IRQ_MASK(KN02BA_IO_INR_LANCE) },
  446. { .i = IO_IRQ_NR(KN02BA_IO_INR_LANCE) } },
  447. { { .i = IO_IRQ_ALL },
  448. { .p = asic_all_int } },
  449. };
  450. static void __init dec_init_kn02ba(void)
  451. {
  452. /* IRQ routing. */
  453. memcpy(&dec_interrupt, &kn02ba_interrupt,
  454. sizeof(kn02ba_interrupt));
  455. /* CPU IRQ priorities. */
  456. memcpy(&cpu_mask_nr_tbl, &kn02ba_cpu_mask_nr_tbl,
  457. sizeof(kn02ba_cpu_mask_nr_tbl));
  458. /* I/O ASIC IRQ priorities. */
  459. memcpy(&asic_mask_nr_tbl, &kn02ba_asic_mask_nr_tbl,
  460. sizeof(kn02ba_asic_mask_nr_tbl));
  461. mips_cpu_irq_init();
  462. init_ioasic_irqs(IO_IRQ_BASE);
  463. } /* dec_init_kn02ba */
  464. /*
  465. * Machine-specific initialisation for KN02-CA, aka DS5000/xx,
  466. * (xx = 20, 25, 33), aka MAXine. Also applies to KN04(-CA), aka
  467. * DS5000/50, aka 4MAXine.
  468. */
  469. static int kn02ca_interrupt[DEC_NR_INTS] __initdata = {
  470. [DEC_IRQ_CASCADE] = DEC_CPU_IRQ_NR(KN02CA_CPU_INR_CASCADE),
  471. [DEC_IRQ_AB_RECV] = IO_IRQ_NR(KN02CA_IO_INR_AB_RECV),
  472. [DEC_IRQ_AB_XMIT] = IO_IRQ_NR(KN02CA_IO_INR_AB_XMIT),
  473. [DEC_IRQ_DZ11] = -1,
  474. [DEC_IRQ_ASC] = IO_IRQ_NR(KN02CA_IO_INR_ASC),
  475. [DEC_IRQ_FLOPPY] = IO_IRQ_NR(KN02CA_IO_INR_FLOPPY),
  476. [DEC_IRQ_FPU] = DEC_CPU_IRQ_NR(DEC_CPU_INR_FPU),
  477. [DEC_IRQ_HALT] = DEC_CPU_IRQ_NR(KN02CA_CPU_INR_HALT),
  478. [DEC_IRQ_ISDN] = IO_IRQ_NR(KN02CA_IO_INR_ISDN),
  479. [DEC_IRQ_LANCE] = IO_IRQ_NR(KN02CA_IO_INR_LANCE),
  480. [DEC_IRQ_BUS] = DEC_CPU_IRQ_NR(KN02CA_CPU_INR_BUS),
  481. [DEC_IRQ_PSU] = -1,
  482. [DEC_IRQ_RTC] = DEC_CPU_IRQ_NR(KN02CA_CPU_INR_RTC),
  483. [DEC_IRQ_SCC0] = IO_IRQ_NR(KN02CA_IO_INR_SCC0),
  484. [DEC_IRQ_SCC1] = -1,
  485. [DEC_IRQ_SII] = -1,
  486. [DEC_IRQ_TC0] = IO_IRQ_NR(KN02CA_IO_INR_TC0),
  487. [DEC_IRQ_TC1] = IO_IRQ_NR(KN02CA_IO_INR_TC1),
  488. [DEC_IRQ_TC2] = -1,
  489. [DEC_IRQ_TIMER] = DEC_CPU_IRQ_NR(KN02CA_CPU_INR_TIMER),
  490. [DEC_IRQ_VIDEO] = IO_IRQ_NR(KN02CA_IO_INR_VIDEO),
  491. [DEC_IRQ_ASC_MERR] = IO_IRQ_NR(IO_INR_ASC_MERR),
  492. [DEC_IRQ_ASC_ERR] = IO_IRQ_NR(IO_INR_ASC_ERR),
  493. [DEC_IRQ_ASC_DMA] = IO_IRQ_NR(IO_INR_ASC_DMA),
  494. [DEC_IRQ_FLOPPY_ERR] = IO_IRQ_NR(IO_INR_FLOPPY_ERR),
  495. [DEC_IRQ_ISDN_ERR] = IO_IRQ_NR(IO_INR_ISDN_ERR),
  496. [DEC_IRQ_ISDN_RXDMA] = IO_IRQ_NR(IO_INR_ISDN_RXDMA),
  497. [DEC_IRQ_ISDN_TXDMA] = IO_IRQ_NR(IO_INR_ISDN_TXDMA),
  498. [DEC_IRQ_LANCE_MERR] = IO_IRQ_NR(IO_INR_LANCE_MERR),
  499. [DEC_IRQ_SCC0A_RXERR] = IO_IRQ_NR(IO_INR_SCC0A_RXERR),
  500. [DEC_IRQ_SCC0A_RXDMA] = IO_IRQ_NR(IO_INR_SCC0A_RXDMA),
  501. [DEC_IRQ_SCC0A_TXERR] = IO_IRQ_NR(IO_INR_SCC0A_TXERR),
  502. [DEC_IRQ_SCC0A_TXDMA] = IO_IRQ_NR(IO_INR_SCC0A_TXDMA),
  503. [DEC_IRQ_AB_RXERR] = IO_IRQ_NR(IO_INR_AB_RXERR),
  504. [DEC_IRQ_AB_RXDMA] = IO_IRQ_NR(IO_INR_AB_RXDMA),
  505. [DEC_IRQ_AB_TXERR] = IO_IRQ_NR(IO_INR_AB_TXERR),
  506. [DEC_IRQ_AB_TXDMA] = IO_IRQ_NR(IO_INR_AB_TXDMA),
  507. [DEC_IRQ_SCC1A_RXERR] = -1,
  508. [DEC_IRQ_SCC1A_RXDMA] = -1,
  509. [DEC_IRQ_SCC1A_TXERR] = -1,
  510. [DEC_IRQ_SCC1A_TXDMA] = -1,
  511. };
  512. static int_ptr kn02ca_cpu_mask_nr_tbl[][2] __initdata = {
  513. { { .i = DEC_CPU_IRQ_MASK(KN02CA_CPU_INR_BUS) },
  514. { .i = DEC_CPU_IRQ_NR(KN02CA_CPU_INR_BUS) } },
  515. { { .i = DEC_CPU_IRQ_MASK(KN02CA_CPU_INR_RTC) },
  516. { .i = DEC_CPU_IRQ_NR(KN02CA_CPU_INR_RTC) } },
  517. { { .i = DEC_CPU_IRQ_MASK(KN02CA_CPU_INR_CASCADE) },
  518. { .p = kn02xa_io_int } },
  519. { { .i = DEC_CPU_IRQ_ALL },
  520. { .p = cpu_all_int } },
  521. };
  522. static int_ptr kn02ca_asic_mask_nr_tbl[][2] __initdata = {
  523. { { .i = IO_IRQ_DMA },
  524. { .p = asic_dma_int } },
  525. { { .i = IO_IRQ_MASK(KN02CA_IO_INR_SCC0) },
  526. { .i = IO_IRQ_NR(KN02CA_IO_INR_SCC0) } },
  527. { { .i = IO_IRQ_MASK(KN02CA_IO_INR_ASC) },
  528. { .i = IO_IRQ_NR(KN02CA_IO_INR_ASC) } },
  529. { { .i = IO_IRQ_MASK(KN02CA_IO_INR_LANCE) },
  530. { .i = IO_IRQ_NR(KN02CA_IO_INR_LANCE) } },
  531. { { .i = IO_IRQ_MASK(KN02CA_IO_INR_TC1) },
  532. { .i = IO_IRQ_NR(KN02CA_IO_INR_TC1) } },
  533. { { .i = IO_IRQ_MASK(KN02CA_IO_INR_TC0) },
  534. { .i = IO_IRQ_NR(KN02CA_IO_INR_TC0) } },
  535. { { .i = IO_IRQ_ALL },
  536. { .p = asic_all_int } },
  537. };
  538. static void __init dec_init_kn02ca(void)
  539. {
  540. /* IRQ routing. */
  541. memcpy(&dec_interrupt, &kn02ca_interrupt,
  542. sizeof(kn02ca_interrupt));
  543. /* CPU IRQ priorities. */
  544. memcpy(&cpu_mask_nr_tbl, &kn02ca_cpu_mask_nr_tbl,
  545. sizeof(kn02ca_cpu_mask_nr_tbl));
  546. /* I/O ASIC IRQ priorities. */
  547. memcpy(&asic_mask_nr_tbl, &kn02ca_asic_mask_nr_tbl,
  548. sizeof(kn02ca_asic_mask_nr_tbl));
  549. mips_cpu_irq_init();
  550. init_ioasic_irqs(IO_IRQ_BASE);
  551. } /* dec_init_kn02ca */
  552. /*
  553. * Machine-specific initialisation for KN03, aka DS5000/240,
  554. * aka 3max+ and DS5900, aka BIGmax. Also applies to KN05, aka
  555. * DS5000/260, aka 4max+ and DS5900/260.
  556. */
  557. static int kn03_interrupt[DEC_NR_INTS] __initdata = {
  558. [DEC_IRQ_CASCADE] = DEC_CPU_IRQ_NR(KN03_CPU_INR_CASCADE),
  559. [DEC_IRQ_AB_RECV] = -1,
  560. [DEC_IRQ_AB_XMIT] = -1,
  561. [DEC_IRQ_DZ11] = -1,
  562. [DEC_IRQ_ASC] = IO_IRQ_NR(KN03_IO_INR_ASC),
  563. [DEC_IRQ_FLOPPY] = -1,
  564. [DEC_IRQ_FPU] = DEC_CPU_IRQ_NR(DEC_CPU_INR_FPU),
  565. [DEC_IRQ_HALT] = DEC_CPU_IRQ_NR(KN03_CPU_INR_HALT),
  566. [DEC_IRQ_ISDN] = -1,
  567. [DEC_IRQ_LANCE] = IO_IRQ_NR(KN03_IO_INR_LANCE),
  568. [DEC_IRQ_BUS] = DEC_CPU_IRQ_NR(KN03_CPU_INR_BUS),
  569. [DEC_IRQ_PSU] = IO_IRQ_NR(KN03_IO_INR_PSU),
  570. [DEC_IRQ_RTC] = DEC_CPU_IRQ_NR(KN03_CPU_INR_RTC),
  571. [DEC_IRQ_SCC0] = IO_IRQ_NR(KN03_IO_INR_SCC0),
  572. [DEC_IRQ_SCC1] = IO_IRQ_NR(KN03_IO_INR_SCC1),
  573. [DEC_IRQ_SII] = -1,
  574. [DEC_IRQ_TC0] = IO_IRQ_NR(KN03_IO_INR_TC0),
  575. [DEC_IRQ_TC1] = IO_IRQ_NR(KN03_IO_INR_TC1),
  576. [DEC_IRQ_TC2] = IO_IRQ_NR(KN03_IO_INR_TC2),
  577. [DEC_IRQ_TIMER] = -1,
  578. [DEC_IRQ_VIDEO] = -1,
  579. [DEC_IRQ_ASC_MERR] = IO_IRQ_NR(IO_INR_ASC_MERR),
  580. [DEC_IRQ_ASC_ERR] = IO_IRQ_NR(IO_INR_ASC_ERR),
  581. [DEC_IRQ_ASC_DMA] = IO_IRQ_NR(IO_INR_ASC_DMA),
  582. [DEC_IRQ_FLOPPY_ERR] = -1,
  583. [DEC_IRQ_ISDN_ERR] = -1,
  584. [DEC_IRQ_ISDN_RXDMA] = -1,
  585. [DEC_IRQ_ISDN_TXDMA] = -1,
  586. [DEC_IRQ_LANCE_MERR] = IO_IRQ_NR(IO_INR_LANCE_MERR),
  587. [DEC_IRQ_SCC0A_RXERR] = IO_IRQ_NR(IO_INR_SCC0A_RXERR),
  588. [DEC_IRQ_SCC0A_RXDMA] = IO_IRQ_NR(IO_INR_SCC0A_RXDMA),
  589. [DEC_IRQ_SCC0A_TXERR] = IO_IRQ_NR(IO_INR_SCC0A_TXERR),
  590. [DEC_IRQ_SCC0A_TXDMA] = IO_IRQ_NR(IO_INR_SCC0A_TXDMA),
  591. [DEC_IRQ_AB_RXERR] = -1,
  592. [DEC_IRQ_AB_RXDMA] = -1,
  593. [DEC_IRQ_AB_TXERR] = -1,
  594. [DEC_IRQ_AB_TXDMA] = -1,
  595. [DEC_IRQ_SCC1A_RXERR] = IO_IRQ_NR(IO_INR_SCC1A_RXERR),
  596. [DEC_IRQ_SCC1A_RXDMA] = IO_IRQ_NR(IO_INR_SCC1A_RXDMA),
  597. [DEC_IRQ_SCC1A_TXERR] = IO_IRQ_NR(IO_INR_SCC1A_TXERR),
  598. [DEC_IRQ_SCC1A_TXDMA] = IO_IRQ_NR(IO_INR_SCC1A_TXDMA),
  599. };
  600. static int_ptr kn03_cpu_mask_nr_tbl[][2] __initdata = {
  601. { { .i = DEC_CPU_IRQ_MASK(KN03_CPU_INR_BUS) },
  602. { .i = DEC_CPU_IRQ_NR(KN03_CPU_INR_BUS) } },
  603. { { .i = DEC_CPU_IRQ_MASK(KN03_CPU_INR_RTC) },
  604. { .i = DEC_CPU_IRQ_NR(KN03_CPU_INR_RTC) } },
  605. { { .i = DEC_CPU_IRQ_MASK(KN03_CPU_INR_CASCADE) },
  606. { .p = kn03_io_int } },
  607. { { .i = DEC_CPU_IRQ_ALL },
  608. { .p = cpu_all_int } },
  609. };
  610. static int_ptr kn03_asic_mask_nr_tbl[][2] __initdata = {
  611. { { .i = IO_IRQ_DMA },
  612. { .p = asic_dma_int } },
  613. { { .i = IO_IRQ_MASK(KN03_IO_INR_SCC0) },
  614. { .i = IO_IRQ_NR(KN03_IO_INR_SCC0) } },
  615. { { .i = IO_IRQ_MASK(KN03_IO_INR_SCC1) },
  616. { .i = IO_IRQ_NR(KN03_IO_INR_SCC1) } },
  617. { { .i = IO_IRQ_MASK(KN03_IO_INR_ASC) },
  618. { .i = IO_IRQ_NR(KN03_IO_INR_ASC) } },
  619. { { .i = IO_IRQ_MASK(KN03_IO_INR_LANCE) },
  620. { .i = IO_IRQ_NR(KN03_IO_INR_LANCE) } },
  621. { { .i = IO_IRQ_MASK(KN03_IO_INR_TC2) },
  622. { .i = IO_IRQ_NR(KN03_IO_INR_TC2) } },
  623. { { .i = IO_IRQ_MASK(KN03_IO_INR_TC1) },
  624. { .i = IO_IRQ_NR(KN03_IO_INR_TC1) } },
  625. { { .i = IO_IRQ_MASK(KN03_IO_INR_TC0) },
  626. { .i = IO_IRQ_NR(KN03_IO_INR_TC0) } },
  627. { { .i = IO_IRQ_ALL },
  628. { .p = asic_all_int } },
  629. };
  630. static void __init dec_init_kn03(void)
  631. {
  632. /* IRQ routing. */
  633. memcpy(&dec_interrupt, &kn03_interrupt,
  634. sizeof(kn03_interrupt));
  635. /* CPU IRQ priorities. */
  636. memcpy(&cpu_mask_nr_tbl, &kn03_cpu_mask_nr_tbl,
  637. sizeof(kn03_cpu_mask_nr_tbl));
  638. /* I/O ASIC IRQ priorities. */
  639. memcpy(&asic_mask_nr_tbl, &kn03_asic_mask_nr_tbl,
  640. sizeof(kn03_asic_mask_nr_tbl));
  641. mips_cpu_irq_init();
  642. init_ioasic_irqs(IO_IRQ_BASE);
  643. } /* dec_init_kn03 */
  644. void __init arch_init_irq(void)
  645. {
  646. switch (mips_machtype) {
  647. case MACH_DS23100: /* DS2100/DS3100 Pmin/Pmax */
  648. dec_init_kn01();
  649. break;
  650. case MACH_DS5100: /* DS5100 MIPSmate */
  651. dec_init_kn230();
  652. break;
  653. case MACH_DS5000_200: /* DS5000/200 3max */
  654. dec_init_kn02();
  655. break;
  656. case MACH_DS5000_1XX: /* DS5000/1xx 3min */
  657. dec_init_kn02ba();
  658. break;
  659. case MACH_DS5000_2X0: /* DS5000/240 3max+ */
  660. case MACH_DS5900: /* DS5900 bigmax */
  661. dec_init_kn03();
  662. break;
  663. case MACH_DS5000_XX: /* Personal DS5000/xx */
  664. dec_init_kn02ca();
  665. break;
  666. case MACH_DS5800: /* DS5800 Isis */
  667. panic("Don't know how to set this up!");
  668. break;
  669. case MACH_DS5400: /* DS5400 MIPSfair */
  670. panic("Don't know how to set this up!");
  671. break;
  672. case MACH_DS5500: /* DS5500 MIPSfair-2 */
  673. panic("Don't know how to set this up!");
  674. break;
  675. }
  676. /* Free the FPU interrupt if the exception is present. */
  677. if (!cpu_has_nofpuex) {
  678. cpu_fpu_mask = 0;
  679. dec_interrupt[DEC_IRQ_FPU] = -1;
  680. }
  681. /* Free the halt interrupt unused on R4k systems. */
  682. if (current_cpu_type() == CPU_R4000SC ||
  683. current_cpu_type() == CPU_R4400SC)
  684. dec_interrupt[DEC_IRQ_HALT] = -1;
  685. /* Register board interrupts: FPU and cascade. */
  686. if (dec_interrupt[DEC_IRQ_FPU] >= 0 && cpu_has_fpu) {
  687. struct irq_desc *desc_fpu;
  688. int irq_fpu;
  689. irq_fpu = dec_interrupt[DEC_IRQ_FPU];
  690. setup_irq(irq_fpu, &fpuirq);
  691. desc_fpu = irq_to_desc(irq_fpu);
  692. fpu_kstat_irq = this_cpu_ptr(desc_fpu->kstat_irqs);
  693. }
  694. if (dec_interrupt[DEC_IRQ_CASCADE] >= 0)
  695. setup_irq(dec_interrupt[DEC_IRQ_CASCADE], &ioirq);
  696. /* Register the bus error interrupt. */
  697. if (dec_interrupt[DEC_IRQ_BUS] >= 0 && busirq.handler)
  698. setup_irq(dec_interrupt[DEC_IRQ_BUS], &busirq);
  699. /* Register the HALT interrupt. */
  700. if (dec_interrupt[DEC_IRQ_HALT] >= 0)
  701. setup_irq(dec_interrupt[DEC_IRQ_HALT], &haltirq);
  702. }
  703. asmlinkage unsigned int dec_irq_dispatch(unsigned int irq)
  704. {
  705. do_IRQ(irq);
  706. return 0;
  707. }