angelo@sysam.it | bb4ba2c | 2015-02-12 01:40:00 +0100 | [diff] [blame] | 1 | /* |
| 2 | * (C) Copyright 2014 Angelo Dureghello <angelo@sysam.it> |
| 3 | * |
| 4 | * SPDX-License-Identifier: GPL-2.0+ |
| 5 | * |
| 6 | */ |
| 7 | |
| 8 | #ifndef __IMMAP_5307__ |
| 9 | #define __IMMAP_5307__ |
| 10 | |
| 11 | #define MMAP_SIM (CONFIG_SYS_MBAR + 0x00000000) |
| 12 | #define MMAP_INTC (CONFIG_SYS_MBAR + 0x00000040) |
| 13 | #define MMAP_CSM (CONFIG_SYS_MBAR + 0x00000080) |
| 14 | #define MMAP_DRAMC (CONFIG_SYS_MBAR + 0x00000100) |
| 15 | #define MMAP_DTMR0 (CONFIG_SYS_MBAR + 0x00000140) |
| 16 | #define MMAP_DTMR1 (CONFIG_SYS_MBAR + 0x00000180) |
| 17 | #define MMAP_UART0 (CONFIG_SYS_MBAR + 0x000001C0) |
| 18 | #define MMAP_UART1 (CONFIG_SYS_MBAR + 0x00000200) |
| 19 | #define MMAP_GPIO (CONFIG_SYS_MBAR + 0x00000244) |
| 20 | |
| 21 | typedef struct sim { |
| 22 | u8 rsr; |
| 23 | u8 sypcr; |
| 24 | u8 swivr; |
| 25 | u8 swsr; |
| 26 | u16 par; |
| 27 | u8 irqpar; |
| 28 | u8 res1; |
| 29 | u8 pllcr; |
| 30 | u8 res2; |
| 31 | u16 res3; |
| 32 | u8 mpark; |
| 33 | u8 res4; |
| 34 | u16 res5; |
| 35 | u32 res6; |
| 36 | } sim_t; |
| 37 | |
| 38 | typedef struct intctrl { |
| 39 | u32 ipr; |
| 40 | u32 imr; |
| 41 | u16 res7; |
| 42 | u8 res8; |
| 43 | u8 avr; |
| 44 | u8 icr0; |
| 45 | u8 icr1; |
| 46 | u8 icr2; |
| 47 | u8 icr3; |
| 48 | u8 icr4; |
| 49 | u8 icr5; |
| 50 | u8 icr6; |
| 51 | u8 icr7; |
| 52 | u8 icr8; |
| 53 | u8 icr9; |
| 54 | u16 res9; |
| 55 | } intctrl_t; |
| 56 | |
| 57 | typedef struct csm { |
| 58 | u16 csar0; /* Chip-select Address */ |
| 59 | u16 res1; |
| 60 | u32 csmr0; /* Chip-select Mask */ |
| 61 | u16 res2; |
| 62 | u16 cscr0; /* Chip-select Control */ |
| 63 | u16 csar1; |
| 64 | u16 res3; |
| 65 | u32 csmr1; |
| 66 | u16 res4; |
| 67 | u16 cscr1; |
| 68 | u16 csar2; |
| 69 | u16 res5; |
| 70 | u32 csmr2; |
| 71 | u16 res6; |
| 72 | u16 cscr2; |
| 73 | u16 csar3; |
| 74 | u16 res7; |
| 75 | u32 csmr3; |
| 76 | u16 res8; |
| 77 | u16 cscr3; |
| 78 | u16 csar4; |
| 79 | u16 res9; |
| 80 | u32 csmr4; |
| 81 | u16 res10; |
| 82 | u16 cscr4; |
| 83 | u16 csar5; |
| 84 | u16 res11; |
| 85 | u32 csmr5; |
| 86 | u16 res12; |
| 87 | u16 cscr5; |
| 88 | u16 csar6; |
| 89 | u16 res13; |
| 90 | u32 csmr6; |
| 91 | u16 res14; |
| 92 | u16 cscr6; |
| 93 | u16 csar7; |
| 94 | u16 res15; |
| 95 | u32 csmr7; |
| 96 | u16 res16; |
| 97 | u16 cscr7; |
| 98 | } csm_t; |
| 99 | |
| 100 | typedef struct sdramctrl { |
| 101 | u16 dcr; |
| 102 | u16 res1; |
| 103 | u32 res2; |
| 104 | u32 dacr0; |
| 105 | u32 dmr0; |
| 106 | u32 dacr1; |
| 107 | u32 dmr1; |
| 108 | } sdramctrl_t; |
| 109 | |
| 110 | typedef struct gpio { |
| 111 | u16 paddr; |
| 112 | u16 res1; |
| 113 | u16 padat; |
| 114 | u16 res2; |
| 115 | } gpio_t; |
| 116 | |
| 117 | #endif /* __IMMAP_5307__ */ |
| 118 | |