m54xxsim.h 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. /*
  2. * m54xxsim.h -- ColdFire 547x/548x System Integration Unit support.
  3. */
  4. #ifndef m54xxsim_h
  5. #define m54xxsim_h
  6. #define CPU_NAME "COLDFIRE(m54xx)"
  7. #define CPU_INSTR_PER_JIFFY 2
  8. #define MCF_BUSCLK (MCF_CLK / 2)
  9. #include <asm/m54xxacr.h>
  10. #define MCFINT_VECBASE 64
  11. /*
  12. * Interrupt Controller Registers
  13. */
  14. #define MCFICM_INTC0 (MCF_MBAR + 0x700) /* Base for Interrupt Ctrl 0 */
  15. #define MCFINTC_IPRH 0x00 /* Interrupt pending 32-63 */
  16. #define MCFINTC_IPRL 0x04 /* Interrupt pending 1-31 */
  17. #define MCFINTC_IMRH 0x08 /* Interrupt mask 32-63 */
  18. #define MCFINTC_IMRL 0x0c /* Interrupt mask 1-31 */
  19. #define MCFINTC_INTFRCH 0x10 /* Interrupt force 32-63 */
  20. #define MCFINTC_INTFRCL 0x14 /* Interrupt force 1-31 */
  21. #define MCFINTC_IRLR 0x18 /* */
  22. #define MCFINTC_IACKL 0x19 /* */
  23. #define MCFINTC_ICR0 0x40 /* Base ICR register */
  24. /*
  25. * UART module.
  26. */
  27. #define MCFUART_BASE0 (MCF_MBAR + 0x8600) /* Base address UART0 */
  28. #define MCFUART_BASE1 (MCF_MBAR + 0x8700) /* Base address UART1 */
  29. #define MCFUART_BASE2 (MCF_MBAR + 0x8800) /* Base address UART2 */
  30. #define MCFUART_BASE3 (MCF_MBAR + 0x8900) /* Base address UART3 */
  31. /*
  32. * Define system peripheral IRQ usage.
  33. */
  34. #define MCF_IRQ_TIMER (MCFINT_VECBASE + 54) /* Slice Timer 0 */
  35. #define MCF_IRQ_PROFILER (MCFINT_VECBASE + 53) /* Slice Timer 1 */
  36. #define MCF_IRQ_UART0 (MCFINT_VECBASE + 35)
  37. #define MCF_IRQ_UART1 (MCFINT_VECBASE + 34)
  38. #define MCF_IRQ_UART2 (MCFINT_VECBASE + 33)
  39. #define MCF_IRQ_UART3 (MCFINT_VECBASE + 32)
  40. /*
  41. * Slice Timer support.
  42. */
  43. #define MCFSLT_TIMER0 (MCF_MBAR + 0x900) /* Base addr TIMER0 */
  44. #define MCFSLT_TIMER1 (MCF_MBAR + 0x910) /* Base addr TIMER1 */
  45. /*
  46. * Generic GPIO support
  47. */
  48. #define MCFGPIO_PIN_MAX 0 /* I am too lazy to count */
  49. #define MCFGPIO_IRQ_MAX -1
  50. #define MCFGPIO_IRQ_VECBASE -1
  51. /*
  52. * EDGE Port support.
  53. */
  54. #define MCFEPORT_EPPAR (MCF_MBAR + 0xf00) /* Pin assignment */
  55. #define MCFEPORT_EPDDR (MCF_MBAR + 0xf04) /* Data direction */
  56. #define MCFEPORT_EPIER (MCF_MBAR + 0xf05) /* Interrupt enable */
  57. #define MCFEPORT_EPDR (MCF_MBAR + 0xf08) /* Port data (w) */
  58. #define MCFEPORT_EPPDR (MCF_MBAR + 0xf09) /* Port data (r) */
  59. #define MCFEPORT_EPFR (MCF_MBAR + 0xf0c) /* Flags */
  60. /*
  61. * Pin Assignment register definitions
  62. */
  63. #define MCFGPIO_PAR_FBCTL (MCF_MBAR + 0xA40)
  64. #define MCFGPIO_PAR_FBCS (MCF_MBAR + 0xA42)
  65. #define MCFGPIO_PAR_DMA (MCF_MBAR + 0xA43)
  66. #define MCFGPIO_PAR_FECI2CIRQ (MCF_MBAR + 0xA44)
  67. #define MCFGPIO_PAR_PCIBG (MCF_MBAR + 0xA48) /* PCI bus grant */
  68. #define MCFGPIO_PAR_PCIBR (MCF_MBAR + 0xA4A) /* PCI */
  69. #define MCFGPIO_PAR_PSC0 (MCF_MBAR + 0xA4F)
  70. #define MCFGPIO_PAR_PSC1 (MCF_MBAR + 0xA4E)
  71. #define MCFGPIO_PAR_PSC2 (MCF_MBAR + 0xA4D)
  72. #define MCFGPIO_PAR_PSC3 (MCF_MBAR + 0xA4C)
  73. #define MCFGPIO_PAR_DSPI (MCF_MBAR + 0xA50)
  74. #define MCFGPIO_PAR_TIMER (MCF_MBAR + 0xA52)
  75. #define MCF_PAR_SDA (0x0008)
  76. #define MCF_PAR_SCL (0x0004)
  77. #define MCF_PAR_PSC_TXD (0x04)
  78. #define MCF_PAR_PSC_RXD (0x08)
  79. #define MCF_PAR_PSC_CTS_GPIO (0x00)
  80. #define MCF_PAR_PSC_CTS_BCLK (0x80)
  81. #define MCF_PAR_PSC_CTS_CTS (0xC0)
  82. #define MCF_PAR_PSC_RTS_GPIO (0x00)
  83. #define MCF_PAR_PSC_RTS_FSYNC (0x20)
  84. #define MCF_PAR_PSC_RTS_RTS (0x30)
  85. #define MCF_PAR_PSC_CANRX (0x40)
  86. #endif /* m54xxsim_h */