interrupts.c 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701
  1. /*
  2. * (C) Copyright 2000-2002
  3. * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
  4. *
  5. * (C) Copyright 2002 (440 port)
  6. * Scott McNutt, Artesyn Communication Producs, smcnutt@artsyncp.com
  7. *
  8. * (C) Copyright 2003 (440GX port)
  9. * Travis B. Sawyer, Sandburst Corporation, tsawyer@sandburst.com
  10. *
  11. * See file CREDITS for list of people who contributed to this
  12. * project.
  13. *
  14. * This program is free software; you can redistribute it and/or
  15. * modify it under the terms of the GNU General Public License as
  16. * published by the Free Software Foundation; either version 2 of
  17. * the License, or (at your option) any later version.
  18. *
  19. * This program is distributed in the hope that it will be useful,
  20. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  21. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  22. * GNU General Public License for more details.
  23. *
  24. * You should have received a copy of the GNU General Public License
  25. * along with this program; if not, write to the Free Software
  26. * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
  27. * MA 02111-1307 USA
  28. */
  29. #include <common.h>
  30. #include <watchdog.h>
  31. #include <command.h>
  32. #include <asm/processor.h>
  33. #include <ppc4xx.h>
  34. #include <ppc_asm.tmpl>
  35. #include <commproc.h>
  36. #include "vecnum.h"
  37. DECLARE_GLOBAL_DATA_PTR;
  38. /****************************************************************************/
  39. /*
  40. * CPM interrupt vector functions.
  41. */
  42. struct irq_action {
  43. interrupt_handler_t *handler;
  44. void *arg;
  45. int count;
  46. };
  47. static struct irq_action irq_vecs[32];
  48. void uic0_interrupt( void * parms); /* UIC0 handler */
  49. #if defined(CONFIG_440) || defined(CONFIG_405EX)
  50. static struct irq_action irq_vecs1[32]; /* For UIC1 */
  51. void uic1_interrupt( void * parms); /* UIC1 handler */
  52. #if defined(CONFIG_440GX) || defined(CONFIG_440SPE) || \
  53. defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  54. static struct irq_action irq_vecs2[32]; /* For UIC2 */
  55. void uic2_interrupt( void * parms); /* UIC2 handler */
  56. #endif /* CONFIG_440GX CONFIG_440SPE */
  57. #if defined(CONFIG_440SPE) || defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  58. static struct irq_action irq_vecs3[32]; /* For UIC3 */
  59. void uic3_interrupt( void * parms); /* UIC3 handler */
  60. #endif /* CONFIG_440SPE */
  61. #endif /* CONFIG_440 */
  62. /****************************************************************************/
  63. #if defined(CONFIG_440)
  64. /* SPRN changed in 440 */
  65. static __inline__ void set_evpr(unsigned long val)
  66. {
  67. asm volatile("mtspr 0x03f,%0" : : "r" (val));
  68. }
  69. #else /* !defined(CONFIG_440) */
  70. static __inline__ void set_pit(unsigned long val)
  71. {
  72. asm volatile("mtpit %0" : : "r" (val));
  73. }
  74. static __inline__ void set_tcr(unsigned long val)
  75. {
  76. asm volatile("mttcr %0" : : "r" (val));
  77. }
  78. static __inline__ void set_evpr(unsigned long val)
  79. {
  80. asm volatile("mtevpr %0" : : "r" (val));
  81. }
  82. #endif /* defined(CONFIG_440 */
  83. /****************************************************************************/
  84. int interrupt_init_cpu (unsigned *decrementer_count)
  85. {
  86. int vec;
  87. unsigned long val;
  88. /* decrementer is automatically reloaded */
  89. *decrementer_count = 0;
  90. /*
  91. * Mark all irqs as free
  92. */
  93. for (vec=0; vec<32; vec++) {
  94. irq_vecs[vec].handler = NULL;
  95. irq_vecs[vec].arg = NULL;
  96. irq_vecs[vec].count = 0;
  97. #if defined(CONFIG_440) || defined(CONFIG_405EX)
  98. irq_vecs1[vec].handler = NULL;
  99. irq_vecs1[vec].arg = NULL;
  100. irq_vecs1[vec].count = 0;
  101. #if defined(CONFIG_440GX) || defined(CONFIG_440SPE) || \
  102. defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  103. irq_vecs2[vec].handler = NULL;
  104. irq_vecs2[vec].arg = NULL;
  105. irq_vecs2[vec].count = 0;
  106. #endif /* CONFIG_440GX */
  107. #if defined(CONFIG_440SPE) || defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  108. irq_vecs3[vec].handler = NULL;
  109. irq_vecs3[vec].arg = NULL;
  110. irq_vecs3[vec].count = 0;
  111. #endif /* CONFIG_440SPE */
  112. #endif
  113. }
  114. #ifdef CONFIG_4xx
  115. /*
  116. * Init PIT
  117. */
  118. #if defined(CONFIG_440)
  119. val = mfspr( tcr );
  120. val &= (~0x04400000); /* clear DIS & ARE */
  121. mtspr( tcr, val );
  122. mtspr( dec, 0 ); /* Prevent exception after TSR clear*/
  123. mtspr( decar, 0 ); /* clear reload */
  124. mtspr( tsr, 0x08000000 ); /* clear DEC status */
  125. val = gd->bd->bi_intfreq/1000; /* 1 msec */
  126. mtspr( decar, val ); /* Set auto-reload value */
  127. mtspr( dec, val ); /* Set inital val */
  128. #else
  129. set_pit(gd->bd->bi_intfreq / 1000);
  130. #endif
  131. #endif /* CONFIG_4xx */
  132. #ifdef CONFIG_ADCIOP
  133. /*
  134. * Init PIT
  135. */
  136. set_pit(66000);
  137. #endif
  138. /*
  139. * Enable PIT
  140. */
  141. val = mfspr(tcr);
  142. val |= 0x04400000;
  143. mtspr(tcr, val);
  144. /*
  145. * Set EVPR to 0
  146. */
  147. set_evpr(0x00000000);
  148. #if defined(CONFIG_440) || defined(CONFIG_405EX)
  149. #if !defined(CONFIG_440GX)
  150. /* Install the UIC1 handlers */
  151. irq_install_handler(VECNUM_UIC1NC, uic1_interrupt, 0);
  152. irq_install_handler(VECNUM_UIC1C, uic1_interrupt, 0);
  153. #endif
  154. #endif
  155. #if defined(CONFIG_440GX)
  156. /* Take the GX out of compatibility mode
  157. * Travis Sawyer, 9 Mar 2004
  158. * NOTE: 440gx user manual inconsistency here
  159. * Compatibility mode and Ethernet Clock select are not
  160. * correct in the manual
  161. */
  162. mfsdr(sdr_mfr, val);
  163. val &= ~0x10000000;
  164. mtsdr(sdr_mfr,val);
  165. /* Enable UIC interrupts via UIC Base Enable Register */
  166. mtdcr(uicb0sr, UICB0_ALL);
  167. mtdcr(uicb0er, 0x54000000);
  168. /* None are critical */
  169. mtdcr(uicb0cr, 0);
  170. #endif
  171. return (0);
  172. }
  173. /****************************************************************************/
  174. /*
  175. * Handle external interrupts
  176. */
  177. #if defined(CONFIG_440GX)
  178. void external_interrupt(struct pt_regs *regs)
  179. {
  180. ulong uic_msr;
  181. /*
  182. * Read masked interrupt status register to determine interrupt source
  183. */
  184. /* 440 GX uses base uic register */
  185. uic_msr = mfdcr(uicb0msr);
  186. if ( (UICB0_UIC0CI & uic_msr) || (UICB0_UIC0NCI & uic_msr) )
  187. uic0_interrupt(0);
  188. if ( (UICB0_UIC1CI & uic_msr) || (UICB0_UIC1NCI & uic_msr) )
  189. uic1_interrupt(0);
  190. if ( (UICB0_UIC2CI & uic_msr) || (UICB0_UIC2NCI & uic_msr) )
  191. uic2_interrupt(0);
  192. mtdcr(uicb0sr, uic_msr);
  193. return;
  194. } /* external_interrupt CONFIG_440GX */
  195. #elif defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  196. void external_interrupt(struct pt_regs *regs)
  197. {
  198. ulong uic_msr;
  199. /*
  200. * Read masked interrupt status register to determine interrupt source
  201. */
  202. /* 440 SPe uses base uic register */
  203. uic_msr = mfdcr(uic0msr);
  204. if ( (UICB0_UIC1CI & uic_msr) || (UICB0_UIC1NCI & uic_msr) )
  205. uic1_interrupt(0);
  206. if ( (UICB0_UIC2CI & uic_msr) || (UICB0_UIC2NCI & uic_msr) )
  207. uic2_interrupt(0);
  208. if (uic_msr & ~(UICB0_ALL))
  209. uic0_interrupt(0);
  210. mtdcr(uic0sr, uic_msr);
  211. return;
  212. } /* external_interrupt CONFIG_440EPX & CONFIG_440GRX */
  213. #elif defined(CONFIG_440SPE)
  214. void external_interrupt(struct pt_regs *regs)
  215. {
  216. ulong uic_msr;
  217. /*
  218. * Read masked interrupt status register to determine interrupt source
  219. */
  220. /* 440 SPe uses base uic register */
  221. uic_msr = mfdcr(uic0msr);
  222. if ( (UICB0_UIC1CI & uic_msr) || (UICB0_UIC1NCI & uic_msr) )
  223. uic1_interrupt(0);
  224. if ( (UICB0_UIC2CI & uic_msr) || (UICB0_UIC2NCI & uic_msr) )
  225. uic2_interrupt(0);
  226. if ( (UICB0_UIC3CI & uic_msr) || (UICB0_UIC3NCI & uic_msr) )
  227. uic3_interrupt(0);
  228. if (uic_msr & ~(UICB0_ALL))
  229. uic0_interrupt(0);
  230. mtdcr(uic0sr, uic_msr);
  231. return;
  232. } /* external_interrupt CONFIG_440SPE */
  233. #else
  234. void external_interrupt(struct pt_regs *regs)
  235. {
  236. ulong uic_msr;
  237. ulong msr_shift;
  238. int vec;
  239. /*
  240. * Read masked interrupt status register to determine interrupt source
  241. */
  242. uic_msr = mfdcr(uicmsr);
  243. msr_shift = uic_msr;
  244. vec = 0;
  245. while (msr_shift != 0) {
  246. if (msr_shift & 0x80000000) {
  247. /*
  248. * Increment irq counter (for debug purpose only)
  249. */
  250. irq_vecs[vec].count++;
  251. if (irq_vecs[vec].handler != NULL) {
  252. /* call isr */
  253. (*irq_vecs[vec].handler)(irq_vecs[vec].arg);
  254. } else {
  255. mtdcr(uicer, mfdcr(uicer) & ~(0x80000000 >> vec));
  256. printf ("Masking bogus interrupt vector 0x%x\n", vec);
  257. }
  258. /*
  259. * After servicing the interrupt, we have to remove the status indicator.
  260. */
  261. mtdcr(uicsr, (0x80000000 >> vec));
  262. }
  263. /*
  264. * Shift msr to next position and increment vector
  265. */
  266. msr_shift <<= 1;
  267. vec++;
  268. }
  269. }
  270. #endif
  271. #if defined(CONFIG_440GX) || defined(CONFIG_440SPE) || \
  272. defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  273. /* Handler for UIC0 interrupt */
  274. void uic0_interrupt( void * parms)
  275. {
  276. ulong uic_msr;
  277. ulong msr_shift;
  278. int vec;
  279. /*
  280. * Read masked interrupt status register to determine interrupt source
  281. */
  282. uic_msr = mfdcr(uicmsr);
  283. msr_shift = uic_msr;
  284. vec = 0;
  285. while (msr_shift != 0) {
  286. if (msr_shift & 0x80000000) {
  287. /*
  288. * Increment irq counter (for debug purpose only)
  289. */
  290. irq_vecs[vec].count++;
  291. if (irq_vecs[vec].handler != NULL) {
  292. /* call isr */
  293. (*irq_vecs[vec].handler)(irq_vecs[vec].arg);
  294. } else {
  295. mtdcr(uicer, mfdcr(uicer) & ~(0x80000000 >> vec));
  296. printf ("Masking bogus interrupt vector (uic0) 0x%x\n", vec);
  297. }
  298. /*
  299. * After servicing the interrupt, we have to remove the status indicator.
  300. */
  301. mtdcr(uicsr, (0x80000000 >> vec));
  302. }
  303. /*
  304. * Shift msr to next position and increment vector
  305. */
  306. msr_shift <<= 1;
  307. vec++;
  308. }
  309. }
  310. #endif /* CONFIG_440GX */
  311. #if defined(CONFIG_440) || defined(CONFIG_405EX)
  312. /* Handler for UIC1 interrupt */
  313. void uic1_interrupt( void * parms)
  314. {
  315. ulong uic1_msr;
  316. ulong msr_shift;
  317. int vec;
  318. /*
  319. * Read masked interrupt status register to determine interrupt source
  320. */
  321. uic1_msr = mfdcr(uic1msr);
  322. msr_shift = uic1_msr;
  323. vec = 0;
  324. while (msr_shift != 0) {
  325. if (msr_shift & 0x80000000) {
  326. /*
  327. * Increment irq counter (for debug purpose only)
  328. */
  329. irq_vecs1[vec].count++;
  330. if (irq_vecs1[vec].handler != NULL) {
  331. /* call isr */
  332. (*irq_vecs1[vec].handler)(irq_vecs1[vec].arg);
  333. } else {
  334. mtdcr(uic1er, mfdcr(uic1er) & ~(0x80000000 >> vec));
  335. printf ("Masking bogus interrupt vector (uic1) 0x%x\n", vec);
  336. }
  337. /*
  338. * After servicing the interrupt, we have to remove the status indicator.
  339. */
  340. mtdcr(uic1sr, (0x80000000 >> vec));
  341. }
  342. /*
  343. * Shift msr to next position and increment vector
  344. */
  345. msr_shift <<= 1;
  346. vec++;
  347. }
  348. }
  349. #endif /* defined(CONFIG_440) */
  350. #if defined(CONFIG_440GX) || defined(CONFIG_440SPE) || \
  351. defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  352. /* Handler for UIC2 interrupt */
  353. void uic2_interrupt( void * parms)
  354. {
  355. ulong uic2_msr;
  356. ulong msr_shift;
  357. int vec;
  358. /*
  359. * Read masked interrupt status register to determine interrupt source
  360. */
  361. uic2_msr = mfdcr(uic2msr);
  362. msr_shift = uic2_msr;
  363. vec = 0;
  364. while (msr_shift != 0) {
  365. if (msr_shift & 0x80000000) {
  366. /*
  367. * Increment irq counter (for debug purpose only)
  368. */
  369. irq_vecs2[vec].count++;
  370. if (irq_vecs2[vec].handler != NULL) {
  371. /* call isr */
  372. (*irq_vecs2[vec].handler)(irq_vecs2[vec].arg);
  373. } else {
  374. mtdcr(uic2er, mfdcr(uic2er) & ~(0x80000000 >> vec));
  375. printf ("Masking bogus interrupt vector (uic2) 0x%x\n", vec);
  376. }
  377. /*
  378. * After servicing the interrupt, we have to remove the status indicator.
  379. */
  380. mtdcr(uic2sr, (0x80000000 >> vec));
  381. }
  382. /*
  383. * Shift msr to next position and increment vector
  384. */
  385. msr_shift <<= 1;
  386. vec++;
  387. }
  388. }
  389. #endif /* defined(CONFIG_440GX) */
  390. #if defined(CONFIG_440SPE)
  391. /* Handler for UIC3 interrupt */
  392. void uic3_interrupt( void * parms)
  393. {
  394. ulong uic3_msr;
  395. ulong msr_shift;
  396. int vec;
  397. /*
  398. * Read masked interrupt status register to determine interrupt source
  399. */
  400. uic3_msr = mfdcr(uic3msr);
  401. msr_shift = uic3_msr;
  402. vec = 0;
  403. while (msr_shift != 0) {
  404. if (msr_shift & 0x80000000) {
  405. /*
  406. * Increment irq counter (for debug purpose only)
  407. */
  408. irq_vecs3[vec].count++;
  409. if (irq_vecs3[vec].handler != NULL) {
  410. /* call isr */
  411. (*irq_vecs3[vec].handler)(irq_vecs3[vec].arg);
  412. } else {
  413. mtdcr(uic3er, mfdcr(uic3er) & ~(0x80000000 >> vec));
  414. printf ("Masking bogus interrupt vector (uic3) 0x%x\n", vec);
  415. }
  416. /*
  417. * After servicing the interrupt, we have to remove the status indicator.
  418. */
  419. mtdcr(uic3sr, (0x80000000 >> vec));
  420. }
  421. /*
  422. * Shift msr to next position and increment vector
  423. */
  424. msr_shift <<= 1;
  425. vec++;
  426. }
  427. }
  428. #endif /* defined(CONFIG_440SPE) */
  429. /****************************************************************************/
  430. /*
  431. * Install and free a interrupt handler.
  432. */
  433. void irq_install_handler (int vec, interrupt_handler_t * handler, void *arg)
  434. {
  435. struct irq_action *irqa = irq_vecs;
  436. int i = vec;
  437. #if defined(CONFIG_440) || defined(CONFIG_405EX)
  438. #if defined(CONFIG_440GX) || defined(CONFIG_440SPE) || \
  439. defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  440. if ((vec > 31) && (vec < 64)) {
  441. i = vec - 32;
  442. irqa = irq_vecs1;
  443. } else if (vec > 63) {
  444. i = vec - 64;
  445. irqa = irq_vecs2;
  446. }
  447. #else /* CONFIG_440GX */
  448. if (vec > 31) {
  449. i = vec - 32;
  450. irqa = irq_vecs1;
  451. }
  452. #endif /* CONFIG_440GX */
  453. #endif /* CONFIG_440 */
  454. /*
  455. * print warning when replacing with a different irq vector
  456. */
  457. if ((irqa[i].handler != NULL) && (irqa[i].handler != handler)) {
  458. printf ("Interrupt vector %d: handler 0x%x replacing 0x%x\n",
  459. vec, (uint) handler, (uint) irqa[i].handler);
  460. }
  461. irqa[i].handler = handler;
  462. irqa[i].arg = arg;
  463. #if defined(CONFIG_440) || defined(CONFIG_405EX)
  464. #if defined(CONFIG_440GX) || defined(CONFIG_440SPE) || \
  465. defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  466. if ((vec > 31) && (vec < 64))
  467. mtdcr (uic1er, mfdcr (uic1er) | (0x80000000 >> i));
  468. else if (vec > 63)
  469. mtdcr (uic2er, mfdcr (uic2er) | (0x80000000 >> i));
  470. else
  471. #endif /* CONFIG_440GX */
  472. if (vec > 31)
  473. mtdcr (uic1er, mfdcr (uic1er) | (0x80000000 >> i));
  474. else
  475. #endif
  476. mtdcr (uicer, mfdcr (uicer) | (0x80000000 >> i));
  477. #if 0
  478. printf ("Install interrupt for vector %d ==> %p\n", vec, handler);
  479. #endif
  480. }
  481. void irq_free_handler (int vec)
  482. {
  483. struct irq_action *irqa = irq_vecs;
  484. int i = vec;
  485. #if defined(CONFIG_440) || defined(CONFIG_405EX)
  486. #if defined(CONFIG_440GX) || defined(CONFIG_440SPE) || \
  487. defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  488. if ((vec > 31) && (vec < 64)) {
  489. irqa = irq_vecs1;
  490. i = vec - 32;
  491. } else if (vec > 63) {
  492. irqa = irq_vecs2;
  493. i = vec - 64;
  494. }
  495. #endif /* CONFIG_440GX */
  496. if (vec > 31) {
  497. irqa = irq_vecs1;
  498. i = vec - 32;
  499. }
  500. #endif
  501. #if 0
  502. printf ("Free interrupt for vector %d ==> %p\n",
  503. vec, irq_vecs[vec].handler);
  504. #endif
  505. #if defined(CONFIG_440) || defined(CONFIG_405EX)
  506. #if defined(CONFIG_440GX) || defined(CONFIG_440SPE) || \
  507. defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  508. if ((vec > 31) && (vec < 64))
  509. mtdcr (uic1er, mfdcr (uic1er) & ~(0x80000000 >> i));
  510. else if (vec > 63)
  511. mtdcr (uic2er, mfdcr (uic2er) & ~(0x80000000 >> i));
  512. else
  513. #endif /* CONFIG_440GX */
  514. if (vec > 31)
  515. mtdcr (uic1er, mfdcr (uic1er) & ~(0x80000000 >> i));
  516. else
  517. #endif
  518. mtdcr (uicer, mfdcr (uicer) & ~(0x80000000 >> i));
  519. irqa[i].handler = NULL;
  520. irqa[i].arg = NULL;
  521. }
  522. /****************************************************************************/
  523. void timer_interrupt_cpu (struct pt_regs *regs)
  524. {
  525. /* nothing to do here */
  526. return;
  527. }
  528. /****************************************************************************/
  529. #if defined(CONFIG_CMD_IRQ)
  530. /*******************************************************************************
  531. *
  532. * irqinfo - print information about PCI devices
  533. *
  534. */
  535. int
  536. do_irqinfo(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
  537. {
  538. int vec;
  539. printf ("\nInterrupt-Information:\n");
  540. #if defined(CONFIG_440) || defined(CONFIG_405EX)
  541. printf ("\nUIC 0\n");
  542. #endif
  543. printf ("Nr Routine Arg Count\n");
  544. for (vec=0; vec<32; vec++) {
  545. if (irq_vecs[vec].handler != NULL) {
  546. printf ("%02d %08lx %08lx %d\n",
  547. vec,
  548. (ulong)irq_vecs[vec].handler,
  549. (ulong)irq_vecs[vec].arg,
  550. irq_vecs[vec].count);
  551. }
  552. }
  553. #if defined(CONFIG_440) || defined(CONFIG_405EX)
  554. printf ("\nUIC 1\n");
  555. printf ("Nr Routine Arg Count\n");
  556. for (vec=0; vec<32; vec++) {
  557. if (irq_vecs1[vec].handler != NULL)
  558. printf ("%02d %08lx %08lx %d\n",
  559. vec+31, (ulong)irq_vecs1[vec].handler,
  560. (ulong)irq_vecs1[vec].arg, irq_vecs1[vec].count);
  561. }
  562. printf("\n");
  563. #endif
  564. #if defined(CONFIG_440GX) || defined(CONFIG_440SPE) || \
  565. defined(CONFIG_440EPX) || defined(CONFIG_440GRX)
  566. printf ("\nUIC 2\n");
  567. printf ("Nr Routine Arg Count\n");
  568. for (vec=0; vec<32; vec++) {
  569. if (irq_vecs2[vec].handler != NULL)
  570. printf ("%02d %08lx %08lx %d\n",
  571. vec+63, (ulong)irq_vecs2[vec].handler,
  572. (ulong)irq_vecs2[vec].arg, irq_vecs2[vec].count);
  573. }
  574. printf("\n");
  575. #endif
  576. #if defined(CONFIG_440SPE)
  577. printf ("\nUIC 3\n");
  578. printf ("Nr Routine Arg Count\n");
  579. for (vec=0; vec<32; vec++) {
  580. if (irq_vecs3[vec].handler != NULL)
  581. printf ("%02d %08lx %08lx %d\n",
  582. vec+63, (ulong)irq_vecs3[vec].handler,
  583. (ulong)irq_vecs3[vec].arg, irq_vecs3[vec].count);
  584. }
  585. printf("\n");
  586. #endif
  587. return 0;
  588. }
  589. #endif