Philippe De Muyter | ea49f8ff | 2010-09-20 13:11:11 +0200 | [diff] [blame] | 1 | /* |
Greg Ungerer | 5b2e655 | 2010-11-02 12:05:29 +1000 | [diff] [blame] | 2 | * m54xxsim.h -- ColdFire 547x/548x System Integration Unit support. |
Philippe De Muyter | ea49f8ff | 2010-09-20 13:11:11 +0200 | [diff] [blame] | 3 | */ |
| 4 | |
Greg Ungerer | 5b2e655 | 2010-11-02 12:05:29 +1000 | [diff] [blame] | 5 | #ifndef m54xxsim_h |
| 6 | #define m54xxsim_h |
Philippe De Muyter | ea49f8ff | 2010-09-20 13:11:11 +0200 | [diff] [blame] | 7 | |
Greg Ungerer | 733f31b | 2010-11-02 17:40:37 +1000 | [diff] [blame] | 8 | #define CPU_NAME "COLDFIRE(m54xx)" |
| 9 | #define CPU_INSTR_PER_JIFFY 2 |
Greg Ungerer | 7fc82b6 | 2010-11-02 17:13:27 +1000 | [diff] [blame] | 10 | |
Greg Ungerer | 3d46140 | 2010-11-09 10:40:44 +1000 | [diff] [blame] | 11 | #include <asm/m54xxacr.h> |
| 12 | |
Greg Ungerer | 733f31b | 2010-11-02 17:40:37 +1000 | [diff] [blame] | 13 | #define MCFINT_VECBASE 64 |
Philippe De Muyter | ea49f8ff | 2010-09-20 13:11:11 +0200 | [diff] [blame] | 14 | |
| 15 | /* |
| 16 | * Interrupt Controller Registers |
| 17 | */ |
Greg Ungerer | 254eef7 | 2011-03-05 22:17:17 +1000 | [diff] [blame^] | 18 | #define MCFICM_INTC0 (MCF_MBAR + 0x700) /* Base for Interrupt Ctrl 0 */ |
| 19 | |
Philippe De Muyter | ea49f8ff | 2010-09-20 13:11:11 +0200 | [diff] [blame] | 20 | #define MCFINTC_IPRH 0x00 /* Interrupt pending 32-63 */ |
| 21 | #define MCFINTC_IPRL 0x04 /* Interrupt pending 1-31 */ |
| 22 | #define MCFINTC_IMRH 0x08 /* Interrupt mask 32-63 */ |
| 23 | #define MCFINTC_IMRL 0x0c /* Interrupt mask 1-31 */ |
| 24 | #define MCFINTC_INTFRCH 0x10 /* Interrupt force 32-63 */ |
| 25 | #define MCFINTC_INTFRCL 0x14 /* Interrupt force 1-31 */ |
| 26 | #define MCFINTC_IRLR 0x18 /* */ |
| 27 | #define MCFINTC_IACKL 0x19 /* */ |
| 28 | #define MCFINTC_ICR0 0x40 /* Base ICR register */ |
| 29 | |
| 30 | /* |
Greg Ungerer | 5701542 | 2010-11-03 12:50:30 +1000 | [diff] [blame] | 31 | * UART module. |
| 32 | */ |
| 33 | #define MCFUART_BASE1 0x8600 /* Base address of UART1 */ |
| 34 | #define MCFUART_BASE2 0x8700 /* Base address of UART2 */ |
| 35 | #define MCFUART_BASE3 0x8800 /* Base address of UART3 */ |
| 36 | #define MCFUART_BASE4 0x8900 /* Base address of UART4 */ |
| 37 | |
| 38 | /* |
Philippe De Muyter | ea49f8ff | 2010-09-20 13:11:11 +0200 | [diff] [blame] | 39 | * Define system peripheral IRQ usage. |
| 40 | */ |
| 41 | #define MCF_IRQ_TIMER (64 + 54) /* Slice Timer 0 */ |
| 42 | #define MCF_IRQ_PROFILER (64 + 53) /* Slice Timer 1 */ |
| 43 | |
| 44 | /* |
| 45 | * Generic GPIO support |
| 46 | */ |
| 47 | #define MCFGPIO_PIN_MAX 0 /* I am too lazy to count */ |
| 48 | #define MCFGPIO_IRQ_MAX -1 |
| 49 | #define MCFGPIO_IRQ_VECBASE -1 |
| 50 | |
| 51 | /* |
| 52 | * Some PSC related definitions |
| 53 | */ |
| 54 | #define MCF_PAR_PSC(x) (0x000A4F-((x)&0x3)) |
| 55 | #define MCF_PAR_SDA (0x0008) |
| 56 | #define MCF_PAR_SCL (0x0004) |
| 57 | #define MCF_PAR_PSC_TXD (0x04) |
| 58 | #define MCF_PAR_PSC_RXD (0x08) |
| 59 | #define MCF_PAR_PSC_RTS(x) (((x)&0x03)<<4) |
| 60 | #define MCF_PAR_PSC_CTS(x) (((x)&0x03)<<6) |
| 61 | #define MCF_PAR_PSC_CTS_GPIO (0x00) |
| 62 | #define MCF_PAR_PSC_CTS_BCLK (0x80) |
| 63 | #define MCF_PAR_PSC_CTS_CTS (0xC0) |
| 64 | #define MCF_PAR_PSC_RTS_GPIO (0x00) |
| 65 | #define MCF_PAR_PSC_RTS_FSYNC (0x20) |
| 66 | #define MCF_PAR_PSC_RTS_RTS (0x30) |
| 67 | #define MCF_PAR_PSC_CANRX (0x40) |
| 68 | |
Greg Ungerer | 5b2e655 | 2010-11-02 12:05:29 +1000 | [diff] [blame] | 69 | #endif /* m54xxsim_h */ |