diff options
author | Lennert Buytenhek <buytenh@wantstofly.org> | 2006-09-18 18:10:26 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2006-09-25 05:25:36 -0400 |
commit | 3f7e5815f4b774270e6506962de37af85aa9c830 (patch) | |
tree | 7e4a2b0d6f8b9f1a21ba7a4eb8baf1a1ec04d4f9 /include/asm-arm/arch-iop33x | |
parent | 98954df6917cb8f7e65f4f0f79ed641112fcf6b6 (diff) |
[ARM] 3817/1: iop3xx: split the iop3xx mach into iop32x and iop33x
Split the iop3xx mach type into iop32x and iop33x -- split the config
symbols, and move the code in the mach-iop3xx directory to the mach-iop32x
and mach-iop33x directories.
Signed-off-by: Lennert Buytenhek <buytenh@wantstofly.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'include/asm-arm/arch-iop33x')
-rw-r--r-- | include/asm-arm/arch-iop33x/debug-macro.S | 24 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/dma.h | 9 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/entry-macro.S | 34 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/hardware.h | 54 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/io.h | 21 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/iop331.h | 358 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/iq80331.h | 23 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/iq80332.h | 23 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/irqs.h | 130 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/memory.h | 26 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/system.h | 29 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/timex.h | 8 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/uncompress.h | 36 | ||||
-rw-r--r-- | include/asm-arm/arch-iop33x/vmalloc.h | 16 |
14 files changed, 791 insertions, 0 deletions
diff --git a/include/asm-arm/arch-iop33x/debug-macro.S b/include/asm-arm/arch-iop33x/debug-macro.S new file mode 100644 index 000000000000..b647edff475d --- /dev/null +++ b/include/asm-arm/arch-iop33x/debug-macro.S | |||
@@ -0,0 +1,24 @@ | |||
1 | /* linux/include/asm-arm/arch-iop33x/debug-macro.S | ||
2 | * | ||
3 | * Debugging macro include header | ||
4 | * | ||
5 | * Copyright (C) 1994-1999 Russell King | ||
6 | * Moved from linux/arch/arm/kernel/debug.S by Ben Dooks | ||
7 | * | ||
8 | * This program is free software; you can redistribute it and/or modify | ||
9 | * it under the terms of the GNU General Public License version 2 as | ||
10 | * published by the Free Software Foundation. | ||
11 | * | ||
12 | */ | ||
13 | |||
14 | .macro addruart,rx | ||
15 | mrc p15, 0, \rx, c1, c0 | ||
16 | tst \rx, #1 @ mmu enabled? | ||
17 | moveq \rx, #0xff000000 @ physical | ||
18 | movne \rx, #0xfe000000 @ virtual | ||
19 | orr \rx, \rx, #0x00ff0000 | ||
20 | orr \rx, \rx, #0x0000f700 | ||
21 | .endm | ||
22 | |||
23 | #define UART_SHIFT 2 | ||
24 | #include <asm/hardware/debug-8250.S> | ||
diff --git a/include/asm-arm/arch-iop33x/dma.h b/include/asm-arm/arch-iop33x/dma.h new file mode 100644 index 000000000000..d577ca59f4b0 --- /dev/null +++ b/include/asm-arm/arch-iop33x/dma.h | |||
@@ -0,0 +1,9 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-iop33x/dma.h | ||
3 | * | ||
4 | * Copyright (C) 2004 Intel Corp. | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 as | ||
8 | * published by the Free Software Foundation. | ||
9 | */ | ||
diff --git a/include/asm-arm/arch-iop33x/entry-macro.S b/include/asm-arm/arch-iop33x/entry-macro.S new file mode 100644 index 000000000000..980ec9b1ac83 --- /dev/null +++ b/include/asm-arm/arch-iop33x/entry-macro.S | |||
@@ -0,0 +1,34 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-iop33x/entry-macro.S | ||
3 | * | ||
4 | * Low-level IRQ helper macros for IOP33x-based platforms | ||
5 | * | ||
6 | * This file is licensed under the terms of the GNU General Public | ||
7 | * License version 2. This program is licensed "as is" without any | ||
8 | * warranty of any kind, whether express or implied. | ||
9 | */ | ||
10 | #include <asm/arch/irqs.h> | ||
11 | |||
12 | .macro disable_fiq | ||
13 | .endm | ||
14 | |||
15 | /* | ||
16 | * Note: only deal with normal interrupts, not FIQ | ||
17 | */ | ||
18 | .macro get_irqnr_and_base, irqnr, irqstat, base, tmp | ||
19 | mov \irqnr, #0 | ||
20 | mrc p6, 0, \irqstat, c4, c0, 0 @ Read IINTSRC0 | ||
21 | cmp \irqstat, #0 | ||
22 | bne 1002f | ||
23 | mrc p6, 0, \irqstat, c5, c0, 0 @ Read IINTSRC1 | ||
24 | cmp \irqstat, #0 | ||
25 | beq 1001f | ||
26 | clz \irqnr, \irqstat | ||
27 | rsbs \irqnr,\irqnr,#31 @ recommend by RMK | ||
28 | add \irqnr,\irqnr,#IRQ_IOP331_XINT8 | ||
29 | b 1001f | ||
30 | 1002: clz \irqnr, \irqstat | ||
31 | rsbs \irqnr,\irqnr,#31 @ recommend by RMK | ||
32 | add \irqnr,\irqnr,#IRQ_IOP331_DMA0_EOT | ||
33 | 1001: | ||
34 | .endm | ||
diff --git a/include/asm-arm/arch-iop33x/hardware.h b/include/asm-arm/arch-iop33x/hardware.h new file mode 100644 index 000000000000..4a457084c5c6 --- /dev/null +++ b/include/asm-arm/arch-iop33x/hardware.h | |||
@@ -0,0 +1,54 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-iop33x/hardware.h | ||
3 | */ | ||
4 | #ifndef __ASM_ARCH_HARDWARE_H | ||
5 | #define __ASM_ARCH_HARDWARE_H | ||
6 | |||
7 | #include <asm/types.h> | ||
8 | |||
9 | /* | ||
10 | * Note about PCI IO space mappings | ||
11 | * | ||
12 | * To make IO space accesses efficient, we store virtual addresses in | ||
13 | * the IO resources. | ||
14 | * | ||
15 | * The PCI IO space is located at virtual 0xfe000000 from physical | ||
16 | * 0x90000000. The PCI BARs must be programmed with physical addresses, | ||
17 | * but when we read them, we convert them to virtual addresses. See | ||
18 | * arch/arm/mach-iop33x/pci.c | ||
19 | */ | ||
20 | |||
21 | #define pcibios_assign_all_busses() 1 | ||
22 | |||
23 | |||
24 | /* | ||
25 | * The min PCI I/O and MEM space are dependent on what specific | ||
26 | * chipset/platform we are running on, so instead of hardcoding with | ||
27 | * #ifdefs, we just fill these in the platform level PCI init code. | ||
28 | */ | ||
29 | #ifndef __ASSEMBLY__ | ||
30 | extern unsigned long iop3xx_pcibios_min_io; | ||
31 | extern unsigned long iop3xx_pcibios_min_mem; | ||
32 | |||
33 | extern unsigned int processor_id; | ||
34 | #endif | ||
35 | |||
36 | /* | ||
37 | * We just set these to zero since they are really bogus anyways | ||
38 | */ | ||
39 | #define PCIBIOS_MIN_IO (iop3xx_pcibios_min_io) | ||
40 | #define PCIBIOS_MIN_MEM (iop3xx_pcibios_min_mem) | ||
41 | |||
42 | /* | ||
43 | * Generic chipset bits | ||
44 | * | ||
45 | */ | ||
46 | #include "iop331.h" | ||
47 | |||
48 | /* | ||
49 | * Board specific bits | ||
50 | */ | ||
51 | #include "iq80331.h" | ||
52 | #include "iq80332.h" | ||
53 | |||
54 | #endif /* _ASM_ARCH_HARDWARE_H */ | ||
diff --git a/include/asm-arm/arch-iop33x/io.h b/include/asm-arm/arch-iop33x/io.h new file mode 100644 index 000000000000..a9949d5d4953 --- /dev/null +++ b/include/asm-arm/arch-iop33x/io.h | |||
@@ -0,0 +1,21 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-iop33x/io.h | ||
3 | * | ||
4 | * Copyright (C) 2001 MontaVista Software, Inc. | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 as | ||
8 | * published by the Free Software Foundation. | ||
9 | */ | ||
10 | |||
11 | #ifndef __ASM_ARM_ARCH_IO_H | ||
12 | #define __ASM_ARM_ARCH_IO_H | ||
13 | |||
14 | #include <asm/hardware.h> | ||
15 | |||
16 | #define IO_SPACE_LIMIT 0xffffffff | ||
17 | |||
18 | #define __io(p) ((void __iomem *)(p)) | ||
19 | #define __mem_pci(a) (a) | ||
20 | |||
21 | #endif | ||
diff --git a/include/asm-arm/arch-iop33x/iop331.h b/include/asm-arm/arch-iop33x/iop331.h new file mode 100644 index 000000000000..780b707edb1e --- /dev/null +++ b/include/asm-arm/arch-iop33x/iop331.h | |||
@@ -0,0 +1,358 @@ | |||
1 | /* | ||
2 | * linux/include/asm/arch-iop33x/iop331.h | ||
3 | * | ||
4 | * Intel IOP331 Chip definitions | ||
5 | * | ||
6 | * Author: Dave Jiang (dave.jiang@intel.com) | ||
7 | * Copyright (C) 2003, 2004 Intel Corp. | ||
8 | * | ||
9 | * This program is free software; you can redistribute it and/or modify | ||
10 | * it under the terms of the GNU General Public License version 2 as | ||
11 | * published by the Free Software Foundation. | ||
12 | */ | ||
13 | |||
14 | #ifndef _IOP331_HW_H_ | ||
15 | #define _IOP331_HW_H_ | ||
16 | |||
17 | |||
18 | /* | ||
19 | * This is needed for mixed drivers that need to work on all | ||
20 | * IOP3xx variants but behave slightly differently on each. | ||
21 | */ | ||
22 | #ifndef __ASSEMBLY__ | ||
23 | #define iop_is_331() 1 | ||
24 | #endif | ||
25 | |||
26 | /* | ||
27 | * IOP331 I/O and Mem space regions for PCI autoconfiguration | ||
28 | */ | ||
29 | #define IOP331_PCI_IO_WINDOW_SIZE 0x00010000 | ||
30 | #define IOP331_PCI_LOWER_IO_PA 0x90000000 | ||
31 | #define IOP331_PCI_LOWER_IO_VA 0xfe000000 | ||
32 | #define IOP331_PCI_LOWER_IO_BA (*IOP331_OIOWTVR) | ||
33 | #define IOP331_PCI_UPPER_IO_PA (IOP331_PCI_LOWER_IO_PA + IOP331_PCI_IO_WINDOW_SIZE - 1) | ||
34 | #define IOP331_PCI_UPPER_IO_VA (IOP331_PCI_LOWER_IO_VA + IOP331_PCI_IO_WINDOW_SIZE - 1) | ||
35 | #define IOP331_PCI_UPPER_IO_BA (IOP331_PCI_LOWER_IO_BA + IOP331_PCI_IO_WINDOW_SIZE - 1) | ||
36 | #define IOP331_PCI_IO_OFFSET (IOP331_PCI_LOWER_IO_VA - IOP331_PCI_LOWER_IO_BA) | ||
37 | |||
38 | /* this can be 128M if OMWTVR1 is set */ | ||
39 | #define IOP331_PCI_MEM_WINDOW_SIZE 0x04000000 /* 64M outbound window */ | ||
40 | /* #define IOP331_PCI_MEM_WINDOW_SIZE (~*IOP331_IALR1 + 1) */ | ||
41 | #define IOP331_PCI_LOWER_MEM_PA 0x80000000 | ||
42 | #define IOP331_PCI_LOWER_MEM_BA (*IOP331_OMWTVR0) | ||
43 | #define IOP331_PCI_UPPER_MEM_PA (IOP331_PCI_LOWER_MEM_PA + IOP331_PCI_MEM_WINDOW_SIZE - 1) | ||
44 | #define IOP331_PCI_UPPER_MEM_BA (IOP331_PCI_LOWER_MEM_BA + IOP331_PCI_MEM_WINDOW_SIZE - 1) | ||
45 | #define IOP331_PCI_MEM_OFFSET (IOP331_PCI_LOWER_MEM_PA - IOP331_PCI_LOWER_MEM_BA) | ||
46 | |||
47 | /* | ||
48 | * IOP331 chipset registers | ||
49 | */ | ||
50 | #define IOP331_VIRT_MEM_BASE 0xfeffe000 /* chip virtual mem address*/ | ||
51 | #define IOP331_PHYS_MEM_BASE 0xffffe000 /* chip physical memory address */ | ||
52 | #define IOP331_REG_ADDR(reg) (IOP331_VIRT_MEM_BASE | (reg)) | ||
53 | |||
54 | /* Reserved 0x00000000 through 0x000000FF */ | ||
55 | |||
56 | /* Address Translation Unit 0x00000100 through 0x000001FF */ | ||
57 | #define IOP331_ATUVID (volatile u16 *)IOP331_REG_ADDR(0x00000100) | ||
58 | #define IOP331_ATUDID (volatile u16 *)IOP331_REG_ADDR(0x00000102) | ||
59 | #define IOP331_ATUCMD (volatile u16 *)IOP331_REG_ADDR(0x00000104) | ||
60 | #define IOP331_ATUSR (volatile u16 *)IOP331_REG_ADDR(0x00000106) | ||
61 | #define IOP331_ATURID (volatile u8 *)IOP331_REG_ADDR(0x00000108) | ||
62 | #define IOP331_ATUCCR (volatile u32 *)IOP331_REG_ADDR(0x00000109) | ||
63 | #define IOP331_ATUCLSR (volatile u8 *)IOP331_REG_ADDR(0x0000010C) | ||
64 | #define IOP331_ATULT (volatile u8 *)IOP331_REG_ADDR(0x0000010D) | ||
65 | #define IOP331_ATUHTR (volatile u8 *)IOP331_REG_ADDR(0x0000010E) | ||
66 | #define IOP331_ATUBIST (volatile u8 *)IOP331_REG_ADDR(0x0000010F) | ||
67 | #define IOP331_IABAR0 (volatile u32 *)IOP331_REG_ADDR(0x00000110) | ||
68 | #define IOP331_IAUBAR0 (volatile u32 *)IOP331_REG_ADDR(0x00000114) | ||
69 | #define IOP331_IABAR1 (volatile u32 *)IOP331_REG_ADDR(0x00000118) | ||
70 | #define IOP331_IAUBAR1 (volatile u32 *)IOP331_REG_ADDR(0x0000011C) | ||
71 | #define IOP331_IABAR2 (volatile u32 *)IOP331_REG_ADDR(0x00000120) | ||
72 | #define IOP331_IAUBAR2 (volatile u32 *)IOP331_REG_ADDR(0x00000124) | ||
73 | #define IOP331_ASVIR (volatile u16 *)IOP331_REG_ADDR(0x0000012C) | ||
74 | #define IOP331_ASIR (volatile u16 *)IOP331_REG_ADDR(0x0000012E) | ||
75 | #define IOP331_ERBAR (volatile u32 *)IOP331_REG_ADDR(0x00000130) | ||
76 | #define IOP331_ATU_CAPPTR (volatile u32 *)IOP331_REG_ADDR(0x00000134) | ||
77 | /* Reserved 0x00000138 through 0x0000013B */ | ||
78 | #define IOP331_ATUILR (volatile u8 *)IOP331_REG_ADDR(0x0000013C) | ||
79 | #define IOP331_ATUIPR (volatile u8 *)IOP331_REG_ADDR(0x0000013D) | ||
80 | #define IOP331_ATUMGNT (volatile u8 *)IOP331_REG_ADDR(0x0000013E) | ||
81 | #define IOP331_ATUMLAT (volatile u8 *)IOP331_REG_ADDR(0x0000013F) | ||
82 | #define IOP331_IALR0 (volatile u32 *)IOP331_REG_ADDR(0x00000140) | ||
83 | #define IOP331_IATVR0 (volatile u32 *)IOP331_REG_ADDR(0x00000144) | ||
84 | #define IOP331_ERLR (volatile u32 *)IOP331_REG_ADDR(0x00000148) | ||
85 | #define IOP331_ERTVR (volatile u32 *)IOP331_REG_ADDR(0x0000014C) | ||
86 | #define IOP331_IALR1 (volatile u32 *)IOP331_REG_ADDR(0x00000150) | ||
87 | #define IOP331_IALR2 (volatile u32 *)IOP331_REG_ADDR(0x00000154) | ||
88 | #define IOP331_IATVR2 (volatile u32 *)IOP331_REG_ADDR(0x00000158) | ||
89 | #define IOP331_OIOWTVR (volatile u32 *)IOP331_REG_ADDR(0x0000015C) | ||
90 | #define IOP331_OMWTVR0 (volatile u32 *)IOP331_REG_ADDR(0x00000160) | ||
91 | #define IOP331_OUMWTVR0 (volatile u32 *)IOP331_REG_ADDR(0x00000164) | ||
92 | #define IOP331_OMWTVR1 (volatile u32 *)IOP331_REG_ADDR(0x00000168) | ||
93 | #define IOP331_OUMWTVR1 (volatile u32 *)IOP331_REG_ADDR(0x0000016C) | ||
94 | /* Reserved 0x00000170 through 0x00000177*/ | ||
95 | #define IOP331_OUDWTVR (volatile u32 *)IOP331_REG_ADDR(0x00000178) | ||
96 | /* Reserved 0x0000017C through 0x0000017F*/ | ||
97 | #define IOP331_ATUCR (volatile u32 *)IOP331_REG_ADDR(0x00000180) | ||
98 | #define IOP331_PCSR (volatile u32 *)IOP331_REG_ADDR(0x00000184) | ||
99 | #define IOP331_ATUISR (volatile u32 *)IOP331_REG_ADDR(0x00000188) | ||
100 | #define IOP331_ATUIMR (volatile u32 *)IOP331_REG_ADDR(0x0000018C) | ||
101 | #define IOP331_IABAR3 (volatile u32 *)IOP331_REG_ADDR(0x00000190) | ||
102 | #define IOP331_IAUBAR3 (volatile u32 *)IOP331_REG_ADDR(0x00000194) | ||
103 | #define IOP331_IALR3 (volatile u32 *)IOP331_REG_ADDR(0x00000198) | ||
104 | #define IOP331_IATVR3 (volatile u32 *)IOP331_REG_ADDR(0x0000019C) | ||
105 | /* Reserved 0x000001A0 through 0x000001A3*/ | ||
106 | #define IOP331_OCCAR (volatile u32 *)IOP331_REG_ADDR(0x000001A4) | ||
107 | /* Reserved 0x000001A8 through 0x000001AB*/ | ||
108 | #define IOP331_OCCDR (volatile u32 *)IOP331_REG_ADDR(0x000001AC) | ||
109 | /* Reserved 0x000001B0 through 0x000001BB*/ | ||
110 | #define IOP331_VPDCAPID (volatile u8 *)IOP331_REG_ADDR(0x000001B8) | ||
111 | #define IOP331_VPDNXTP (volatile u8 *)IOP331_REG_ADDR(0x000001B9) | ||
112 | #define IOP331_VPDAR (volatile u16 *)IOP331_REG_ADDR(0x000001BA) | ||
113 | #define IOP331_VPDDR (volatile u32 *)IOP331_REG_ADDR(0x000001BC) | ||
114 | #define IOP331_PMCAPID (volatile u8 *)IOP331_REG_ADDR(0x000001C0) | ||
115 | #define IOP331_PMNEXT (volatile u8 *)IOP331_REG_ADDR(0x000001C1) | ||
116 | #define IOP331_APMCR (volatile u16 *)IOP331_REG_ADDR(0x000001C2) | ||
117 | #define IOP331_APMCSR (volatile u16 *)IOP331_REG_ADDR(0x000001C4) | ||
118 | /* Reserved 0x000001C6 through 0x000001CF */ | ||
119 | #define IOP331_MSICAPID (volatile u8 *)IOP331_REG_ADDR(0x000001D0) | ||
120 | #define IOP331_MSINXTP (volatile u8 *)IOP331_REG_ADDR(0x000001D1) | ||
121 | #define IOP331_MSIMCR (volatile u16 *)IOP331_REG_ADDR(0x000001D2) | ||
122 | #define IOP331_MSIMAR (volatile u32 *)IOP331_REG_ADDR(0x000001D4) | ||
123 | #define IOP331_MSIMUAR (volatile u32 *)IOP331_REG_ADDR(0x000001D8) | ||
124 | #define IOP331_MSIMDR (volatile u32 *)IOP331_REG_ADDR(0x000001DC) | ||
125 | #define IOP331_PCIXCAPID (volatile u8 *)IOP331_REG_ADDR(0x000001E0) | ||
126 | #define IOP331_PCIXNEXT (volatile u8 *)IOP331_REG_ADDR(0x000001E1) | ||
127 | #define IOP331_PCIXCMD (volatile u16 *)IOP331_REG_ADDR(0x000001E2) | ||
128 | #define IOP331_PCIXSR (volatile u32 *)IOP331_REG_ADDR(0x000001E4) | ||
129 | #define IOP331_PCIIRSR (volatile u32 *)IOP331_REG_ADDR(0x000001EC) | ||
130 | |||
131 | /* Messaging Unit 0x00000300 through 0x000003FF */ | ||
132 | |||
133 | /* Reserved 0x00000300 through 0x0000030c */ | ||
134 | #define IOP331_IMR0 (volatile u32 *)IOP331_REG_ADDR(0x00000310) | ||
135 | #define IOP331_IMR1 (volatile u32 *)IOP331_REG_ADDR(0x00000314) | ||
136 | #define IOP331_OMR0 (volatile u32 *)IOP331_REG_ADDR(0x00000318) | ||
137 | #define IOP331_OMR1 (volatile u32 *)IOP331_REG_ADDR(0x0000031C) | ||
138 | #define IOP331_IDR (volatile u32 *)IOP331_REG_ADDR(0x00000320) | ||
139 | #define IOP331_IISR (volatile u32 *)IOP331_REG_ADDR(0x00000324) | ||
140 | #define IOP331_IIMR (volatile u32 *)IOP331_REG_ADDR(0x00000328) | ||
141 | #define IOP331_ODR (volatile u32 *)IOP331_REG_ADDR(0x0000032C) | ||
142 | #define IOP331_OISR (volatile u32 *)IOP331_REG_ADDR(0x00000330) | ||
143 | #define IOP331_OIMR (volatile u32 *)IOP331_REG_ADDR(0x00000334) | ||
144 | /* Reserved 0x00000338 through 0x0000034F */ | ||
145 | #define IOP331_MUCR (volatile u32 *)IOP331_REG_ADDR(0x00000350) | ||
146 | #define IOP331_QBAR (volatile u32 *)IOP331_REG_ADDR(0x00000354) | ||
147 | /* Reserved 0x00000358 through 0x0000035C */ | ||
148 | #define IOP331_IFHPR (volatile u32 *)IOP331_REG_ADDR(0x00000360) | ||
149 | #define IOP331_IFTPR (volatile u32 *)IOP331_REG_ADDR(0x00000364) | ||
150 | #define IOP331_IPHPR (volatile u32 *)IOP331_REG_ADDR(0x00000368) | ||
151 | #define IOP331_IPTPR (volatile u32 *)IOP331_REG_ADDR(0x0000036C) | ||
152 | #define IOP331_OFHPR (volatile u32 *)IOP331_REG_ADDR(0x00000370) | ||
153 | #define IOP331_OFTPR (volatile u32 *)IOP331_REG_ADDR(0x00000374) | ||
154 | #define IOP331_OPHPR (volatile u32 *)IOP331_REG_ADDR(0x00000378) | ||
155 | #define IOP331_OPTPR (volatile u32 *)IOP331_REG_ADDR(0x0000037C) | ||
156 | #define IOP331_IAR (volatile u32 *)IOP331_REG_ADDR(0x00000380) | ||
157 | /* Reserved 0x00000384 through 0x000003FF */ | ||
158 | |||
159 | /* DMA Controller 0x00000400 through 0x000004FF */ | ||
160 | #define IOP331_DMA0_CCR (volatile u32 *)IOP331_REG_ADDR(0x00000400) | ||
161 | #define IOP331_DMA0_CSR (volatile u32 *)IOP331_REG_ADDR(0x00000404) | ||
162 | #define IOP331_DMA0_DAR (volatile u32 *)IOP331_REG_ADDR(0x0000040C) | ||
163 | #define IOP331_DMA0_NDAR (volatile u32 *)IOP331_REG_ADDR(0x00000410) | ||
164 | #define IOP331_DMA0_PADR (volatile u32 *)IOP331_REG_ADDR(0x00000414) | ||
165 | #define IOP331_DMA0_PUADR (volatile u32 *)IOP331_REG_ADDR(0x00000418) | ||
166 | #define IOP331_DMA0_LADR (volatile u32 *)IOP331_REG_ADDR(0X0000041C) | ||
167 | #define IOP331_DMA0_BCR (volatile u32 *)IOP331_REG_ADDR(0x00000420) | ||
168 | #define IOP331_DMA0_DCR (volatile u32 *)IOP331_REG_ADDR(0x00000424) | ||
169 | /* Reserved 0x00000428 through 0x0000043C */ | ||
170 | #define IOP331_DMA1_CCR (volatile u32 *)IOP331_REG_ADDR(0x00000440) | ||
171 | #define IOP331_DMA1_CSR (volatile u32 *)IOP331_REG_ADDR(0x00000444) | ||
172 | #define IOP331_DMA1_DAR (volatile u32 *)IOP331_REG_ADDR(0x0000044C) | ||
173 | #define IOP331_DMA1_NDAR (volatile u32 *)IOP331_REG_ADDR(0x00000450) | ||
174 | #define IOP331_DMA1_PADR (volatile u32 *)IOP331_REG_ADDR(0x00000454) | ||
175 | #define IOP331_DMA1_PUADR (volatile u32 *)IOP331_REG_ADDR(0x00000458) | ||
176 | #define IOP331_DMA1_LADR (volatile u32 *)IOP331_REG_ADDR(0x0000045C) | ||
177 | #define IOP331_DMA1_BCR (volatile u32 *)IOP331_REG_ADDR(0x00000460) | ||
178 | #define IOP331_DMA1_DCR (volatile u32 *)IOP331_REG_ADDR(0x00000464) | ||
179 | /* Reserved 0x00000468 through 0x000004FF */ | ||
180 | |||
181 | /* Memory controller 0x00000500 through 0x0005FF */ | ||
182 | |||
183 | /* Peripheral bus interface unit 0x00000680 through 0x0006FF */ | ||
184 | #define IOP331_PBCR (volatile u32 *)IOP331_REG_ADDR(0x00000680) | ||
185 | #define IOP331_PBISR (volatile u32 *)IOP331_REG_ADDR(0x00000684) | ||
186 | #define IOP331_PBBAR0 (volatile u32 *)IOP331_REG_ADDR(0x00000688) | ||
187 | #define IOP331_PBLR0 (volatile u32 *)IOP331_REG_ADDR(0x0000068C) | ||
188 | #define IOP331_PBBAR1 (volatile u32 *)IOP331_REG_ADDR(0x00000690) | ||
189 | #define IOP331_PBLR1 (volatile u32 *)IOP331_REG_ADDR(0x00000694) | ||
190 | #define IOP331_PBBAR2 (volatile u32 *)IOP331_REG_ADDR(0x00000698) | ||
191 | #define IOP331_PBLR2 (volatile u32 *)IOP331_REG_ADDR(0x0000069C) | ||
192 | #define IOP331_PBBAR3 (volatile u32 *)IOP331_REG_ADDR(0x000006A0) | ||
193 | #define IOP331_PBLR3 (volatile u32 *)IOP331_REG_ADDR(0x000006A4) | ||
194 | #define IOP331_PBBAR4 (volatile u32 *)IOP331_REG_ADDR(0x000006A8) | ||
195 | #define IOP331_PBLR4 (volatile u32 *)IOP331_REG_ADDR(0x000006AC) | ||
196 | #define IOP331_PBBAR5 (volatile u32 *)IOP331_REG_ADDR(0x000006B0) | ||
197 | #define IOP331_PBLR5 (volatile u32 *)IOP331_REG_ADDR(0x000006B4) | ||
198 | #define IOP331_PBDSCR (volatile u32 *)IOP331_REG_ADDR(0x000006B8) | ||
199 | /* Reserved 0x000006BC */ | ||
200 | #define IOP331_PMBR0 (volatile u32 *)IOP331_REG_ADDR(0x000006C0) | ||
201 | /* Reserved 0x000006C4 through 0x000006DC */ | ||
202 | #define IOP331_PMBR1 (volatile u32 *)IOP331_REG_ADDR(0x000006E0) | ||
203 | #define IOP331_PMBR2 (volatile u32 *)IOP331_REG_ADDR(0x000006E4) | ||
204 | |||
205 | #define IOP331_PBCR_EN 0x1 | ||
206 | |||
207 | #define IOP331_PBISR_BOOR_ERR 0x1 | ||
208 | |||
209 | |||
210 | |||
211 | /* Peripheral performance monitoring unit 0x00000700 through 0x00077F */ | ||
212 | /* Internal arbitration unit 0x00000780 through 0x0007BF */ | ||
213 | |||
214 | /* Interrupt Controller */ | ||
215 | #define IOP331_INTCTL0 (volatile u32 *)IOP331_REG_ADDR(0x00000790) | ||
216 | #define IOP331_INTCTL1 (volatile u32 *)IOP331_REG_ADDR(0x00000794) | ||
217 | #define IOP331_INTSTR0 (volatile u32 *)IOP331_REG_ADDR(0x00000798) | ||
218 | #define IOP331_INTSTR1 (volatile u32 *)IOP331_REG_ADDR(0x0000079C) | ||
219 | #define IOP331_IINTSRC0 (volatile u32 *)IOP331_REG_ADDR(0x000007A0) | ||
220 | #define IOP331_IINTSRC1 (volatile u32 *)IOP331_REG_ADDR(0x000007A4) | ||
221 | #define IOP331_FINTSRC0 (volatile u32 *)IOP331_REG_ADDR(0x000007A8) | ||
222 | #define IOP331_FINTSRC1 (volatile u32 *)IOP331_REG_ADDR(0x000007AC) | ||
223 | #define IOP331_IPR0 (volatile u32 *)IOP331_REG_ADDR(0x000007B0) | ||
224 | #define IOP331_IPR1 (volatile u32 *)IOP331_REG_ADDR(0x000007B4) | ||
225 | #define IOP331_IPR2 (volatile u32 *)IOP331_REG_ADDR(0x000007B8) | ||
226 | #define IOP331_IPR3 (volatile u32 *)IOP331_REG_ADDR(0x000007BC) | ||
227 | #define IOP331_INTBASE (volatile u32 *)IOP331_REG_ADDR(0x000007C0) | ||
228 | #define IOP331_INTSIZE (volatile u32 *)IOP331_REG_ADDR(0x000007C4) | ||
229 | #define IOP331_IINTVEC (volatile u32 *)IOP331_REG_ADDR(0x000007C8) | ||
230 | #define IOP331_FINTVEC (volatile u32 *)IOP331_REG_ADDR(0x000007CC) | ||
231 | |||
232 | |||
233 | /* Timers */ | ||
234 | |||
235 | #define IOP331_TU_TMR0 (volatile u32 *)IOP331_REG_ADDR(0x000007D0) | ||
236 | #define IOP331_TU_TMR1 (volatile u32 *)IOP331_REG_ADDR(0x000007D4) | ||
237 | |||
238 | #define IOP331_TMR_TC 0x01 | ||
239 | #define IOP331_TMR_EN 0x02 | ||
240 | #define IOP331_TMR_RELOAD 0x04 | ||
241 | #define IOP331_TMR_PRIVILEGED 0x09 | ||
242 | |||
243 | #define IOP331_TMR_RATIO_1_1 0x00 | ||
244 | #define IOP331_TMR_RATIO_4_1 0x10 | ||
245 | #define IOP331_TMR_RATIO_8_1 0x20 | ||
246 | #define IOP331_TMR_RATIO_16_1 0x30 | ||
247 | |||
248 | #define IOP331_TU_TCR0 (volatile u32 *)IOP331_REG_ADDR(0x000007D8) | ||
249 | #define IOP331_TU_TCR1 (volatile u32 *)IOP331_REG_ADDR(0x000007DC) | ||
250 | #define IOP331_TU_TRR0 (volatile u32 *)IOP331_REG_ADDR(0x000007E0) | ||
251 | #define IOP331_TU_TRR1 (volatile u32 *)IOP331_REG_ADDR(0x000007E4) | ||
252 | #define IOP331_TU_TISR (volatile u32 *)IOP331_REG_ADDR(0x000007E8) | ||
253 | #define IOP331_TU_WDTCR (volatile u32 *)IOP331_REG_ADDR(0x000007EC) | ||
254 | |||
255 | #if defined(CONFIG_ARCH_IOP33X) | ||
256 | #define IOP331_TICK_RATE 266000000 /* 266 MHz IB clock */ | ||
257 | #endif | ||
258 | |||
259 | #if defined(CONFIG_IOP331_STEPD) || defined(CONFIG_ARCH_IQ80333) | ||
260 | #undef IOP331_TICK_RATE | ||
261 | #define IOP331_TICK_RATE 333000000 /* 333 Mhz IB clock */ | ||
262 | #endif | ||
263 | |||
264 | /* Application accelerator unit 0x00000800 - 0x000008FF */ | ||
265 | #define IOP331_AAU_ACR (volatile u32 *)IOP331_REG_ADDR(0x00000800) | ||
266 | #define IOP331_AAU_ASR (volatile u32 *)IOP331_REG_ADDR(0x00000804) | ||
267 | #define IOP331_AAU_ADAR (volatile u32 *)IOP331_REG_ADDR(0x00000808) | ||
268 | #define IOP331_AAU_ANDAR (volatile u32 *)IOP331_REG_ADDR(0x0000080C) | ||
269 | #define IOP331_AAU_SAR1 (volatile u32 *)IOP331_REG_ADDR(0x00000810) | ||
270 | #define IOP331_AAU_SAR2 (volatile u32 *)IOP331_REG_ADDR(0x00000814) | ||
271 | #define IOP331_AAU_SAR3 (volatile u32 *)IOP331_REG_ADDR(0x00000818) | ||
272 | #define IOP331_AAU_SAR4 (volatile u32 *)IOP331_REG_ADDR(0x0000081C) | ||
273 | #define IOP331_AAU_SAR5 (volatile u32 *)IOP331_REG_ADDR(0x0000082C) | ||
274 | #define IOP331_AAU_SAR6 (volatile u32 *)IOP331_REG_ADDR(0x00000830) | ||
275 | #define IOP331_AAU_SAR7 (volatile u32 *)IOP331_REG_ADDR(0x00000834) | ||
276 | #define IOP331_AAU_SAR8 (volatile u32 *)IOP331_REG_ADDR(0x00000838) | ||
277 | #define IOP331_AAU_SAR9 (volatile u32 *)IOP331_REG_ADDR(0x00000840) | ||
278 | #define IOP331_AAU_SAR10 (volatile u32 *)IOP331_REG_ADDR(0x00000844) | ||
279 | #define IOP331_AAU_SAR11 (volatile u32 *)IOP331_REG_ADDR(0x00000848) | ||
280 | #define IOP331_AAU_SAR12 (volatile u32 *)IOP331_REG_ADDR(0x0000084C) | ||
281 | #define IOP331_AAU_SAR13 (volatile u32 *)IOP331_REG_ADDR(0x00000850) | ||
282 | #define IOP331_AAU_SAR14 (volatile u32 *)IOP331_REG_ADDR(0x00000854) | ||
283 | #define IOP331_AAU_SAR15 (volatile u32 *)IOP331_REG_ADDR(0x00000858) | ||
284 | #define IOP331_AAU_SAR16 (volatile u32 *)IOP331_REG_ADDR(0x0000085C) | ||
285 | #define IOP331_AAU_SAR17 (volatile u32 *)IOP331_REG_ADDR(0x00000864) | ||
286 | #define IOP331_AAU_SAR18 (volatile u32 *)IOP331_REG_ADDR(0x00000868) | ||
287 | #define IOP331_AAU_SAR19 (volatile u32 *)IOP331_REG_ADDR(0x0000086C) | ||
288 | #define IOP331_AAU_SAR20 (volatile u32 *)IOP331_REG_ADDR(0x00000870) | ||
289 | #define IOP331_AAU_SAR21 (volatile u32 *)IOP331_REG_ADDR(0x00000874) | ||
290 | #define IOP331_AAU_SAR22 (volatile u32 *)IOP331_REG_ADDR(0x00000878) | ||
291 | #define IOP331_AAU_SAR23 (volatile u32 *)IOP331_REG_ADDR(0x0000087C) | ||
292 | #define IOP331_AAU_SAR24 (volatile u32 *)IOP331_REG_ADDR(0x00000880) | ||
293 | #define IOP331_AAU_SAR25 (volatile u32 *)IOP331_REG_ADDR(0x00000888) | ||
294 | #define IOP331_AAU_SAR26 (volatile u32 *)IOP331_REG_ADDR(0x0000088C) | ||
295 | #define IOP331_AAU_SAR27 (volatile u32 *)IOP331_REG_ADDR(0x00000890) | ||
296 | #define IOP331_AAU_SAR28 (volatile u32 *)IOP331_REG_ADDR(0x00000894) | ||
297 | #define IOP331_AAU_SAR29 (volatile u32 *)IOP331_REG_ADDR(0x00000898) | ||
298 | #define IOP331_AAU_SAR30 (volatile u32 *)IOP331_REG_ADDR(0x0000089C) | ||
299 | #define IOP331_AAU_SAR31 (volatile u32 *)IOP331_REG_ADDR(0x000008A0) | ||
300 | #define IOP331_AAU_SAR32 (volatile u32 *)IOP331_REG_ADDR(0x000008A4) | ||
301 | #define IOP331_AAU_DAR (volatile u32 *)IOP331_REG_ADDR(0x00000820) | ||
302 | #define IOP331_AAU_ABCR (volatile u32 *)IOP331_REG_ADDR(0x00000824) | ||
303 | #define IOP331_AAU_ADCR (volatile u32 *)IOP331_REG_ADDR(0x00000828) | ||
304 | #define IOP331_AAU_EDCR0 (volatile u32 *)IOP331_REG_ADDR(0x0000083c) | ||
305 | #define IOP331_AAU_EDCR1 (volatile u32 *)IOP331_REG_ADDR(0x00000860) | ||
306 | #define IOP331_AAU_EDCR2 (volatile u32 *)IOP331_REG_ADDR(0x00000884) | ||
307 | |||
308 | |||
309 | #define IOP331_SPDSCR (volatile u32 *)IOP331_REG_ADDR(0x000015C0) | ||
310 | #define IOP331_PPDSCR (volatile u32 *)IOP331_REG_ADDR(0x000015C8) | ||
311 | /* SSP serial port unit 0x00001600 - 0x0000167F */ | ||
312 | |||
313 | /* I2C bus interface unit 0x00001680 - 0x000016FF */ | ||
314 | /* for I2C bit defs see drivers/i2c/i2c-iop3xx.h */ | ||
315 | |||
316 | #define IOP331_ICR0 (volatile u32 *)IOP331_REG_ADDR(0x00001680) | ||
317 | #define IOP331_ISR0 (volatile u32 *)IOP331_REG_ADDR(0x00001684) | ||
318 | #define IOP331_ISAR0 (volatile u32 *)IOP331_REG_ADDR(0x00001688) | ||
319 | #define IOP331_IDBR0 (volatile u32 *)IOP331_REG_ADDR(0x0000168C) | ||
320 | /* Reserved 0x00001690 */ | ||
321 | #define IOP331_IBMR0 (volatile u32 *)IOP331_REG_ADDR(0x00001694) | ||
322 | /* Reserved 0x00001698 */ | ||
323 | /* Reserved 0x0000169C */ | ||
324 | #define IOP331_ICR1 (volatile u32 *)IOP331_REG_ADDR(0x000016A0) | ||
325 | #define IOP331_ISR1 (volatile u32 *)IOP331_REG_ADDR(0x000016A4) | ||
326 | #define IOP331_ISAR1 (volatile u32 *)IOP331_REG_ADDR(0x000016A8) | ||
327 | #define IOP331_IDBR1 (volatile u32 *)IOP331_REG_ADDR(0x000016AC) | ||
328 | #define IOP331_IBMR1 (volatile u32 *)IOP331_REG_ADDR(0x000016B4) | ||
329 | /* Reserved 0x000016B8 through 0x000016FF */ | ||
330 | |||
331 | /* 0x00001700 through 0x0000172C UART 0 */ | ||
332 | |||
333 | /* Reserved 0x00001730 through 0x0000173F */ | ||
334 | |||
335 | /* 0x00001740 through 0x0000176C UART 1 */ | ||
336 | |||
337 | #define IOP331_UART0_PHYS (IOP331_PHYS_MEM_BASE | 0x00001700) /* UART #1 physical */ | ||
338 | #define IOP331_UART1_PHYS (IOP331_PHYS_MEM_BASE | 0x00001740) /* UART #2 physical */ | ||
339 | #define IOP331_UART0_VIRT (IOP331_VIRT_MEM_BASE | 0x00001700) /* UART #1 virtual addr */ | ||
340 | #define IOP331_UART1_VIRT (IOP331_VIRT_MEM_BASE | 0x00001740) /* UART #2 virtual addr */ | ||
341 | |||
342 | /* Reserved 0x00001770 through 0x0000177F */ | ||
343 | |||
344 | /* General Purpose I/O Registers */ | ||
345 | #define IOP331_GPOE (volatile u32 *)IOP331_REG_ADDR(0x00001780) | ||
346 | #define IOP331_GPID (volatile u32 *)IOP331_REG_ADDR(0x00001784) | ||
347 | #define IOP331_GPOD (volatile u32 *)IOP331_REG_ADDR(0x00001788) | ||
348 | |||
349 | /* Reserved 0x0000178c through 0x000019ff */ | ||
350 | |||
351 | |||
352 | #ifndef __ASSEMBLY__ | ||
353 | extern void iop331_map_io(void); | ||
354 | extern void iop331_init_irq(void); | ||
355 | extern void iop331_time_init(void); | ||
356 | #endif | ||
357 | |||
358 | #endif // _IOP331_HW_H_ | ||
diff --git a/include/asm-arm/arch-iop33x/iq80331.h b/include/asm-arm/arch-iop33x/iq80331.h new file mode 100644 index 000000000000..bda7ab6d55cf --- /dev/null +++ b/include/asm-arm/arch-iop33x/iq80331.h | |||
@@ -0,0 +1,23 @@ | |||
1 | /* | ||
2 | * linux/include/asm/arch-iop33x/iq80331.h | ||
3 | * | ||
4 | * Intel IQ80331 evaluation board registers | ||
5 | */ | ||
6 | |||
7 | #ifndef _IQ80331_H_ | ||
8 | #define _IQ80331_H_ | ||
9 | |||
10 | #define IQ80331_FLASHBASE 0xc0000000 /* Flash */ | ||
11 | #define IQ80331_FLASHSIZE 0x00800000 | ||
12 | #define IQ80331_FLASHWIDTH 1 | ||
13 | |||
14 | #define IQ80331_7SEG_1 0xce840000 /* 7-Segment MSB */ | ||
15 | #define IQ80331_7SEG_0 0xce850000 /* 7-Segment LSB (WO) */ | ||
16 | #define IQ80331_ROTARY_SW 0xce8d0000 /* Rotary Switch */ | ||
17 | #define IQ80331_BATT_STAT 0xce8f0000 /* Battery Status */ | ||
18 | |||
19 | #ifndef __ASSEMBLY__ | ||
20 | extern void iq80331_map_io(void); | ||
21 | #endif | ||
22 | |||
23 | #endif // _IQ80331_H_ | ||
diff --git a/include/asm-arm/arch-iop33x/iq80332.h b/include/asm-arm/arch-iop33x/iq80332.h new file mode 100644 index 000000000000..f728e04378ab --- /dev/null +++ b/include/asm-arm/arch-iop33x/iq80332.h | |||
@@ -0,0 +1,23 @@ | |||
1 | /* | ||
2 | * linux/include/asm/arch-iop33x/iq80332.h | ||
3 | * | ||
4 | * Intel IQ80332 evaluation board registers | ||
5 | */ | ||
6 | |||
7 | #ifndef _IQ80332_H_ | ||
8 | #define _IQ80332_H_ | ||
9 | |||
10 | #define IQ80332_FLASHBASE 0xc0000000 /* Flash */ | ||
11 | #define IQ80332_FLASHSIZE 0x00800000 | ||
12 | #define IQ80332_FLASHWIDTH 1 | ||
13 | |||
14 | #define IQ80332_7SEG_1 0xce840000 /* 7-Segment MSB */ | ||
15 | #define IQ80332_7SEG_0 0xce850000 /* 7-Segment LSB (WO) */ | ||
16 | #define IQ80332_ROTARY_SW 0xce8d0000 /* Rotary Switch */ | ||
17 | #define IQ80332_BATT_STAT 0xce8f0000 /* Battery Status */ | ||
18 | |||
19 | #ifndef __ASSEMBLY__ | ||
20 | extern void iq80332_map_io(void); | ||
21 | #endif | ||
22 | |||
23 | #endif // _IQ80332_H_ | ||
diff --git a/include/asm-arm/arch-iop33x/irqs.h b/include/asm-arm/arch-iop33x/irqs.h new file mode 100644 index 000000000000..45856a12815a --- /dev/null +++ b/include/asm-arm/arch-iop33x/irqs.h | |||
@@ -0,0 +1,130 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-iop33x/irqs.h | ||
3 | * | ||
4 | * Author: Dave Jiang (dave.jiang@intel.com) | ||
5 | * Copyright: (C) 2003 Intel Corp. | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify | ||
8 | * it under the terms of the GNU General Public License version 2 as | ||
9 | * published by the Free Software Foundation. | ||
10 | * | ||
11 | */ | ||
12 | #ifndef _IRQS_H_ | ||
13 | #define _IRQS_H_ | ||
14 | |||
15 | /* | ||
16 | * IOP80331 chipset interrupts | ||
17 | */ | ||
18 | #define IOP331_IRQ_OFS 0 | ||
19 | #define IOP331_IRQ(x) (IOP331_IRQ_OFS + (x)) | ||
20 | |||
21 | /* | ||
22 | * On IRQ or FIQ register | ||
23 | */ | ||
24 | #define IRQ_IOP331_DMA0_EOT IOP331_IRQ(0) | ||
25 | #define IRQ_IOP331_DMA0_EOC IOP331_IRQ(1) | ||
26 | #define IRQ_IOP331_DMA1_EOT IOP331_IRQ(2) | ||
27 | #define IRQ_IOP331_DMA1_EOC IOP331_IRQ(3) | ||
28 | #define IRQ_IOP331_RSVD_4 IOP331_IRQ(4) | ||
29 | #define IRQ_IOP331_RSVD_5 IOP331_IRQ(5) | ||
30 | #define IRQ_IOP331_AA_EOT IOP331_IRQ(6) | ||
31 | #define IRQ_IOP331_AA_EOC IOP331_IRQ(7) | ||
32 | #define IRQ_IOP331_TIMER0 IOP331_IRQ(8) | ||
33 | #define IRQ_IOP331_TIMER1 IOP331_IRQ(9) | ||
34 | #define IRQ_IOP331_I2C_0 IOP331_IRQ(10) | ||
35 | #define IRQ_IOP331_I2C_1 IOP331_IRQ(11) | ||
36 | #define IRQ_IOP331_MSG IOP331_IRQ(12) | ||
37 | #define IRQ_IOP331_MSGIBQ IOP331_IRQ(13) | ||
38 | #define IRQ_IOP331_ATU_BIST IOP331_IRQ(14) | ||
39 | #define IRQ_IOP331_PERFMON IOP331_IRQ(15) | ||
40 | #define IRQ_IOP331_CORE_PMU IOP331_IRQ(16) | ||
41 | #define IRQ_IOP331_RSVD_17 IOP331_IRQ(17) | ||
42 | #define IRQ_IOP331_RSVD_18 IOP331_IRQ(18) | ||
43 | #define IRQ_IOP331_RSVD_19 IOP331_IRQ(19) | ||
44 | #define IRQ_IOP331_RSVD_20 IOP331_IRQ(20) | ||
45 | #define IRQ_IOP331_RSVD_21 IOP331_IRQ(21) | ||
46 | #define IRQ_IOP331_RSVD_22 IOP331_IRQ(22) | ||
47 | #define IRQ_IOP331_RSVD_23 IOP331_IRQ(23) | ||
48 | #define IRQ_IOP331_XINT0 IOP331_IRQ(24) | ||
49 | #define IRQ_IOP331_XINT1 IOP331_IRQ(25) | ||
50 | #define IRQ_IOP331_XINT2 IOP331_IRQ(26) | ||
51 | #define IRQ_IOP331_XINT3 IOP331_IRQ(27) | ||
52 | #define IRQ_IOP331_RSVD_28 IOP331_IRQ(28) | ||
53 | #define IRQ_IOP331_RSVD_29 IOP331_IRQ(29) | ||
54 | #define IRQ_IOP331_RSVD_30 IOP331_IRQ(30) | ||
55 | #define IRQ_IOP331_RSVD_31 IOP331_IRQ(31) | ||
56 | #define IRQ_IOP331_XINT8 IOP331_IRQ(32) // 0 | ||
57 | #define IRQ_IOP331_XINT9 IOP331_IRQ(33) // 1 | ||
58 | #define IRQ_IOP331_XINT10 IOP331_IRQ(34) // 2 | ||
59 | #define IRQ_IOP331_XINT11 IOP331_IRQ(35) // 3 | ||
60 | #define IRQ_IOP331_XINT12 IOP331_IRQ(36) // 4 | ||
61 | #define IRQ_IOP331_XINT13 IOP331_IRQ(37) // 5 | ||
62 | #define IRQ_IOP331_XINT14 IOP331_IRQ(38) // 6 | ||
63 | #define IRQ_IOP331_XINT15 IOP331_IRQ(39) // 7 | ||
64 | #define IRQ_IOP331_RSVD_40 IOP331_IRQ(40) // 8 | ||
65 | #define IRQ_IOP331_RSVD_41 IOP331_IRQ(41) // 9 | ||
66 | #define IRQ_IOP331_RSVD_42 IOP331_IRQ(42) // 10 | ||
67 | #define IRQ_IOP331_RSVD_43 IOP331_IRQ(43) // 11 | ||
68 | #define IRQ_IOP331_RSVD_44 IOP331_IRQ(44) // 12 | ||
69 | #define IRQ_IOP331_RSVD_45 IOP331_IRQ(45) // 13 | ||
70 | #define IRQ_IOP331_RSVD_46 IOP331_IRQ(46) // 14 | ||
71 | #define IRQ_IOP331_RSVD_47 IOP331_IRQ(47) // 15 | ||
72 | #define IRQ_IOP331_RSVD_48 IOP331_IRQ(48) // 16 | ||
73 | #define IRQ_IOP331_RSVD_49 IOP331_IRQ(49) // 17 | ||
74 | #define IRQ_IOP331_RSVD_50 IOP331_IRQ(50) // 18 | ||
75 | #define IRQ_IOP331_UART0 IOP331_IRQ(51) // 19 | ||
76 | #define IRQ_IOP331_UART1 IOP331_IRQ(52) // 20 | ||
77 | #define IRQ_IOP331_PBIE IOP331_IRQ(53) // 21 | ||
78 | #define IRQ_IOP331_ATU_CRW IOP331_IRQ(54) // 22 | ||
79 | #define IRQ_IOP331_ATU_ERR IOP331_IRQ(55) // 23 | ||
80 | #define IRQ_IOP331_MCU_ERR IOP331_IRQ(56) // 24 | ||
81 | #define IRQ_IOP331_DMA0_ERR IOP331_IRQ(57) // 25 | ||
82 | #define IRQ_IOP331_DMA1_ERR IOP331_IRQ(58) // 26 | ||
83 | #define IRQ_IOP331_RSVD_59 IOP331_IRQ(59) // 27 | ||
84 | #define IRQ_IOP331_AA_ERR IOP331_IRQ(60) // 28 | ||
85 | #define IRQ_IOP331_RSVD_61 IOP331_IRQ(61) // 29 | ||
86 | #define IRQ_IOP331_MSG_ERR IOP331_IRQ(62) // 30 | ||
87 | #define IRQ_IOP331_HPI IOP331_IRQ(63) // 31 | ||
88 | |||
89 | #define NR_IRQS (IOP331_IRQ(63) + 1) | ||
90 | |||
91 | |||
92 | /* | ||
93 | * Interrupts available on the IQ80331 board | ||
94 | */ | ||
95 | |||
96 | /* | ||
97 | * On board devices | ||
98 | */ | ||
99 | #define IRQ_IQ80331_I82544 IRQ_IOP331_XINT0 | ||
100 | #define IRQ_IQ80331_UART0 IRQ_IOP331_UART0 | ||
101 | #define IRQ_IQ80331_UART1 IRQ_IOP331_UART1 | ||
102 | |||
103 | /* | ||
104 | * PCI interrupts | ||
105 | */ | ||
106 | #define IRQ_IQ80331_INTA IRQ_IOP331_XINT0 | ||
107 | #define IRQ_IQ80331_INTB IRQ_IOP331_XINT1 | ||
108 | #define IRQ_IQ80331_INTC IRQ_IOP331_XINT2 | ||
109 | #define IRQ_IQ80331_INTD IRQ_IOP331_XINT3 | ||
110 | |||
111 | /* | ||
112 | * Interrupts available on the IQ80332 board | ||
113 | */ | ||
114 | |||
115 | /* | ||
116 | * On board devices | ||
117 | */ | ||
118 | #define IRQ_IQ80332_I82544 IRQ_IOP331_XINT0 | ||
119 | #define IRQ_IQ80332_UART0 IRQ_IOP331_UART0 | ||
120 | #define IRQ_IQ80332_UART1 IRQ_IOP331_UART1 | ||
121 | |||
122 | /* | ||
123 | * PCI interrupts | ||
124 | */ | ||
125 | #define IRQ_IQ80332_INTA IRQ_IOP331_XINT0 | ||
126 | #define IRQ_IQ80332_INTB IRQ_IOP331_XINT1 | ||
127 | #define IRQ_IQ80332_INTC IRQ_IOP331_XINT2 | ||
128 | #define IRQ_IQ80332_INTD IRQ_IOP331_XINT3 | ||
129 | |||
130 | #endif // _IRQ_H_ | ||
diff --git a/include/asm-arm/arch-iop33x/memory.h b/include/asm-arm/arch-iop33x/memory.h new file mode 100644 index 000000000000..5e47164934ce --- /dev/null +++ b/include/asm-arm/arch-iop33x/memory.h | |||
@@ -0,0 +1,26 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-iop33x/memory.h | ||
3 | */ | ||
4 | |||
5 | #ifndef __ASM_ARCH_MEMORY_H | ||
6 | #define __ASM_ARCH_MEMORY_H | ||
7 | |||
8 | #include <asm/hardware.h> | ||
9 | |||
10 | /* | ||
11 | * Physical DRAM offset. | ||
12 | */ | ||
13 | #define PHYS_OFFSET UL(0x00000000) | ||
14 | |||
15 | /* | ||
16 | * Virtual view <-> PCI DMA view memory address translations | ||
17 | * virt_to_bus: Used to translate the virtual address to an | ||
18 | * address suitable to be passed to set_dma_addr | ||
19 | * bus_to_virt: Used to convert an address for DMA operations | ||
20 | * to an address that the kernel can use. | ||
21 | */ | ||
22 | #define __virt_to_bus(x) (((__virt_to_phys(x)) & ~(*IOP331_IATVR2)) | ((*IOP331_IABAR2) & 0xfffffff0)) | ||
23 | #define __bus_to_virt(x) (__phys_to_virt(((x) & ~(*IOP331_IALR2)) | ( *IOP331_IATVR2))) | ||
24 | |||
25 | |||
26 | #endif | ||
diff --git a/include/asm-arm/arch-iop33x/system.h b/include/asm-arm/arch-iop33x/system.h new file mode 100644 index 000000000000..43cc787ea629 --- /dev/null +++ b/include/asm-arm/arch-iop33x/system.h | |||
@@ -0,0 +1,29 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-iop33x/system.h | ||
3 | * | ||
4 | * Copyright (C) 2001 MontaVista Software, Inc. | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 as | ||
8 | * published by the Free Software Foundation. | ||
9 | */ | ||
10 | |||
11 | static inline void arch_idle(void) | ||
12 | { | ||
13 | cpu_do_idle(); | ||
14 | } | ||
15 | |||
16 | |||
17 | static inline void arch_reset(char mode) | ||
18 | { | ||
19 | *IOP331_PCSR = 0x30; | ||
20 | |||
21 | if ( 1 && mode == 's') { | ||
22 | /* Jump into ROM at address 0 */ | ||
23 | cpu_reset(0); | ||
24 | } else { | ||
25 | /* No on-chip reset capability */ | ||
26 | cpu_reset(0); | ||
27 | } | ||
28 | } | ||
29 | |||
diff --git a/include/asm-arm/arch-iop33x/timex.h b/include/asm-arm/arch-iop33x/timex.h new file mode 100644 index 000000000000..cc8085fa2a1e --- /dev/null +++ b/include/asm-arm/arch-iop33x/timex.h | |||
@@ -0,0 +1,8 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-iop33x/timex.h | ||
3 | * | ||
4 | * IOP3xx architecture timex specifications | ||
5 | */ | ||
6 | #include <asm/hardware.h> | ||
7 | |||
8 | #define CLOCK_TICK_RATE IOP331_TICK_RATE | ||
diff --git a/include/asm-arm/arch-iop33x/uncompress.h b/include/asm-arm/arch-iop33x/uncompress.h new file mode 100644 index 000000000000..62904ae3b038 --- /dev/null +++ b/include/asm-arm/arch-iop33x/uncompress.h | |||
@@ -0,0 +1,36 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-iop33x/uncompress.h | ||
3 | */ | ||
4 | #include <asm/types.h> | ||
5 | #include <asm/mach-types.h> | ||
6 | #include <linux/serial_reg.h> | ||
7 | #include <asm/hardware.h> | ||
8 | |||
9 | static volatile u32 *uart_base; | ||
10 | |||
11 | #define TX_DONE (UART_LSR_TEMT|UART_LSR_THRE) | ||
12 | |||
13 | static inline void putc(char c) | ||
14 | { | ||
15 | while ((uart_base[UART_LSR] & TX_DONE) != TX_DONE) | ||
16 | barrier(); | ||
17 | *uart_base = c; | ||
18 | } | ||
19 | |||
20 | static inline void flush(void) | ||
21 | { | ||
22 | } | ||
23 | |||
24 | static __inline__ void __arch_decomp_setup(unsigned long arch_id) | ||
25 | { | ||
26 | if (machine_is_iq80331() || machine_is_iq80332()) | ||
27 | uart_base = (volatile u32 *)IOP331_UART0_PHYS; | ||
28 | else | ||
29 | uart_base = (volatile u32 *)0xfe800000; | ||
30 | } | ||
31 | |||
32 | /* | ||
33 | * nothing to do | ||
34 | */ | ||
35 | #define arch_decomp_setup() __arch_decomp_setup(arch_id) | ||
36 | #define arch_decomp_wdog() | ||
diff --git a/include/asm-arm/arch-iop33x/vmalloc.h b/include/asm-arm/arch-iop33x/vmalloc.h new file mode 100644 index 000000000000..b5092027449e --- /dev/null +++ b/include/asm-arm/arch-iop33x/vmalloc.h | |||
@@ -0,0 +1,16 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-iop33x/vmalloc.h | ||
3 | */ | ||
4 | |||
5 | /* | ||
6 | * Just any arbitrary offset to the start of the vmalloc VM area: the | ||
7 | * current 8MB value just means that there will be a 8MB "hole" after the | ||
8 | * physical memory until the kernel virtual memory starts. That means that | ||
9 | * any out-of-bounds memory accesses will hopefully be caught. | ||
10 | * The vmalloc() routines leaves a hole of 4kB between each vmalloced | ||
11 | * area for the same reason. ;) | ||
12 | */ | ||
13 | //#define VMALLOC_END (0xe8000000) | ||
14 | /* increase usable physical RAM to ~992M per RMK */ | ||
15 | #define VMALLOC_END (0xfe000000) | ||
16 | |||