2 * Copyright 2005-2008 Analog Devices Inc.
4 * Licensed under the GPL-2 or later
10 #include <mach-common/irq.h>
12 #define NR_PERI_INTS 32
14 #define IRQ_PLL_WAKEUP BFIN_IRQ(0) /* PLL Wakeup Interrupt */
15 #define IRQ_DMA_ERROR BFIN_IRQ(1) /* DMA Error (general) */
16 #define IRQ_GENERIC_ERROR BFIN_IRQ(2) /* GENERIC Error Interrupt */
17 #define IRQ_RTC BFIN_IRQ(3) /* RTC Interrupt */
18 #define IRQ_PPI BFIN_IRQ(4) /* DMA0 Interrupt (PPI) */
19 #define IRQ_SPORT0_RX BFIN_IRQ(5) /* DMA3 Interrupt (SPORT0 RX) */
20 #define IRQ_SPORT0_TX BFIN_IRQ(6) /* DMA4 Interrupt (SPORT0 TX) */
21 #define IRQ_SPORT1_RX BFIN_IRQ(7) /* DMA5 Interrupt (SPORT1 RX) */
22 #define IRQ_SPORT1_TX BFIN_IRQ(8) /* DMA6 Interrupt (SPORT1 TX) */
23 #define IRQ_TWI BFIN_IRQ(9) /* TWI Interrupt */
24 #define IRQ_SPI BFIN_IRQ(10) /* DMA7 Interrupt (SPI) */
25 #define IRQ_UART0_RX BFIN_IRQ(11) /* DMA8 Interrupt (UART0 RX) */
26 #define IRQ_UART0_TX BFIN_IRQ(12) /* DMA9 Interrupt (UART0 TX) */
27 #define IRQ_UART1_RX BFIN_IRQ(13) /* DMA10 Interrupt (UART1 RX) */
28 #define IRQ_UART1_TX BFIN_IRQ(14) /* DMA11 Interrupt (UART1 TX) */
29 #define IRQ_CAN_RX BFIN_IRQ(15) /* CAN Receive Interrupt */
30 #define IRQ_CAN_TX BFIN_IRQ(16) /* CAN Transmit Interrupt */
31 #define IRQ_PH_INTA_MAC_RX BFIN_IRQ(17) /* Port H Interrupt A & DMA1 Interrupt (Ethernet RX) */
32 #define IRQ_PH_INTB_MAC_TX BFIN_IRQ(18) /* Port H Interrupt B & DMA2 Interrupt (Ethernet TX) */
33 #define IRQ_TIMER0 BFIN_IRQ(19) /* Timer 0 */
34 #define IRQ_TIMER1 BFIN_IRQ(20) /* Timer 1 */
35 #define IRQ_TIMER2 BFIN_IRQ(21) /* Timer 2 */
36 #define IRQ_TIMER3 BFIN_IRQ(22) /* Timer 3 */
37 #define IRQ_TIMER4 BFIN_IRQ(23) /* Timer 4 */
38 #define IRQ_TIMER5 BFIN_IRQ(24) /* Timer 5 */
39 #define IRQ_TIMER6 BFIN_IRQ(25) /* Timer 6 */
40 #define IRQ_TIMER7 BFIN_IRQ(26) /* Timer 7 */
41 #define IRQ_PF_INTA_PG_INTA BFIN_IRQ(27) /* Ports F&G Interrupt A */
42 #define IRQ_PORTG_INTB BFIN_IRQ(28) /* Port G Interrupt B */
43 #define IRQ_MEM_DMA0 BFIN_IRQ(29) /* (Memory DMA Stream 0) */
44 #define IRQ_MEM_DMA1 BFIN_IRQ(30) /* (Memory DMA Stream 1) */
45 #define IRQ_PF_INTB_WATCH BFIN_IRQ(31) /* Watchdog & Port F Interrupt B */
49 #define IRQ_PPI_ERROR 42 /* PPI Error Interrupt */
50 #define IRQ_CAN_ERROR 43 /* CAN Error Interrupt */
51 #define IRQ_MAC_ERROR 44 /* MAC Status/Error Interrupt */
52 #define IRQ_SPORT0_ERROR 45 /* SPORT0 Error Interrupt */
53 #define IRQ_SPORT1_ERROR 46 /* SPORT1 Error Interrupt */
54 #define IRQ_SPI_ERROR 47 /* SPI Error Interrupt */
55 #define IRQ_UART0_ERROR 48 /* UART Error Interrupt */
56 #define IRQ_UART1_ERROR 49 /* UART Error Interrupt */
109 #define GPIO_IRQ_BASE IRQ_PF0
111 #define IRQ_MAC_PHYINT 98 /* PHY_INT Interrupt */
112 #define IRQ_MAC_MMCINT 99 /* MMC Counter Interrupt */
113 #define IRQ_MAC_RXFSINT 100 /* RX Frame-Status Interrupt */
114 #define IRQ_MAC_TXFSINT 101 /* TX Frame-Status Interrupt */
115 #define IRQ_MAC_WAKEDET 102 /* Wake-Up Interrupt */
116 #define IRQ_MAC_RXDMAERR 103 /* RX DMA Direction Error Interrupt */
117 #define IRQ_MAC_TXDMAERR 104 /* TX DMA Direction Error Interrupt */
118 #define IRQ_MAC_STMDONE 105 /* Station Mgt. Transfer Done Interrupt */
120 #define IRQ_MAC_RX 106 /* DMA1 Interrupt (Ethernet RX) */
121 #define IRQ_PORTH_INTA 107 /* Port H Interrupt A */
123 #if 0 /* No Interrupt B support (yet) */
124 #define IRQ_MAC_TX 108 /* DMA2 Interrupt (Ethernet TX) */
125 #define IRQ_PORTH_INTB 109 /* Port H Interrupt B */
127 #define IRQ_MAC_TX IRQ_PH_INTB_MAC_TX
130 #define IRQ_PORTF_INTA 110 /* Port F Interrupt A */
131 #define IRQ_PORTG_INTA 111 /* Port G Interrupt A */
133 #if 0 /* No Interrupt B support (yet) */
134 #define IRQ_WATCH 112 /* Watchdog Timer */
135 #define IRQ_PORTF_INTB 113 /* Port F Interrupt B */
137 #define IRQ_WATCH IRQ_PF_INTB_WATCH
140 #define NR_MACH_IRQS (113 + 1)
142 /* IAR0 BIT FIELDS */
143 #define IRQ_PLL_WAKEUP_POS 0
144 #define IRQ_DMA_ERROR_POS 4
145 #define IRQ_ERROR_POS 8
146 #define IRQ_RTC_POS 12
147 #define IRQ_PPI_POS 16
148 #define IRQ_SPORT0_RX_POS 20
149 #define IRQ_SPORT0_TX_POS 24
150 #define IRQ_SPORT1_RX_POS 28
152 /* IAR1 BIT FIELDS */
153 #define IRQ_SPORT1_TX_POS 0
154 #define IRQ_TWI_POS 4
155 #define IRQ_SPI_POS 8
156 #define IRQ_UART0_RX_POS 12
157 #define IRQ_UART0_TX_POS 16
158 #define IRQ_UART1_RX_POS 20
159 #define IRQ_UART1_TX_POS 24
160 #define IRQ_CAN_RX_POS 28
162 /* IAR2 BIT FIELDS */
163 #define IRQ_CAN_TX_POS 0
164 #define IRQ_MAC_RX_POS 4
165 #define IRQ_MAC_TX_POS 8
166 #define IRQ_TIMER0_POS 12
167 #define IRQ_TIMER1_POS 16
168 #define IRQ_TIMER2_POS 20
169 #define IRQ_TIMER3_POS 24
170 #define IRQ_TIMER4_POS 28
172 /* IAR3 BIT FIELDS */
173 #define IRQ_TIMER5_POS 0
174 #define IRQ_TIMER6_POS 4
175 #define IRQ_TIMER7_POS 8
176 #define IRQ_PROG_INTA_POS 12
177 #define IRQ_PORTG_INTB_POS 16
178 #define IRQ_MEM_DMA0_POS 20
179 #define IRQ_MEM_DMA1_POS 24
180 #define IRQ_WATCH_POS 28
182 #define init_mach_irq init_mach_irq