Go to the documentation of this file. 1 #ifndef _ASM_M32R_M32R_MP_FPGA_
2 #define _ASM_M32R_M32R_MP_FPGA_
65 #define M32R_SFR_OFFSET (0x00E00000)
70 #define M32R_FPGA_TOP (0x000F0000+M32R_SFR_OFFSET)
72 #define M32R_FPGA_NUM_OF_CPUS_PORTL (0x00+M32R_FPGA_TOP)
73 #define M32R_FPGA_CPU_NAME0_PORTL (0x10+M32R_FPGA_TOP)
74 #define M32R_FPGA_CPU_NAME1_PORTL (0x14+M32R_FPGA_TOP)
75 #define M32R_FPGA_CPU_NAME2_PORTL (0x18+M32R_FPGA_TOP)
76 #define M32R_FPGA_CPU_NAME3_PORTL (0x1C+M32R_FPGA_TOP)
77 #define M32R_FPGA_MODEL_ID0_PORTL (0x20+M32R_FPGA_TOP)
78 #define M32R_FPGA_MODEL_ID1_PORTL (0x24+M32R_FPGA_TOP)
79 #define M32R_FPGA_MODEL_ID2_PORTL (0x28+M32R_FPGA_TOP)
80 #define M32R_FPGA_MODEL_ID3_PORTL (0x2C+M32R_FPGA_TOP)
81 #define M32R_FPGA_VERSION0_PORTL (0x30+M32R_FPGA_TOP)
82 #define M32R_FPGA_VERSION1_PORTL (0x34+M32R_FPGA_TOP)
87 #define M32R_CPM_OFFSET (0x000F4000+M32R_SFR_OFFSET)
89 #define M32R_CPM_CPUCLKCR_PORTL (0x00+M32R_CPM_OFFSET)
90 #define M32R_CPM_CLKMOD_PORTL (0x04+M32R_CPM_OFFSET)
91 #define M32R_CPM_PLLCR_PORTL (0x08+M32R_CPM_OFFSET)
96 #define M32R_BSELC_OFFSET (0x000F5000+M32R_SFR_OFFSET)
98 #define M32R_BSEL0_CR0_PORTL (0x000+M32R_BSELC_OFFSET)
99 #define M32R_BSEL0_CR1_PORTL (0x004+M32R_BSELC_OFFSET)
100 #define M32R_BSEL1_CR0_PORTL (0x100+M32R_BSELC_OFFSET)
101 #define M32R_BSEL1_CR1_PORTL (0x104+M32R_BSELC_OFFSET)
102 #define M32R_BSEL2_CR0_PORTL (0x200+M32R_BSELC_OFFSET)
103 #define M32R_BSEL2_CR1_PORTL (0x204+M32R_BSELC_OFFSET)
104 #define M32R_BSEL3_CR0_PORTL (0x300+M32R_BSELC_OFFSET)
105 #define M32R_BSEL3_CR1_PORTL (0x304+M32R_BSELC_OFFSET)
106 #define M32R_BSEL4_CR0_PORTL (0x400+M32R_BSELC_OFFSET)
107 #define M32R_BSEL4_CR1_PORTL (0x404+M32R_BSELC_OFFSET)
108 #define M32R_BSEL5_CR0_PORTL (0x500+M32R_BSELC_OFFSET)
109 #define M32R_BSEL5_CR1_PORTL (0x504+M32R_BSELC_OFFSET)
110 #define M32R_BSEL6_CR0_PORTL (0x600+M32R_BSELC_OFFSET)
111 #define M32R_BSEL6_CR1_PORTL (0x604+M32R_BSELC_OFFSET)
112 #define M32R_BSEL7_CR0_PORTL (0x700+M32R_BSELC_OFFSET)
113 #define M32R_BSEL7_CR1_PORTL (0x704+M32R_BSELC_OFFSET)
118 #define M32R_MFT_OFFSET (0x000FC000+M32R_SFR_OFFSET)
120 #define M32R_MFTCR_PORTL (0x000+M32R_MFT_OFFSET)
121 #define M32R_MFTRPR_PORTL (0x004+M32R_MFT_OFFSET)
123 #define M32R_MFT0_OFFSET (0x100+M32R_MFT_OFFSET)
124 #define M32R_MFT0MOD_PORTL (0x00+M32R_MFT0_OFFSET)
125 #define M32R_MFT0BOS_PORTL (0x04+M32R_MFT0_OFFSET)
126 #define M32R_MFT0CUT_PORTL (0x08+M32R_MFT0_OFFSET)
127 #define M32R_MFT0RLD_PORTL (0x0C+M32R_MFT0_OFFSET)
128 #define M32R_MFT0CMPRLD_PORTL (0x10+M32R_MFT0_OFFSET)
130 #define M32R_MFT1_OFFSET (0x200+M32R_MFT_OFFSET)
131 #define M32R_MFT1MOD_PORTL (0x00+M32R_MFT1_OFFSET)
132 #define M32R_MFT1BOS_PORTL (0x04+M32R_MFT1_OFFSET)
133 #define M32R_MFT1CUT_PORTL (0x08+M32R_MFT1_OFFSET)
134 #define M32R_MFT1RLD_PORTL (0x0C+M32R_MFT1_OFFSET)
135 #define M32R_MFT1CMPRLD_PORTL (0x10+M32R_MFT1_OFFSET)
137 #define M32R_MFT2_OFFSET (0x300+M32R_MFT_OFFSET)
138 #define M32R_MFT2MOD_PORTL (0x00+M32R_MFT2_OFFSET)
139 #define M32R_MFT2BOS_PORTL (0x04+M32R_MFT2_OFFSET)
140 #define M32R_MFT2CUT_PORTL (0x08+M32R_MFT2_OFFSET)
141 #define M32R_MFT2RLD_PORTL (0x0C+M32R_MFT2_OFFSET)
142 #define M32R_MFT2CMPRLD_PORTL (0x10+M32R_MFT2_OFFSET)
144 #define M32R_MFT3_OFFSET (0x400+M32R_MFT_OFFSET)
145 #define M32R_MFT3MOD_PORTL (0x00+M32R_MFT3_OFFSET)
146 #define M32R_MFT3BOS_PORTL (0x04+M32R_MFT3_OFFSET)
147 #define M32R_MFT3CUT_PORTL (0x08+M32R_MFT3_OFFSET)
148 #define M32R_MFT3RLD_PORTL (0x0C+M32R_MFT3_OFFSET)
149 #define M32R_MFT3CMPRLD_PORTL (0x10+M32R_MFT3_OFFSET)
151 #define M32R_MFT4_OFFSET (0x500+M32R_MFT_OFFSET)
152 #define M32R_MFT4MOD_PORTL (0x00+M32R_MFT4_OFFSET)
153 #define M32R_MFT4BOS_PORTL (0x04+M32R_MFT4_OFFSET)
154 #define M32R_MFT4CUT_PORTL (0x08+M32R_MFT4_OFFSET)
155 #define M32R_MFT4RLD_PORTL (0x0C+M32R_MFT4_OFFSET)
156 #define M32R_MFT4CMPRLD_PORTL (0x10+M32R_MFT4_OFFSET)
158 #define M32R_MFT5_OFFSET (0x600+M32R_MFT_OFFSET)
159 #define M32R_MFT5MOD_PORTL (0x00+M32R_MFT5_OFFSET)
160 #define M32R_MFT5BOS_PORTL (0x04+M32R_MFT5_OFFSET)
161 #define M32R_MFT5CUT_PORTL (0x08+M32R_MFT5_OFFSET)
162 #define M32R_MFT5RLD_PORTL (0x0C+M32R_MFT5_OFFSET)
163 #define M32R_MFT5CMPRLD_PORTL (0x10+M32R_MFT5_OFFSET)
165 #define M32R_MFTCR_MFT0MSK (1UL<<15)
166 #define M32R_MFTCR_MFT1MSK (1UL<<14)
167 #define M32R_MFTCR_MFT2MSK (1UL<<13)
168 #define M32R_MFTCR_MFT3MSK (1UL<<12)
169 #define M32R_MFTCR_MFT4MSK (1UL<<11)
170 #define M32R_MFTCR_MFT5MSK (1UL<<10)
171 #define M32R_MFTCR_MFT0EN (1UL<<7)
172 #define M32R_MFTCR_MFT1EN (1UL<<6)
173 #define M32R_MFTCR_MFT2EN (1UL<<5)
174 #define M32R_MFTCR_MFT3EN (1UL<<4)
175 #define M32R_MFTCR_MFT4EN (1UL<<3)
176 #define M32R_MFTCR_MFT5EN (1UL<<2)
178 #define M32R_MFTMOD_CC_MASK (1UL<<15)
179 #define M32R_MFTMOD_TCCR (1UL<<13)
180 #define M32R_MFTMOD_GTSEL000 (0UL<<8)
181 #define M32R_MFTMOD_GTSEL001 (1UL<<8)
182 #define M32R_MFTMOD_GTSEL010 (2UL<<8)
183 #define M32R_MFTMOD_GTSEL011 (3UL<<8)
184 #define M32R_MFTMOD_GTSEL110 (6UL<<8)
185 #define M32R_MFTMOD_GTSEL111 (7UL<<8)
186 #define M32R_MFTMOD_CMSEL (1UL<<3)
187 #define M32R_MFTMOD_CSSEL000 (0UL<<0)
188 #define M32R_MFTMOD_CSSEL001 (1UL<<0)
189 #define M32R_MFTMOD_CSSEL010 (2UL<<0)
190 #define M32R_MFTMOD_CSSEL011 (3UL<<0)
191 #define M32R_MFTMOD_CSSEL100 (4UL<<0)
192 #define M32R_MFTMOD_CSSEL110 (6UL<<0)
197 #define M32R_SIO_OFFSET (0x000FD000+M32R_SFR_OFFSET)
199 #define M32R_SIO0_CR_PORTL (0x000+M32R_SIO_OFFSET)
200 #define M32R_SIO0_MOD0_PORTL (0x004+M32R_SIO_OFFSET)
201 #define M32R_SIO0_MOD1_PORTL (0x008+M32R_SIO_OFFSET)
202 #define M32R_SIO0_STS_PORTL (0x00C+M32R_SIO_OFFSET)
203 #define M32R_SIO0_TRCR_PORTL (0x010+M32R_SIO_OFFSET)
204 #define M32R_SIO0_BAUR_PORTL (0x014+M32R_SIO_OFFSET)
205 #define M32R_SIO0_RBAUR_PORTL (0x018+M32R_SIO_OFFSET)
206 #define M32R_SIO0_TXB_PORTL (0x01C+M32R_SIO_OFFSET)
207 #define M32R_SIO0_RXB_PORTL (0x020+M32R_SIO_OFFSET)
212 #define M32R_ICU_OFFSET (0x000FF000+M32R_SFR_OFFSET)
214 #define M32R_ICU_ISTS_PORTL (0x004+M32R_ICU_OFFSET)
215 #define M32R_ICU_IREQ0_PORTL (0x008+M32R_ICU_OFFSET)
216 #define M32R_ICU_IREQ1_PORTL (0x00C+M32R_ICU_OFFSET)
217 #define M32R_ICU_SBICR_PORTL (0x018+M32R_ICU_OFFSET)
218 #define M32R_ICU_IMASK_PORTL (0x01C+M32R_ICU_OFFSET)
219 #define M32R_ICU_CR1_PORTL (0x200+M32R_ICU_OFFSET)
220 #define M32R_ICU_CR2_PORTL (0x204+M32R_ICU_OFFSET)
221 #define M32R_ICU_CR3_PORTL (0x208+M32R_ICU_OFFSET)
222 #define M32R_ICU_CR4_PORTL (0x20C+M32R_ICU_OFFSET)
223 #define M32R_ICU_CR5_PORTL (0x210+M32R_ICU_OFFSET)
224 #define M32R_ICU_CR6_PORTL (0x214+M32R_ICU_OFFSET)
225 #define M32R_ICU_CR7_PORTL (0x218+M32R_ICU_OFFSET)
226 #define M32R_ICU_CR8_PORTL (0x218+M32R_ICU_OFFSET)
227 #define M32R_ICU_CR32_PORTL (0x27C+M32R_ICU_OFFSET)
228 #define M32R_ICU_CR33_PORTL (0x280+M32R_ICU_OFFSET)
229 #define M32R_ICU_CR40_PORTL (0x29C+M32R_ICU_OFFSET)
230 #define M32R_ICU_CR41_PORTL (0x2A0+M32R_ICU_OFFSET)
231 #define M32R_ICU_CR48_PORTL (0x2BC+M32R_ICU_OFFSET)
232 #define M32R_ICU_CR49_PORTL (0x2C0+M32R_ICU_OFFSET)
233 #define M32R_ICU_CR50_PORTL (0x2C4+M32R_ICU_OFFSET)
234 #define M32R_ICU_CR51_PORTL (0x2C8+M32R_ICU_OFFSET)
235 #define M32R_ICU_CR52_PORTL (0x2CC+M32R_ICU_OFFSET)
236 #define M32R_ICU_CR53_PORTL (0x2D0+M32R_ICU_OFFSET)
237 #define M32R_ICU_IPICR0_PORTL (0x2DC+M32R_ICU_OFFSET)
238 #define M32R_ICU_IPICR1_PORTL (0x2E0+M32R_ICU_OFFSET)
239 #define M32R_ICU_IPICR2_PORTL (0x2E4+M32R_ICU_OFFSET)
240 #define M32R_ICU_IPICR3_PORTL (0x2E8+M32R_ICU_OFFSET)
241 #define M32R_ICU_IPICR4_PORTL (0x2EC+M32R_ICU_OFFSET)
242 #define M32R_ICU_IPICR5_PORTL (0x2F0+M32R_ICU_OFFSET)
243 #define M32R_ICU_IPICR6_PORTL (0x2F4+M32R_ICU_OFFSET)
244 #define M32R_ICU_IPICR7_PORTL (0x2FC+M32R_ICU_OFFSET)
246 #define M32R_ICUISTS_VECB(val) ((val>>28) & 0xF)
247 #define M32R_ICUISTS_ISN(val) ((val>>22) & 0x3F)
248 #define M32R_ICUISTS_PIML(val) ((val>>16) & 0x7)
250 #define M32R_ICUIMASK_IMSK0 (0UL<<16)
251 #define M32R_ICUIMASK_IMSK1 (1UL<<16)
252 #define M32R_ICUIMASK_IMSK2 (2UL<<16)
253 #define M32R_ICUIMASK_IMSK3 (3UL<<16)
254 #define M32R_ICUIMASK_IMSK4 (4UL<<16)
255 #define M32R_ICUIMASK_IMSK5 (5UL<<16)
256 #define M32R_ICUIMASK_IMSK6 (6UL<<16)
257 #define M32R_ICUIMASK_IMSK7 (7UL<<16)
259 #define M32R_ICUCR_IEN (1UL<<12)
260 #define M32R_ICUCR_IRQ (1UL<<8)
261 #define M32R_ICUCR_ISMOD00 (0UL<<4)
262 #define M32R_ICUCR_ISMOD01 (1UL<<4)
263 #define M32R_ICUCR_ISMOD10 (2UL<<4)
264 #define M32R_ICUCR_ISMOD11 (3UL<<4)
265 #define M32R_ICUCR_ILEVEL0 (0UL<<0)
266 #define M32R_ICUCR_ILEVEL1 (1UL<<0)
267 #define M32R_ICUCR_ILEVEL2 (2UL<<0)
268 #define M32R_ICUCR_ILEVEL3 (3UL<<0)
269 #define M32R_ICUCR_ILEVEL4 (4UL<<0)
270 #define M32R_ICUCR_ILEVEL5 (5UL<<0)
271 #define M32R_ICUCR_ILEVEL6 (6UL<<0)
272 #define M32R_ICUCR_ILEVEL7 (7UL<<0)
273 #define M32R_ICUCR_ILEVEL_MASK (7UL)
275 #define M32R_IRQ_INT0 (1)
276 #define M32R_IRQ_INT1 (2)
277 #define M32R_IRQ_INT2 (3)
278 #define M32R_IRQ_INT3 (4)
279 #define M32R_IRQ_INT4 (5)
280 #define M32R_IRQ_INT5 (6)
281 #define M32R_IRQ_INT6 (7)
282 #define M32R_IRQ_INT7 (8)
283 #define M32R_IRQ_MFT0 (16)
284 #define M32R_IRQ_MFT1 (17)
285 #define M32R_IRQ_MFT2 (18)
286 #define M32R_IRQ_MFT3 (19)
287 #define M32R_IRQ_MFT4 (20)
288 #define M32R_IRQ_MFT5 (21)
289 #define M32R_IRQ_DMAC0 (32)
290 #define M32R_IRQ_DMAC1 (33)
291 #define M32R_IRQ_SIO0_R (48)
292 #define M32R_IRQ_SIO0_S (49)
293 #define M32R_IRQ_SIO1_R (50)
294 #define M32R_IRQ_SIO1_S (51)
295 #define M32R_IRQ_IPI0 (56)
296 #define M32R_IRQ_IPI1 (57)
297 #define M32R_IRQ_IPI2 (58)
298 #define M32R_IRQ_IPI3 (59)
299 #define M32R_IRQ_IPI4 (60)
300 #define M32R_IRQ_IPI5 (61)
301 #define M32R_IRQ_IPI6 (62)
302 #define M32R_IRQ_IPI7 (63)
308 #define M32R_CPUID_PORTL (0xFFFFFFE0)
309 #define M32R_MCICAR_PORTL (0xFFFFFFF0)
310 #define M32R_MCDCAR_PORTL (0xFFFFFFF4)
311 #define M32R_MCCR_PORTL (0xFFFFFFFC)