diff options
author | Linus Torvalds <torvalds@g5.osdl.org> | 2006-01-07 13:45:22 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-01-07 13:45:22 -0500 |
commit | 8995b161eb142b843094dd614b80e4cce1d66352 (patch) | |
tree | ffd9988879441d5ec45ab96b2e06f4fcb1210158 /include/asm-arm | |
parent | cc918c7ab7da017bfaf9661420bb5c462e057cfb (diff) | |
parent | fe5dd7c73d328b255286b6b65ca19dd34447f709 (diff) |
Merge master.kernel.org:/home/rmk/linux-2.6-arm
Diffstat (limited to 'include/asm-arm')
64 files changed, 276 insertions, 990 deletions
diff --git a/include/asm-arm/arch-aaec2000/dma.h b/include/asm-arm/arch-aaec2000/dma.h index 28c890b4a1d3..e100b1e526fe 100644 --- a/include/asm-arm/arch-aaec2000/dma.h +++ b/include/asm-arm/arch-aaec2000/dma.h | |||
@@ -7,11 +7,3 @@ | |||
7 | * it under the terms of the GNU General Public License version 2 as | 7 | * it under the terms of the GNU General Public License version 2 as |
8 | * published by the Free Software Foundation. | 8 | * published by the Free Software Foundation. |
9 | */ | 9 | */ |
10 | |||
11 | #ifndef __ASM_ARCH_DMA_H | ||
12 | #define __ASM_ARCH_DMA_H | ||
13 | |||
14 | #define MAX_DMA_ADDRESS 0xffffffff | ||
15 | #define MAX_DMA_CHANNELS 0 | ||
16 | |||
17 | #endif | ||
diff --git a/include/asm-arm/arch-cl7500/dma.h b/include/asm-arm/arch-cl7500/dma.h index 1d6a8829d327..591ed2551892 100644 --- a/include/asm-arm/arch-cl7500/dma.h +++ b/include/asm-arm/arch-cl7500/dma.h | |||
@@ -15,7 +15,6 @@ | |||
15 | * bytes of RAM. | 15 | * bytes of RAM. |
16 | */ | 16 | */ |
17 | #define MAX_DMA_ADDRESS 0xd0000000 | 17 | #define MAX_DMA_ADDRESS 0xd0000000 |
18 | #define MAX_DMA_CHANNELS 0 | ||
19 | 18 | ||
20 | #define DMA_S0 0 | 19 | #define DMA_S0 0 |
21 | 20 | ||
diff --git a/include/asm-arm/arch-cl7500/entry-macro.S b/include/asm-arm/arch-cl7500/entry-macro.S index 686f413f82d6..c9e5395e5106 100644 --- a/include/asm-arm/arch-cl7500/entry-macro.S +++ b/include/asm-arm/arch-cl7500/entry-macro.S | |||
@@ -1,3 +1,3 @@ | |||
1 | 1 | #include <asm/hardware.h> | |
2 | #include <asm/hardware/entry-macro-iomd.S> | 2 | #include <asm/hardware/entry-macro-iomd.S> |
3 | 3 | ||
diff --git a/include/asm-arm/arch-clps711x/dma.h b/include/asm-arm/arch-clps711x/dma.h index 3c4c5c843252..610997938423 100644 --- a/include/asm-arm/arch-clps711x/dma.h +++ b/include/asm-arm/arch-clps711x/dma.h | |||
@@ -17,12 +17,3 @@ | |||
17 | * along with this program; if not, write to the Free Software | 17 | * along with this program; if not, write to the Free Software |
18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
19 | */ | 19 | */ |
20 | #ifndef __ASM_ARCH_DMA_H | ||
21 | #define __ASM_ARCH_DMA_H | ||
22 | |||
23 | #define MAX_DMA_ADDRESS 0xffffffff | ||
24 | |||
25 | #define MAX_DMA_CHANNELS 0 | ||
26 | |||
27 | #endif /* _ASM_ARCH_DMA_H */ | ||
28 | |||
diff --git a/include/asm-arm/arch-clps711x/entry-macro.S b/include/asm-arm/arch-clps711x/entry-macro.S index b31079a1d4a9..21f6ee485819 100644 --- a/include/asm-arm/arch-clps711x/entry-macro.S +++ b/include/asm-arm/arch-clps711x/entry-macro.S | |||
@@ -7,6 +7,7 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | #include <asm/hardware.h> | ||
10 | #include <asm/hardware/clps7111.h> | 11 | #include <asm/hardware/clps7111.h> |
11 | 12 | ||
12 | .macro disable_fiq | 13 | .macro disable_fiq |
diff --git a/include/asm-arm/arch-clps711x/system.h b/include/asm-arm/arch-clps711x/system.h index 2ab981fee37f..11e1491535a8 100644 --- a/include/asm-arm/arch-clps711x/system.h +++ b/include/asm-arm/arch-clps711x/system.h | |||
@@ -20,7 +20,9 @@ | |||
20 | #ifndef __ASM_ARCH_SYSTEM_H | 20 | #ifndef __ASM_ARCH_SYSTEM_H |
21 | #define __ASM_ARCH_SYSTEM_H | 21 | #define __ASM_ARCH_SYSTEM_H |
22 | 22 | ||
23 | #include <asm/hardware.h> | ||
23 | #include <asm/hardware/clps7111.h> | 24 | #include <asm/hardware/clps7111.h> |
25 | #include <asm/io.h> | ||
24 | 26 | ||
25 | static inline void arch_idle(void) | 27 | static inline void arch_idle(void) |
26 | { | 28 | { |
diff --git a/include/asm-arm/arch-ebsa110/dma.h b/include/asm-arm/arch-ebsa110/dma.h index d491776ac1cc..c52f9e2ab0bb 100644 --- a/include/asm-arm/arch-ebsa110/dma.h +++ b/include/asm-arm/arch-ebsa110/dma.h | |||
@@ -9,11 +9,3 @@ | |||
9 | * | 9 | * |
10 | * EBSA110 DMA definitions | 10 | * EBSA110 DMA definitions |
11 | */ | 11 | */ |
12 | #ifndef __ASM_ARCH_DMA_H | ||
13 | #define __ASM_ARCH_DMA_H | ||
14 | |||
15 | #define MAX_DMA_ADDRESS 0xffffffff | ||
16 | #define MAX_DMA_CHANNELS 0 | ||
17 | |||
18 | #endif /* _ASM_ARCH_DMA_H */ | ||
19 | |||
diff --git a/include/asm-arm/arch-ebsa285/dma.h b/include/asm-arm/arch-ebsa285/dma.h index c43046eb8bc7..0259ad45d33c 100644 --- a/include/asm-arm/arch-ebsa285/dma.h +++ b/include/asm-arm/arch-ebsa285/dma.h | |||
@@ -10,11 +10,6 @@ | |||
10 | #define __ASM_ARCH_DMA_H | 10 | #define __ASM_ARCH_DMA_H |
11 | 11 | ||
12 | /* | 12 | /* |
13 | * This is the maximum DMA address that can be DMAd to. | ||
14 | */ | ||
15 | #define MAX_DMA_ADDRESS 0xffffffff | ||
16 | |||
17 | /* | ||
18 | * The 21285 has two internal DMA channels; we call these 8 and 9. | 13 | * The 21285 has two internal DMA channels; we call these 8 and 9. |
19 | * On CATS hardware we have an additional eight ISA dma channels | 14 | * On CATS hardware we have an additional eight ISA dma channels |
20 | * numbered 0..7. | 15 | * numbered 0..7. |
diff --git a/include/asm-arm/arch-ebsa285/entry-macro.S b/include/asm-arm/arch-ebsa285/entry-macro.S index db5729ff6349..cf10ac96fdde 100644 --- a/include/asm-arm/arch-ebsa285/entry-macro.S +++ b/include/asm-arm/arch-ebsa285/entry-macro.S | |||
@@ -7,6 +7,8 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | #include <asm/hardware.h> | ||
11 | #include <asm/arch/irqs.h> | ||
10 | #include <asm/hardware/dec21285.h> | 12 | #include <asm/hardware/dec21285.h> |
11 | 13 | ||
12 | .macro disable_fiq | 14 | .macro disable_fiq |
diff --git a/include/asm-arm/arch-epxa10db/dma.h b/include/asm-arm/arch-epxa10db/dma.h index 5d97734d1077..de20ec8e74b1 100644 --- a/include/asm-arm/arch-epxa10db/dma.h +++ b/include/asm-arm/arch-epxa10db/dma.h | |||
@@ -17,12 +17,3 @@ | |||
17 | * along with this program; if not, write to the Free Software | 17 | * along with this program; if not, write to the Free Software |
18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
19 | */ | 19 | */ |
20 | #ifndef __ASM_ARCH_DMA_H | ||
21 | #define __ASM_ARCH_DMA_H | ||
22 | |||
23 | #define MAX_DMA_ADDRESS 0xffffffff | ||
24 | |||
25 | #define MAX_DMA_CHANNELS 0 | ||
26 | |||
27 | #endif /* _ASM_ARCH_DMA_H */ | ||
28 | |||
diff --git a/include/asm-arm/arch-imx/dma.h b/include/asm-arm/arch-imx/dma.h index dbdc01780413..b45fa367d71e 100644 --- a/include/asm-arm/arch-imx/dma.h +++ b/include/asm-arm/arch-imx/dma.h | |||
@@ -20,10 +20,6 @@ | |||
20 | #ifndef __ASM_ARCH_DMA_H | 20 | #ifndef __ASM_ARCH_DMA_H |
21 | #define __ASM_ARCH_DMA_H | 21 | #define __ASM_ARCH_DMA_H |
22 | 22 | ||
23 | #define MAX_DMA_ADDRESS 0xffffffff | ||
24 | |||
25 | #define MAX_DMA_CHANNELS 0 | ||
26 | |||
27 | /* | 23 | /* |
28 | * DMA registration | 24 | * DMA registration |
29 | */ | 25 | */ |
diff --git a/include/asm-arm/arch-imx/entry-macro.S b/include/asm-arm/arch-imx/entry-macro.S index b40ea7cf88ec..3b9ef6914627 100644 --- a/include/asm-arm/arch-imx/entry-macro.S +++ b/include/asm-arm/arch-imx/entry-macro.S | |||
@@ -7,6 +7,8 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | #include <asm/hardware.h> | ||
11 | |||
10 | .macro disable_fiq | 12 | .macro disable_fiq |
11 | .endm | 13 | .endm |
12 | #define AITC_NIVECSR 0x40 | 14 | #define AITC_NIVECSR 0x40 |
diff --git a/include/asm-arm/arch-integrator/debug-macro.S b/include/asm-arm/arch-integrator/debug-macro.S index 484a1aa47098..031d30941791 100644 --- a/include/asm-arm/arch-integrator/debug-macro.S +++ b/include/asm-arm/arch-integrator/debug-macro.S | |||
@@ -11,7 +11,7 @@ | |||
11 | * | 11 | * |
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <asm/hardware/amba_serial.h> | 14 | #include <linux/amba/serial.h> |
15 | 15 | ||
16 | .macro addruart,rx | 16 | .macro addruart,rx |
17 | mrc p15, 0, \rx, c1, c0 | 17 | mrc p15, 0, \rx, c1, c0 |
diff --git a/include/asm-arm/arch-integrator/dma.h b/include/asm-arm/arch-integrator/dma.h index 7171792290bd..83fd6bbaf9d3 100644 --- a/include/asm-arm/arch-integrator/dma.h +++ b/include/asm-arm/arch-integrator/dma.h | |||
@@ -17,12 +17,3 @@ | |||
17 | * along with this program; if not, write to the Free Software | 17 | * along with this program; if not, write to the Free Software |
18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
19 | */ | 19 | */ |
20 | #ifndef __ASM_ARCH_DMA_H | ||
21 | #define __ASM_ARCH_DMA_H | ||
22 | |||
23 | #define MAX_DMA_ADDRESS 0xffffffff | ||
24 | |||
25 | #define MAX_DMA_CHANNELS 0 | ||
26 | |||
27 | #endif /* _ASM_ARCH_DMA_H */ | ||
28 | |||
diff --git a/include/asm-arm/arch-integrator/entry-macro.S b/include/asm-arm/arch-integrator/entry-macro.S index 44f7ee613194..69838d04f90b 100644 --- a/include/asm-arm/arch-integrator/entry-macro.S +++ b/include/asm-arm/arch-integrator/entry-macro.S | |||
@@ -7,6 +7,8 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | #include <asm/hardware.h> | ||
11 | #include <asm/arch/irqs.h> | ||
10 | 12 | ||
11 | .macro disable_fiq | 13 | .macro disable_fiq |
12 | .endm | 14 | .endm |
diff --git a/include/asm-arm/arch-iop3xx/dma.h b/include/asm-arm/arch-iop3xx/dma.h index 797f9e6fc745..1e808db8af2a 100644 --- a/include/asm-arm/arch-iop3xx/dma.h +++ b/include/asm-arm/arch-iop3xx/dma.h | |||
@@ -7,10 +7,3 @@ | |||
7 | * it under the terms of the GNU General Public License version 2 as | 7 | * it under the terms of the GNU General Public License version 2 as |
8 | * published by the Free Software Foundation. | 8 | * published by the Free Software Foundation. |
9 | */ | 9 | */ |
10 | |||
11 | #ifndef _IOP3XX_DMA_H_P | ||
12 | #define _IOP3XX_DMA_H_P | ||
13 | |||
14 | #define MAX_DMA_ADDRESS 0xffffffff | ||
15 | |||
16 | #endif /* _ASM_ARCH_DMA_H_P */ | ||
diff --git a/include/asm-arm/arch-iop3xx/entry-macro.S b/include/asm-arm/arch-iop3xx/entry-macro.S index e2ce7f5467c8..926668c098a5 100644 --- a/include/asm-arm/arch-iop3xx/entry-macro.S +++ b/include/asm-arm/arch-iop3xx/entry-macro.S | |||
@@ -7,6 +7,7 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | #include <asm/arch/irqs.h> | ||
10 | 11 | ||
11 | #if defined(CONFIG_ARCH_IOP321) | 12 | #if defined(CONFIG_ARCH_IOP321) |
12 | .macro disable_fiq | 13 | .macro disable_fiq |
diff --git a/include/asm-arm/arch-ixp2000/dma.h b/include/asm-arm/arch-ixp2000/dma.h index 0fb3568a98dd..548d8dc507eb 100644 --- a/include/asm-arm/arch-ixp2000/dma.h +++ b/include/asm-arm/arch-ixp2000/dma.h | |||
@@ -7,12 +7,3 @@ | |||
7 | * it under the terms of the GNU General Public License version 2 as | 7 | * it under the terms of the GNU General Public License version 2 as |
8 | * published by the Free Software Foundation. | 8 | * published by the Free Software Foundation. |
9 | */ | 9 | */ |
10 | #ifndef __ASM_ARCH_DMA_H | ||
11 | #define __ASM_ARCH_DMA_H | ||
12 | |||
13 | #define MAX_DMA_ADDRESS 0xffffffff | ||
14 | |||
15 | /* No DMA */ | ||
16 | #define MAX_DMA_CHANNELS 0 | ||
17 | |||
18 | #endif /* _ASM_ARCH_DMA_H */ | ||
diff --git a/include/asm-arm/arch-ixp2000/enp2611.h b/include/asm-arm/arch-ixp2000/enp2611.h index 95128d9f5026..42f3c28dc5c4 100644 --- a/include/asm-arm/arch-ixp2000/enp2611.h +++ b/include/asm-arm/arch-ixp2000/enp2611.h | |||
@@ -36,5 +36,11 @@ | |||
36 | #define ENP2611_GPIO_SCL 7 | 36 | #define ENP2611_GPIO_SCL 7 |
37 | #define ENP2611_GPIO_SDA 6 | 37 | #define ENP2611_GPIO_SDA 6 |
38 | 38 | ||
39 | #define IRQ_ENP2611_THERMAL IRQ_IXP2000_GPIO4 | ||
40 | #define IRQ_ENP2611_OPTION_BOARD IRQ_IXP2000_GPIO3 | ||
41 | #define IRQ_ENP2611_CALEB IRQ_IXP2000_GPIO2 | ||
42 | #define IRQ_ENP2611_PM3386_1 IRQ_IXP2000_GPIO1 | ||
43 | #define IRQ_ENP2611_PM3386_0 IRQ_IXP2000_GPIO0 | ||
44 | |||
39 | 45 | ||
40 | #endif | 46 | #endif |
diff --git a/include/asm-arm/arch-ixp2000/entry-macro.S b/include/asm-arm/arch-ixp2000/entry-macro.S index e3a4e4121298..16e1e6124b31 100644 --- a/include/asm-arm/arch-ixp2000/entry-macro.S +++ b/include/asm-arm/arch-ixp2000/entry-macro.S | |||
@@ -7,6 +7,7 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | #include <asm/arch/irqs.h> | ||
10 | 11 | ||
11 | .macro disable_fiq | 12 | .macro disable_fiq |
12 | .endm | 13 | .endm |
diff --git a/include/asm-arm/arch-ixp2000/io.h b/include/asm-arm/arch-ixp2000/io.h index 7fbcdf9931ee..c0ff2c6c66e7 100644 --- a/include/asm-arm/arch-ixp2000/io.h +++ b/include/asm-arm/arch-ixp2000/io.h | |||
@@ -131,102 +131,4 @@ | |||
131 | #endif | 131 | #endif |
132 | 132 | ||
133 | 133 | ||
134 | #ifdef CONFIG_ARCH_IXDP2X01 | ||
135 | /* | ||
136 | * This is an ugly hack but the CS8900 on the 2x01's does not sit in any sort | ||
137 | * of "I/O space" and is just direct mapped into a 32-bit-only addressable | ||
138 | * bus. The address space for this bus is such that we can't really easily | ||
139 | * make it contiguous to the PCI I/O address range, and it also does not | ||
140 | * need swapping like PCI addresses do (IXDP2x01 is a BE platform). | ||
141 | * B/C of this we can't use the standard in/out functions and need to | ||
142 | * runtime check if the incoming address is a PCI address or for | ||
143 | * the CS89x0. | ||
144 | */ | ||
145 | #undef inw | ||
146 | #undef outw | ||
147 | #undef insw | ||
148 | #undef outsw | ||
149 | |||
150 | #include <asm/mach-types.h> | ||
151 | |||
152 | static inline void insw(u32 ptr, void *buf, int length) | ||
153 | { | ||
154 | register volatile u32 *port = (volatile u32 *)ptr; | ||
155 | |||
156 | /* | ||
157 | * Is this cycle meant for the CS8900? | ||
158 | */ | ||
159 | if ((machine_is_ixdp2401() || machine_is_ixdp2801()) && | ||
160 | (((u32)port >= (u32)IXDP2X01_CS8900_VIRT_BASE) && | ||
161 | ((u32)port <= (u32)IXDP2X01_CS8900_VIRT_END))) { | ||
162 | u8 *buf8 = (u8*)buf; | ||
163 | register u32 tmp32; | ||
164 | |||
165 | do { | ||
166 | tmp32 = *port; | ||
167 | *buf8++ = (u8)tmp32; | ||
168 | *buf8++ = (u8)(tmp32 >> 8); | ||
169 | } while(--length); | ||
170 | |||
171 | return; | ||
172 | } | ||
173 | |||
174 | __raw_readsw(alignw(___io(ptr)),buf,length); | ||
175 | } | ||
176 | |||
177 | static inline void outsw(u32 ptr, void *buf, int length) | ||
178 | { | ||
179 | register volatile u32 *port = (volatile u32 *)ptr; | ||
180 | |||
181 | /* | ||
182 | * Is this cycle meant for the CS8900? | ||
183 | */ | ||
184 | if ((machine_is_ixdp2401() || machine_is_ixdp2801()) && | ||
185 | (((u32)port >= (u32)IXDP2X01_CS8900_VIRT_BASE) && | ||
186 | ((u32)port <= (u32)IXDP2X01_CS8900_VIRT_END))) { | ||
187 | register u32 tmp32; | ||
188 | u8 *buf8 = (u8*)buf; | ||
189 | do { | ||
190 | tmp32 = *buf8++; | ||
191 | tmp32 |= (*buf8++) << 8; | ||
192 | *port = tmp32; | ||
193 | } while(--length); | ||
194 | return; | ||
195 | } | ||
196 | |||
197 | __raw_writesw(alignw(___io(ptr)),buf,length); | ||
198 | } | ||
199 | |||
200 | |||
201 | static inline u16 inw(u32 ptr) | ||
202 | { | ||
203 | register volatile u32 *port = (volatile u32 *)ptr; | ||
204 | |||
205 | /* | ||
206 | * Is this cycle meant for the CS8900? | ||
207 | */ | ||
208 | if ((machine_is_ixdp2401() || machine_is_ixdp2801()) && | ||
209 | (((u32)port >= (u32)IXDP2X01_CS8900_VIRT_BASE) && | ||
210 | ((u32)port <= (u32)IXDP2X01_CS8900_VIRT_END))) { | ||
211 | return (u16)(*port); | ||
212 | } | ||
213 | |||
214 | return __raw_readw(alignw(___io(ptr))); | ||
215 | } | ||
216 | |||
217 | static inline void outw(u16 value, u32 ptr) | ||
218 | { | ||
219 | register volatile u32 *port = (volatile u32 *)ptr; | ||
220 | |||
221 | if ((machine_is_ixdp2401() || machine_is_ixdp2801()) && | ||
222 | (((u32)port >= (u32)IXDP2X01_CS8900_VIRT_BASE) && | ||
223 | ((u32)port <= (u32)IXDP2X01_CS8900_VIRT_END))) { | ||
224 | *port = value; | ||
225 | return; | ||
226 | } | ||
227 | |||
228 | __raw_writew((value),alignw(___io(ptr))); | ||
229 | } | ||
230 | #endif /* IXDP2x01 */ | ||
231 | |||
232 | #endif | 134 | #endif |
diff --git a/include/asm-arm/arch-ixp2000/ixp2000-regs.h b/include/asm-arm/arch-ixp2000/ixp2000-regs.h index fc5ac6aec4f2..8cf70ff160af 100644 --- a/include/asm-arm/arch-ixp2000/ixp2000-regs.h +++ b/include/asm-arm/arch-ixp2000/ixp2000-regs.h | |||
@@ -156,6 +156,14 @@ | |||
156 | #define IXP2000_IRQ_THD_RAW_STATUS_B_1 IXP2000_INTCTL_REG(0x84) | 156 | #define IXP2000_IRQ_THD_RAW_STATUS_B_1 IXP2000_INTCTL_REG(0x84) |
157 | #define IXP2000_IRQ_THD_RAW_STATUS_B_2 IXP2000_INTCTL_REG(0x88) | 157 | #define IXP2000_IRQ_THD_RAW_STATUS_B_2 IXP2000_INTCTL_REG(0x88) |
158 | #define IXP2000_IRQ_THD_RAW_STATUS_B_3 IXP2000_INTCTL_REG(0x8c) | 158 | #define IXP2000_IRQ_THD_RAW_STATUS_B_3 IXP2000_INTCTL_REG(0x8c) |
159 | #define IXP2000_IRQ_THD_STATUS_A_0 IXP2000_INTCTL_REG(0xe0) | ||
160 | #define IXP2000_IRQ_THD_STATUS_A_1 IXP2000_INTCTL_REG(0xe4) | ||
161 | #define IXP2000_IRQ_THD_STATUS_A_2 IXP2000_INTCTL_REG(0xe8) | ||
162 | #define IXP2000_IRQ_THD_STATUS_A_3 IXP2000_INTCTL_REG(0xec) | ||
163 | #define IXP2000_IRQ_THD_STATUS_B_0 IXP2000_INTCTL_REG(0x100) | ||
164 | #define IXP2000_IRQ_THD_STATUS_B_1 IXP2000_INTCTL_REG(0x104) | ||
165 | #define IXP2000_IRQ_THD_STATUS_B_2 IXP2000_INTCTL_REG(0x108) | ||
166 | #define IXP2000_IRQ_THD_STATUS_B_3 IXP2000_INTCTL_REG(0x10c) | ||
159 | #define IXP2000_IRQ_THD_ENABLE_SET_A_0 IXP2000_INTCTL_REG(0x160) | 167 | #define IXP2000_IRQ_THD_ENABLE_SET_A_0 IXP2000_INTCTL_REG(0x160) |
160 | #define IXP2000_IRQ_THD_ENABLE_SET_A_1 IXP2000_INTCTL_REG(0x164) | 168 | #define IXP2000_IRQ_THD_ENABLE_SET_A_1 IXP2000_INTCTL_REG(0x164) |
161 | #define IXP2000_IRQ_THD_ENABLE_SET_A_2 IXP2000_INTCTL_REG(0x168) | 169 | #define IXP2000_IRQ_THD_ENABLE_SET_A_2 IXP2000_INTCTL_REG(0x168) |
diff --git a/include/asm-arm/arch-ixp4xx/coyote.h b/include/asm-arm/arch-ixp4xx/coyote.h index dd0c2d2d8503..7ac9ba2c035c 100644 --- a/include/asm-arm/arch-ixp4xx/coyote.h +++ b/include/asm-arm/arch-ixp4xx/coyote.h | |||
@@ -16,9 +16,6 @@ | |||
16 | #error "Do not include this directly, instead #include <asm/hardware.h>" | 16 | #error "Do not include this directly, instead #include <asm/hardware.h>" |
17 | #endif | 17 | #endif |
18 | 18 | ||
19 | #define COYOTE_FLASH_BASE IXP4XX_EXP_BUS_CS0_BASE_PHYS | ||
20 | #define COYOTE_FLASH_SIZE IXP4XX_EXP_BUS_CSX_REGION_SIZE * 2 | ||
21 | |||
22 | /* PCI controller GPIO to IRQ pin mappings */ | 19 | /* PCI controller GPIO to IRQ pin mappings */ |
23 | #define COYOTE_PCI_SLOT0_PIN 6 | 20 | #define COYOTE_PCI_SLOT0_PIN 6 |
24 | #define COYOTE_PCI_SLOT1_PIN 11 | 21 | #define COYOTE_PCI_SLOT1_PIN 11 |
@@ -26,7 +23,7 @@ | |||
26 | #define COYOTE_PCI_SLOT0_DEVID 14 | 23 | #define COYOTE_PCI_SLOT0_DEVID 14 |
27 | #define COYOTE_PCI_SLOT1_DEVID 15 | 24 | #define COYOTE_PCI_SLOT1_DEVID 15 |
28 | 25 | ||
29 | #define COYOTE_IDE_BASE_PHYS IXP4XX_EXP_BUS_CS3_BASE_PHYS | 26 | #define COYOTE_IDE_BASE_PHYS IXP4XX_EXP_BUS_BASE(3) |
30 | #define COYOTE_IDE_BASE_VIRT 0xFFFE1000 | 27 | #define COYOTE_IDE_BASE_VIRT 0xFFFE1000 |
31 | #define COYOTE_IDE_REGION_SIZE 0x1000 | 28 | #define COYOTE_IDE_REGION_SIZE 0x1000 |
32 | 29 | ||
diff --git a/include/asm-arm/arch-ixp4xx/dma.h b/include/asm-arm/arch-ixp4xx/dma.h index 312065dc0e7a..b1a071ecebc8 100644 --- a/include/asm-arm/arch-ixp4xx/dma.h +++ b/include/asm-arm/arch-ixp4xx/dma.h | |||
@@ -20,7 +20,4 @@ | |||
20 | 20 | ||
21 | #define MAX_DMA_ADDRESS (PAGE_OFFSET + SZ_64M) | 21 | #define MAX_DMA_ADDRESS (PAGE_OFFSET + SZ_64M) |
22 | 22 | ||
23 | /* No DMA */ | ||
24 | #define MAX_DMA_CHANNELS 0 | ||
25 | |||
26 | #endif /* _ASM_ARCH_DMA_H */ | 23 | #endif /* _ASM_ARCH_DMA_H */ |
diff --git a/include/asm-arm/arch-ixp4xx/entry-macro.S b/include/asm-arm/arch-ixp4xx/entry-macro.S index 323b0bc4a39c..27e124132e4c 100644 --- a/include/asm-arm/arch-ixp4xx/entry-macro.S +++ b/include/asm-arm/arch-ixp4xx/entry-macro.S | |||
@@ -7,6 +7,7 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | #include <asm/hardware.h> | ||
10 | 11 | ||
11 | .macro disable_fiq | 12 | .macro disable_fiq |
12 | .endm | 13 | .endm |
diff --git a/include/asm-arm/arch-ixp4xx/gtwx5715.h b/include/asm-arm/arch-ixp4xx/gtwx5715.h index fc460af70627..c3069d67c00e 100644 --- a/include/asm-arm/arch-ixp4xx/gtwx5715.h +++ b/include/asm-arm/arch-ixp4xx/gtwx5715.h | |||
@@ -57,10 +57,6 @@ | |||
57 | #define GTWX5715_GPIO13_IRQ IRQ_IXP4XX_SW_INT1 | 57 | #define GTWX5715_GPIO13_IRQ IRQ_IXP4XX_SW_INT1 |
58 | #define GTWX5715_GPIO14_IRQ IRQ_IXP4XX_SW_INT2 | 58 | #define GTWX5715_GPIO14_IRQ IRQ_IXP4XX_SW_INT2 |
59 | 59 | ||
60 | |||
61 | #define GTWX5715_FLASH_BASE IXP4XX_EXP_BUS_CS0_BASE_PHYS | ||
62 | #define GTWX5715_FLASH_SIZE (0x00800000) | ||
63 | |||
64 | /* PCI controller GPIO to IRQ pin mappings | 60 | /* PCI controller GPIO to IRQ pin mappings |
65 | 61 | ||
66 | INTA INTB | 62 | INTA INTB |
diff --git a/include/asm-arm/arch-ixp4xx/hardware.h b/include/asm-arm/arch-ixp4xx/hardware.h index cfb413c845f7..6acb69c95ef9 100644 --- a/include/asm-arm/arch-ixp4xx/hardware.h +++ b/include/asm-arm/arch-ixp4xx/hardware.h | |||
@@ -45,5 +45,6 @@ extern unsigned int processor_id; | |||
45 | #include "coyote.h" | 45 | #include "coyote.h" |
46 | #include "prpmc1100.h" | 46 | #include "prpmc1100.h" |
47 | #include "nslu2.h" | 47 | #include "nslu2.h" |
48 | #include "nas100d.h" | ||
48 | 49 | ||
49 | #endif /* _ASM_ARCH_HARDWARE_H */ | 50 | #endif /* _ASM_ARCH_HARDWARE_H */ |
diff --git a/include/asm-arm/arch-ixp4xx/irqs.h b/include/asm-arm/arch-ixp4xx/irqs.h index 2cf4930372bc..f24b763ca18e 100644 --- a/include/asm-arm/arch-ixp4xx/irqs.h +++ b/include/asm-arm/arch-ixp4xx/irqs.h | |||
@@ -100,4 +100,13 @@ | |||
100 | #define IRQ_NSLU2_PCI_INTB IRQ_IXP4XX_GPIO10 | 100 | #define IRQ_NSLU2_PCI_INTB IRQ_IXP4XX_GPIO10 |
101 | #define IRQ_NSLU2_PCI_INTC IRQ_IXP4XX_GPIO9 | 101 | #define IRQ_NSLU2_PCI_INTC IRQ_IXP4XX_GPIO9 |
102 | 102 | ||
103 | /* | ||
104 | * NAS100D board IRQs | ||
105 | */ | ||
106 | #define IRQ_NAS100D_PCI_INTA IRQ_IXP4XX_GPIO11 | ||
107 | #define IRQ_NAS100D_PCI_INTB IRQ_IXP4XX_GPIO10 | ||
108 | #define IRQ_NAS100D_PCI_INTC IRQ_IXP4XX_GPIO9 | ||
109 | #define IRQ_NAS100D_PCI_INTD IRQ_IXP4XX_GPIO8 | ||
110 | #define IRQ_NAS100D_PCI_INTE IRQ_IXP4XX_GPIO7 | ||
111 | |||
103 | #endif | 112 | #endif |
diff --git a/include/asm-arm/arch-ixp4xx/ixdp425.h b/include/asm-arm/arch-ixp4xx/ixdp425.h index 7d21bf941379..3d3820d7ba09 100644 --- a/include/asm-arm/arch-ixp4xx/ixdp425.h +++ b/include/asm-arm/arch-ixp4xx/ixdp425.h | |||
@@ -16,9 +16,6 @@ | |||
16 | #error "Do not include this directly, instead #include <asm/hardware.h>" | 16 | #error "Do not include this directly, instead #include <asm/hardware.h>" |
17 | #endif | 17 | #endif |
18 | 18 | ||
19 | #define IXDP425_FLASH_BASE IXP4XX_EXP_BUS_CS0_BASE_PHYS | ||
20 | #define IXDP425_FLASH_SIZE IXP4XX_EXP_BUS_CSX_REGION_SIZE | ||
21 | |||
22 | #define IXDP425_SDA_PIN 7 | 19 | #define IXDP425_SDA_PIN 7 |
23 | #define IXDP425_SCL_PIN 6 | 20 | #define IXDP425_SCL_PIN 6 |
24 | 21 | ||
diff --git a/include/asm-arm/arch-ixp4xx/memory.h b/include/asm-arm/arch-ixp4xx/memory.h index e024d0a1a669..ee211d28a3ef 100644 --- a/include/asm-arm/arch-ixp4xx/memory.h +++ b/include/asm-arm/arch-ixp4xx/memory.h | |||
@@ -16,31 +16,10 @@ | |||
16 | 16 | ||
17 | #ifndef __ASSEMBLY__ | 17 | #ifndef __ASSEMBLY__ |
18 | 18 | ||
19 | /* | 19 | void ixp4xx_adjust_zones(int node, unsigned long *size, unsigned long *holes); |
20 | * Only first 64MB of memory can be accessed via PCI. | ||
21 | * We use GFP_DMA to allocate safe buffers to do map/unmap. | ||
22 | * This is really ugly and we need a better way of specifying | ||
23 | * DMA-capable regions of memory. | ||
24 | */ | ||
25 | static inline void __arch_adjust_zones(int node, unsigned long *zone_size, | ||
26 | unsigned long *zhole_size) | ||
27 | { | ||
28 | unsigned int sz = SZ_64M >> PAGE_SHIFT; | ||
29 | |||
30 | /* | ||
31 | * Only adjust if > 64M on current system | ||
32 | */ | ||
33 | if (node || (zone_size[0] <= sz)) | ||
34 | return; | ||
35 | |||
36 | zone_size[1] = zone_size[0] - sz; | ||
37 | zone_size[0] = sz; | ||
38 | zhole_size[1] = zhole_size[0]; | ||
39 | zhole_size[0] = 0; | ||
40 | } | ||
41 | 20 | ||
42 | #define arch_adjust_zones(node, size, holes) \ | 21 | #define arch_adjust_zones(node, size, holes) \ |
43 | __arch_adjust_zones(node, size, holes) | 22 | ixp4xx_adjust_zones(node, size, holes) |
44 | 23 | ||
45 | #define ISA_DMA_THRESHOLD (SZ_64M - 1) | 24 | #define ISA_DMA_THRESHOLD (SZ_64M - 1) |
46 | 25 | ||
diff --git a/include/asm-arm/arch-ixp4xx/nas100d.h b/include/asm-arm/arch-ixp4xx/nas100d.h new file mode 100644 index 000000000000..51ac0180427c --- /dev/null +++ b/include/asm-arm/arch-ixp4xx/nas100d.h | |||
@@ -0,0 +1,72 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-ixp4xx/nas100d.h | ||
3 | * | ||
4 | * NAS100D platform specific definitions | ||
5 | * | ||
6 | * Copyright (c) 2005 Tower Technologies | ||
7 | * | ||
8 | * Author: Alessandro Zummo <a.zummo@towertech.it> | ||
9 | * | ||
10 | * based on ixdp425.h: | ||
11 | * Copyright 2004 (c) MontaVista, Software, Inc. | ||
12 | * | ||
13 | * This file is licensed under the terms of the GNU General Public | ||
14 | * License version 2. This program is licensed "as is" without any | ||
15 | * warranty of any kind, whether express or implied. | ||
16 | */ | ||
17 | |||
18 | #ifndef __ASM_ARCH_HARDWARE_H__ | ||
19 | #error "Do not include this directly, instead #include <asm/hardware.h>" | ||
20 | #endif | ||
21 | |||
22 | #define NAS100D_SDA_PIN 6 | ||
23 | #define NAS100D_SCL_PIN 5 | ||
24 | |||
25 | /* | ||
26 | * NAS100D PCI IRQs | ||
27 | */ | ||
28 | #define NAS100D_PCI_MAX_DEV 3 | ||
29 | #define NAS100D_PCI_IRQ_LINES 3 | ||
30 | |||
31 | |||
32 | /* PCI controller GPIO to IRQ pin mappings */ | ||
33 | #define NAS100D_PCI_INTA_PIN 11 | ||
34 | #define NAS100D_PCI_INTB_PIN 10 | ||
35 | #define NAS100D_PCI_INTC_PIN 9 | ||
36 | #define NAS100D_PCI_INTD_PIN 8 | ||
37 | #define NAS100D_PCI_INTE_PIN 7 | ||
38 | |||
39 | /* GPIO */ | ||
40 | |||
41 | #define NAS100D_GPIO0 0 | ||
42 | #define NAS100D_GPIO1 1 | ||
43 | #define NAS100D_GPIO2 2 | ||
44 | #define NAS100D_GPIO3 3 | ||
45 | #define NAS100D_GPIO4 4 | ||
46 | #define NAS100D_GPIO5 5 | ||
47 | #define NAS100D_GPIO6 6 | ||
48 | #define NAS100D_GPIO7 7 | ||
49 | #define NAS100D_GPIO8 8 | ||
50 | #define NAS100D_GPIO9 9 | ||
51 | #define NAS100D_GPIO10 10 | ||
52 | #define NAS100D_GPIO11 11 | ||
53 | #define NAS100D_GPIO12 12 | ||
54 | #define NAS100D_GPIO13 13 | ||
55 | #define NAS100D_GPIO14 14 | ||
56 | #define NAS100D_GPIO15 15 | ||
57 | |||
58 | |||
59 | /* Buttons */ | ||
60 | |||
61 | #define NAS100D_PB_GPIO NAS100D_GPIO14 | ||
62 | #define NAS100D_RB_GPIO NAS100D_GPIO4 | ||
63 | #define NAS100D_PO_GPIO NAS100D_GPIO12 /* power off */ | ||
64 | |||
65 | #define NAS100D_PB_IRQ IRQ_IXP4XX_GPIO14 | ||
66 | #define NAS100D_RB_IRQ IRQ_IXP4XX_GPIO4 | ||
67 | |||
68 | /* | ||
69 | #define NAS100D_PB_BM (1L << NAS100D_PB_GPIO) | ||
70 | #define NAS100D_PO_BM (1L << NAS100D_PO_GPIO) | ||
71 | #define NAS100D_RB_BM (1L << NAS100D_RB_GPIO) | ||
72 | */ | ||
diff --git a/include/asm-arm/arch-ixp4xx/nslu2.h b/include/asm-arm/arch-ixp4xx/nslu2.h index b8b347a559c7..4281838873ef 100644 --- a/include/asm-arm/arch-ixp4xx/nslu2.h +++ b/include/asm-arm/arch-ixp4xx/nslu2.h | |||
@@ -18,9 +18,6 @@ | |||
18 | #error "Do not include this directly, instead #include <asm/hardware.h>" | 18 | #error "Do not include this directly, instead #include <asm/hardware.h>" |
19 | #endif | 19 | #endif |
20 | 20 | ||
21 | #define NSLU2_FLASH_BASE IXP4XX_EXP_BUS_CS0_BASE_PHYS | ||
22 | #define NSLU2_FLASH_SIZE IXP4XX_EXP_BUS_CSX_REGION_SIZE | ||
23 | |||
24 | #define NSLU2_SDA_PIN 7 | 21 | #define NSLU2_SDA_PIN 7 |
25 | #define NSLU2_SCL_PIN 6 | 22 | #define NSLU2_SCL_PIN 6 |
26 | 23 | ||
diff --git a/include/asm-arm/arch-ixp4xx/platform.h b/include/asm-arm/arch-ixp4xx/platform.h index f14ed63590c3..daf9790645ca 100644 --- a/include/asm-arm/arch-ixp4xx/platform.h +++ b/include/asm-arm/arch-ixp4xx/platform.h | |||
@@ -26,16 +26,17 @@ | |||
26 | */ | 26 | */ |
27 | #define IXP4XX_EXP_BUS_BASE_PHYS (0x50000000) | 27 | #define IXP4XX_EXP_BUS_BASE_PHYS (0x50000000) |
28 | 28 | ||
29 | #define IXP4XX_EXP_BUS_CSX_REGION_SIZE (0x01000000) | 29 | /* |
30 | * The expansion bus on the IXP4xx can be configured for either 16 or | ||
31 | * 32MB windows and the CS offset for each region changes based on the | ||
32 | * current configuration. This means that we cannot simply hardcode | ||
33 | * each offset. ixp4xx_sys_init() looks at the expansion bus configuration | ||
34 | * as setup by the bootloader to determine our window size. | ||
35 | */ | ||
36 | extern unsigned long ixp4xx_exp_bus_size; | ||
30 | 37 | ||
31 | #define IXP4XX_EXP_BUS_CS0_BASE_PHYS (IXP4XX_EXP_BUS_BASE_PHYS + 0x00000000) | 38 | #define IXP4XX_EXP_BUS_BASE(region)\ |
32 | #define IXP4XX_EXP_BUS_CS1_BASE_PHYS (IXP4XX_EXP_BUS_BASE_PHYS + 0x01000000) | 39 | (IXP4XX_EXP_BUS_BASE_PHYS + ((region) * ixp4xx_exp_bus_size)) |
33 | #define IXP4XX_EXP_BUS_CS2_BASE_PHYS (IXP4XX_EXP_BUS_BASE_PHYS + 0x02000000) | ||
34 | #define IXP4XX_EXP_BUS_CS3_BASE_PHYS (IXP4XX_EXP_BUS_BASE_PHYS + 0x03000000) | ||
35 | #define IXP4XX_EXP_BUS_CS4_BASE_PHYS (IXP4XX_EXP_BUS_BASE_PHYS + 0x04000000) | ||
36 | #define IXP4XX_EXP_BUS_CS5_BASE_PHYS (IXP4XX_EXP_BUS_BASE_PHYS + 0x05000000) | ||
37 | #define IXP4XX_EXP_BUS_CS6_BASE_PHYS (IXP4XX_EXP_BUS_BASE_PHYS + 0x06000000) | ||
38 | #define IXP4XX_EXP_BUS_CS7_BASE_PHYS (IXP4XX_EXP_BUS_BASE_PHYS + 0x07000000) | ||
39 | 40 | ||
40 | #define IXP4XX_FLASH_WRITABLE (0x2) | 41 | #define IXP4XX_FLASH_WRITABLE (0x2) |
41 | #define IXP4XX_FLASH_DEFAULT (0xbcd23c40) | 42 | #define IXP4XX_FLASH_DEFAULT (0xbcd23c40) |
@@ -112,10 +113,5 @@ static inline void gpio_line_set(u8 line, int value) | |||
112 | *IXP4XX_GPIO_GPOUTR &= ~(1 << line); | 113 | *IXP4XX_GPIO_GPOUTR &= ~(1 << line); |
113 | } | 114 | } |
114 | 115 | ||
115 | static inline void gpio_line_isr_clear(u8 line) | ||
116 | { | ||
117 | *IXP4XX_GPIO_GPISR = (1 << line); | ||
118 | } | ||
119 | |||
120 | #endif // __ASSEMBLY__ | 116 | #endif // __ASSEMBLY__ |
121 | 117 | ||
diff --git a/include/asm-arm/arch-l7200/dma.h b/include/asm-arm/arch-l7200/dma.h index 6595b386cfc9..4c7eca63f035 100644 --- a/include/asm-arm/arch-l7200/dma.h +++ b/include/asm-arm/arch-l7200/dma.h | |||
@@ -17,7 +17,6 @@ | |||
17 | * bytes of RAM. | 17 | * bytes of RAM. |
18 | */ | 18 | */ |
19 | #define MAX_DMA_ADDRESS 0xd0000000 | 19 | #define MAX_DMA_ADDRESS 0xd0000000 |
20 | #define MAX_DMA_CHANNELS 0 | ||
21 | 20 | ||
22 | #define DMA_S0 0 | 21 | #define DMA_S0 0 |
23 | 22 | ||
diff --git a/include/asm-arm/arch-l7200/system.h b/include/asm-arm/arch-l7200/system.h index cb4ff29059b8..18825cf071ba 100644 --- a/include/asm-arm/arch-l7200/system.h +++ b/include/asm-arm/arch-l7200/system.h | |||
@@ -12,6 +12,8 @@ | |||
12 | #ifndef __ASM_ARCH_SYSTEM_H | 12 | #ifndef __ASM_ARCH_SYSTEM_H |
13 | #define __ASM_ARCH_SYSTEM_H | 13 | #define __ASM_ARCH_SYSTEM_H |
14 | 14 | ||
15 | #include <asm/hardware.h> | ||
16 | |||
15 | static inline void arch_idle(void) | 17 | static inline void arch_idle(void) |
16 | { | 18 | { |
17 | *(unsigned long *)(IO_BASE + 0x50004) = 1; /* idle mode */ | 19 | *(unsigned long *)(IO_BASE + 0x50004) = 1; /* idle mode */ |
diff --git a/include/asm-arm/arch-lh7a40x/dma.h b/include/asm-arm/arch-lh7a40x/dma.h index 5797f01e1844..15492e3253f6 100644 --- a/include/asm-arm/arch-lh7a40x/dma.h +++ b/include/asm-arm/arch-lh7a40x/dma.h | |||
@@ -7,11 +7,3 @@ | |||
7 | * version 2 as published by the Free Software Foundation. | 7 | * version 2 as published by the Free Software Foundation. |
8 | * | 8 | * |
9 | */ | 9 | */ |
10 | |||
11 | #ifndef __ASM_ARCH_DMA_H | ||
12 | #define __ASM_ARCH_DMA_H | ||
13 | |||
14 | #define MAX_DMA_ADDRESS 0xffffffff | ||
15 | #define MAX_DMA_CHANNELS 0 /* All DMA is internal to CPU */ | ||
16 | |||
17 | #endif /* _ASM_ARCH_DMA_H */ | ||
diff --git a/include/asm-arm/arch-lh7a40x/entry-macro.S b/include/asm-arm/arch-lh7a40x/entry-macro.S index 865f396aa63c..a2f67c06d9c9 100644 --- a/include/asm-arm/arch-lh7a40x/entry-macro.S +++ b/include/asm-arm/arch-lh7a40x/entry-macro.S | |||
@@ -7,6 +7,8 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | #include <asm/hardware.h> | ||
11 | #include <asm/arch/irqs.h> | ||
10 | 12 | ||
11 | # if defined (CONFIG_ARCH_LH7A400) && defined (CONFIG_ARCH_LH7A404) | 13 | # if defined (CONFIG_ARCH_LH7A400) && defined (CONFIG_ARCH_LH7A404) |
12 | # error "LH7A400 and LH7A404 are mutually exclusive" | 14 | # error "LH7A400 and LH7A404 are mutually exclusive" |
diff --git a/include/asm-arm/arch-omap/dma.h b/include/asm-arm/arch-omap/dma.h index ccbcb580a5c1..d4e73efcb816 100644 --- a/include/asm-arm/arch-omap/dma.h +++ b/include/asm-arm/arch-omap/dma.h | |||
@@ -21,9 +21,6 @@ | |||
21 | #ifndef __ASM_ARCH_DMA_H | 21 | #ifndef __ASM_ARCH_DMA_H |
22 | #define __ASM_ARCH_DMA_H | 22 | #define __ASM_ARCH_DMA_H |
23 | 23 | ||
24 | #define MAX_DMA_ADDRESS 0xffffffff | ||
25 | #define MAX_DMA_CHANNELS 0 | ||
26 | |||
27 | /* Hardware registers for omap1 */ | 24 | /* Hardware registers for omap1 */ |
28 | #define OMAP_DMA_BASE (0xfffed800) | 25 | #define OMAP_DMA_BASE (0xfffed800) |
29 | #define OMAP_DMA_GCR (OMAP_DMA_BASE + 0x400) | 26 | #define OMAP_DMA_GCR (OMAP_DMA_BASE + 0x400) |
diff --git a/include/asm-arm/arch-omap/entry-macro.S b/include/asm-arm/arch-omap/entry-macro.S index f8814a84910e..0ffb1185f1ac 100644 --- a/include/asm-arm/arch-omap/entry-macro.S +++ b/include/asm-arm/arch-omap/entry-macro.S | |||
@@ -7,6 +7,8 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | #include <asm/hardware.h> | ||
11 | #include <asm/arch/irqs.h> | ||
10 | 12 | ||
11 | #if defined(CONFIG_ARCH_OMAP1) | 13 | #if defined(CONFIG_ARCH_OMAP1) |
12 | 14 | ||
diff --git a/include/asm-arm/arch-omap/system.h b/include/asm-arm/arch-omap/system.h index 9af415d2944a..6724a81bd10b 100644 --- a/include/asm-arm/arch-omap/system.h +++ b/include/asm-arm/arch-omap/system.h | |||
@@ -5,8 +5,9 @@ | |||
5 | #ifndef __ASM_ARCH_SYSTEM_H | 5 | #ifndef __ASM_ARCH_SYSTEM_H |
6 | #define __ASM_ARCH_SYSTEM_H | 6 | #define __ASM_ARCH_SYSTEM_H |
7 | #include <linux/config.h> | 7 | #include <linux/config.h> |
8 | #include <linux/clk.h> | ||
9 | |||
8 | #include <asm/mach-types.h> | 10 | #include <asm/mach-types.h> |
9 | #include <asm/hardware/clock.h> | ||
10 | #include <asm/hardware.h> | 11 | #include <asm/hardware.h> |
11 | #include <asm/arch/prcm.h> | 12 | #include <asm/arch/prcm.h> |
12 | 13 | ||
diff --git a/include/asm-arm/arch-pxa/dma.h b/include/asm-arm/arch-pxa/dma.h index 56db3d49bfc8..3e88a2a02a0f 100644 --- a/include/asm-arm/arch-pxa/dma.h +++ b/include/asm-arm/arch-pxa/dma.h | |||
@@ -12,11 +12,6 @@ | |||
12 | #ifndef __ASM_ARCH_DMA_H | 12 | #ifndef __ASM_ARCH_DMA_H |
13 | #define __ASM_ARCH_DMA_H | 13 | #define __ASM_ARCH_DMA_H |
14 | 14 | ||
15 | #define MAX_DMA_ADDRESS 0xffffffff | ||
16 | |||
17 | /* No DMA as the rest of the world see it */ | ||
18 | #define MAX_DMA_CHANNELS 0 | ||
19 | |||
20 | /* | 15 | /* |
21 | * Descriptor structure for PXA's DMA engine | 16 | * Descriptor structure for PXA's DMA engine |
22 | * Note: this structure must always be aligned to a 16-byte boundary. | 17 | * Note: this structure must always be aligned to a 16-byte boundary. |
diff --git a/include/asm-arm/arch-pxa/entry-macro.S b/include/asm-arm/arch-pxa/entry-macro.S index 2abfc8bb3ee5..4985e33afc12 100644 --- a/include/asm-arm/arch-pxa/entry-macro.S +++ b/include/asm-arm/arch-pxa/entry-macro.S | |||
@@ -7,6 +7,8 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | #include <asm/hardware.h> | ||
11 | #include <asm/arch/irqs.h> | ||
10 | 12 | ||
11 | .macro disable_fiq | 13 | .macro disable_fiq |
12 | .endm | 14 | .endm |
diff --git a/include/asm-arm/arch-pxa/pxa-regs.h b/include/asm-arm/arch-pxa/pxa-regs.h index a75a2470f4f5..dae138b9cac5 100644 --- a/include/asm-arm/arch-pxa/pxa-regs.h +++ b/include/asm-arm/arch-pxa/pxa-regs.h | |||
@@ -2042,6 +2042,18 @@ | |||
2042 | 2042 | ||
2043 | #ifdef CONFIG_PXA27x | 2043 | #ifdef CONFIG_PXA27x |
2044 | 2044 | ||
2045 | #define ARB_CNTRL __REG(0x48000048) /* Arbiter Control Register */ | ||
2046 | |||
2047 | #define ARB_DMA_SLV_PARK (1<<31) /* Be parked with DMA slave when idle */ | ||
2048 | #define ARB_CI_PARK (1<<30) /* Be parked with Camera Interface when idle */ | ||
2049 | #define ARB_EX_MEM_PARK (1<<29) /* Be parked with external MEMC when idle */ | ||
2050 | #define ARB_INT_MEM_PARK (1<<28) /* Be parked with internal MEMC when idle */ | ||
2051 | #define ARB_USB_PARK (1<<27) /* Be parked with USB when idle */ | ||
2052 | #define ARB_LCD_PARK (1<<26) /* Be parked with LCD when idle */ | ||
2053 | #define ARB_DMA_PARK (1<<25) /* Be parked with DMA when idle */ | ||
2054 | #define ARB_CORE_PARK (1<<24) /* Be parked with core when idle */ | ||
2055 | #define ARB_LOCK_FLAG (1<<23) /* Only Locking masters gain access to the bus */ | ||
2056 | |||
2045 | /* | 2057 | /* |
2046 | * Keypad | 2058 | * Keypad |
2047 | */ | 2059 | */ |
diff --git a/include/asm-arm/arch-realview/debug-macro.S b/include/asm-arm/arch-realview/debug-macro.S index ed28bd012236..017ad996848d 100644 --- a/include/asm-arm/arch-realview/debug-macro.S +++ b/include/asm-arm/arch-realview/debug-macro.S | |||
@@ -11,7 +11,7 @@ | |||
11 | * | 11 | * |
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <asm/hardware/amba_serial.h> | 14 | #include <linux/amba/serial.h> |
15 | 15 | ||
16 | .macro addruart,rx | 16 | .macro addruart,rx |
17 | mrc p15, 0, \rx, c1, c0 | 17 | mrc p15, 0, \rx, c1, c0 |
diff --git a/include/asm-arm/arch-realview/dma.h b/include/asm-arm/arch-realview/dma.h index 744491a74bd9..8342e3f9d6ec 100644 --- a/include/asm-arm/arch-realview/dma.h +++ b/include/asm-arm/arch-realview/dma.h | |||
@@ -18,10 +18,3 @@ | |||
18 | * along with this program; if not, write to the Free Software | 18 | * along with this program; if not, write to the Free Software |
19 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 19 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
20 | */ | 20 | */ |
21 | #ifndef __ASM_ARCH_DMA_H | ||
22 | #define __ASM_ARCH_DMA_H | ||
23 | |||
24 | #define MAX_DMA_ADDRESS 0xffffffff | ||
25 | #define MAX_DMA_CHANNELS 0 | ||
26 | |||
27 | #endif /* _ASM_ARCH_DMA_H */ | ||
diff --git a/include/asm-arm/arch-realview/entry-macro.S b/include/asm-arm/arch-realview/entry-macro.S index 6288fad0dc41..1a6eec86bd47 100644 --- a/include/asm-arm/arch-realview/entry-macro.S +++ b/include/asm-arm/arch-realview/entry-macro.S | |||
@@ -7,7 +7,7 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | 10 | #include <asm/hardware.h> | |
11 | #include <asm/hardware/gic.h> | 11 | #include <asm/hardware/gic.h> |
12 | 12 | ||
13 | .macro disable_fiq | 13 | .macro disable_fiq |
diff --git a/include/asm-arm/arch-rpc/entry-macro.S b/include/asm-arm/arch-rpc/entry-macro.S index 686f413f82d6..c9e5395e5106 100644 --- a/include/asm-arm/arch-rpc/entry-macro.S +++ b/include/asm-arm/arch-rpc/entry-macro.S | |||
@@ -1,3 +1,3 @@ | |||
1 | 1 | #include <asm/hardware.h> | |
2 | #include <asm/hardware/entry-macro-iomd.S> | 2 | #include <asm/hardware/entry-macro-iomd.S> |
3 | 3 | ||
diff --git a/include/asm-arm/arch-s3c2410/dma.h b/include/asm-arm/arch-s3c2410/dma.h index e830a40e573a..b011e14f3bc6 100644 --- a/include/asm-arm/arch-s3c2410/dma.h +++ b/include/asm-arm/arch-s3c2410/dma.h | |||
@@ -31,14 +31,6 @@ | |||
31 | #define MAX_DMA_TRANSFER_SIZE 0x100000 /* Data Unit is half word */ | 31 | #define MAX_DMA_TRANSFER_SIZE 0x100000 /* Data Unit is half word */ |
32 | 32 | ||
33 | 33 | ||
34 | /* according to the samsung port, we cannot use the regular | ||
35 | * dma channels... we must therefore provide our own interface | ||
36 | * for DMA, and allow our drivers to use that. | ||
37 | */ | ||
38 | |||
39 | #define MAX_DMA_CHANNELS 0 | ||
40 | |||
41 | |||
42 | /* we have 4 dma channels */ | 34 | /* we have 4 dma channels */ |
43 | #define S3C2410_DMA_CHANNELS (4) | 35 | #define S3C2410_DMA_CHANNELS (4) |
44 | 36 | ||
diff --git a/include/asm-arm/arch-s3c2410/entry-macro.S b/include/asm-arm/arch-s3c2410/entry-macro.S index b7d4d7f4422d..cc06b1bd37b2 100644 --- a/include/asm-arm/arch-s3c2410/entry-macro.S +++ b/include/asm-arm/arch-s3c2410/entry-macro.S | |||
@@ -10,6 +10,8 @@ | |||
10 | * Modifications: | 10 | * Modifications: |
11 | * 10-Mar-2005 LCVR Changed S3C2410_VA to S3C24XX_VA | 11 | * 10-Mar-2005 LCVR Changed S3C2410_VA to S3C24XX_VA |
12 | */ | 12 | */ |
13 | #include <asm/hardware.h> | ||
14 | #include <asm/arch/irqs.h> | ||
13 | 15 | ||
14 | 16 | ||
15 | .macro get_irqnr_and_base, irqnr, irqstat, base, tmp | 17 | .macro get_irqnr_and_base, irqnr, irqstat, base, tmp |
diff --git a/include/asm-arm/arch-sa1100/dma.h b/include/asm-arm/arch-sa1100/dma.h index 3d60ed9f8c34..02575d72ac6b 100644 --- a/include/asm-arm/arch-sa1100/dma.h +++ b/include/asm-arm/arch-sa1100/dma.h | |||
@@ -15,20 +15,6 @@ | |||
15 | 15 | ||
16 | 16 | ||
17 | /* | 17 | /* |
18 | * This is the maximum DMA address that can be DMAd to. | ||
19 | */ | ||
20 | #define MAX_DMA_ADDRESS 0xffffffff | ||
21 | |||
22 | |||
23 | /* | ||
24 | * The regular generic DMA interface is inappropriate for the | ||
25 | * SA1100 DMA model. None of the SA1100 specific drivers using | ||
26 | * DMA are portable anyway so it's pointless to try to twist the | ||
27 | * regular DMA API to accommodate them. | ||
28 | */ | ||
29 | #define MAX_DMA_CHANNELS 0 | ||
30 | |||
31 | /* | ||
32 | * The SA1100 has six internal DMA channels. | 18 | * The SA1100 has six internal DMA channels. |
33 | */ | 19 | */ |
34 | #define SA1100_DMA_CHANNELS 6 | 20 | #define SA1100_DMA_CHANNELS 6 |
diff --git a/include/asm-arm/arch-versatile/debug-macro.S b/include/asm-arm/arch-versatile/debug-macro.S index 89e38ac1444e..ef6167116dbb 100644 --- a/include/asm-arm/arch-versatile/debug-macro.S +++ b/include/asm-arm/arch-versatile/debug-macro.S | |||
@@ -11,7 +11,7 @@ | |||
11 | * | 11 | * |
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <asm/hardware/amba_serial.h> | 14 | #include <linux/amba/serial.h> |
15 | 15 | ||
16 | .macro addruart,rx | 16 | .macro addruart,rx |
17 | mrc p15, 0, \rx, c1, c0 | 17 | mrc p15, 0, \rx, c1, c0 |
diff --git a/include/asm-arm/arch-versatile/dma.h b/include/asm-arm/arch-versatile/dma.h index dcc8ac26eac0..642577348623 100644 --- a/include/asm-arm/arch-versatile/dma.h +++ b/include/asm-arm/arch-versatile/dma.h | |||
@@ -18,10 +18,3 @@ | |||
18 | * along with this program; if not, write to the Free Software | 18 | * along with this program; if not, write to the Free Software |
19 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 19 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
20 | */ | 20 | */ |
21 | #ifndef __ASM_ARCH_DMA_H | ||
22 | #define __ASM_ARCH_DMA_H | ||
23 | |||
24 | #define MAX_DMA_ADDRESS 0xffffffff | ||
25 | #define MAX_DMA_CHANNELS 0 | ||
26 | |||
27 | #endif /* _ASM_ARCH_DMA_H */ | ||
diff --git a/include/asm-arm/arch-versatile/entry-macro.S b/include/asm-arm/arch-versatile/entry-macro.S index 90e4e970d253..58f0d71759f6 100644 --- a/include/asm-arm/arch-versatile/entry-macro.S +++ b/include/asm-arm/arch-versatile/entry-macro.S | |||
@@ -7,7 +7,9 @@ | |||
7 | * License version 2. This program is licensed "as is" without any | 7 | * License version 2. This program is licensed "as is" without any |
8 | * warranty of any kind, whether express or implied. | 8 | * warranty of any kind, whether express or implied. |
9 | */ | 9 | */ |
10 | .macro disable_fiq | 10 | #include <asm/hardware.h> |
11 | |||
12 | .macro disable_fiq | ||
11 | .endm | 13 | .endm |
12 | 14 | ||
13 | .macro get_irqnr_and_base, irqnr, irqstat, base, tmp | 15 | .macro get_irqnr_and_base, irqnr, irqstat, base, tmp |
diff --git a/include/asm-arm/byteorder.h b/include/asm-arm/byteorder.h index d648a1915c33..741f5bc5d016 100644 --- a/include/asm-arm/byteorder.h +++ b/include/asm-arm/byteorder.h | |||
@@ -15,9 +15,23 @@ | |||
15 | #ifndef __ASM_ARM_BYTEORDER_H | 15 | #ifndef __ASM_ARM_BYTEORDER_H |
16 | #define __ASM_ARM_BYTEORDER_H | 16 | #define __ASM_ARM_BYTEORDER_H |
17 | 17 | ||
18 | 18 | #include <linux/compiler.h> | |
19 | #include <asm/types.h> | 19 | #include <asm/types.h> |
20 | 20 | ||
21 | static inline __attribute_const__ __u32 ___arch__swab32(__u32 x) | ||
22 | { | ||
23 | __u32 t; | ||
24 | |||
25 | t = x ^ ((x << 16) | (x >> 16)); /* eor r1,r0,r0,ror #16 */ | ||
26 | x = (x << 24) | (x >> 8); /* mov r0,r0,ror #8 */ | ||
27 | t &= ~0x00FF0000; /* bic r1,r1,#0x00FF0000 */ | ||
28 | x ^= (t >> 8); /* eor r0,r0,r1,lsr #8 */ | ||
29 | |||
30 | return x; | ||
31 | } | ||
32 | |||
33 | #define __arch__swab32(x) ___arch__swab32(x) | ||
34 | |||
21 | #if !defined(__STRICT_ANSI__) || defined(__KERNEL__) | 35 | #if !defined(__STRICT_ANSI__) || defined(__KERNEL__) |
22 | # define __BYTEORDER_HAS_U64__ | 36 | # define __BYTEORDER_HAS_U64__ |
23 | # define __SWAB_64_THRU_32__ | 37 | # define __SWAB_64_THRU_32__ |
diff --git a/include/asm-arm/cacheflush.h b/include/asm-arm/cacheflush.h index e81baff4f54b..09e19a783a51 100644 --- a/include/asm-arm/cacheflush.h +++ b/include/asm-arm/cacheflush.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #include <linux/sched.h> | 14 | #include <linux/sched.h> |
15 | #include <linux/mm.h> | 15 | #include <linux/mm.h> |
16 | 16 | ||
17 | #include <asm/mman.h> | ||
18 | #include <asm/glue.h> | 17 | #include <asm/glue.h> |
19 | #include <asm/shmparam.h> | 18 | #include <asm/shmparam.h> |
20 | 19 | ||
diff --git a/include/asm-arm/dma.h b/include/asm-arm/dma.h index ef41df43a584..49c01e2bf7c8 100644 --- a/include/asm-arm/dma.h +++ b/include/asm-arm/dma.h | |||
@@ -10,6 +10,13 @@ typedef unsigned int dmach_t; | |||
10 | #include <asm/arch/dma.h> | 10 | #include <asm/arch/dma.h> |
11 | 11 | ||
12 | /* | 12 | /* |
13 | * This is the maximum virtual address which can be DMA'd from. | ||
14 | */ | ||
15 | #ifndef MAX_DMA_ADDRESS | ||
16 | #define MAX_DMA_ADDRESS 0xffffffff | ||
17 | #endif | ||
18 | |||
19 | /* | ||
13 | * DMA modes | 20 | * DMA modes |
14 | */ | 21 | */ |
15 | typedef unsigned int dmamode_t; | 22 | typedef unsigned int dmamode_t; |
@@ -91,7 +98,9 @@ extern void set_dma_sg(dmach_t channel, struct scatterlist *sg, int nr_sg); | |||
91 | * especially since some DMA architectures don't update the | 98 | * especially since some DMA architectures don't update the |
92 | * DMA address immediately, but defer it to the enable_dma(). | 99 | * DMA address immediately, but defer it to the enable_dma(). |
93 | */ | 100 | */ |
94 | extern void set_dma_addr(dmach_t channel, unsigned long physaddr); | 101 | extern void __set_dma_addr(dmach_t channel, void *addr); |
102 | #define set_dma_addr(channel, addr) \ | ||
103 | __set_dma_addr(channel, bus_to_virt(addr)) | ||
95 | 104 | ||
96 | /* Set the DMA byte count for this channel | 105 | /* Set the DMA byte count for this channel |
97 | * | 106 | * |
diff --git a/include/asm-arm/hardware/amba.h b/include/asm-arm/hardware/amba.h deleted file mode 100644 index 51e6e54b2aa1..000000000000 --- a/include/asm-arm/hardware/amba.h +++ /dev/null | |||
@@ -1,55 +0,0 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/hardware/amba.h | ||
3 | * | ||
4 | * Copyright (C) 2003 Deep Blue Solutions Ltd, All Rights Reserved. | ||
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 | #ifndef ASMARM_AMBA_H | ||
11 | #define ASMARM_AMBA_H | ||
12 | |||
13 | #define AMBA_NR_IRQS 2 | ||
14 | |||
15 | struct amba_device { | ||
16 | struct device dev; | ||
17 | struct resource res; | ||
18 | u64 dma_mask; | ||
19 | unsigned int periphid; | ||
20 | unsigned int irq[AMBA_NR_IRQS]; | ||
21 | }; | ||
22 | |||
23 | struct amba_id { | ||
24 | unsigned int id; | ||
25 | unsigned int mask; | ||
26 | void *data; | ||
27 | }; | ||
28 | |||
29 | struct amba_driver { | ||
30 | struct device_driver drv; | ||
31 | int (*probe)(struct amba_device *, void *); | ||
32 | int (*remove)(struct amba_device *); | ||
33 | void (*shutdown)(struct amba_device *); | ||
34 | int (*suspend)(struct amba_device *, pm_message_t); | ||
35 | int (*resume)(struct amba_device *); | ||
36 | struct amba_id *id_table; | ||
37 | }; | ||
38 | |||
39 | #define amba_get_drvdata(d) dev_get_drvdata(&d->dev) | ||
40 | #define amba_set_drvdata(d,p) dev_set_drvdata(&d->dev, p) | ||
41 | |||
42 | int amba_driver_register(struct amba_driver *); | ||
43 | void amba_driver_unregister(struct amba_driver *); | ||
44 | int amba_device_register(struct amba_device *, struct resource *); | ||
45 | void amba_device_unregister(struct amba_device *); | ||
46 | struct amba_device *amba_find_device(const char *, struct device *, unsigned int, unsigned int); | ||
47 | int amba_request_regions(struct amba_device *, const char *); | ||
48 | void amba_release_regions(struct amba_device *); | ||
49 | |||
50 | #define amba_config(d) (((d)->periphid >> 24) & 0xff) | ||
51 | #define amba_rev(d) (((d)->periphid >> 20) & 0x0f) | ||
52 | #define amba_manf(d) (((d)->periphid >> 12) & 0xff) | ||
53 | #define amba_part(d) ((d)->periphid & 0xfff) | ||
54 | |||
55 | #endif | ||
diff --git a/include/asm-arm/hardware/amba_clcd.h b/include/asm-arm/hardware/amba_clcd.h deleted file mode 100644 index 6b8d73dc1ab0..000000000000 --- a/include/asm-arm/hardware/amba_clcd.h +++ /dev/null | |||
@@ -1,271 +0,0 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/hardware/amba_clcd.h -- Integrator LCD panel. | ||
3 | * | ||
4 | * David A Rusling | ||
5 | * | ||
6 | * Copyright (C) 2001 ARM Limited | ||
7 | * | ||
8 | * This file is subject to the terms and conditions of the GNU General Public | ||
9 | * License. See the file COPYING in the main directory of this archive | ||
10 | * for more details. | ||
11 | */ | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/fb.h> | ||
14 | |||
15 | /* | ||
16 | * CLCD Controller Internal Register addresses | ||
17 | */ | ||
18 | #define CLCD_TIM0 0x00000000 | ||
19 | #define CLCD_TIM1 0x00000004 | ||
20 | #define CLCD_TIM2 0x00000008 | ||
21 | #define CLCD_TIM3 0x0000000c | ||
22 | #define CLCD_UBAS 0x00000010 | ||
23 | #define CLCD_LBAS 0x00000014 | ||
24 | |||
25 | #if !defined(CONFIG_ARCH_VERSATILE) && !defined(CONFIG_ARCH_REALVIEW) | ||
26 | #define CLCD_IENB 0x00000018 | ||
27 | #define CLCD_CNTL 0x0000001c | ||
28 | #else | ||
29 | /* | ||
30 | * Someone rearranged these two registers on the Versatile | ||
31 | * platform... | ||
32 | */ | ||
33 | #define CLCD_IENB 0x0000001c | ||
34 | #define CLCD_CNTL 0x00000018 | ||
35 | #endif | ||
36 | |||
37 | #define CLCD_STAT 0x00000020 | ||
38 | #define CLCD_INTR 0x00000024 | ||
39 | #define CLCD_UCUR 0x00000028 | ||
40 | #define CLCD_LCUR 0x0000002C | ||
41 | #define CLCD_PALL 0x00000200 | ||
42 | #define CLCD_PALETTE 0x00000200 | ||
43 | |||
44 | #define TIM2_CLKSEL (1 << 5) | ||
45 | #define TIM2_IVS (1 << 11) | ||
46 | #define TIM2_IHS (1 << 12) | ||
47 | #define TIM2_IPC (1 << 13) | ||
48 | #define TIM2_IOE (1 << 14) | ||
49 | #define TIM2_BCD (1 << 26) | ||
50 | |||
51 | #define CNTL_LCDEN (1 << 0) | ||
52 | #define CNTL_LCDBPP1 (0 << 1) | ||
53 | #define CNTL_LCDBPP2 (1 << 1) | ||
54 | #define CNTL_LCDBPP4 (2 << 1) | ||
55 | #define CNTL_LCDBPP8 (3 << 1) | ||
56 | #define CNTL_LCDBPP16 (4 << 1) | ||
57 | #define CNTL_LCDBPP24 (5 << 1) | ||
58 | #define CNTL_LCDBW (1 << 4) | ||
59 | #define CNTL_LCDTFT (1 << 5) | ||
60 | #define CNTL_LCDMONO8 (1 << 6) | ||
61 | #define CNTL_LCDDUAL (1 << 7) | ||
62 | #define CNTL_BGR (1 << 8) | ||
63 | #define CNTL_BEBO (1 << 9) | ||
64 | #define CNTL_BEPO (1 << 10) | ||
65 | #define CNTL_LCDPWR (1 << 11) | ||
66 | #define CNTL_LCDVCOMP(x) ((x) << 12) | ||
67 | #define CNTL_LDMAFIFOTIME (1 << 15) | ||
68 | #define CNTL_WATERMARK (1 << 16) | ||
69 | |||
70 | struct clcd_panel { | ||
71 | struct fb_videomode mode; | ||
72 | signed short width; /* width in mm */ | ||
73 | signed short height; /* height in mm */ | ||
74 | u32 tim2; | ||
75 | u32 tim3; | ||
76 | u32 cntl; | ||
77 | unsigned int bpp:8, | ||
78 | fixedtimings:1, | ||
79 | grayscale:1; | ||
80 | unsigned int connector; | ||
81 | }; | ||
82 | |||
83 | struct clcd_regs { | ||
84 | u32 tim0; | ||
85 | u32 tim1; | ||
86 | u32 tim2; | ||
87 | u32 tim3; | ||
88 | u32 cntl; | ||
89 | unsigned long pixclock; | ||
90 | }; | ||
91 | |||
92 | struct clcd_fb; | ||
93 | |||
94 | /* | ||
95 | * the board-type specific routines | ||
96 | */ | ||
97 | struct clcd_board { | ||
98 | const char *name; | ||
99 | |||
100 | /* | ||
101 | * Optional. Check whether the var structure is acceptable | ||
102 | * for this display. | ||
103 | */ | ||
104 | int (*check)(struct clcd_fb *fb, struct fb_var_screeninfo *var); | ||
105 | |||
106 | /* | ||
107 | * Compulsary. Decode fb->fb.var into regs->*. In the case of | ||
108 | * fixed timing, set regs->* to the register values required. | ||
109 | */ | ||
110 | void (*decode)(struct clcd_fb *fb, struct clcd_regs *regs); | ||
111 | |||
112 | /* | ||
113 | * Optional. Disable any extra display hardware. | ||
114 | */ | ||
115 | void (*disable)(struct clcd_fb *); | ||
116 | |||
117 | /* | ||
118 | * Optional. Enable any extra display hardware. | ||
119 | */ | ||
120 | void (*enable)(struct clcd_fb *); | ||
121 | |||
122 | /* | ||
123 | * Setup platform specific parts of CLCD driver | ||
124 | */ | ||
125 | int (*setup)(struct clcd_fb *); | ||
126 | |||
127 | /* | ||
128 | * mmap the framebuffer memory | ||
129 | */ | ||
130 | int (*mmap)(struct clcd_fb *, struct vm_area_struct *); | ||
131 | |||
132 | /* | ||
133 | * Remove platform specific parts of CLCD driver | ||
134 | */ | ||
135 | void (*remove)(struct clcd_fb *); | ||
136 | }; | ||
137 | |||
138 | struct amba_device; | ||
139 | struct clk; | ||
140 | |||
141 | /* this data structure describes each frame buffer device we find */ | ||
142 | struct clcd_fb { | ||
143 | struct fb_info fb; | ||
144 | struct amba_device *dev; | ||
145 | struct clk *clk; | ||
146 | struct clcd_panel *panel; | ||
147 | struct clcd_board *board; | ||
148 | void *board_data; | ||
149 | void __iomem *regs; | ||
150 | u32 clcd_cntl; | ||
151 | u32 cmap[16]; | ||
152 | }; | ||
153 | |||
154 | static inline void clcdfb_decode(struct clcd_fb *fb, struct clcd_regs *regs) | ||
155 | { | ||
156 | u32 val, cpl; | ||
157 | |||
158 | /* | ||
159 | * Program the CLCD controller registers and start the CLCD | ||
160 | */ | ||
161 | val = ((fb->fb.var.xres / 16) - 1) << 2; | ||
162 | val |= (fb->fb.var.hsync_len - 1) << 8; | ||
163 | val |= (fb->fb.var.right_margin - 1) << 16; | ||
164 | val |= (fb->fb.var.left_margin - 1) << 24; | ||
165 | regs->tim0 = val; | ||
166 | |||
167 | val = fb->fb.var.yres; | ||
168 | if (fb->panel->cntl & CNTL_LCDDUAL) | ||
169 | val /= 2; | ||
170 | val -= 1; | ||
171 | val |= (fb->fb.var.vsync_len - 1) << 10; | ||
172 | val |= fb->fb.var.lower_margin << 16; | ||
173 | val |= fb->fb.var.upper_margin << 24; | ||
174 | regs->tim1 = val; | ||
175 | |||
176 | val = fb->panel->tim2; | ||
177 | val |= fb->fb.var.sync & FB_SYNC_HOR_HIGH_ACT ? 0 : TIM2_IHS; | ||
178 | val |= fb->fb.var.sync & FB_SYNC_VERT_HIGH_ACT ? 0 : TIM2_IVS; | ||
179 | |||
180 | cpl = fb->fb.var.xres_virtual; | ||
181 | if (fb->panel->cntl & CNTL_LCDTFT) /* TFT */ | ||
182 | /* / 1 */; | ||
183 | else if (!fb->fb.var.grayscale) /* STN color */ | ||
184 | cpl = cpl * 8 / 3; | ||
185 | else if (fb->panel->cntl & CNTL_LCDMONO8) /* STN monochrome, 8bit */ | ||
186 | cpl /= 8; | ||
187 | else /* STN monochrome, 4bit */ | ||
188 | cpl /= 4; | ||
189 | |||
190 | regs->tim2 = val | ((cpl - 1) << 16); | ||
191 | |||
192 | regs->tim3 = fb->panel->tim3; | ||
193 | |||
194 | val = fb->panel->cntl; | ||
195 | if (fb->fb.var.grayscale) | ||
196 | val |= CNTL_LCDBW; | ||
197 | |||
198 | switch (fb->fb.var.bits_per_pixel) { | ||
199 | case 1: | ||
200 | val |= CNTL_LCDBPP1; | ||
201 | break; | ||
202 | case 2: | ||
203 | val |= CNTL_LCDBPP2; | ||
204 | break; | ||
205 | case 4: | ||
206 | val |= CNTL_LCDBPP4; | ||
207 | break; | ||
208 | case 8: | ||
209 | val |= CNTL_LCDBPP8; | ||
210 | break; | ||
211 | case 16: | ||
212 | val |= CNTL_LCDBPP16; | ||
213 | break; | ||
214 | case 32: | ||
215 | val |= CNTL_LCDBPP24; | ||
216 | break; | ||
217 | } | ||
218 | |||
219 | regs->cntl = val; | ||
220 | regs->pixclock = fb->fb.var.pixclock; | ||
221 | } | ||
222 | |||
223 | static inline int clcdfb_check(struct clcd_fb *fb, struct fb_var_screeninfo *var) | ||
224 | { | ||
225 | var->xres_virtual = var->xres = (var->xres + 15) & ~15; | ||
226 | var->yres_virtual = var->yres = (var->yres + 1) & ~1; | ||
227 | |||
228 | #define CHECK(e,l,h) (var->e < l || var->e > h) | ||
229 | if (CHECK(right_margin, (5+1), 256) || /* back porch */ | ||
230 | CHECK(left_margin, (5+1), 256) || /* front porch */ | ||
231 | CHECK(hsync_len, (5+1), 256) || | ||
232 | var->xres > 4096 || | ||
233 | var->lower_margin > 255 || /* back porch */ | ||
234 | var->upper_margin > 255 || /* front porch */ | ||
235 | var->vsync_len > 32 || | ||
236 | var->yres > 1024) | ||
237 | return -EINVAL; | ||
238 | #undef CHECK | ||
239 | |||
240 | /* single panel mode: PCD = max(PCD, 1) */ | ||
241 | /* dual panel mode: PCD = max(PCD, 5) */ | ||
242 | |||
243 | /* | ||
244 | * You can't change the grayscale setting, and | ||
245 | * we can only do non-interlaced video. | ||
246 | */ | ||
247 | if (var->grayscale != fb->fb.var.grayscale || | ||
248 | (var->vmode & FB_VMODE_MASK) != FB_VMODE_NONINTERLACED) | ||
249 | return -EINVAL; | ||
250 | |||
251 | #define CHECK(e) (var->e != fb->fb.var.e) | ||
252 | if (fb->panel->fixedtimings && | ||
253 | (CHECK(xres) || | ||
254 | CHECK(yres) || | ||
255 | CHECK(bits_per_pixel) || | ||
256 | CHECK(pixclock) || | ||
257 | CHECK(left_margin) || | ||
258 | CHECK(right_margin) || | ||
259 | CHECK(upper_margin) || | ||
260 | CHECK(lower_margin) || | ||
261 | CHECK(hsync_len) || | ||
262 | CHECK(vsync_len) || | ||
263 | CHECK(sync))) | ||
264 | return -EINVAL; | ||
265 | #undef CHECK | ||
266 | |||
267 | var->nonstd = 0; | ||
268 | var->accel_flags = 0; | ||
269 | |||
270 | return 0; | ||
271 | } | ||
diff --git a/include/asm-arm/hardware/amba_kmi.h b/include/asm-arm/hardware/amba_kmi.h deleted file mode 100644 index a39e5be751b3..000000000000 --- a/include/asm-arm/hardware/amba_kmi.h +++ /dev/null | |||
@@ -1,92 +0,0 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/hardware/amba_kmi.h | ||
3 | * | ||
4 | * Internal header file for AMBA KMI ports | ||
5 | * | ||
6 | * Copyright (C) 2000 Deep Blue Solutions Ltd. | ||
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 as published by | ||
10 | * the Free Software Foundation; either version 2 of the License, or | ||
11 | * (at your option) any later version. | ||
12 | * | ||
13 | * This program is distributed in the hope that it will be useful, | ||
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
16 | * GNU General Public License for more details. | ||
17 | * | ||
18 | * You should have received a copy of the GNU General Public License | ||
19 | * along with this program; if not, write to the Free Software | ||
20 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
21 | * | ||
22 | * | ||
23 | * --------------------------------------------------------------------------- | ||
24 | * From ARM PrimeCell(tm) PS2 Keyboard/Mouse Interface (PL050) Technical | ||
25 | * Reference Manual - ARM DDI 0143B - see http://www.arm.com/ | ||
26 | * --------------------------------------------------------------------------- | ||
27 | */ | ||
28 | #ifndef ASM_ARM_HARDWARE_AMBA_KMI_H | ||
29 | #define ASM_ARM_HARDWARE_AMBA_KMI_H | ||
30 | |||
31 | /* | ||
32 | * KMI control register: | ||
33 | * KMICR_TYPE 0 = PS2/AT mode, 1 = No line control bit mode | ||
34 | * KMICR_RXINTREN 1 = enable RX interrupts | ||
35 | * KMICR_TXINTREN 1 = enable TX interrupts | ||
36 | * KMICR_EN 1 = enable KMI | ||
37 | * KMICR_FD 1 = force KMI data low | ||
38 | * KMICR_FC 1 = force KMI clock low | ||
39 | */ | ||
40 | #define KMICR (KMI_BASE + 0x00) | ||
41 | #define KMICR_TYPE (1 << 5) | ||
42 | #define KMICR_RXINTREN (1 << 4) | ||
43 | #define KMICR_TXINTREN (1 << 3) | ||
44 | #define KMICR_EN (1 << 2) | ||
45 | #define KMICR_FD (1 << 1) | ||
46 | #define KMICR_FC (1 << 0) | ||
47 | |||
48 | /* | ||
49 | * KMI status register: | ||
50 | * KMISTAT_TXEMPTY 1 = transmitter register empty | ||
51 | * KMISTAT_TXBUSY 1 = currently sending data | ||
52 | * KMISTAT_RXFULL 1 = receiver register ready to be read | ||
53 | * KMISTAT_RXBUSY 1 = currently receiving data | ||
54 | * KMISTAT_RXPARITY parity of last databyte received | ||
55 | * KMISTAT_IC current level of KMI clock input | ||
56 | * KMISTAT_ID current level of KMI data input | ||
57 | */ | ||
58 | #define KMISTAT (KMI_BASE + 0x04) | ||
59 | #define KMISTAT_TXEMPTY (1 << 6) | ||
60 | #define KMISTAT_TXBUSY (1 << 5) | ||
61 | #define KMISTAT_RXFULL (1 << 4) | ||
62 | #define KMISTAT_RXBUSY (1 << 3) | ||
63 | #define KMISTAT_RXPARITY (1 << 2) | ||
64 | #define KMISTAT_IC (1 << 1) | ||
65 | #define KMISTAT_ID (1 << 0) | ||
66 | |||
67 | /* | ||
68 | * KMI data register | ||
69 | */ | ||
70 | #define KMIDATA (KMI_BASE + 0x08) | ||
71 | |||
72 | /* | ||
73 | * KMI clock divisor: to generate 8MHz internal clock | ||
74 | * div = (ref / 8MHz) - 1; 0 <= div <= 15 | ||
75 | */ | ||
76 | #define KMICLKDIV (KMI_BASE + 0x0c) | ||
77 | |||
78 | /* | ||
79 | * KMI interrupt register: | ||
80 | * KMIIR_TXINTR 1 = transmit interrupt asserted | ||
81 | * KMIIR_RXINTR 1 = receive interrupt asserted | ||
82 | */ | ||
83 | #define KMIIR (KMI_BASE + 0x10) | ||
84 | #define KMIIR_TXINTR (1 << 1) | ||
85 | #define KMIIR_RXINTR (1 << 0) | ||
86 | |||
87 | /* | ||
88 | * The size of the KMI primecell | ||
89 | */ | ||
90 | #define KMI_SIZE (0x100) | ||
91 | |||
92 | #endif | ||
diff --git a/include/asm-arm/hardware/amba_serial.h b/include/asm-arm/hardware/amba_serial.h deleted file mode 100644 index dc726ffccebd..000000000000 --- a/include/asm-arm/hardware/amba_serial.h +++ /dev/null | |||
@@ -1,161 +0,0 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/hardware/serial_amba.h | ||
3 | * | ||
4 | * Internal header file for AMBA serial ports | ||
5 | * | ||
6 | * Copyright (C) ARM Limited | ||
7 | * Copyright (C) 2000 Deep Blue Solutions Ltd. | ||
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 as published by | ||
11 | * the Free Software Foundation; either version 2 of the License, or | ||
12 | * (at your option) any later version. | ||
13 | * | ||
14 | * This program is distributed in the hope that it will be useful, | ||
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
17 | * GNU General Public License for more details. | ||
18 | * | ||
19 | * You should have received a copy of the GNU General Public License | ||
20 | * along with this program; if not, write to the Free Software | ||
21 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
22 | */ | ||
23 | #ifndef ASM_ARM_HARDWARE_SERIAL_AMBA_H | ||
24 | #define ASM_ARM_HARDWARE_SERIAL_AMBA_H | ||
25 | |||
26 | /* ------------------------------------------------------------------------------- | ||
27 | * From AMBA UART (PL010) Block Specification | ||
28 | * ------------------------------------------------------------------------------- | ||
29 | * UART Register Offsets. | ||
30 | */ | ||
31 | #define UART01x_DR 0x00 /* Data read or written from the interface. */ | ||
32 | #define UART01x_RSR 0x04 /* Receive status register (Read). */ | ||
33 | #define UART01x_ECR 0x04 /* Error clear register (Write). */ | ||
34 | #define UART010_LCRH 0x08 /* Line control register, high byte. */ | ||
35 | #define UART010_LCRM 0x0C /* Line control register, middle byte. */ | ||
36 | #define UART010_LCRL 0x10 /* Line control register, low byte. */ | ||
37 | #define UART010_CR 0x14 /* Control register. */ | ||
38 | #define UART01x_FR 0x18 /* Flag register (Read only). */ | ||
39 | #define UART010_IIR 0x1C /* Interrupt indentification register (Read). */ | ||
40 | #define UART010_ICR 0x1C /* Interrupt clear register (Write). */ | ||
41 | #define UART01x_ILPR 0x20 /* IrDA low power counter register. */ | ||
42 | #define UART011_IBRD 0x24 /* Integer baud rate divisor register. */ | ||
43 | #define UART011_FBRD 0x28 /* Fractional baud rate divisor register. */ | ||
44 | #define UART011_LCRH 0x2c /* Line control register. */ | ||
45 | #define UART011_CR 0x30 /* Control register. */ | ||
46 | #define UART011_IFLS 0x34 /* Interrupt fifo level select. */ | ||
47 | #define UART011_IMSC 0x38 /* Interrupt mask. */ | ||
48 | #define UART011_RIS 0x3c /* Raw interrupt status. */ | ||
49 | #define UART011_MIS 0x40 /* Masked interrupt status. */ | ||
50 | #define UART011_ICR 0x44 /* Interrupt clear register. */ | ||
51 | #define UART011_DMACR 0x48 /* DMA control register. */ | ||
52 | |||
53 | #define UART011_DR_OE (1 << 11) | ||
54 | #define UART011_DR_BE (1 << 10) | ||
55 | #define UART011_DR_PE (1 << 9) | ||
56 | #define UART011_DR_FE (1 << 8) | ||
57 | |||
58 | #define UART01x_RSR_OE 0x08 | ||
59 | #define UART01x_RSR_BE 0x04 | ||
60 | #define UART01x_RSR_PE 0x02 | ||
61 | #define UART01x_RSR_FE 0x01 | ||
62 | |||
63 | #define UART011_FR_RI 0x100 | ||
64 | #define UART011_FR_TXFE 0x080 | ||
65 | #define UART011_FR_RXFF 0x040 | ||
66 | #define UART01x_FR_TXFF 0x020 | ||
67 | #define UART01x_FR_RXFE 0x010 | ||
68 | #define UART01x_FR_BUSY 0x008 | ||
69 | #define UART01x_FR_DCD 0x004 | ||
70 | #define UART01x_FR_DSR 0x002 | ||
71 | #define UART01x_FR_CTS 0x001 | ||
72 | #define UART01x_FR_TMSK (UART01x_FR_TXFF + UART01x_FR_BUSY) | ||
73 | |||
74 | #define UART011_CR_CTSEN 0x8000 /* CTS hardware flow control */ | ||
75 | #define UART011_CR_RTSEN 0x4000 /* RTS hardware flow control */ | ||
76 | #define UART011_CR_OUT2 0x2000 /* OUT2 */ | ||
77 | #define UART011_CR_OUT1 0x1000 /* OUT1 */ | ||
78 | #define UART011_CR_RTS 0x0800 /* RTS */ | ||
79 | #define UART011_CR_DTR 0x0400 /* DTR */ | ||
80 | #define UART011_CR_RXE 0x0200 /* receive enable */ | ||
81 | #define UART011_CR_TXE 0x0100 /* transmit enable */ | ||
82 | #define UART011_CR_LBE 0x0080 /* loopback enable */ | ||
83 | #define UART010_CR_RTIE 0x0040 | ||
84 | #define UART010_CR_TIE 0x0020 | ||
85 | #define UART010_CR_RIE 0x0010 | ||
86 | #define UART010_CR_MSIE 0x0008 | ||
87 | #define UART01x_CR_IIRLP 0x0004 /* SIR low power mode */ | ||
88 | #define UART01x_CR_SIREN 0x0002 /* SIR enable */ | ||
89 | #define UART01x_CR_UARTEN 0x0001 /* UART enable */ | ||
90 | |||
91 | #define UART011_LCRH_SPS 0x80 | ||
92 | #define UART01x_LCRH_WLEN_8 0x60 | ||
93 | #define UART01x_LCRH_WLEN_7 0x40 | ||
94 | #define UART01x_LCRH_WLEN_6 0x20 | ||
95 | #define UART01x_LCRH_WLEN_5 0x00 | ||
96 | #define UART01x_LCRH_FEN 0x10 | ||
97 | #define UART01x_LCRH_STP2 0x08 | ||
98 | #define UART01x_LCRH_EPS 0x04 | ||
99 | #define UART01x_LCRH_PEN 0x02 | ||
100 | #define UART01x_LCRH_BRK 0x01 | ||
101 | |||
102 | #define UART010_IIR_RTIS 0x08 | ||
103 | #define UART010_IIR_TIS 0x04 | ||
104 | #define UART010_IIR_RIS 0x02 | ||
105 | #define UART010_IIR_MIS 0x01 | ||
106 | |||
107 | #define UART011_IFLS_RX1_8 (0 << 3) | ||
108 | #define UART011_IFLS_RX2_8 (1 << 3) | ||
109 | #define UART011_IFLS_RX4_8 (2 << 3) | ||
110 | #define UART011_IFLS_RX6_8 (3 << 3) | ||
111 | #define UART011_IFLS_RX7_8 (4 << 3) | ||
112 | #define UART011_IFLS_TX1_8 (0 << 0) | ||
113 | #define UART011_IFLS_TX2_8 (1 << 0) | ||
114 | #define UART011_IFLS_TX4_8 (2 << 0) | ||
115 | #define UART011_IFLS_TX6_8 (3 << 0) | ||
116 | #define UART011_IFLS_TX7_8 (4 << 0) | ||
117 | |||
118 | #define UART011_OEIM (1 << 10) /* overrun error interrupt mask */ | ||
119 | #define UART011_BEIM (1 << 9) /* break error interrupt mask */ | ||
120 | #define UART011_PEIM (1 << 8) /* parity error interrupt mask */ | ||
121 | #define UART011_FEIM (1 << 7) /* framing error interrupt mask */ | ||
122 | #define UART011_RTIM (1 << 6) /* receive timeout interrupt mask */ | ||
123 | #define UART011_TXIM (1 << 5) /* transmit interrupt mask */ | ||
124 | #define UART011_RXIM (1 << 4) /* receive interrupt mask */ | ||
125 | #define UART011_DSRMIM (1 << 3) /* DSR interrupt mask */ | ||
126 | #define UART011_DCDMIM (1 << 2) /* DCD interrupt mask */ | ||
127 | #define UART011_CTSMIM (1 << 1) /* CTS interrupt mask */ | ||
128 | #define UART011_RIMIM (1 << 0) /* RI interrupt mask */ | ||
129 | |||
130 | #define UART011_OEIS (1 << 10) /* overrun error interrupt status */ | ||
131 | #define UART011_BEIS (1 << 9) /* break error interrupt status */ | ||
132 | #define UART011_PEIS (1 << 8) /* parity error interrupt status */ | ||
133 | #define UART011_FEIS (1 << 7) /* framing error interrupt status */ | ||
134 | #define UART011_RTIS (1 << 6) /* receive timeout interrupt status */ | ||
135 | #define UART011_TXIS (1 << 5) /* transmit interrupt status */ | ||
136 | #define UART011_RXIS (1 << 4) /* receive interrupt status */ | ||
137 | #define UART011_DSRMIS (1 << 3) /* DSR interrupt status */ | ||
138 | #define UART011_DCDMIS (1 << 2) /* DCD interrupt status */ | ||
139 | #define UART011_CTSMIS (1 << 1) /* CTS interrupt status */ | ||
140 | #define UART011_RIMIS (1 << 0) /* RI interrupt status */ | ||
141 | |||
142 | #define UART011_OEIC (1 << 10) /* overrun error interrupt clear */ | ||
143 | #define UART011_BEIC (1 << 9) /* break error interrupt clear */ | ||
144 | #define UART011_PEIC (1 << 8) /* parity error interrupt clear */ | ||
145 | #define UART011_FEIC (1 << 7) /* framing error interrupt clear */ | ||
146 | #define UART011_RTIC (1 << 6) /* receive timeout interrupt clear */ | ||
147 | #define UART011_TXIC (1 << 5) /* transmit interrupt clear */ | ||
148 | #define UART011_RXIC (1 << 4) /* receive interrupt clear */ | ||
149 | #define UART011_DSRMIC (1 << 3) /* DSR interrupt clear */ | ||
150 | #define UART011_DCDMIC (1 << 2) /* DCD interrupt clear */ | ||
151 | #define UART011_CTSMIC (1 << 1) /* CTS interrupt clear */ | ||
152 | #define UART011_RIMIC (1 << 0) /* RI interrupt clear */ | ||
153 | |||
154 | #define UART011_DMAONERR (1 << 2) /* disable dma on error */ | ||
155 | #define UART011_TXDMAE (1 << 1) /* enable transmit dma */ | ||
156 | #define UART011_RXDMAE (1 << 0) /* enable receive dma */ | ||
157 | |||
158 | #define UART01x_RSR_ANY (UART01x_RSR_OE|UART01x_RSR_BE|UART01x_RSR_PE|UART01x_RSR_FE) | ||
159 | #define UART01x_FR_MODEM_ANY (UART01x_FR_DCD|UART01x_FR_DSR|UART01x_FR_CTS) | ||
160 | |||
161 | #endif | ||
diff --git a/include/asm-arm/hardware/clock.h b/include/asm-arm/hardware/clock.h deleted file mode 100644 index 19da861e523d..000000000000 --- a/include/asm-arm/hardware/clock.h +++ /dev/null | |||
@@ -1,124 +0,0 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/hardware/clock.h | ||
3 | * | ||
4 | * Copyright (C) 2004 ARM Limited. | ||
5 | * Written by Deep Blue Solutions Limited. | ||
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 | #ifndef ASMARM_CLOCK_H | ||
12 | #define ASMARM_CLOCK_H | ||
13 | |||
14 | struct device; | ||
15 | |||
16 | /* | ||
17 | * The base API. | ||
18 | */ | ||
19 | |||
20 | |||
21 | /* | ||
22 | * struct clk - an machine class defined object / cookie. | ||
23 | */ | ||
24 | struct clk; | ||
25 | |||
26 | /** | ||
27 | * clk_get - lookup and obtain a reference to a clock producer. | ||
28 | * @dev: device for clock "consumer" | ||
29 | * @id: clock comsumer ID | ||
30 | * | ||
31 | * Returns a struct clk corresponding to the clock producer, or | ||
32 | * valid IS_ERR() condition containing errno. The implementation | ||
33 | * uses @dev and @id to determine the clock consumer, and thereby | ||
34 | * the clock producer. (IOW, @id may be identical strings, but | ||
35 | * clk_get may return different clock producers depending on @dev.) | ||
36 | */ | ||
37 | struct clk *clk_get(struct device *dev, const char *id); | ||
38 | |||
39 | /** | ||
40 | * clk_enable - inform the system when the clock source should be running. | ||
41 | * @clk: clock source | ||
42 | * | ||
43 | * If the clock can not be enabled/disabled, this should return success. | ||
44 | * | ||
45 | * Returns success (0) or negative errno. | ||
46 | */ | ||
47 | int clk_enable(struct clk *clk); | ||
48 | |||
49 | /** | ||
50 | * clk_disable - inform the system when the clock source is no longer required. | ||
51 | * @clk: clock source | ||
52 | */ | ||
53 | void clk_disable(struct clk *clk); | ||
54 | |||
55 | /** | ||
56 | * clk_use - increment the use count | ||
57 | * @clk: clock source | ||
58 | * | ||
59 | * Returns success (0) or negative errno. | ||
60 | */ | ||
61 | int clk_use(struct clk *clk); | ||
62 | |||
63 | /** | ||
64 | * clk_unuse - decrement the use count | ||
65 | * @clk: clock source | ||
66 | */ | ||
67 | void clk_unuse(struct clk *clk); | ||
68 | |||
69 | /** | ||
70 | * clk_get_rate - obtain the current clock rate (in Hz) for a clock source. | ||
71 | * This is only valid once the clock source has been enabled. | ||
72 | * @clk: clock source | ||
73 | */ | ||
74 | unsigned long clk_get_rate(struct clk *clk); | ||
75 | |||
76 | /** | ||
77 | * clk_put - "free" the clock source | ||
78 | * @clk: clock source | ||
79 | */ | ||
80 | void clk_put(struct clk *clk); | ||
81 | |||
82 | |||
83 | /* | ||
84 | * The remaining APIs are optional for machine class support. | ||
85 | */ | ||
86 | |||
87 | |||
88 | /** | ||
89 | * clk_round_rate - adjust a rate to the exact rate a clock can provide | ||
90 | * @clk: clock source | ||
91 | * @rate: desired clock rate in Hz | ||
92 | * | ||
93 | * Returns rounded clock rate in Hz, or negative errno. | ||
94 | */ | ||
95 | long clk_round_rate(struct clk *clk, unsigned long rate); | ||
96 | |||
97 | /** | ||
98 | * clk_set_rate - set the clock rate for a clock source | ||
99 | * @clk: clock source | ||
100 | * @rate: desired clock rate in Hz | ||
101 | * | ||
102 | * Returns success (0) or negative errno. | ||
103 | */ | ||
104 | int clk_set_rate(struct clk *clk, unsigned long rate); | ||
105 | |||
106 | /** | ||
107 | * clk_set_parent - set the parent clock source for this clock | ||
108 | * @clk: clock source | ||
109 | * @parent: parent clock source | ||
110 | * | ||
111 | * Returns success (0) or negative errno. | ||
112 | */ | ||
113 | int clk_set_parent(struct clk *clk, struct clk *parent); | ||
114 | |||
115 | /** | ||
116 | * clk_get_parent - get the parent clock source for this clock | ||
117 | * @clk: clock source | ||
118 | * | ||
119 | * Returns struct clk corresponding to parent clock source, or | ||
120 | * valid IS_ERR() condition containing errno. | ||
121 | */ | ||
122 | struct clk *clk_get_parent(struct clk *clk); | ||
123 | |||
124 | #endif | ||
diff --git a/include/asm-arm/hardware/sharpsl_pm.h b/include/asm-arm/hardware/sharpsl_pm.h new file mode 100644 index 000000000000..36983e5f3665 --- /dev/null +++ b/include/asm-arm/hardware/sharpsl_pm.h | |||
@@ -0,0 +1,94 @@ | |||
1 | /* | ||
2 | * SharpSL Battery/PM Driver | ||
3 | * | ||
4 | * Copyright (c) 2004-2005 Richard Purdie | ||
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 | |||
12 | #include <linux/interrupt.h> | ||
13 | |||
14 | struct sharpsl_charger_machinfo { | ||
15 | void (*init)(void); | ||
16 | void (*exit)(void); | ||
17 | int gpio_acin; | ||
18 | int gpio_batfull; | ||
19 | int gpio_batlock; | ||
20 | int gpio_fatal; | ||
21 | void (*discharge)(int); | ||
22 | void (*discharge1)(int); | ||
23 | void (*charge)(int); | ||
24 | void (*measure_temp)(int); | ||
25 | void (*presuspend)(void); | ||
26 | void (*postsuspend)(void); | ||
27 | unsigned long (*read_devdata)(int); | ||
28 | #define SHARPSL_BATT_VOLT 1 | ||
29 | #define SHARPSL_BATT_TEMP 2 | ||
30 | #define SHARPSL_ACIN_VOLT 3 | ||
31 | #define SHARPSL_STATUS_ACIN 4 | ||
32 | #define SHARPSL_STATUS_LOCK 5 | ||
33 | #define SHARPSL_STATUS_CHRGFULL 6 | ||
34 | #define SHARPSL_STATUS_FATAL 7 | ||
35 | unsigned long (*charger_wakeup)(void); | ||
36 | int (*should_wakeup)(unsigned int resume_on_alarm); | ||
37 | int bat_levels; | ||
38 | struct battery_thresh *bat_levels_noac; | ||
39 | struct battery_thresh *bat_levels_acin; | ||
40 | int status_high_acin; | ||
41 | int status_low_acin; | ||
42 | int status_high_noac; | ||
43 | int status_low_noac; | ||
44 | }; | ||
45 | |||
46 | struct battery_thresh { | ||
47 | int voltage; | ||
48 | int percentage; | ||
49 | }; | ||
50 | |||
51 | struct battery_stat { | ||
52 | int ac_status; /* APM AC Present/Not Present */ | ||
53 | int mainbat_status; /* APM Main Battery Status */ | ||
54 | int mainbat_percent; /* Main Battery Percentage Charge */ | ||
55 | int mainbat_voltage; /* Main Battery Voltage */ | ||
56 | }; | ||
57 | |||
58 | struct sharpsl_pm_status { | ||
59 | struct device *dev; | ||
60 | struct timer_list ac_timer; | ||
61 | struct timer_list chrg_full_timer; | ||
62 | |||
63 | int charge_mode; | ||
64 | #define CHRG_ERROR (-1) | ||
65 | #define CHRG_OFF (0) | ||
66 | #define CHRG_ON (1) | ||
67 | #define CHRG_DONE (2) | ||
68 | |||
69 | unsigned int flags; | ||
70 | #define SHARPSL_SUSPENDED (1 << 0) /* Device is Suspended */ | ||
71 | #define SHARPSL_ALARM_ACTIVE (1 << 1) /* Alarm is for charging event (not user) */ | ||
72 | #define SHARPSL_BL_LIMIT (1 << 2) /* Backlight Intensity Limited */ | ||
73 | #define SHARPSL_APM_QUEUED (1 << 3) /* APM Event Queued */ | ||
74 | #define SHARPSL_DO_OFFLINE_CHRG (1 << 4) /* Trigger the offline charger */ | ||
75 | |||
76 | int full_count; | ||
77 | unsigned long charge_start_time; | ||
78 | struct sharpsl_charger_machinfo *machinfo; | ||
79 | struct battery_stat battstat; | ||
80 | }; | ||
81 | |||
82 | extern struct sharpsl_pm_status sharpsl_pm; | ||
83 | |||
84 | |||
85 | #define SHARPSL_LED_ERROR 2 | ||
86 | #define SHARPSL_LED_ON 1 | ||
87 | #define SHARPSL_LED_OFF 0 | ||
88 | |||
89 | void sharpsl_battery_kick(void); | ||
90 | void sharpsl_pm_led(int val); | ||
91 | irqreturn_t sharpsl_ac_isr(int irq, void *dev_id, struct pt_regs *fp); | ||
92 | irqreturn_t sharpsl_chrg_full_isr(int irq, void *dev_id, struct pt_regs *fp); | ||
93 | irqreturn_t sharpsl_fatal_isr(int irq, void *dev_id, struct pt_regs *fp); | ||
94 | |||
diff --git a/include/asm-arm/mach/dma.h b/include/asm-arm/mach/dma.h index 31bf716106ee..e7c4a20aad53 100644 --- a/include/asm-arm/mach/dma.h +++ b/include/asm-arm/mach/dma.h | |||
@@ -25,13 +25,15 @@ struct dma_ops { | |||
25 | }; | 25 | }; |
26 | 26 | ||
27 | struct dma_struct { | 27 | struct dma_struct { |
28 | void *addr; /* single DMA address */ | ||
29 | unsigned long count; /* single DMA size */ | ||
28 | struct scatterlist buf; /* single DMA */ | 30 | struct scatterlist buf; /* single DMA */ |
29 | int sgcount; /* number of DMA SG */ | 31 | int sgcount; /* number of DMA SG */ |
30 | struct scatterlist *sg; /* DMA Scatter-Gather List */ | 32 | struct scatterlist *sg; /* DMA Scatter-Gather List */ |
31 | 33 | ||
32 | unsigned int active:1; /* Transfer active */ | 34 | unsigned int active:1; /* Transfer active */ |
33 | unsigned int invalid:1; /* Address/Count changed */ | 35 | unsigned int invalid:1; /* Address/Count changed */ |
34 | unsigned int using_sg:1; /* using scatter list? */ | 36 | |
35 | dmamode_t dma_mode; /* DMA mode */ | 37 | dmamode_t dma_mode; /* DMA mode */ |
36 | int speed; /* DMA speed */ | 38 | int speed; /* DMA speed */ |
37 | 39 | ||
diff --git a/include/asm-arm/scatterlist.h b/include/asm-arm/scatterlist.h index 83b876fb04cc..de2f65eb42ed 100644 --- a/include/asm-arm/scatterlist.h +++ b/include/asm-arm/scatterlist.h | |||
@@ -9,7 +9,6 @@ struct scatterlist { | |||
9 | unsigned int offset; /* buffer offset */ | 9 | unsigned int offset; /* buffer offset */ |
10 | dma_addr_t dma_address; /* dma address */ | 10 | dma_addr_t dma_address; /* dma address */ |
11 | unsigned int length; /* length */ | 11 | unsigned int length; /* length */ |
12 | char *__address; /* for set_dma_addr */ | ||
13 | }; | 12 | }; |
14 | 13 | ||
15 | /* | 14 | /* |