irq.h 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214
  1. /*
  2. * file: include/asm-blackfin/mach-bf537/irq.h
  3. * based on:
  4. * author:
  5. *
  6. * created:
  7. * description:
  8. * system mmr register map
  9. * rev:
  10. *
  11. * modified:
  12. *
  13. *
  14. * bugs: enter bugs at http://blackfin.uclinux.org/
  15. *
  16. * this program is free software; you can redistribute it and/or modify
  17. * it under the terms of the gnu general public license as published by
  18. * the free software foundation; either version 2, or (at your option)
  19. * any later version.
  20. *
  21. * this program is distributed in the hope that it will be useful,
  22. * but without any warranty; without even the implied warranty of
  23. * merchantability or fitness for a particular purpose. see the
  24. * gnu general public license for more details.
  25. *
  26. * you should have received a copy of the gnu general public license
  27. * along with this program; see the file copying.
  28. * if not, write to the free software foundation,
  29. * 59 temple place - suite 330, boston, ma 02111-1307, usa.
  30. */
  31. #ifndef _BF537_IRQ_H_
  32. #define _BF537_IRQ_H_
  33. /*
  34. * Interrupt source definitions
  35. * Event Source Core Event Name
  36. * Core Emulation **
  37. * Events (highest priority) EMU 0
  38. * Reset RST 1
  39. * NMI NMI 2
  40. * Exception EVX 3
  41. * Reserved -- 4
  42. * Hardware Error IVHW 5
  43. * Core Timer IVTMR 6
  44. * .....
  45. *
  46. * Softirq IVG14
  47. * System Call --
  48. * (lowest priority) IVG15
  49. */
  50. #define SYS_IRQS 39
  51. #define NR_PERI_INTS 32
  52. /* The ABSTRACT IRQ definitions */
  53. /** the first seven of the following are fixed, the rest you change if you need to **/
  54. #define IRQ_EMU 0 /*Emulation */
  55. #define IRQ_RST 1 /*reset */
  56. #define IRQ_NMI 2 /*Non Maskable */
  57. #define IRQ_EVX 3 /*Exception */
  58. #define IRQ_UNUSED 4 /*- unused interrupt*/
  59. #define IRQ_HWERR 5 /*Hardware Error */
  60. #define IRQ_CORETMR 6 /*Core timer */
  61. #define IRQ_PLL_WAKEUP 7 /*PLL Wakeup Interrupt */
  62. #define IRQ_DMA_ERROR 8 /*DMA Error (general) */
  63. #define IRQ_GENERIC_ERROR 9 /*GENERIC Error Interrupt */
  64. #define IRQ_RTC 10 /*RTC Interrupt */
  65. #define IRQ_PPI 11 /*DMA0 Interrupt (PPI) */
  66. #define IRQ_SPORT0_RX 12 /*DMA3 Interrupt (SPORT0 RX) */
  67. #define IRQ_SPORT0_TX 13 /*DMA4 Interrupt (SPORT0 TX) */
  68. #define IRQ_SPORT1_RX 14 /*DMA5 Interrupt (SPORT1 RX) */
  69. #define IRQ_SPORT1_TX 15 /*DMA6 Interrupt (SPORT1 TX) */
  70. #define IRQ_TWI 16 /*TWI Interrupt */
  71. #define IRQ_SPI 17 /*DMA7 Interrupt (SPI) */
  72. #define IRQ_UART0_RX 18 /*DMA8 Interrupt (UART0 RX) */
  73. #define IRQ_UART0_TX 19 /*DMA9 Interrupt (UART0 TX) */
  74. #define IRQ_UART1_RX 20 /*DMA10 Interrupt (UART1 RX) */
  75. #define IRQ_UART1_TX 21 /*DMA11 Interrupt (UART1 TX) */
  76. #define IRQ_CAN_RX 22 /*CAN Receive Interrupt */
  77. #define IRQ_CAN_TX 23 /*CAN Transmit Interrupt */
  78. #define IRQ_MAC_RX 24 /*DMA1 (Ethernet RX) Interrupt */
  79. #define IRQ_MAC_TX 25 /*DMA2 (Ethernet TX) Interrupt */
  80. #define IRQ_TMR0 26 /*Timer 0 */
  81. #define IRQ_TMR1 27 /*Timer 1 */
  82. #define IRQ_TMR2 28 /*Timer 2 */
  83. #define IRQ_TMR3 29 /*Timer 3 */
  84. #define IRQ_TMR4 30 /*Timer 4 */
  85. #define IRQ_TMR5 31 /*Timer 5 */
  86. #define IRQ_TMR6 32 /*Timer 6 */
  87. #define IRQ_TMR7 33 /*Timer 7 */
  88. #define IRQ_PROG_INTA 34 /* PF Ports F&G (PF15:0) Interrupt A */
  89. #define IRQ_PORTG_INTB 35 /* PF Port G (PF15:0) Interrupt B */
  90. #define IRQ_MEM_DMA0 36 /*(Memory DMA Stream 0) */
  91. #define IRQ_MEM_DMA1 37 /*(Memory DMA Stream 1) */
  92. #define IRQ_PROG_INTB 38 /* PF Ports F (PF15:0) Interrupt B */
  93. #define IRQ_WATCH 38 /*Watch Dog Timer */
  94. #define IRQ_PPI_ERROR 42 /*PPI Error Interrupt */
  95. #define IRQ_CAN_ERROR 43 /*CAN Error Interrupt */
  96. #define IRQ_MAC_ERROR 44 /*PPI Error Interrupt */
  97. #define IRQ_SPORT0_ERROR 45 /*SPORT0 Error Interrupt */
  98. #define IRQ_SPORT1_ERROR 46 /*SPORT1 Error Interrupt */
  99. #define IRQ_SPI_ERROR 47 /*SPI Error Interrupt */
  100. #define IRQ_UART0_ERROR 48 /*UART Error Interrupt */
  101. #define IRQ_UART1_ERROR 49 /*UART Error Interrupt */
  102. #define IRQ_PF0 50
  103. #define IRQ_PF1 51
  104. #define IRQ_PF2 52
  105. #define IRQ_PF3 53
  106. #define IRQ_PF4 54
  107. #define IRQ_PF5 55
  108. #define IRQ_PF6 56
  109. #define IRQ_PF7 57
  110. #define IRQ_PF8 58
  111. #define IRQ_PF9 59
  112. #define IRQ_PF10 60
  113. #define IRQ_PF11 61
  114. #define IRQ_PF12 62
  115. #define IRQ_PF13 63
  116. #define IRQ_PF14 64
  117. #define IRQ_PF15 65
  118. #define IRQ_PG0 66
  119. #define IRQ_PG1 67
  120. #define IRQ_PG2 68
  121. #define IRQ_PG3 69
  122. #define IRQ_PG4 70
  123. #define IRQ_PG5 71
  124. #define IRQ_PG6 72
  125. #define IRQ_PG7 73
  126. #define IRQ_PG8 74
  127. #define IRQ_PG9 75
  128. #define IRQ_PG10 76
  129. #define IRQ_PG11 77
  130. #define IRQ_PG12 78
  131. #define IRQ_PG13 79
  132. #define IRQ_PG14 80
  133. #define IRQ_PG15 81
  134. #define IRQ_PH0 82
  135. #define IRQ_PH1 83
  136. #define IRQ_PH2 84
  137. #define IRQ_PH3 85
  138. #define IRQ_PH4 86
  139. #define IRQ_PH5 87
  140. #define IRQ_PH6 88
  141. #define IRQ_PH7 89
  142. #define IRQ_PH8 90
  143. #define IRQ_PH9 91
  144. #define IRQ_PH10 92
  145. #define IRQ_PH11 93
  146. #define IRQ_PH12 94
  147. #define IRQ_PH13 95
  148. #define IRQ_PH14 96
  149. #define IRQ_PH15 97
  150. #define GPIO_IRQ_BASE IRQ_PF0
  151. #define NR_IRQS (IRQ_PH15+1)
  152. #define IVG7 7
  153. #define IVG8 8
  154. #define IVG9 9
  155. #define IVG10 10
  156. #define IVG11 11
  157. #define IVG12 12
  158. #define IVG13 13
  159. #define IVG14 14
  160. #define IVG15 15
  161. /* IAR0 BIT FIELDS*/
  162. #define IRQ_PLL_WAKEUP_POS 0
  163. #define IRQ_DMA_ERROR_POS 4
  164. #define IRQ_ERROR_POS 8
  165. #define IRQ_RTC_POS 12
  166. #define IRQ_PPI_POS 16
  167. #define IRQ_SPORT0_RX_POS 20
  168. #define IRQ_SPORT0_TX_POS 24
  169. #define IRQ_SPORT1_RX_POS 28
  170. /* IAR1 BIT FIELDS*/
  171. #define IRQ_SPORT1_TX_POS 0
  172. #define IRQ_TWI_POS 4
  173. #define IRQ_SPI_POS 8
  174. #define IRQ_UART0_RX_POS 12
  175. #define IRQ_UART0_TX_POS 16
  176. #define IRQ_UART1_RX_POS 20
  177. #define IRQ_UART1_TX_POS 24
  178. #define IRQ_CAN_RX_POS 28
  179. /* IAR2 BIT FIELDS*/
  180. #define IRQ_CAN_TX_POS 0
  181. #define IRQ_MAC_RX_POS 4
  182. #define IRQ_MAC_TX_POS 8
  183. #define IRQ_TMR0_POS 12
  184. #define IRQ_TMR1_POS 16
  185. #define IRQ_TMR2_POS 20
  186. #define IRQ_TMR3_POS 24
  187. #define IRQ_TMR4_POS 28
  188. /* IAR3 BIT FIELDS*/
  189. #define IRQ_TMR5_POS 0
  190. #define IRQ_TMR6_POS 4
  191. #define IRQ_TMR7_POS 8
  192. #define IRQ_PROG_INTA_POS 12
  193. #define IRQ_PORTG_INTB_POS 16
  194. #define IRQ_MEM_DMA0_POS 20
  195. #define IRQ_MEM_DMA1_POS 24
  196. #define IRQ_WATCH_POS 28
  197. #endif /* _BF537_IRQ_H_ */