Go to the documentation of this file.
19 #ifndef __ASM_ARCH_HARDWARE_H
20 #error You must include hardware.h not SA-1100.h
29 #define SA1100_CS0_PHYS 0x00000000
30 #define SA1100_CS1_PHYS 0x08000000
31 #define SA1100_CS2_PHYS 0x10000000
32 #define SA1100_CS3_PHYS 0x18000000
33 #define SA1100_CS4_PHYS 0x40000000
34 #define SA1100_CS5_PHYS 0x48000000
40 #define PCMCIAPrtSp 0x04000000
41 #define PCMCIASp (4*PCMCIAPrtSp)
42 #define PCMCIAIOSp PCMCIAPrtSp
43 #define PCMCIAAttrSp PCMCIAPrtSp
44 #define PCMCIAMemSp PCMCIAPrtSp
46 #define PCMCIA0Sp PCMCIASp
47 #define PCMCIA0IOSp PCMCIAIOSp
48 #define PCMCIA0AttrSp PCMCIAAttrSp
49 #define PCMCIA0MemSp PCMCIAMemSp
51 #define PCMCIA1Sp PCMCIASp
52 #define PCMCIA1IOSp PCMCIAIOSp
53 #define PCMCIA1AttrSp PCMCIAAttrSp
54 #define PCMCIA1MemSp PCMCIAMemSp
57 (0x20000000 + (Nb)*PCMCIASp)
58 #define _PCMCIAIO(Nb) _PCMCIA (Nb)
59 #define _PCMCIAAttr(Nb) \
60 (_PCMCIA (Nb) + 2*PCMCIAPrtSp)
61 #define _PCMCIAMem(Nb) \
62 (_PCMCIA (Nb) + 3*PCMCIAPrtSp)
64 #define _PCMCIA0 _PCMCIA (0)
65 #define _PCMCIA0IO _PCMCIAIO (0)
66 #define _PCMCIA0Attr _PCMCIAAttr (0)
67 #define _PCMCIA0Mem _PCMCIAMem (0)
69 #define _PCMCIA1 _PCMCIA (1)
70 #define _PCMCIA1IO _PCMCIAIO (1)
71 #define _PCMCIA1Attr _PCMCIAAttr (1)
72 #define _PCMCIA1Mem _PCMCIAMem (1)
110 #define Ser0UDCCR __REG(0x80000000)
111 #define Ser0UDCAR __REG(0x80000004)
112 #define Ser0UDCOMP __REG(0x80000008)
113 #define Ser0UDCIMP __REG(0x8000000C)
114 #define Ser0UDCCS0 __REG(0x80000010)
115 #define Ser0UDCCS1 __REG(0x80000014)
116 #define Ser0UDCCS2 __REG(0x80000018)
117 #define Ser0UDCD0 __REG(0x8000001C)
118 #define Ser0UDCWC __REG(0x80000020)
119 #define Ser0UDCDR __REG(0x80000028)
120 #define Ser0UDCSR __REG(0x80000030)
122 #define UDCCR_UDD 0x00000001
123 #define UDCCR_UDA 0x00000002
124 #define UDCCR_RESIM 0x00000004
125 #define UDCCR_EIM 0x00000008
127 #define UDCCR_RIM 0x00000010
129 #define UDCCR_TIM 0x00000020
131 #define UDCCR_SRM 0x00000040
133 #define UDCCR_SUSIM UDCCR_SRM
134 #define UDCCR_REM 0x00000080
136 #define UDCAR_ADD Fld (7, 0)
138 #define UDCOMP_OUTMAXP Fld (8, 0)
140 #define UDCOMP_OutMaxPkt(Size) \
142 (((Size) - 1) << FShft (UDCOMP_OUTMAXP))
144 #define UDCIMP_INMAXP Fld (8, 0)
146 #define UDCIMP_InMaxPkt(Size) \
148 (((Size) - 1) << FShft (UDCIMP_INMAXP))
150 #define UDCCS0_OPR 0x00000001
151 #define UDCCS0_IPR 0x00000002
152 #define UDCCS0_SST 0x00000004
153 #define UDCCS0_FST 0x00000008
154 #define UDCCS0_DE 0x00000010
155 #define UDCCS0_SE 0x00000020
156 #define UDCCS0_SO 0x00000040
158 #define UDCCS0_SSE 0x00000080
160 #define UDCCS1_RFS 0x00000001
162 #define UDCCS1_RPC 0x00000002
163 #define UDCCS1_RPE 0x00000004
164 #define UDCCS1_SST 0x00000008
165 #define UDCCS1_FST 0x00000010
166 #define UDCCS1_RNE 0x00000020
168 #define UDCCS2_TFS 0x00000001
170 #define UDCCS2_TPC 0x00000002
171 #define UDCCS2_TPE 0x00000004
172 #define UDCCS2_TUR 0x00000008
173 #define UDCCS2_SST 0x00000010
174 #define UDCCS2_FST 0x00000020
176 #define UDCD0_DATA Fld (8, 0)
178 #define UDCWC_WC Fld (4, 0)
180 #define UDCDR_DATA Fld (8, 0)
182 #define UDCSR_EIR 0x00000001
183 #define UDCSR_RIR 0x00000002
184 #define UDCSR_TIR 0x00000004
185 #define UDCSR_SUSIR 0x00000008
186 #define UDCSR_RESIR 0x00000010
187 #define UDCSR_RSTIR 0x00000020
266 #define _UTCR0(Nb) __REG(0x80010000 + ((Nb) - 1)*0x00020000)
267 #define _UTCR1(Nb) __REG(0x80010004 + ((Nb) - 1)*0x00020000)
268 #define _UTCR2(Nb) __REG(0x80010008 + ((Nb) - 1)*0x00020000)
269 #define _UTCR3(Nb) __REG(0x8001000C + ((Nb) - 1)*0x00020000)
270 #define _UTCR4(Nb) __REG(0x80010010 + ((Nb) - 1)*0x00020000)
271 #define _UTDR(Nb) __REG(0x80010014 + ((Nb) - 1)*0x00020000)
272 #define _UTSR0(Nb) __REG(0x8001001C + ((Nb) - 1)*0x00020000)
273 #define _UTSR1(Nb) __REG(0x80010020 + ((Nb) - 1)*0x00020000)
275 #define Ser1UTCR0 _UTCR0 (1)
276 #define Ser1UTCR1 _UTCR1 (1)
277 #define Ser1UTCR2 _UTCR2 (1)
278 #define Ser1UTCR3 _UTCR3 (1)
279 #define Ser1UTDR _UTDR (1)
280 #define Ser1UTSR0 _UTSR0 (1)
281 #define Ser1UTSR1 _UTSR1 (1)
283 #define Ser2UTCR0 _UTCR0 (2)
284 #define Ser2UTCR1 _UTCR1 (2)
285 #define Ser2UTCR2 _UTCR2 (2)
286 #define Ser2UTCR3 _UTCR3 (2)
287 #define Ser2UTCR4 _UTCR4 (2)
288 #define Ser2UTDR _UTDR (2)
289 #define Ser2UTSR0 _UTSR0 (2)
290 #define Ser2UTSR1 _UTSR1 (2)
292 #define Ser3UTCR0 _UTCR0 (3)
293 #define Ser3UTCR1 _UTCR1 (3)
294 #define Ser3UTCR2 _UTCR2 (3)
295 #define Ser3UTCR3 _UTCR3 (3)
296 #define Ser3UTDR _UTDR (3)
297 #define Ser3UTSR0 _UTSR0 (3)
298 #define Ser3UTSR1 _UTSR1 (3)
301 #define _Ser1UTCR0 __PREG(Ser1UTCR0)
302 #define _Ser2UTCR0 __PREG(Ser2UTCR0)
303 #define _Ser3UTCR0 __PREG(Ser3UTCR0)
314 #define UTCR0_PE 0x00000001
315 #define UTCR0_OES 0x00000002
316 #define UTCR0_OddPar (UTCR0_OES*0)
317 #define UTCR0_EvenPar (UTCR0_OES*1)
318 #define UTCR0_SBS 0x00000004
319 #define UTCR0_1StpBit (UTCR0_SBS*0)
320 #define UTCR0_2StpBit (UTCR0_SBS*1)
321 #define UTCR0_DSS 0x00000008
322 #define UTCR0_7BitData (UTCR0_DSS*0)
323 #define UTCR0_8BitData (UTCR0_DSS*1)
324 #define UTCR0_SCE 0x00000010
327 #define UTCR0_RCE 0x00000020
328 #define UTCR0_RcRsEdg (UTCR0_RCE*0)
329 #define UTCR0_RcFlEdg (UTCR0_RCE*1)
330 #define UTCR0_TCE 0x00000040
331 #define UTCR0_TrRsEdg (UTCR0_TCE*0)
332 #define UTCR0_TrFlEdg (UTCR0_TCE*1)
333 #define UTCR0_Ser2IrDA \
334 (UTCR0_1StpBit + UTCR0_8BitData)
336 #define UTCR1_BRD Fld (4, 0)
337 #define UTCR2_BRD Fld (8, 0)
340 #define UTCR1_BdRtDiv(Div) \
341 (((Div) - 16)/16 >> FSize (UTCR2_BRD) << \
343 #define UTCR2_BdRtDiv(Div) \
344 (((Div) - 16)/16 & FAlnMsk (UTCR2_BRD) << \
348 #define UTCR1_CeilBdRtDiv(Div) \
349 (((Div) - 1)/16 >> FSize (UTCR2_BRD) << \
351 #define UTCR2_CeilBdRtDiv(Div) \
352 (((Div) - 1)/16 & FAlnMsk (UTCR2_BRD) << \
357 #define UTCR3_RXE 0x00000001
358 #define UTCR3_TXE 0x00000002
359 #define UTCR3_BRK 0x00000004
360 #define UTCR3_RIE 0x00000008
362 #define UTCR3_TIE 0x00000010
364 #define UTCR3_LBM 0x00000020
365 #define UTCR3_Ser2IrDA \
367 (UTCR3_RXE + UTCR3_TXE)
369 #define UTCR4_HSE 0x00000001
371 #define UTCR4_NRZ (UTCR4_HSE*0)
372 #define UTCR4_HPSIR (UTCR4_HSE*1)
373 #define UTCR4_LPM 0x00000002
374 #define UTCR4_Z3_16Bit (UTCR4_LPM*0)
375 #define UTCR4_Z1_6us (UTCR4_LPM*1)
377 #define UTDR_DATA Fld (8, 0)
379 #define UTDR_PRE 0x00000100
380 #define UTDR_FRE 0x00000200
381 #define UTDR_ROR 0x00000400
384 #define UTSR0_TFS 0x00000001
386 #define UTSR0_RFS 0x00000002
388 #define UTSR0_RID 0x00000004
389 #define UTSR0_RBB 0x00000008
390 #define UTSR0_REB 0x00000010
391 #define UTSR0_EIF 0x00000020
393 #define UTSR1_TBY 0x00000001
394 #define UTSR1_RNE 0x00000002
395 #define UTSR1_TNF 0x00000004
396 #define UTSR1_PRE 0x00000008
397 #define UTSR1_FRE 0x00000010
398 #define UTSR1_ROR 0x00000020
428 #define Ser1SDCR0 __REG(0x80020060)
429 #define Ser1SDCR1 __REG(0x80020064)
430 #define Ser1SDCR2 __REG(0x80020068)
431 #define Ser1SDCR3 __REG(0x8002006C)
432 #define Ser1SDCR4 __REG(0x80020070)
433 #define Ser1SDDR __REG(0x80020078)
434 #define Ser1SDSR0 __REG(0x80020080)
435 #define Ser1SDSR1 __REG(0x80020084)
437 #define SDCR0_SUS 0x00000001
438 #define SDCR0_SDLC (SDCR0_SUS*0)
439 #define SDCR0_UART (SDCR0_SUS*1)
440 #define SDCR0_SDF 0x00000002
441 #define SDCR0_SglFlg (SDCR0_SDF*0)
442 #define SDCR0_DblFlg (SDCR0_SDF*1)
443 #define SDCR0_LBM 0x00000004
444 #define SDCR0_BMS 0x00000008
445 #define SDCR0_FM0 (SDCR0_BMS*0)
446 #define SDCR0_NRZ (SDCR0_BMS*1)
447 #define SDCR0_SCE 0x00000010
448 #define SDCR0_SCD 0x00000020
450 #define SDCR0_SClkIn (SDCR0_SCD*0)
451 #define SDCR0_SClkOut (SDCR0_SCD*1)
452 #define SDCR0_RCE 0x00000040
453 #define SDCR0_RcRsEdg (SDCR0_RCE*0)
454 #define SDCR0_RcFlEdg (SDCR0_RCE*1)
455 #define SDCR0_TCE 0x00000080
456 #define SDCR0_TrRsEdg (SDCR0_TCE*0)
457 #define SDCR0_TrFlEdg (SDCR0_TCE*1)
459 #define SDCR1_AAF 0x00000001
461 #define SDCR1_TXE 0x00000002
462 #define SDCR1_RXE 0x00000004
463 #define SDCR1_RIE 0x00000008
465 #define SDCR1_TIE 0x00000010
467 #define SDCR1_AME 0x00000020
468 #define SDCR1_TUS 0x00000040
469 #define SDCR1_EFrmURn (SDCR1_TUS*0)
470 #define SDCR1_AbortURn (SDCR1_TUS*1)
471 #define SDCR1_RAE 0x00000080
473 #define SDCR2_AMV Fld (8, 0)
475 #define SDCR3_BRD Fld (4, 0)
476 #define SDCR4_BRD Fld (8, 0)
479 #define SDCR3_BdRtDiv(Div) \
480 (((Div) - 16)/16 >> FSize (SDCR4_BRD) << \
482 #define SDCR4_BdRtDiv(Div) \
483 (((Div) - 16)/16 & FAlnMsk (SDCR4_BRD) << \
487 #define SDCR3_CeilBdRtDiv(Div) \
488 (((Div) - 1)/16 >> FSize (SDCR4_BRD) << \
490 #define SDCR4_CeilBdRtDiv(Div) \
491 (((Div) - 1)/16 & FAlnMsk (SDCR4_BRD) << \
496 #define SDDR_DATA Fld (8, 0)
498 #define SDDR_EOF 0x00000100
499 #define SDDR_CRE 0x00000200
500 #define SDDR_ROR 0x00000400
503 #define SDSR0_EIF 0x00000001
504 #define SDSR0_TUR 0x00000002
505 #define SDSR0_RAB 0x00000004
506 #define SDSR0_TFS 0x00000008
508 #define SDSR0_RFS 0x00000010
511 #define SDSR1_RSY 0x00000001
512 #define SDSR1_TBY 0x00000002
513 #define SDSR1_RNE 0x00000004
514 #define SDSR1_TNF 0x00000008
515 #define SDSR1_RTD 0x00000010
516 #define SDSR1_EOF 0x00000020
517 #define SDSR1_CRE 0x00000040
518 #define SDSR1_ROR 0x00000080
542 #define Ser2HSCR0 __REG(0x80040060)
543 #define Ser2HSCR1 __REG(0x80040064)
544 #define Ser2HSDR __REG(0x8004006C)
545 #define Ser2HSSR0 __REG(0x80040074)
546 #define Ser2HSSR1 __REG(0x80040078)
547 #define Ser2HSCR2 __REG(0x90060028)
549 #define HSCR0_ITR 0x00000001
550 #define HSCR0_UART (HSCR0_ITR*0)
551 #define HSCR0_HSSP (HSCR0_ITR*1)
552 #define HSCR0_LBM 0x00000002
553 #define HSCR0_TUS 0x00000004
554 #define HSCR0_EFrmURn (HSCR0_TUS*0)
555 #define HSCR0_AbortURn (HSCR0_TUS*1)
556 #define HSCR0_TXE 0x00000008
557 #define HSCR0_RXE 0x00000010
558 #define HSCR0_RIE 0x00000020
560 #define HSCR0_TIE 0x00000040
562 #define HSCR0_AME 0x00000080
564 #define HSCR1_AMV Fld (8, 0)
566 #define HSDR_DATA Fld (8, 0)
568 #define HSDR_EOF 0x00000100
569 #define HSDR_CRE 0x00000200
570 #define HSDR_ROR 0x00000400
573 #define HSSR0_EIF 0x00000001
574 #define HSSR0_TUR 0x00000002
575 #define HSSR0_RAB 0x00000004
576 #define HSSR0_TFS 0x00000008
578 #define HSSR0_RFS 0x00000010
580 #define HSSR0_FRE 0x00000020
582 #define HSSR1_RSY 0x00000001
583 #define HSSR1_TBY 0x00000002
584 #define HSSR1_RNE 0x00000004
585 #define HSSR1_TNF 0x00000008
586 #define HSSR1_EOF 0x00000010
587 #define HSSR1_CRE 0x00000020
588 #define HSSR1_ROR 0x00000040
590 #define HSCR2_TXP 0x00040000
591 #define HSCR2_TrDataL (HSCR2_TXP*0)
593 #define HSCR2_TrDataH (HSCR2_TXP*1)
595 #define HSCR2_RXP 0x00080000
596 #define HSCR2_RcDataL (HSCR2_RXP*0)
598 #define HSCR2_RcDataH (HSCR2_RXP*1)
629 #define Ser4MCCR0 __REG(0x80060000)
630 #define Ser4MCDR0 __REG(0x80060008)
631 #define Ser4MCDR1 __REG(0x8006000C)
632 #define Ser4MCDR2 __REG(0x80060010)
633 #define Ser4MCSR __REG(0x80060018)
634 #define Ser4MCCR1 __REG(0x90060030)
636 #define MCCR0_ASD Fld (7, 0)
640 #define MCCR0_AudSmpDiv(Div) \
642 ((Div)/32 << FShft (MCCR0_ASD))
645 #define MCCR0_CeilAudSmpDiv(Div) \
646 (((Div) + 31)/32 << FShft (MCCR0_ASD))
649 #define MCCR0_TSD Fld (7, 8)
653 #define MCCR0_TcmSmpDiv(Div) \
655 ((Div)/32 << FShft (MCCR0_TSD))
658 #define MCCR0_CeilTcmSmpDiv(Div) \
659 (((Div) + 31)/32 << FShft (MCCR0_TSD))
662 #define MCCR0_MCE 0x00010000
663 #define MCCR0_ECS 0x00020000
664 #define MCCR0_IntClk (MCCR0_ECS*0)
665 #define MCCR0_ExtClk (MCCR0_ECS*1)
666 #define MCCR0_ADM 0x00040000
668 #define MCCR0_VldBit (MCCR0_ADM*0)
669 #define MCCR0_SmpCnt (MCCR0_ADM*1)
670 #define MCCR0_TTE 0x00080000
672 #define MCCR0_TRE 0x00100000
674 #define MCCR0_ATE 0x00200000
676 #define MCCR0_ARE 0x00400000
678 #define MCCR0_LBM 0x00800000
679 #define MCCR0_ECP Fld (2, 24)
680 #define MCCR0_ExtClkDiv(Div) \
681 (((Div) - 1) << FShft (MCCR0_ECP))
683 #define MCDR0_DATA Fld (12, 4)
686 #define MCDR1_DATA Fld (14, 2)
691 #define MCDR2_DATA Fld (16, 0)
692 #define MCDR2_RW 0x00010000
693 #define MCDR2_Rd (MCDR2_RW*0)
694 #define MCDR2_Wr (MCDR2_RW*1)
695 #define MCDR2_ADD Fld (4, 17)
697 #define MCSR_ATS 0x00000001
699 #define MCSR_ARS 0x00000002
701 #define MCSR_TTS 0x00000004
703 #define MCSR_TRS 0x00000008
705 #define MCSR_ATU 0x00000010
706 #define MCSR_ARO 0x00000020
707 #define MCSR_TTU 0x00000040
708 #define MCSR_TRO 0x00000080
709 #define MCSR_ANF 0x00000100
711 #define MCSR_ANE 0x00000200
713 #define MCSR_TNF 0x00000400
715 #define MCSR_TNE 0x00000800
717 #define MCSR_CWC 0x00001000
719 #define MCSR_CRC 0x00002000
721 #define MCSR_ACE 0x00004000
722 #define MCSR_TCE 0x00008000
724 #define MCCR1_CFS 0x00100000
725 #define MCCR1_F12MHz (MCCR1_CFS*0)
727 #define MCCR1_F10MHz (MCCR1_CFS*1)
752 #define Ser4SSCR0 __REG(0x80070060)
753 #define Ser4SSCR1 __REG(0x80070064)
754 #define Ser4SSDR __REG(0x8007006C)
755 #define Ser4SSSR __REG(0x80070074)
757 #define SSCR0_DSS Fld (4, 0)
758 #define SSCR0_DataSize(Size) \
759 (((Size) - 1) << FShft (SSCR0_DSS))
760 #define SSCR0_FRF Fld (2, 4)
761 #define SSCR0_Motorola \
763 (0 << FShft (SSCR0_FRF))
766 (1 << FShft (SSCR0_FRF))
767 #define SSCR0_National \
768 (2 << FShft (SSCR0_FRF))
769 #define SSCR0_SSE 0x00000080
770 #define SSCR0_SCR Fld (8, 8)
773 #define SSCR0_SerClkDiv(Div) \
774 (((Div) - 2)/2 << FShft (SSCR0_SCR))
777 #define SSCR0_CeilSerClkDiv(Div) \
778 (((Div) - 1)/2 << FShft (SSCR0_SCR))
782 #define SSCR1_RIE 0x00000001
784 #define SSCR1_TIE 0x00000002
786 #define SSCR1_LBM 0x00000004
787 #define SSCR1_SPO 0x00000008
788 #define SSCR1_SClkIactL (SSCR1_SPO*0)
789 #define SSCR1_SClkIactH (SSCR1_SPO*1)
790 #define SSCR1_SP 0x00000010
791 #define SSCR1_SClk1P (SSCR1_SP*0)
793 #define SSCR1_SClk1_2P (SSCR1_SP*1)
795 #define SSCR1_ECS 0x00000020
796 #define SSCR1_IntClk (SSCR1_ECS*0)
797 #define SSCR1_ExtClk (SSCR1_ECS*1)
799 #define SSDR_DATA Fld (16, 0)
801 #define SSSR_TNF 0x00000002
802 #define SSSR_RNE 0x00000004
803 #define SSSR_BSY 0x00000008
804 #define SSSR_TFS 0x00000010
806 #define SSSR_RFS 0x00000020
808 #define SSSR_ROR 0x00000040
833 #define OSMR0 io_p2v(0x90000000)
834 #define OSMR1 io_p2v(0x90000004)
835 #define OSMR2 io_p2v(0x90000008)
836 #define OSMR3 io_p2v(0x9000000c)
837 #define OSCR io_p2v(0x90000010)
838 #define OSSR io_p2v(0x90000014)
839 #define OWER io_p2v(0x90000018)
840 #define OIER io_p2v(0x9000001C)
844 #define OSSR_M0 OSSR_M (0)
845 #define OSSR_M1 OSSR_M (1)
846 #define OSSR_M2 OSSR_M (2)
847 #define OSSR_M3 OSSR_M (3)
849 #define OWER_WME 0x00000001
854 #define OIER_E0 OIER_E (0)
855 #define OIER_E1 OIER_E (1)
856 #define OIER_E2 OIER_E (2)
857 #define OIER_E3 OIER_E (3)
876 #define RTAR __REG(0x90010000)
877 #define RCNR __REG(0x90010004)
878 #define RTTR __REG(0x90010008)
879 #define RTSR __REG(0x90010010)
881 #define RTTR_C Fld (16, 0)
882 #define RTTR_D Fld (10, 16)
888 #define RTSR_AL 0x00000001
889 #define RTSR_HZ 0x00000002
890 #define RTSR_ALE 0x00000004
891 #define RTSR_HZE 0x00000008
917 #define PMCR __REG(0x90020000)
918 #define PSSR __REG(0x90020004)
919 #define PSPR __REG(0x90020008)
920 #define PWER __REG(0x9002000C)
921 #define PCFR __REG(0x90020010)
922 #define PPCR __REG(0x90020014)
923 #define PGSR __REG(0x90020018)
924 #define POSR __REG(0x9002001C)
926 #define PMCR_SF 0x00000001
928 #define PSSR_SS 0x00000001
929 #define PSSR_BFS 0x00000002
931 #define PSSR_VFS 0x00000004
932 #define PSSR_DH 0x00000008
933 #define PSSR_PH 0x00000010
935 #define PWER_GPIO(Nb) GPIO_GPIO (Nb)
936 #define PWER_GPIO0 PWER_GPIO (0)
937 #define PWER_GPIO1 PWER_GPIO (1)
938 #define PWER_GPIO2 PWER_GPIO (2)
939 #define PWER_GPIO3 PWER_GPIO (3)
940 #define PWER_GPIO4 PWER_GPIO (4)
941 #define PWER_GPIO5 PWER_GPIO (5)
942 #define PWER_GPIO6 PWER_GPIO (6)
943 #define PWER_GPIO7 PWER_GPIO (7)
944 #define PWER_GPIO8 PWER_GPIO (8)
945 #define PWER_GPIO9 PWER_GPIO (9)
946 #define PWER_GPIO10 PWER_GPIO (10)
947 #define PWER_GPIO11 PWER_GPIO (11)
948 #define PWER_GPIO12 PWER_GPIO (12)
949 #define PWER_GPIO13 PWER_GPIO (13)
950 #define PWER_GPIO14 PWER_GPIO (14)
951 #define PWER_GPIO15 PWER_GPIO (15)
952 #define PWER_GPIO16 PWER_GPIO (16)
953 #define PWER_GPIO17 PWER_GPIO (17)
954 #define PWER_GPIO18 PWER_GPIO (18)
955 #define PWER_GPIO19 PWER_GPIO (19)
956 #define PWER_GPIO20 PWER_GPIO (20)
957 #define PWER_GPIO21 PWER_GPIO (21)
958 #define PWER_GPIO22 PWER_GPIO (22)
959 #define PWER_GPIO23 PWER_GPIO (23)
960 #define PWER_GPIO24 PWER_GPIO (24)
961 #define PWER_GPIO25 PWER_GPIO (25)
962 #define PWER_GPIO26 PWER_GPIO (26)
963 #define PWER_GPIO27 PWER_GPIO (27)
964 #define PWER_RTC 0x80000000
966 #define PCFR_OPDE 0x00000001
967 #define PCFR_ClkRun (PCFR_OPDE*0)
968 #define PCFR_ClkStp (PCFR_OPDE*1)
969 #define PCFR_FP 0x00000002
970 #define PCFR_PCMCIANeg (PCFR_FP*0)
971 #define PCFR_PCMCIAFlt (PCFR_FP*1)
972 #define PCFR_FS 0x00000004
973 #define PCFR_StMemNeg (PCFR_FS*0)
974 #define PCFR_StMemFlt (PCFR_FS*1)
975 #define PCFR_FO 0x00000008
978 #define PPCR_CCF Fld (5, 0)
980 (0x00 << FShft (PPCR_CCF))
982 (0x01 << FShft (PPCR_CCF))
984 (0x02 << FShft (PPCR_CCF))
986 (0x03 << FShft (PPCR_CCF))
988 (0x04 << FShft (PPCR_CCF))
990 (0x05 << FShft (PPCR_CCF))
992 (0x06 << FShft (PPCR_CCF))
994 (0x07 << FShft (PPCR_CCF))
996 (0x08 << FShft (PPCR_CCF))
998 (0x09 << FShft (PPCR_CCF))
1000 (0x0A << FShft (PPCR_CCF))
1002 (0x0B << FShft (PPCR_CCF))
1004 (0x0C << FShft (PPCR_CCF))
1006 (0x0D << FShft (PPCR_CCF))
1008 (0x0E << FShft (PPCR_CCF))
1010 (0x0F << FShft (PPCR_CCF))
1012 #define PPCR_F59_0MHz PPCR_Fx16
1013 #define PPCR_F73_7MHz PPCR_Fx20
1014 #define PPCR_F88_5MHz PPCR_Fx24
1015 #define PPCR_F103_2MHz PPCR_Fx28
1016 #define PPCR_F118_0MHz PPCR_Fx32
1017 #define PPCR_F132_7MHz PPCR_Fx36
1018 #define PPCR_F147_5MHz PPCR_Fx40
1019 #define PPCR_F162_2MHz PPCR_Fx44
1020 #define PPCR_F176_9MHz PPCR_Fx48
1021 #define PPCR_F191_7MHz PPCR_Fx52
1022 #define PPCR_F206_4MHz PPCR_Fx56
1023 #define PPCR_F221_2MHz PPCR_Fx60
1024 #define PPCR_F239_6MHz PPCR_Fx64
1025 #define PPCR_F250_7MHz PPCR_Fx68
1026 #define PPCR_F265_4MHz PPCR_Fx72
1027 #define PPCR_F280_2MHz PPCR_Fx76
1029 #define PPCR_F57_3MHz PPCR_Fx16
1030 #define PPCR_F71_6MHz PPCR_Fx20
1031 #define PPCR_F85_9MHz PPCR_Fx24
1032 #define PPCR_F100_2MHz PPCR_Fx28
1033 #define PPCR_F114_5MHz PPCR_Fx32
1034 #define PPCR_F128_9MHz PPCR_Fx36
1035 #define PPCR_F143_2MHz PPCR_Fx40
1036 #define PPCR_F157_5MHz PPCR_Fx44
1037 #define PPCR_F171_8MHz PPCR_Fx48
1038 #define PPCR_F186_1MHz PPCR_Fx52
1039 #define PPCR_F200_5MHz PPCR_Fx56
1040 #define PPCR_F214_8MHz PPCR_Fx60
1041 #define PPCR_F229_1MHz PPCR_Fx64
1042 #define PPCR_F243_4MHz PPCR_Fx68
1043 #define PPCR_F257_7MHz PPCR_Fx72
1044 #define PPCR_F272_0MHz PPCR_Fx76
1046 #define POSR_OOK 0x00000001
1058 #define RSRR __REG(0x90030000)
1059 #define RCSR __REG(0x90030004)
1061 #define RSRR_SWR 0x00000001
1063 #define RCSR_HWR 0x00000001
1064 #define RCSR_SWR 0x00000002
1065 #define RCSR_WDR 0x00000004
1066 #define RCSR_SMR 0x00000008
1076 #define TUCR __REG(0x90030008)
1078 #define TUCR_TIC 0x00000040
1079 #define TUCR_TTST 0x00000080
1080 #define TUCR_RCRC 0x00000100
1082 #define TUCR_PMD 0x00000200
1083 #define TUCR_MR 0x00000400
1084 #define TUCR_NoMB (TUCR_MR*0)
1085 #define TUCR_MBGPIO (TUCR_MR*1)
1087 #define TUCR_CTB Fld (3, 20)
1088 #define TUCR_FDC 0x00800000
1089 #define TUCR_FMC 0x01000000
1090 #define TUCR_TMC 0x02000000
1091 #define TUCR_DPS 0x04000000
1092 #define TUCR_TSEL Fld (3, 29)
1093 #define TUCR_32_768kHz \
1094 (0 << FShft (TUCR_TSEL))
1095 #define TUCR_3_6864MHz \
1096 (1 << FShft (TUCR_TSEL))
1098 (2 << FShft (TUCR_TSEL))
1099 #define TUCR_96MHzPLL \
1100 (3 << FShft (TUCR_TSEL))
1101 #define TUCR_Clock \
1103 (4 << FShft (TUCR_TSEL))
1104 #define TUCR_3_6864MHzA \
1106 (5 << FShft (TUCR_TSEL))
1107 #define TUCR_MainPLL \
1108 (6 << FShft (TUCR_TSEL))
1110 (7 << FShft (TUCR_TSEL))
1138 #define GPLR __REG(0x90040000)
1139 #define GPDR __REG(0x90040004)
1140 #define GPSR __REG(0x90040008)
1141 #define GPCR __REG(0x9004000C)
1142 #define GRER __REG(0x90040010)
1143 #define GFER __REG(0x90040014)
1144 #define GEDR __REG(0x90040018)
1145 #define GAFR __REG(0x9004001C)
1147 #define GPIO_MIN (0)
1148 #define GPIO_MAX (27)
1150 #define GPIO_GPIO(Nb) \
1151 (0x00000001 << (Nb))
1152 #define GPIO_GPIO0 GPIO_GPIO (0)
1153 #define GPIO_GPIO1 GPIO_GPIO (1)
1154 #define GPIO_GPIO2 GPIO_GPIO (2)
1155 #define GPIO_GPIO3 GPIO_GPIO (3)
1156 #define GPIO_GPIO4 GPIO_GPIO (4)
1157 #define GPIO_GPIO5 GPIO_GPIO (5)
1158 #define GPIO_GPIO6 GPIO_GPIO (6)
1159 #define GPIO_GPIO7 GPIO_GPIO (7)
1160 #define GPIO_GPIO8 GPIO_GPIO (8)
1161 #define GPIO_GPIO9 GPIO_GPIO (9)
1162 #define GPIO_GPIO10 GPIO_GPIO (10)
1163 #define GPIO_GPIO11 GPIO_GPIO (11)
1164 #define GPIO_GPIO12 GPIO_GPIO (12)
1165 #define GPIO_GPIO13 GPIO_GPIO (13)
1166 #define GPIO_GPIO14 GPIO_GPIO (14)
1167 #define GPIO_GPIO15 GPIO_GPIO (15)
1168 #define GPIO_GPIO16 GPIO_GPIO (16)
1169 #define GPIO_GPIO17 GPIO_GPIO (17)
1170 #define GPIO_GPIO18 GPIO_GPIO (18)
1171 #define GPIO_GPIO19 GPIO_GPIO (19)
1172 #define GPIO_GPIO20 GPIO_GPIO (20)
1173 #define GPIO_GPIO21 GPIO_GPIO (21)
1174 #define GPIO_GPIO22 GPIO_GPIO (22)
1175 #define GPIO_GPIO23 GPIO_GPIO (23)
1176 #define GPIO_GPIO24 GPIO_GPIO (24)
1177 #define GPIO_GPIO25 GPIO_GPIO (25)
1178 #define GPIO_GPIO26 GPIO_GPIO (26)
1179 #define GPIO_GPIO27 GPIO_GPIO (27)
1181 #define GPIO_LDD(Nb) \
1182 GPIO_GPIO ((Nb) - 6)
1183 #define GPIO_LDD8 GPIO_LDD (8)
1184 #define GPIO_LDD9 GPIO_LDD (9)
1185 #define GPIO_LDD10 GPIO_LDD (10)
1186 #define GPIO_LDD11 GPIO_LDD (11)
1187 #define GPIO_LDD12 GPIO_LDD (12)
1188 #define GPIO_LDD13 GPIO_LDD (13)
1189 #define GPIO_LDD14 GPIO_LDD (14)
1190 #define GPIO_LDD15 GPIO_LDD (15)
1192 #define GPIO_SSP_TXD GPIO_GPIO (10)
1193 #define GPIO_SSP_RXD GPIO_GPIO (11)
1194 #define GPIO_SSP_SCLK GPIO_GPIO (12)
1195 #define GPIO_SSP_SFRM GPIO_GPIO (13)
1197 #define GPIO_UART_TXD GPIO_GPIO (14)
1198 #define GPIO_UART_RXD GPIO_GPIO (15)
1199 #define GPIO_SDLC_SCLK GPIO_GPIO (16)
1200 #define GPIO_SDLC_AAF GPIO_GPIO (17)
1201 #define GPIO_UART_SCLK1 GPIO_GPIO (18)
1203 #define GPIO_SSP_CLK GPIO_GPIO (19)
1205 #define GPIO_UART_SCLK3 GPIO_GPIO (20)
1207 #define GPIO_MCP_CLK GPIO_GPIO (21)
1209 #define GPIO_TIC_ACK GPIO_GPIO (21)
1210 #define GPIO_MBGNT GPIO_GPIO (21)
1211 #define GPIO_TREQA GPIO_GPIO (22)
1212 #define GPIO_MBREQ GPIO_GPIO (22)
1213 #define GPIO_TREQB GPIO_GPIO (23)
1214 #define GPIO_1Hz GPIO_GPIO (25)
1215 #define GPIO_RCLK GPIO_GPIO (26)
1216 #define GPIO_32_768kHz GPIO_GPIO (27)
1243 #define ICIP __REG(0x90050000)
1244 #define ICMR __REG(0x90050004)
1245 #define ICLR __REG(0x90050008)
1246 #define ICCR __REG(0x9005000C)
1247 #define ICFP __REG(0x90050010)
1248 #define ICPR __REG(0x90050020)
1250 #define IC_GPIO(Nb) \
1251 (0x00000001 << (Nb))
1252 #define IC_GPIO0 IC_GPIO (0)
1253 #define IC_GPIO1 IC_GPIO (1)
1254 #define IC_GPIO2 IC_GPIO (2)
1255 #define IC_GPIO3 IC_GPIO (3)
1256 #define IC_GPIO4 IC_GPIO (4)
1257 #define IC_GPIO5 IC_GPIO (5)
1258 #define IC_GPIO6 IC_GPIO (6)
1259 #define IC_GPIO7 IC_GPIO (7)
1260 #define IC_GPIO8 IC_GPIO (8)
1261 #define IC_GPIO9 IC_GPIO (9)
1262 #define IC_GPIO10 IC_GPIO (10)
1263 #define IC_GPIO11_27 0x00000800
1264 #define IC_LCD 0x00001000
1265 #define IC_Ser0UDC 0x00002000
1266 #define IC_Ser1SDLC 0x00004000
1267 #define IC_Ser1UART 0x00008000
1268 #define IC_Ser2ICP 0x00010000
1269 #define IC_Ser3UART 0x00020000
1270 #define IC_Ser4MCP 0x00040000
1271 #define IC_Ser4SSP 0x00080000
1272 #define IC_DMA(Nb) \
1273 (0x00100000 << (Nb))
1274 #define IC_DMA0 IC_DMA (0)
1275 #define IC_DMA1 IC_DMA (1)
1276 #define IC_DMA2 IC_DMA (2)
1277 #define IC_DMA3 IC_DMA (3)
1278 #define IC_DMA4 IC_DMA (4)
1279 #define IC_DMA5 IC_DMA (5)
1280 #define IC_OST(Nb) \
1281 (0x04000000 << (Nb))
1282 #define IC_OST0 IC_OST (0)
1283 #define IC_OST1 IC_OST (1)
1284 #define IC_OST2 IC_OST (2)
1285 #define IC_OST3 IC_OST (3)
1286 #define IC_RTC1Hz 0x40000000
1287 #define IC_RTCAlrm 0x80000000
1292 #define ICCR_DIM 0x00000001
1294 #define ICCR_IdleAllInt (ICCR_DIM*0)
1296 #define ICCR_IdleMskInt (ICCR_DIM*1)
1316 #define PPDR __REG(0x90060000)
1317 #define PPSR __REG(0x90060004)
1318 #define PPAR __REG(0x90060008)
1319 #define PSDR __REG(0x9006000C)
1320 #define PPFR __REG(0x90060010)
1322 #define PPC_LDD(Nb) \
1323 (0x00000001 << (Nb))
1324 #define PPC_LDD0 PPC_LDD (0)
1325 #define PPC_LDD1 PPC_LDD (1)
1326 #define PPC_LDD2 PPC_LDD (2)
1327 #define PPC_LDD3 PPC_LDD (3)
1328 #define PPC_LDD4 PPC_LDD (4)
1329 #define PPC_LDD5 PPC_LDD (5)
1330 #define PPC_LDD6 PPC_LDD (6)
1331 #define PPC_LDD7 PPC_LDD (7)
1332 #define PPC_L_PCLK 0x00000100
1333 #define PPC_L_LCLK 0x00000200
1334 #define PPC_L_FCLK 0x00000400
1335 #define PPC_L_BIAS 0x00000800
1337 #define PPC_TXD1 0x00001000
1338 #define PPC_RXD1 0x00002000
1340 #define PPC_TXD2 0x00004000
1341 #define PPC_RXD2 0x00008000
1343 #define PPC_TXD3 0x00010000
1344 #define PPC_RXD3 0x00020000
1346 #define PPC_TXD4 0x00040000
1347 #define PPC_RXD4 0x00080000
1348 #define PPC_SCLK 0x00100000
1349 #define PPC_SFRM 0x00200000
1355 #define PPAR_UPR 0x00001000
1356 #define PPAR_UARTTR (PPAR_UPR*0)
1357 #define PPAR_UARTGPIO (PPAR_UPR*1)
1359 #define PPAR_SPR 0x00040000
1360 #define PPAR_SSPTRSS (PPAR_SPR*0)
1362 #define PPAR_SSPGPIO (PPAR_SPR*1)
1367 #define PPFR_LCD 0x00000001
1368 #define PPFR_SP1TX 0x00001000
1369 #define PPFR_SP1RX 0x00002000
1370 #define PPFR_SP2TX 0x00004000
1371 #define PPFR_SP2RX 0x00008000
1372 #define PPFR_SP3TX 0x00010000
1373 #define PPFR_SP3RX 0x00020000
1374 #define PPFR_SP4 0x00040000
1375 #define PPFR_PerEn 0
1376 #define PPFR_PPCEn 1
1401 #define MDCNFG __REG(0xA0000000)
1402 #define MDCAS0 __REG(0xA0000004)
1403 #define MDCAS1 __REG(0xA0000008)
1404 #define MDCAS2 __REG(0xA000000c)
1407 #define MDCNFG_DE(Nb) \
1408 (0x00000001 << (Nb))
1409 #define MDCNFG_DE0 MDCNFG_DE (0)
1410 #define MDCNFG_DE1 MDCNFG_DE (1)
1411 #define MDCNFG_DE2 MDCNFG_DE (2)
1412 #define MDCNFG_DE3 MDCNFG_DE (3)
1413 #define MDCNFG_DRAC Fld (2, 4)
1414 #define MDCNFG_RowAdd(Add) \
1415 (((Add) - 9) << FShft (MDCNFG_DRAC))
1416 #define MDCNFG_CDB2 0x00000040
1418 #define MDCNFG_TRP Fld (4, 7)
1419 #define MDCNFG_PrChrg(Tcpu) \
1420 (((Tcpu) - 2)/2 << FShft (MDCNFG_TRP))
1421 #define MDCNFG_CeilPrChrg(Tcpu) \
1422 (((Tcpu) - 1)/2 << FShft (MDCNFG_TRP))
1423 #define MDCNFG_TRASR Fld (4, 11)
1424 #define MDCNFG_Ref(Tcpu) \
1425 (((Tcpu) - 2)/2 << FShft (MDCNFG_TRASR))
1426 #define MDCNFG_CeilRef(Tcpu) \
1427 (((Tcpu) - 1)/2 << FShft (MDCNFG_TRASR))
1428 #define MDCNFG_TDL Fld (2, 15)
1429 #define MDCNFG_DataLtch(Tcpu) \
1430 ((Tcpu) << FShft (MDCNFG_TDL))
1431 #define MDCNFG_DRI Fld (15, 17)
1433 #define MDCNFG_RefInt(Tcpu) \
1435 ((Tcpu)/8 << FShft (MDCNFG_DRI))
1438 #define MDCNFG_SA1110_DE0 0x00000001
1439 #define MDCNFG_SA1110_DE1 0x00000002
1440 #define MDCNFG_SA1110_DTIM0 0x00000004
1441 #define MDCNFG_SA1110_DWID0 0x00000008
1442 #define MDCNFG_SA1110_DRAC0 Fld(3, 4)
1444 #define MDCNFG_SA1110_CDB20 0x00000080
1445 #define MDCNFG_SA1110_TRP0 Fld(3, 8)
1446 #define MDCNFG_SA1110_TDL0 Fld(2, 12)
1448 #define MDCNFG_SA1110_TWR0 Fld(2, 14)
1449 #define MDCNFG_SA1110_DE2 0x00010000
1450 #define MDCNFG_SA1110_DE3 0x00020000
1451 #define MDCNFG_SA1110_DTIM2 0x00040000
1452 #define MDCNFG_SA1110_DWID2 0x00080000
1453 #define MDCNFG_SA1110_DRAC2 Fld(3, 20)
1455 #define MDCNFG_SA1110_CDB22 0x00800000
1456 #define MDCNFG_SA1110_TRP2 Fld(3, 24)
1457 #define MDCNFG_SA1110_TDL2 Fld(2, 28)
1459 #define MDCNFG_SA1110_TWR2 Fld(2, 30)
1476 #define MSC0 __REG(0xa0000010)
1477 #define MSC1 __REG(0xa0000014)
1478 #define MSC2 __REG(0xa000002c)
1480 #define MSC_Bnk(Nb) \
1481 Fld (16, ((Nb) Modulo 2)*16)
1482 #define MSC0_Bnk0 MSC_Bnk (0)
1483 #define MSC0_Bnk1 MSC_Bnk (1)
1484 #define MSC1_Bnk2 MSC_Bnk (2)
1485 #define MSC1_Bnk3 MSC_Bnk (3)
1487 #define MSC_RT Fld (2, 0)
1488 #define MSC_NonBrst \
1489 (0 << FShft (MSC_RT))
1491 (1 << FShft (MSC_RT))
1493 (2 << FShft (MSC_RT))
1495 (3 << FShft (MSC_RT))
1496 #define MSC_RBW 0x0004
1497 #define MSC_32BitStMem (MSC_RBW*0)
1498 #define MSC_16BitStMem (MSC_RBW*1)
1499 #define MSC_RDF Fld (5, 3)
1501 #define MSC_1stRdAcc(Tcpu) \
1503 ((((Tcpu) - 3)/2) << FShft (MSC_RDF))
1504 #define MSC_Ceil1stRdAcc(Tcpu) \
1505 ((((Tcpu) - 2)/2) << FShft (MSC_RDF))
1506 #define MSC_RdAcc(Tcpu) \
1508 ((((Tcpu) - 2)/2) << FShft (MSC_RDF))
1509 #define MSC_CeilRdAcc(Tcpu) \
1510 ((((Tcpu) - 1)/2) << FShft (MSC_RDF))
1511 #define MSC_RDN Fld (5, 8)
1513 #define MSC_NxtRdAcc(Tcpu) \
1515 ((((Tcpu) - 2)/2) << FShft (MSC_RDN))
1516 #define MSC_CeilNxtRdAcc(Tcpu) \
1517 ((((Tcpu) - 1)/2) << FShft (MSC_RDN))
1518 #define MSC_WrAcc(Tcpu) \
1520 ((((Tcpu) - 2)/2) << FShft (MSC_RDN))
1521 #define MSC_CeilWrAcc(Tcpu) \
1522 ((((Tcpu) - 1)/2) << FShft (MSC_RDN))
1523 #define MSC_RRR Fld (3, 13)
1525 #define MSC_Rec(Tcpu) \
1526 (((Tcpu)/4) << FShft (MSC_RRR))
1527 #define MSC_CeilRec(Tcpu) \
1528 ((((Tcpu) + 3)/4) << FShft (MSC_RRR))
1546 #define MECR __REG(0xA0000018)
1548 #define MECR_PCMCIA(Nb) \
1550 #define MECR_PCMCIA0 MECR_PCMCIA (0)
1551 #define MECR_PCMCIA1 MECR_PCMCIA (1)
1553 #define MECR_BSIO Fld (5, 0)
1554 #define MECR_IOClk(Tcpu) \
1555 ((((Tcpu) - 2)/2) << FShft (MECR_BSIO))
1556 #define MECR_CeilIOClk(Tcpu) \
1557 ((((Tcpu) - 1)/2) << FShft (MECR_BSIO))
1558 #define MECR_BSA Fld (5, 5)
1560 #define MECR_AttrClk(Tcpu) \
1561 ((((Tcpu) - 2)/2) << FShft (MECR_BSA))
1562 #define MECR_CeilAttrClk(Tcpu) \
1563 ((((Tcpu) - 1)/2) << FShft (MECR_BSA))
1564 #define MECR_BSM Fld (5, 10)
1565 #define MECR_MemClk(Tcpu) \
1566 ((((Tcpu) - 2)/2) << FShft (MECR_BSM))
1567 #define MECR_CeilMemClk(Tcpu) \
1568 ((((Tcpu) - 1)/2) << FShft (MECR_BSM))
1574 #define MDREFR __REG(0xA000001C)
1576 #define MDREFR_TRASR Fld (4, 0)
1577 #define MDREFR_DRI Fld (12, 4)
1578 #define MDREFR_E0PIN (1 << 16)
1579 #define MDREFR_K0RUN (1 << 17)
1580 #define MDREFR_K0DB2 (1 << 18)
1581 #define MDREFR_E1PIN (1 << 20)
1582 #define MDREFR_K1RUN (1 << 21)
1583 #define MDREFR_K1DB2 (1 << 22)
1584 #define MDREFR_K2RUN (1 << 25)
1585 #define MDREFR_K2DB2 (1 << 26)
1586 #define MDREFR_EAPD (1 << 28)
1587 #define MDREFR_KAPD (1 << 29)
1588 #define MDREFR_SLFRSH (1 << 31)
1594 #define DMA_SIZE (6 * 0x20)
1595 #define DMA_PHYS 0xb0000000
1650 #define LCD_PEntrySp 2
1651 #define LCD_4BitPSp \
1654 #define LCD_8BitPSp \
1657 #define LCD_12_16BitPSp \
1661 #define LCD_PGrey Fld (4, 0)
1662 #define LCD_PBlue Fld (4, 0)
1663 #define LCD_PGreen Fld (4, 4)
1664 #define LCD_PRed Fld (4, 8)
1665 #define LCD_PBS Fld (2, 12)
1667 (0 << FShft (LCD_PBS))
1669 (1 << FShft (LCD_PBS))
1670 #define LCD_12_16Bit \
1671 (2 << FShft (LCD_PBS))
1673 #define LCD_Int0_0 0x0
1674 #define LCD_Int11_1 0x1
1675 #define LCD_Int20_0 0x2
1676 #define LCD_Int26_7 0x3
1677 #define LCD_Int33_3 0x4
1678 #define LCD_Int40_0 0x5
1679 #define LCD_Int44_4 0x6
1680 #define LCD_Int50_0 0x7
1681 #define LCD_Int55_6 0x8
1682 #define LCD_Int60_0 0x9
1683 #define LCD_Int66_7 0xA
1684 #define LCD_Int73_3 0xB
1685 #define LCD_Int80_0 0xC
1686 #define LCD_Int88_9 0xD
1687 #define LCD_Int100_0 0xE
1688 #define LCD_Int100_0A 0xF
1691 #define LCCR0_LEN 0x00000001
1692 #define LCCR0_CMS 0x00000002
1693 #define LCCR0_Color (LCCR0_CMS*0)
1694 #define LCCR0_Mono (LCCR0_CMS*1)
1695 #define LCCR0_SDS 0x00000004
1697 #define LCCR0_Sngl (LCCR0_SDS*0)
1698 #define LCCR0_Dual (LCCR0_SDS*1)
1699 #define LCCR0_LDM 0x00000008
1701 #define LCCR0_BAM 0x00000010
1703 #define LCCR0_ERM 0x00000020
1706 #define LCCR0_PAS 0x00000080
1707 #define LCCR0_Pas (LCCR0_PAS*0)
1708 #define LCCR0_Act (LCCR0_PAS*1)
1709 #define LCCR0_BLE 0x00000100
1710 #define LCCR0_LtlEnd (LCCR0_BLE*0)
1711 #define LCCR0_BigEnd (LCCR0_BLE*1)
1712 #define LCCR0_DPD 0x00000200
1714 #define LCCR0_4PixMono (LCCR0_DPD*0)
1716 #define LCCR0_8PixMono (LCCR0_DPD*1)
1718 #define LCCR0_PDD Fld (8, 12)
1720 #define LCCR0_DMADel(Tcpu) \
1722 ((Tcpu)/2 << FShft (LCCR0_PDD))
1724 #define LCSR_LDD 0x00000001
1725 #define LCSR_BAU 0x00000002
1726 #define LCSR_BER 0x00000004
1727 #define LCSR_ABC 0x00000008
1728 #define LCSR_IOL 0x00000010
1730 #define LCSR_IUL 0x00000020
1732 #define LCSR_IOU 0x00000040
1734 #define LCSR_IUU 0x00000080
1736 #define LCSR_OOL 0x00000100
1738 #define LCSR_OUL 0x00000200
1740 #define LCSR_OOU 0x00000400
1742 #define LCSR_OUU 0x00000800
1745 #define LCCR1_PPL Fld (6, 4)
1746 #define LCCR1_DisWdth(Pixel) \
1747 (((Pixel) - 16)/16 << FShft (LCCR1_PPL))
1748 #define LCCR1_HSW Fld (6, 10)
1750 #define LCCR1_HorSnchWdth(Tpix) \
1752 (((Tpix) - 1) << FShft (LCCR1_HSW))
1753 #define LCCR1_ELW Fld (8, 16)
1755 #define LCCR1_EndLnDel(Tpix) \
1757 (((Tpix) - 1) << FShft (LCCR1_ELW))
1758 #define LCCR1_BLW Fld (8, 24)
1760 #define LCCR1_BegLnDel(Tpix) \
1762 (((Tpix) - 1) << FShft (LCCR1_BLW))
1764 #define LCCR2_LPP Fld (10, 0)
1765 #define LCCR2_DisHght(Line) \
1766 (((Line) - 1) << FShft (LCCR2_LPP))
1767 #define LCCR2_VSW Fld (6, 10)
1769 #define LCCR2_VrtSnchWdth(Tln) \
1771 (((Tln) - 1) << FShft (LCCR2_VSW))
1772 #define LCCR2_EFW Fld (8, 16)
1774 #define LCCR2_EndFrmDel(Tln) \
1776 ((Tln) << FShft (LCCR2_EFW))
1777 #define LCCR2_BFW Fld (8, 24)
1779 #define LCCR2_BegFrmDel(Tln) \
1781 ((Tln) << FShft (LCCR2_BFW))
1783 #define LCCR3_PCD Fld (8, 0)
1787 #define LCCR3_PixClkDiv(Div) \
1788 (((Div) - 4)/2 << FShft (LCCR3_PCD))
1791 #define LCCR3_CeilPixClkDiv(Div) \
1792 (((Div) - 3)/2 << FShft (LCCR3_PCD))
1795 #define LCCR3_ACB Fld (8, 8)
1797 #define LCCR3_ACBsDiv(Div) \
1798 (((Div) - 2)/2 << FShft (LCCR3_ACB))
1801 #define LCCR3_CeilACBsDiv(Div) \
1802 (((Div) - 1)/2 << FShft (LCCR3_ACB))
1805 #define LCCR3_API Fld (4, 16)
1807 #define LCCR3_ACBsCntOff \
1809 (0 << FShft (LCCR3_API))
1810 #define LCCR3_ACBsCnt(Trans) \
1812 ((Trans) << FShft (LCCR3_API))
1813 #define LCCR3_VSP 0x00100000
1815 #define LCCR3_VrtSnchH (LCCR3_VSP*0)
1817 #define LCCR3_VrtSnchL (LCCR3_VSP*1)
1819 #define LCCR3_HSP 0x00200000
1821 #define LCCR3_HorSnchH (LCCR3_HSP*0)
1823 #define LCCR3_HorSnchL (LCCR3_HSP*1)
1825 #define LCCR3_PCP 0x00400000
1826 #define LCCR3_PixRsEdg (LCCR3_PCP*0)
1827 #define LCCR3_PixFlEdg (LCCR3_PCP*1)
1828 #define LCCR3_OEP 0x00800000
1830 #define LCCR3_OutEnH (LCCR3_OEP*0)
1831 #define LCCR3_OutEnL (LCCR3_OEP*1)