diff options
Diffstat (limited to 'include/asm-arm')
68 files changed, 593 insertions, 147 deletions
diff --git a/include/asm-arm/arch-aaec2000/aaec2000.h b/include/asm-arm/arch-aaec2000/aaec2000.h index 0e9b7e18af05..002227924b9f 100644 --- a/include/asm-arm/arch-aaec2000/aaec2000.h +++ b/include/asm-arm/arch-aaec2000/aaec2000.h | |||
@@ -17,6 +17,16 @@ | |||
17 | #error You must include hardware.h not this file | 17 | #error You must include hardware.h not this file |
18 | #endif /* __ASM_ARCH_HARDWARE_H */ | 18 | #endif /* __ASM_ARCH_HARDWARE_H */ |
19 | 19 | ||
20 | /* Chip selects */ | ||
21 | #define AAEC_CS0 0x00000000 | ||
22 | #define AAEC_CS1 0x10000000 | ||
23 | #define AAEC_CS2 0x20000000 | ||
24 | #define AAEC_CS3 0x30000000 | ||
25 | |||
26 | /* Flash */ | ||
27 | #define AAEC_FLASH_BASE AAEC_CS0 | ||
28 | #define AAEC_FLASH_SIZE SZ_64M | ||
29 | |||
20 | /* Interrupt controller */ | 30 | /* Interrupt controller */ |
21 | #define IRQ_BASE __REG(0x80000500) | 31 | #define IRQ_BASE __REG(0x80000500) |
22 | #define IRQ_INTSR __REG(0x80000500) /* Int Status Register */ | 32 | #define IRQ_INTSR __REG(0x80000500) /* Int Status Register */ |
@@ -148,4 +158,50 @@ | |||
148 | #define POWER_STFCLR __REG(0x8000041c) /* NbFlg, RSTFlg, PFFlg, CLDFlg Clear */ | 158 | #define POWER_STFCLR __REG(0x8000041c) /* NbFlg, RSTFlg, PFFlg, CLDFlg Clear */ |
149 | #define POWER_CLKSET __REG(0x80000420) /* Clock Speed Control */ | 159 | #define POWER_CLKSET __REG(0x80000420) /* Clock Speed Control */ |
150 | 160 | ||
161 | /* GPIO Registers */ | ||
162 | #define AAEC_GPIO_PHYS 0x80000e00 | ||
163 | |||
164 | #define AAEC_GPIO_PADR __REG(AAEC_GPIO_PHYS + 0x00) | ||
165 | #define AAEC_GPIO_PBDR __REG(AAEC_GPIO_PHYS + 0x04) | ||
166 | #define AAEC_GPIO_PCDR __REG(AAEC_GPIO_PHYS + 0x08) | ||
167 | #define AAEC_GPIO_PDDR __REG(AAEC_GPIO_PHYS + 0x0c) | ||
168 | #define AAEC_GPIO_PADDR __REG(AAEC_GPIO_PHYS + 0x10) | ||
169 | #define AAEC_GPIO_PBDDR __REG(AAEC_GPIO_PHYS + 0x14) | ||
170 | #define AAEC_GPIO_PCDDR __REG(AAEC_GPIO_PHYS + 0x18) | ||
171 | #define AAEC_GPIO_PDDDR __REG(AAEC_GPIO_PHYS + 0x1c) | ||
172 | #define AAEC_GPIO_PEDR __REG(AAEC_GPIO_PHYS + 0x20) | ||
173 | #define AAEC_GPIO_PEDDR __REG(AAEC_GPIO_PHYS + 0x24) | ||
174 | #define AAEC_GPIO_KSCAN __REG(AAEC_GPIO_PHYS + 0x28) | ||
175 | #define AAEC_GPIO_PINMUX __REG(AAEC_GPIO_PHYS + 0x2c) | ||
176 | #define AAEC_GPIO_PFDR __REG(AAEC_GPIO_PHYS + 0x30) | ||
177 | #define AAEC_GPIO_PFDDR __REG(AAEC_GPIO_PHYS + 0x34) | ||
178 | #define AAEC_GPIO_PGDR __REG(AAEC_GPIO_PHYS + 0x38) | ||
179 | #define AAEC_GPIO_PGDDR __REG(AAEC_GPIO_PHYS + 0x3c) | ||
180 | #define AAEC_GPIO_PHDR __REG(AAEC_GPIO_PHYS + 0x40) | ||
181 | #define AAEC_GPIO_PHDDR __REG(AAEC_GPIO_PHYS + 0x44) | ||
182 | #define AAEC_GPIO_RAZ __REG(AAEC_GPIO_PHYS + 0x48) | ||
183 | #define AAEC_GPIO_INTTYPE1 __REG(AAEC_GPIO_PHYS + 0x4c) | ||
184 | #define AAEC_GPIO_INTTYPE2 __REG(AAEC_GPIO_PHYS + 0x50) | ||
185 | #define AAEC_GPIO_FEOI __REG(AAEC_GPIO_PHYS + 0x54) | ||
186 | #define AAEC_GPIO_INTEN __REG(AAEC_GPIO_PHYS + 0x58) | ||
187 | #define AAEC_GPIO_INTSTATUS __REG(AAEC_GPIO_PHYS + 0x5c) | ||
188 | #define AAEC_GPIO_RAWINTSTATUS __REG(AAEC_GPIO_PHYS + 0x60) | ||
189 | #define AAEC_GPIO_DB __REG(AAEC_GPIO_PHYS + 0x64) | ||
190 | #define AAEC_GPIO_PAPINDR __REG(AAEC_GPIO_PHYS + 0x68) | ||
191 | #define AAEC_GPIO_PBPINDR __REG(AAEC_GPIO_PHYS + 0x6c) | ||
192 | #define AAEC_GPIO_PCPINDR __REG(AAEC_GPIO_PHYS + 0x70) | ||
193 | #define AAEC_GPIO_PDPINDR __REG(AAEC_GPIO_PHYS + 0x74) | ||
194 | #define AAEC_GPIO_PEPINDR __REG(AAEC_GPIO_PHYS + 0x78) | ||
195 | #define AAEC_GPIO_PFPINDR __REG(AAEC_GPIO_PHYS + 0x7c) | ||
196 | #define AAEC_GPIO_PGPINDR __REG(AAEC_GPIO_PHYS + 0x80) | ||
197 | #define AAEC_GPIO_PHPINDR __REG(AAEC_GPIO_PHYS + 0x84) | ||
198 | |||
199 | #define AAEC_GPIO_PINMUX_PE0CON (1 << 0) | ||
200 | #define AAEC_GPIO_PINMUX_PD0CON (1 << 1) | ||
201 | #define AAEC_GPIO_PINMUX_CODECON (1 << 2) | ||
202 | #define AAEC_GPIO_PINMUX_UART3CON (1 << 3) | ||
203 | |||
204 | /* LCD Controller */ | ||
205 | #define AAEC_CLCD_PHYS 0x80003000 | ||
206 | |||
151 | #endif /* __ARM_ARCH_AAEC2000_H */ | 207 | #endif /* __ARM_ARCH_AAEC2000_H */ |
diff --git a/include/asm-arm/arch-aaec2000/aaed2000.h b/include/asm-arm/arch-aaec2000/aaed2000.h new file mode 100644 index 000000000000..bc76d2badb91 --- /dev/null +++ b/include/asm-arm/arch-aaec2000/aaed2000.h | |||
@@ -0,0 +1,40 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-aaec2000/aaed2000.h | ||
3 | * | ||
4 | * AAED-2000 specific bits definition | ||
5 | * | ||
6 | * Copyright (c) 2005 Nicolas Bellido Y Ortega | ||
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 | #ifndef __ASM_ARCH_AAED2000_H | ||
14 | #define __ASM_ARCH_AAED2000_H | ||
15 | |||
16 | /* External GPIOs. */ | ||
17 | |||
18 | #define EXT_GPIO_PBASE AAEC_CS3 | ||
19 | #define EXT_GPIO_VBASE 0xf8100000 | ||
20 | #define EXT_GPIO_LENGTH 0x00001000 | ||
21 | |||
22 | #define __ext_gpio_p2v(x) ((x) - EXT_GPIO_PBASE + EXT_GPIO_VBASE) | ||
23 | #define __ext_gpio_v2p(x) ((x) + EXT_GPIO_PBASE - EXT_GPIO_VBASE) | ||
24 | |||
25 | #define __EXT_GPIO_REG(x) (*((volatile u32 *)__ext_gpio_p2v(x))) | ||
26 | #define __EXT_GPIO_PREG(x) (__ext_gpio_v2p((u32)&(x))) | ||
27 | |||
28 | #define AAED_EXT_GPIO __EXT_GPIO_REG(EXT_GPIO_PBASE) | ||
29 | |||
30 | #define AAED_EGPIO_KBD_SCAN 0x00003fff /* Keyboard scan data */ | ||
31 | #define AAED_EGPIO_PWR_INT 0x00008fff /* Smart battery charger interrupt */ | ||
32 | #define AAED_EGPIO_SWITCHED 0x000f0000 /* DIP Switches */ | ||
33 | #define AAED_EGPIO_USB_VBUS 0x00400000 /* USB Vbus sense */ | ||
34 | #define AAED_EGPIO_LCD_PWR_EN 0x02000000 /* LCD and backlight PWR enable */ | ||
35 | #define AAED_EGPIO_nLED0 0x20000000 /* LED 0 */ | ||
36 | #define AAED_EGPIO_nLED1 0x20000000 /* LED 1 */ | ||
37 | #define AAED_EGPIO_nLED2 0x20000000 /* LED 2 */ | ||
38 | |||
39 | |||
40 | #endif /* __ARM_ARCH_AAED2000_H */ | ||
diff --git a/include/asm-arm/arch-aaec2000/hardware.h b/include/asm-arm/arch-aaec2000/hardware.h index 4c37219e030e..153506fd06ed 100644 --- a/include/asm-arm/arch-aaec2000/hardware.h +++ b/include/asm-arm/arch-aaec2000/hardware.h | |||
@@ -11,7 +11,8 @@ | |||
11 | #ifndef __ASM_ARCH_HARDWARE_H | 11 | #ifndef __ASM_ARCH_HARDWARE_H |
12 | #define __ASM_ARCH_HARDWARE_H | 12 | #define __ASM_ARCH_HARDWARE_H |
13 | 13 | ||
14 | #include <linux/config.h> | 14 | #include <asm/sizes.h> |
15 | #include <asm/arch/aaec2000.h> | ||
15 | 16 | ||
16 | /* The kernel is loaded at physical address 0xf8000000. | 17 | /* The kernel is loaded at physical address 0xf8000000. |
17 | * We map the IO space a bit after | 18 | * We map the IO space a bit after |
diff --git a/include/asm-arm/arch-aaec2000/io.h b/include/asm-arm/arch-aaec2000/io.h index c58a8d10425a..8d67907fd4f0 100644 --- a/include/asm-arm/arch-aaec2000/io.h +++ b/include/asm-arm/arch-aaec2000/io.h | |||
@@ -6,6 +6,8 @@ | |||
6 | #ifndef __ASM_ARM_ARCH_IO_H | 6 | #ifndef __ASM_ARM_ARCH_IO_H |
7 | #define __ASM_ARM_ARCH_IO_H | 7 | #define __ASM_ARM_ARCH_IO_H |
8 | 8 | ||
9 | #include <asm/hardware.h> | ||
10 | |||
9 | #define IO_SPACE_LIMIT 0xffffffff | 11 | #define IO_SPACE_LIMIT 0xffffffff |
10 | 12 | ||
11 | /* | 13 | /* |
diff --git a/include/asm-arm/arch-aaec2000/memory.h b/include/asm-arm/arch-aaec2000/memory.h index 79c90813bc3e..d8209f8911d6 100644 --- a/include/asm-arm/arch-aaec2000/memory.h +++ b/include/asm-arm/arch-aaec2000/memory.h | |||
@@ -13,7 +13,7 @@ | |||
13 | 13 | ||
14 | #include <linux/config.h> | 14 | #include <linux/config.h> |
15 | 15 | ||
16 | #define PHYS_OFFSET (0xf0000000UL) | 16 | #define PHYS_OFFSET UL(0xf0000000) |
17 | 17 | ||
18 | #define __virt_to_bus(x) __virt_to_phys(x) | 18 | #define __virt_to_bus(x) __virt_to_phys(x) |
19 | #define __bus_to_virt(x) __phys_to_virt(x) | 19 | #define __bus_to_virt(x) __phys_to_virt(x) |
diff --git a/include/asm-arm/arch-cl7500/io.h b/include/asm-arm/arch-cl7500/io.h index f0113bc75630..89a33287f4fe 100644 --- a/include/asm-arm/arch-cl7500/io.h +++ b/include/asm-arm/arch-cl7500/io.h | |||
@@ -10,6 +10,8 @@ | |||
10 | #ifndef __ASM_ARM_ARCH_IO_H | 10 | #ifndef __ASM_ARM_ARCH_IO_H |
11 | #define __ASM_ARM_ARCH_IO_H | 11 | #define __ASM_ARM_ARCH_IO_H |
12 | 12 | ||
13 | #include <asm/hardware.h> | ||
14 | |||
13 | #define IO_SPACE_LIMIT 0xffffffff | 15 | #define IO_SPACE_LIMIT 0xffffffff |
14 | 16 | ||
15 | /* | 17 | /* |
diff --git a/include/asm-arm/arch-cl7500/memory.h b/include/asm-arm/arch-cl7500/memory.h index 9776bba8e585..34f40a6cec30 100644 --- a/include/asm-arm/arch-cl7500/memory.h +++ b/include/asm-arm/arch-cl7500/memory.h | |||
@@ -17,7 +17,7 @@ | |||
17 | /* | 17 | /* |
18 | * Physical DRAM offset. | 18 | * Physical DRAM offset. |
19 | */ | 19 | */ |
20 | #define PHYS_OFFSET (0x10000000UL) | 20 | #define PHYS_OFFSET UL(0x10000000) |
21 | 21 | ||
22 | /* | 22 | /* |
23 | * These are exactly the same on the RiscPC as the | 23 | * These are exactly the same on the RiscPC as the |
diff --git a/include/asm-arm/arch-clps711x/hardware.h b/include/asm-arm/arch-clps711x/hardware.h index 1386871e1a5a..f864c367c934 100644 --- a/include/asm-arm/arch-clps711x/hardware.h +++ b/include/asm-arm/arch-clps711x/hardware.h | |||
@@ -235,4 +235,121 @@ | |||
235 | #define CEIVA_PB0_BLK_BTN (1<<0) | 235 | #define CEIVA_PB0_BLK_BTN (1<<0) |
236 | #endif // #if defined (CONFIG_ARCH_CEIVA) | 236 | #endif // #if defined (CONFIG_ARCH_CEIVA) |
237 | 237 | ||
238 | #if defined (CONFIG_MACH_MP1000) | ||
239 | /* NOR FLASH */ | ||
240 | #define MP1000_NIO_BASE 0xf9000000 /* virtual */ | ||
241 | #define MP1000_NIO_START CS0_PHYS_BASE /* physical */ | ||
242 | #define MP1000_NIO_SIZE 0x00400000 | ||
243 | |||
244 | /* DSP Interface */ | ||
245 | #define MP1000_DSP_BASE 0xfa000000 /* virtual */ | ||
246 | #define MP1000_DSP_START CS1_PHYS_BASE /* physical */ | ||
247 | #define MP1000_DSP_SIZE 0x00100000 | ||
248 | |||
249 | /* LCD, DAA/DSP, RTC, DAA RW Reg all in CS2 */ | ||
250 | #define MP1000_LIO_BASE 0xfb000000 /* virtual */ | ||
251 | #define MP1000_LIO_START CS2_PHYS_BASE /* physical */ | ||
252 | #define MP1000_LIO_SIZE 0x00100000 | ||
253 | |||
254 | /* NAND FLASH */ | ||
255 | #define MP1000_FIO_BASE 0xfc000000 /* virtual */ | ||
256 | #define MP1000_FIO_START CS3_PHYS_BASE /* physical */ | ||
257 | #define MP1000_FIO_SIZE 0x00800000 | ||
258 | |||
259 | /* Ethernet */ | ||
260 | #define MP1000_EIO_BASE 0xfd000000 /* virtual */ | ||
261 | #define MP1000_EIO_START CS4_PHYS_BASE /* physical */ | ||
262 | #define MP1000_EIO_SIZE 0x00100000 | ||
263 | |||
264 | #define MP1000_LCD_OFFSET 0x00000000 /* LCD offset in CS2 */ | ||
265 | #define MP1000_DDD_OFFSET 0x00001000 /* DAA/DAI/DSP sft reset offst*/ | ||
266 | #define MP1000_RTC_OFFSET 0x00002000 /* RTC offset in CS2 */ | ||
267 | #define MP1000_DAA_OFFSET 0x00003000 /* DAA RW reg offset in CS2 */ | ||
268 | |||
269 | /* IDE */ | ||
270 | #define MP1000_IDE_BASE 0xfe000000 /* virtual */ | ||
271 | #define MP1000_IDE_START CS5_PHYS_BASE /* physical */ | ||
272 | #define MP1000_IDE_SIZE 0x00100000 /* actually it's only 0x1000 */ | ||
273 | |||
274 | #define IRQ_HARDDISK IRQ_EINT2 | ||
275 | |||
276 | /* | ||
277 | * IDE registers definition | ||
278 | */ | ||
279 | |||
280 | #define IDE_CONTROL_BASE (MP1000_IDE_BASE + 0x1000) | ||
281 | #define IDE_BASE_OFF (MP1000_IDE_BASE) | ||
282 | |||
283 | #define IDE_WRITE_DEVICE_DATA (IDE_BASE_OFF + 0x0) | ||
284 | #define IDE_FEATURES_REGISTER (IDE_BASE_OFF + 0x2) | ||
285 | #define IDE_SECTOR_COUNT_REGISTER (IDE_BASE_OFF + 0x4) | ||
286 | #define IDE_SECTOR_NUMBER_REGISTER (IDE_BASE_OFF + 0x6) | ||
287 | #define IDE_CYLINDER_LOW_REGISTER (IDE_BASE_OFF + 0x8) | ||
288 | #define IDE_CYLINDER_HIGH_REGISTER (IDE_BASE_OFF + 0xa) | ||
289 | #define IDE_DEVICE_HEAD_REGISTER (IDE_BASE_OFF + 0xc) | ||
290 | #define IDE_COMMAND_DATA_REGISTER (IDE_BASE_OFF + 0xe) | ||
291 | #define IDE_DEVICE_CONTROL_REGISTER (IDE_CONTROL_BASE + 0xc) | ||
292 | |||
293 | #define IDE_IRQ IRQ_EINT2 | ||
294 | |||
295 | |||
296 | #define RTC_PORT(x) (MP1000_LIO_BASE+0x2000 + (x*2)) | ||
297 | #define RTC_ALWAYS_BCD 0 | ||
298 | |||
299 | /* | ||
300 | // Definitions of the bit fields in the HwPortA register for the | ||
301 | // MP1000 board. | ||
302 | */ | ||
303 | #define HwPortAKeyboardRow1 0x00000001 | ||
304 | #define HwPortAKeyboardRow2 0x00000002 | ||
305 | #define HwPortAKeyboardRow3 0x00000004 | ||
306 | #define HwPortAKeyboardRow4 0x00000008 | ||
307 | #define HwPortAKeyboardRow5 0x00000010 | ||
308 | #define HwPortAKeyboardRow6 0x00000020 | ||
309 | #define HwPortALCDEnable 0x00000040 | ||
310 | #define HwPortAOffhook 0x00000080 | ||
311 | |||
312 | /* | ||
313 | // Definitions of the bit fields in the HwPortB register for the | ||
314 | // MP1000 board. | ||
315 | */ | ||
316 | #define HwPortBL3Mode 0x00000001 | ||
317 | #define HwPortBL3Clk 0x00000002 | ||
318 | #define HwPortBSClk 0x00000001 | ||
319 | #define HwPortBSData 0x00000002 | ||
320 | #define HwPortBL3Data 0x00000004 | ||
321 | #define HwPortBMute 0x00000008 | ||
322 | #define HwPortBQD0 0x00000010 | ||
323 | #define HwPortBQD1 0x00000020 | ||
324 | #define HwPortBQD2 0x00000040 | ||
325 | #define HwPortBQD3 0x00000080 | ||
326 | |||
327 | /* | ||
328 | // Definitions of the bit fields in the HwPortD register for the | ||
329 | // MP1000 board. | ||
330 | */ | ||
331 | #define HwPortDLED1 0x00000001 | ||
332 | #define HwPortDLED2 0x00000002 | ||
333 | #define HwPortDLED3 0x00000004 | ||
334 | #define HwPortDLED4 0x00000008 | ||
335 | #define HwPortDLED5 0x00000010 | ||
336 | #define HwPortDEECS 0x00000020 | ||
337 | #define HwPortBRTS 0x00000040 | ||
338 | #define HwPortBRI 0x00000080 | ||
339 | |||
340 | |||
341 | /* | ||
342 | // Definitions of the bit fields in the HwPortE register for the | ||
343 | // MP1000 board. | ||
344 | */ | ||
345 | |||
346 | #define HwPortECLE 0x00000001 | ||
347 | #define HwPortESepromDOut 0x00000001 | ||
348 | #define HwPortEALE 0x00000002 | ||
349 | #define HwPortESepromDIn 0x00000002 | ||
350 | #define HwPortENANDCS 0x00000004 | ||
351 | #define HwPortESepromCLK 0x00000004 | ||
352 | |||
353 | #endif // #if defined (CONFIG_MACH_MP1000) | ||
354 | |||
238 | #endif | 355 | #endif |
diff --git a/include/asm-arm/arch-clps711x/io.h b/include/asm-arm/arch-clps711x/io.h index 14d7e8da5453..62613b0e2d96 100644 --- a/include/asm-arm/arch-clps711x/io.h +++ b/include/asm-arm/arch-clps711x/io.h | |||
@@ -20,6 +20,8 @@ | |||
20 | #ifndef __ASM_ARM_ARCH_IO_H | 20 | #ifndef __ASM_ARM_ARCH_IO_H |
21 | #define __ASM_ARM_ARCH_IO_H | 21 | #define __ASM_ARM_ARCH_IO_H |
22 | 22 | ||
23 | #include <asm/hardware.h> | ||
24 | |||
23 | #define IO_SPACE_LIMIT 0xffffffff | 25 | #define IO_SPACE_LIMIT 0xffffffff |
24 | 26 | ||
25 | #define __io(a) ((void __iomem *)(a)) | 27 | #define __io(a) ((void __iomem *)(a)) |
diff --git a/include/asm-arm/arch-clps711x/memory.h b/include/asm-arm/arch-clps711x/memory.h index bd978947db42..61d8717406ce 100644 --- a/include/asm-arm/arch-clps711x/memory.h +++ b/include/asm-arm/arch-clps711x/memory.h | |||
@@ -25,7 +25,7 @@ | |||
25 | /* | 25 | /* |
26 | * Physical DRAM offset. | 26 | * Physical DRAM offset. |
27 | */ | 27 | */ |
28 | #define PHYS_OFFSET (0xc0000000UL) | 28 | #define PHYS_OFFSET UL(0xc0000000) |
29 | 29 | ||
30 | /* | 30 | /* |
31 | * Virtual view <-> DMA view memory address translations | 31 | * Virtual view <-> DMA view memory address translations |
diff --git a/include/asm-arm/arch-clps711x/mp1000-seprom.h b/include/asm-arm/arch-clps711x/mp1000-seprom.h new file mode 100644 index 000000000000..3e5566cf9666 --- /dev/null +++ b/include/asm-arm/arch-clps711x/mp1000-seprom.h | |||
@@ -0,0 +1,77 @@ | |||
1 | #ifndef MP1000_SEPROM_H | ||
2 | #define MP1000_SEPROM_H | ||
3 | |||
4 | /* | ||
5 | * mp1000-seprom.h | ||
6 | * | ||
7 | * | ||
8 | * This file contains the Serial EEPROM definitions for the MP1000 board | ||
9 | * | ||
10 | * Copyright (C) 2005 Comdial Corporation | ||
11 | * | ||
12 | * This program is free software; you can redistribute it and/or modify | ||
13 | * it under the terms of the GNU General Public License as published by | ||
14 | * the Free Software Foundation; either version 2 of the License, or | ||
15 | * (at your option) any later version. | ||
16 | * | ||
17 | * This program is distributed in the hope that it will be useful, | ||
18 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
19 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
20 | * GNU General Public License for more details. | ||
21 | * | ||
22 | * You should have received a copy of the GNU General Public License | ||
23 | * along with this program; if not, write to the Free Software | ||
24 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
25 | * | ||
26 | */ | ||
27 | |||
28 | #define COMMAND_ERASE (0x1C0) | ||
29 | #define COMMAND_ERASE_ALL (0x120) | ||
30 | #define COMMAND_WRITE_DISABLE (0x100) | ||
31 | #define COMMAND_WRITE_ENABLE (0x130) | ||
32 | #define COMMAND_READ (0x180) | ||
33 | #define COMMAND_WRITE (0x140) | ||
34 | #define COMMAND_WRITE_ALL (0x110) | ||
35 | |||
36 | // | ||
37 | // Serial EEPROM data format | ||
38 | // | ||
39 | |||
40 | #define PACKED __attribute__ ((packed)) | ||
41 | |||
42 | typedef struct _EEPROM { | ||
43 | union { | ||
44 | unsigned char eprom_byte_data[128]; | ||
45 | unsigned short eprom_short_data[64]; | ||
46 | struct { | ||
47 | unsigned char version PACKED; // EEPROM Version "1" for now | ||
48 | unsigned char box_id PACKED; // Box ID (Standalone, SOHO, embedded, etc) | ||
49 | unsigned char major_hw_version PACKED; // Major Hardware version (Hex) | ||
50 | unsigned char minor_hw_version PACKED; // Minor Hardware Version (Hex) | ||
51 | unsigned char mfg_id[3] PACKED; // Manufacturer ID (3 character Alphabetic) | ||
52 | unsigned char mfg_serial_number[10] PACKED; // Manufacturer Serial number | ||
53 | unsigned char mfg_date[3] PACKED; // Date of Mfg (Formatted YY:MM:DD) | ||
54 | unsigned char country PACKED; // Country of deployment | ||
55 | unsigned char mac_Address[6] PACKED; // MAC Address | ||
56 | unsigned char oem_string[20] PACKED; // OEM ID string | ||
57 | unsigned short feature_bits1 PACKED; // Feature Bits 1 | ||
58 | unsigned short feature_bits2 PACKED; // Feature Bits 2 | ||
59 | unsigned char filler[75] PACKED; // Unused/Undefined “0” initialized | ||
60 | unsigned short checksum PACKED; // byte accumulated short checksum | ||
61 | } eprom_struct; | ||
62 | } variant; | ||
63 | } eeprom_struct; | ||
64 | |||
65 | /* These settings must be mutually exclusive */ | ||
66 | #define FEATURE_BITS1_DRAMSIZE_16MEG 0x0001 /* 0 signifies 4 MEG system */ | ||
67 | #define FEATURE_BITS1_DRAMSIZE_8MEG 0x0002 /* 1 in bit 1 = 8MEG system */ | ||
68 | #define FEATURE_BITS1_DRAMSIZE_64MEG 0x0004 /* 1 in bit 2 = 64MEG system */ | ||
69 | |||
70 | #define FEATURE_BITS1_CPUIS90MEG 0x0010 | ||
71 | |||
72 | extern void seprom_init(void); | ||
73 | extern eeprom_struct* get_seprom_ptr(void); | ||
74 | extern unsigned char* get_eeprom_mac_address(void); | ||
75 | |||
76 | #endif /* MP1000_SEPROM_H */ | ||
77 | |||
diff --git a/include/asm-arm/arch-ebsa110/memory.h b/include/asm-arm/arch-ebsa110/memory.h index 5a9493e12275..02f144520c10 100644 --- a/include/asm-arm/arch-ebsa110/memory.h +++ b/include/asm-arm/arch-ebsa110/memory.h | |||
@@ -19,7 +19,7 @@ | |||
19 | /* | 19 | /* |
20 | * Physical DRAM offset. | 20 | * Physical DRAM offset. |
21 | */ | 21 | */ |
22 | #define PHYS_OFFSET (0x00000000UL) | 22 | #define PHYS_OFFSET UL(0x00000000) |
23 | 23 | ||
24 | /* | 24 | /* |
25 | * We keep this 1:1 so that we don't interfere | 25 | * We keep this 1:1 so that we don't interfere |
diff --git a/include/asm-arm/arch-ebsa285/io.h b/include/asm-arm/arch-ebsa285/io.h index 70576b17f922..776f9d377057 100644 --- a/include/asm-arm/arch-ebsa285/io.h +++ b/include/asm-arm/arch-ebsa285/io.h | |||
@@ -14,6 +14,8 @@ | |||
14 | #ifndef __ASM_ARM_ARCH_IO_H | 14 | #ifndef __ASM_ARM_ARCH_IO_H |
15 | #define __ASM_ARM_ARCH_IO_H | 15 | #define __ASM_ARM_ARCH_IO_H |
16 | 16 | ||
17 | #include <asm/hardware.h> | ||
18 | |||
17 | #define IO_SPACE_LIMIT 0xffff | 19 | #define IO_SPACE_LIMIT 0xffff |
18 | 20 | ||
19 | /* | 21 | /* |
diff --git a/include/asm-arm/arch-ebsa285/memory.h b/include/asm-arm/arch-ebsa285/memory.h index d0466f9987d3..09e335cd687d 100644 --- a/include/asm-arm/arch-ebsa285/memory.h +++ b/include/asm-arm/arch-ebsa285/memory.h | |||
@@ -46,14 +46,14 @@ extern unsigned long __bus_to_virt(unsigned long); | |||
46 | #if defined(CONFIG_ARCH_FOOTBRIDGE) | 46 | #if defined(CONFIG_ARCH_FOOTBRIDGE) |
47 | 47 | ||
48 | /* Task size and page offset at 3GB */ | 48 | /* Task size and page offset at 3GB */ |
49 | #define TASK_SIZE (0xbf000000UL) | 49 | #define TASK_SIZE UL(0xbf000000) |
50 | #define PAGE_OFFSET (0xc0000000UL) | 50 | #define PAGE_OFFSET UL(0xc0000000) |
51 | 51 | ||
52 | #elif defined(CONFIG_ARCH_CO285) | 52 | #elif defined(CONFIG_ARCH_CO285) |
53 | 53 | ||
54 | /* Task size and page offset at 1.5GB */ | 54 | /* Task size and page offset at 1.5GB */ |
55 | #define TASK_SIZE (0x5f000000UL) | 55 | #define TASK_SIZE UL(0x5f000000) |
56 | #define PAGE_OFFSET (0x60000000UL) | 56 | #define PAGE_OFFSET UL(0x60000000) |
57 | 57 | ||
58 | #else | 58 | #else |
59 | 59 | ||
@@ -64,7 +64,7 @@ extern unsigned long __bus_to_virt(unsigned long); | |||
64 | /* | 64 | /* |
65 | * Physical DRAM offset. | 65 | * Physical DRAM offset. |
66 | */ | 66 | */ |
67 | #define PHYS_OFFSET (0x00000000UL) | 67 | #define PHYS_OFFSET UL(0x00000000) |
68 | 68 | ||
69 | /* | 69 | /* |
70 | * This decides where the kernel will search for a free chunk of vm | 70 | * This decides where the kernel will search for a free chunk of vm |
diff --git a/include/asm-arm/arch-epxa10db/io.h b/include/asm-arm/arch-epxa10db/io.h index 1f0afa257621..9fe100c9d6be 100644 --- a/include/asm-arm/arch-epxa10db/io.h +++ b/include/asm-arm/arch-epxa10db/io.h | |||
@@ -20,6 +20,8 @@ | |||
20 | #ifndef __ASM_ARM_ARCH_IO_H | 20 | #ifndef __ASM_ARM_ARCH_IO_H |
21 | #define __ASM_ARM_ARCH_IO_H | 21 | #define __ASM_ARM_ARCH_IO_H |
22 | 22 | ||
23 | #include <asm/hardware.h> | ||
24 | |||
23 | #define IO_SPACE_LIMIT 0xffff | 25 | #define IO_SPACE_LIMIT 0xffff |
24 | 26 | ||
25 | 27 | ||
diff --git a/include/asm-arm/arch-epxa10db/memory.h b/include/asm-arm/arch-epxa10db/memory.h index 3f86bf7f67f0..999541b6a9f5 100644 --- a/include/asm-arm/arch-epxa10db/memory.h +++ b/include/asm-arm/arch-epxa10db/memory.h | |||
@@ -23,7 +23,7 @@ | |||
23 | /* | 23 | /* |
24 | * Physical DRAM offset. | 24 | * Physical DRAM offset. |
25 | */ | 25 | */ |
26 | #define PHYS_OFFSET (0x00000000UL) | 26 | #define PHYS_OFFSET UL(0x00000000) |
27 | 27 | ||
28 | /* | 28 | /* |
29 | * Virtual view <-> DMA view memory address translations | 29 | * Virtual view <-> DMA view memory address translations |
diff --git a/include/asm-arm/arch-h720x/io.h b/include/asm-arm/arch-h720x/io.h index 68814828c9a7..d3ccfd8172b7 100644 --- a/include/asm-arm/arch-h720x/io.h +++ b/include/asm-arm/arch-h720x/io.h | |||
@@ -14,7 +14,7 @@ | |||
14 | #ifndef __ASM_ARM_ARCH_IO_H | 14 | #ifndef __ASM_ARM_ARCH_IO_H |
15 | #define __ASM_ARM_ARCH_IO_H | 15 | #define __ASM_ARM_ARCH_IO_H |
16 | 16 | ||
17 | #include <asm/arch/hardware.h> | 17 | #include <asm/hardware.h> |
18 | 18 | ||
19 | #define IO_SPACE_LIMIT 0xffffffff | 19 | #define IO_SPACE_LIMIT 0xffffffff |
20 | 20 | ||
diff --git a/include/asm-arm/arch-h720x/memory.h b/include/asm-arm/arch-h720x/memory.h index 5633447af268..4a1bfd78a0fe 100644 --- a/include/asm-arm/arch-h720x/memory.h +++ b/include/asm-arm/arch-h720x/memory.h | |||
@@ -11,7 +11,7 @@ | |||
11 | * Page offset: | 11 | * Page offset: |
12 | * ( 0xc0000000UL ) | 12 | * ( 0xc0000000UL ) |
13 | */ | 13 | */ |
14 | #define PHYS_OFFSET (0x40000000UL) | 14 | #define PHYS_OFFSET UL(0x40000000) |
15 | 15 | ||
16 | /* | 16 | /* |
17 | * Virtual view <-> DMA view memory address translations | 17 | * Virtual view <-> DMA view memory address translations |
diff --git a/include/asm-arm/arch-imx/io.h b/include/asm-arm/arch-imx/io.h index 28a4cca6a4cb..b191cdd05576 100644 --- a/include/asm-arm/arch-imx/io.h +++ b/include/asm-arm/arch-imx/io.h | |||
@@ -20,6 +20,8 @@ | |||
20 | #ifndef __ASM_ARM_ARCH_IO_H | 20 | #ifndef __ASM_ARM_ARCH_IO_H |
21 | #define __ASM_ARM_ARCH_IO_H | 21 | #define __ASM_ARM_ARCH_IO_H |
22 | 22 | ||
23 | #include <asm/hardware.h> | ||
24 | |||
23 | #define IO_SPACE_LIMIT 0xffffffff | 25 | #define IO_SPACE_LIMIT 0xffffffff |
24 | 26 | ||
25 | #define __io(a) ((void __iomem *)(a)) | 27 | #define __io(a) ((void __iomem *)(a)) |
diff --git a/include/asm-arm/arch-imx/memory.h b/include/asm-arm/arch-imx/memory.h index 116a91fa14f1..d09ae32cd2f4 100644 --- a/include/asm-arm/arch-imx/memory.h +++ b/include/asm-arm/arch-imx/memory.h | |||
@@ -21,7 +21,7 @@ | |||
21 | #ifndef __ASM_ARCH_MMU_H | 21 | #ifndef __ASM_ARCH_MMU_H |
22 | #define __ASM_ARCH_MMU_H | 22 | #define __ASM_ARCH_MMU_H |
23 | 23 | ||
24 | #define PHYS_OFFSET (0x08000000UL) | 24 | #define PHYS_OFFSET UL(0x08000000) |
25 | 25 | ||
26 | /* | 26 | /* |
27 | * Virtual view <-> DMA view memory address translations | 27 | * Virtual view <-> DMA view memory address translations |
diff --git a/include/asm-arm/arch-integrator/hardware.h b/include/asm-arm/arch-integrator/hardware.h index be2716eeaa02..6f0947bc500d 100644 --- a/include/asm-arm/arch-integrator/hardware.h +++ b/include/asm-arm/arch-integrator/hardware.h | |||
@@ -33,15 +33,6 @@ | |||
33 | #define IO_SIZE 0x0B000000 // How much? | 33 | #define IO_SIZE 0x0B000000 // How much? |
34 | #define IO_START INTEGRATOR_HDR_BASE // PA of IO | 34 | #define IO_START INTEGRATOR_HDR_BASE // PA of IO |
35 | 35 | ||
36 | /* | ||
37 | * Similar to above, but for PCI addresses (memory, IO, Config and the | ||
38 | * V3 chip itself). WARNING: this has to mirror definitions in platform.h | ||
39 | */ | ||
40 | #define PCI_MEMORY_VADDR 0xe8000000 | ||
41 | #define PCI_CONFIG_VADDR 0xec000000 | ||
42 | #define PCI_V3_VADDR 0xed000000 | ||
43 | #define PCI_IO_VADDR 0xee000000 | ||
44 | |||
45 | #define PCIO_BASE PCI_IO_VADDR | 36 | #define PCIO_BASE PCI_IO_VADDR |
46 | #define PCIMEM_BASE PCI_MEMORY_VADDR | 37 | #define PCIMEM_BASE PCI_MEMORY_VADDR |
47 | 38 | ||
diff --git a/include/asm-arm/arch-integrator/io.h b/include/asm-arm/arch-integrator/io.h index fbea8be67d26..31f2deab51b0 100644 --- a/include/asm-arm/arch-integrator/io.h +++ b/include/asm-arm/arch-integrator/io.h | |||
@@ -22,6 +22,14 @@ | |||
22 | 22 | ||
23 | #define IO_SPACE_LIMIT 0xffff | 23 | #define IO_SPACE_LIMIT 0xffff |
24 | 24 | ||
25 | /* | ||
26 | * WARNING: this has to mirror definitions in platform.h | ||
27 | */ | ||
28 | #define PCI_MEMORY_VADDR 0xe8000000 | ||
29 | #define PCI_CONFIG_VADDR 0xec000000 | ||
30 | #define PCI_V3_VADDR 0xed000000 | ||
31 | #define PCI_IO_VADDR 0xee000000 | ||
32 | |||
25 | #define __io(a) ((void __iomem *)(PCI_IO_VADDR + (a))) | 33 | #define __io(a) ((void __iomem *)(PCI_IO_VADDR + (a))) |
26 | #define __mem_pci(a) (a) | 34 | #define __mem_pci(a) (a) |
27 | #define __mem_isa(a) ((a) + PCI_MEMORY_VADDR) | 35 | #define __mem_isa(a) ((a) + PCI_MEMORY_VADDR) |
diff --git a/include/asm-arm/arch-integrator/memory.h b/include/asm-arm/arch-integrator/memory.h index 2087ea7d28a9..1ab56d783e7c 100644 --- a/include/asm-arm/arch-integrator/memory.h +++ b/include/asm-arm/arch-integrator/memory.h | |||
@@ -23,8 +23,8 @@ | |||
23 | /* | 23 | /* |
24 | * Physical DRAM offset. | 24 | * Physical DRAM offset. |
25 | */ | 25 | */ |
26 | #define PHYS_OFFSET (0x00000000UL) | 26 | #define PHYS_OFFSET UL(0x00000000) |
27 | #define BUS_OFFSET (0x80000000UL) | 27 | #define BUS_OFFSET UL(0x80000000) |
28 | 28 | ||
29 | /* | 29 | /* |
30 | * Virtual view <-> DMA view memory address translations | 30 | * Virtual view <-> DMA view memory address translations |
diff --git a/include/asm-arm/arch-iop3xx/io.h b/include/asm-arm/arch-iop3xx/io.h index 2761dfd8694d..f39046a6ab14 100644 --- a/include/asm-arm/arch-iop3xx/io.h +++ b/include/asm-arm/arch-iop3xx/io.h | |||
@@ -11,6 +11,8 @@ | |||
11 | #ifndef __ASM_ARM_ARCH_IO_H | 11 | #ifndef __ASM_ARM_ARCH_IO_H |
12 | #define __ASM_ARM_ARCH_IO_H | 12 | #define __ASM_ARM_ARCH_IO_H |
13 | 13 | ||
14 | #include <asm/hardware.h> | ||
15 | |||
14 | #define IO_SPACE_LIMIT 0xffffffff | 16 | #define IO_SPACE_LIMIT 0xffffffff |
15 | 17 | ||
16 | #define __io(p) ((void __iomem *)(p)) | 18 | #define __io(p) ((void __iomem *)(p)) |
diff --git a/include/asm-arm/arch-iop3xx/memory.h b/include/asm-arm/arch-iop3xx/memory.h index 45351f5cd904..bc62f4b13235 100644 --- a/include/asm-arm/arch-iop3xx/memory.h +++ b/include/asm-arm/arch-iop3xx/memory.h | |||
@@ -12,9 +12,9 @@ | |||
12 | * Physical DRAM offset. | 12 | * Physical DRAM offset. |
13 | */ | 13 | */ |
14 | #ifndef CONFIG_ARCH_IOP331 | 14 | #ifndef CONFIG_ARCH_IOP331 |
15 | #define PHYS_OFFSET (0xa0000000UL) | 15 | #define PHYS_OFFSET UL(0xa0000000) |
16 | #else | 16 | #else |
17 | #define PHYS_OFFSET (0x00000000UL) | 17 | #define PHYS_OFFSET UL(0x00000000) |
18 | #endif | 18 | #endif |
19 | 19 | ||
20 | /* | 20 | /* |
diff --git a/include/asm-arm/arch-ixp2000/io.h b/include/asm-arm/arch-ixp2000/io.h index 3241cd6f0778..7fbcdf9931ee 100644 --- a/include/asm-arm/arch-ixp2000/io.h +++ b/include/asm-arm/arch-ixp2000/io.h | |||
@@ -15,6 +15,8 @@ | |||
15 | #ifndef __ASM_ARM_ARCH_IO_H | 15 | #ifndef __ASM_ARM_ARCH_IO_H |
16 | #define __ASM_ARM_ARCH_IO_H | 16 | #define __ASM_ARM_ARCH_IO_H |
17 | 17 | ||
18 | #include <asm/hardware.h> | ||
19 | |||
18 | #define IO_SPACE_LIMIT 0xffffffff | 20 | #define IO_SPACE_LIMIT 0xffffffff |
19 | #define __mem_pci(a) (a) | 21 | #define __mem_pci(a) (a) |
20 | 22 | ||
diff --git a/include/asm-arm/arch-ixp2000/ixdp2x01.h b/include/asm-arm/arch-ixp2000/ixdp2x01.h index b768009c3a51..c6d51426e98f 100644 --- a/include/asm-arm/arch-ixp2000/ixdp2x01.h +++ b/include/asm-arm/arch-ixp2000/ixdp2x01.h | |||
@@ -22,7 +22,7 @@ | |||
22 | #define IXDP2X01_CPLD_REGION_SIZE 0x00100000 | 22 | #define IXDP2X01_CPLD_REGION_SIZE 0x00100000 |
23 | 23 | ||
24 | #define IXDP2X01_CPLD_VIRT_REG(reg) (volatile unsigned long*)(IXDP2X01_VIRT_CPLD_BASE | reg) | 24 | #define IXDP2X01_CPLD_VIRT_REG(reg) (volatile unsigned long*)(IXDP2X01_VIRT_CPLD_BASE | reg) |
25 | #define IXDP2X01_CPLD_PHYS_REG(reg) (volatile u32*)(IXDP2X01_PHYS_CPLD_BASE | reg) | 25 | #define IXDP2X01_CPLD_PHYS_REG(reg) (IXDP2X01_PHYS_CPLD_BASE | reg) |
26 | 26 | ||
27 | #define IXDP2X01_UART1_VIRT_BASE IXDP2X01_CPLD_VIRT_REG(0x40) | 27 | #define IXDP2X01_UART1_VIRT_BASE IXDP2X01_CPLD_VIRT_REG(0x40) |
28 | #define IXDP2X01_UART1_PHYS_BASE IXDP2X01_CPLD_PHYS_REG(0x40) | 28 | #define IXDP2X01_UART1_PHYS_BASE IXDP2X01_CPLD_PHYS_REG(0x40) |
diff --git a/include/asm-arm/arch-ixp2000/ixp2000-regs.h b/include/asm-arm/arch-ixp2000/ixp2000-regs.h index 32aece069869..def089d693d2 100644 --- a/include/asm-arm/arch-ixp2000/ixp2000-regs.h +++ b/include/asm-arm/arch-ixp2000/ixp2000-regs.h | |||
@@ -392,4 +392,47 @@ | |||
392 | #define WDT_RESET_ENABLE 0x01000000 | 392 | #define WDT_RESET_ENABLE 0x01000000 |
393 | 393 | ||
394 | 394 | ||
395 | /* | ||
396 | * MSF registers. The IXP2400 and IXP2800 have somewhat different MSF | ||
397 | * units, but the registers that differ between the two don't overlap, | ||
398 | * so we can have one register list for both. | ||
399 | */ | ||
400 | #define IXP2000_MSF_REG(x) ((volatile unsigned long*)(IXP2000_MSF_VIRT_BASE + (x))) | ||
401 | #define IXP2000_MSF_RX_CONTROL IXP2000_MSF_REG(0x0000) | ||
402 | #define IXP2000_MSF_TX_CONTROL IXP2000_MSF_REG(0x0004) | ||
403 | #define IXP2000_MSF_INTERRUPT_STATUS IXP2000_MSF_REG(0x0008) | ||
404 | #define IXP2000_MSF_INTERRUPT_ENABLE IXP2000_MSF_REG(0x000c) | ||
405 | #define IXP2000_MSF_CSIX_TYPE_MAP IXP2000_MSF_REG(0x0010) | ||
406 | #define IXP2000_MSF_FC_EGRESS_STATUS IXP2000_MSF_REG(0x0014) | ||
407 | #define IXP2000_MSF_FC_INGRESS_STATUS IXP2000_MSF_REG(0x0018) | ||
408 | #define IXP2000_MSF_HWM_CONTROL IXP2000_MSF_REG(0x0024) | ||
409 | #define IXP2000_MSF_FC_STATUS_OVERRIDE IXP2000_MSF_REG(0x0028) | ||
410 | #define IXP2000_MSF_CLOCK_CONTROL IXP2000_MSF_REG(0x002c) | ||
411 | #define IXP2000_MSF_RX_PORT_MAP IXP2000_MSF_REG(0x0040) | ||
412 | #define IXP2000_MSF_RBUF_ELEMENT_DONE IXP2000_MSF_REG(0x0044) | ||
413 | #define IXP2000_MSF_RX_MPHY_POLL_LIMIT IXP2000_MSF_REG(0x0048) | ||
414 | #define IXP2000_MSF_RX_CALENDAR_LENGTH IXP2000_MSF_REG(0x0048) | ||
415 | #define IXP2000_MSF_RX_THREAD_FREELIST_TIMEOUT_0 IXP2000_MSF_REG(0x0050) | ||
416 | #define IXP2000_MSF_RX_THREAD_FREELIST_TIMEOUT_1 IXP2000_MSF_REG(0x0054) | ||
417 | #define IXP2000_MSF_RX_THREAD_FREELIST_TIMEOUT_2 IXP2000_MSF_REG(0x0058) | ||
418 | #define IXP2000_MSF_TX_SEQUENCE_0 IXP2000_MSF_REG(0x0060) | ||
419 | #define IXP2000_MSF_TX_SEQUENCE_1 IXP2000_MSF_REG(0x0064) | ||
420 | #define IXP2000_MSF_TX_SEQUENCE_2 IXP2000_MSF_REG(0x0068) | ||
421 | #define IXP2000_MSF_TX_MPHY_POLL_LIMIT IXP2000_MSF_REG(0x0070) | ||
422 | #define IXP2000_MSF_TX_CALENDAR_LENGTH IXP2000_MSF_REG(0x0070) | ||
423 | #define IXP2000_MSF_RX_UP_CONTROL_0 IXP2000_MSF_REG(0x0080) | ||
424 | #define IXP2000_MSF_RX_UP_CONTROL_1 IXP2000_MSF_REG(0x0084) | ||
425 | #define IXP2000_MSF_RX_UP_CONTROL_2 IXP2000_MSF_REG(0x0088) | ||
426 | #define IXP2000_MSF_RX_UP_CONTROL_3 IXP2000_MSF_REG(0x008c) | ||
427 | #define IXP2000_MSF_TX_UP_CONTROL_0 IXP2000_MSF_REG(0x0090) | ||
428 | #define IXP2000_MSF_TX_UP_CONTROL_1 IXP2000_MSF_REG(0x0094) | ||
429 | #define IXP2000_MSF_TX_UP_CONTROL_2 IXP2000_MSF_REG(0x0098) | ||
430 | #define IXP2000_MSF_TX_UP_CONTROL_3 IXP2000_MSF_REG(0x009c) | ||
431 | #define IXP2000_MSF_TRAIN_DATA IXP2000_MSF_REG(0x00a0) | ||
432 | #define IXP2000_MSF_TRAIN_CALENDAR IXP2000_MSF_REG(0x00a4) | ||
433 | #define IXP2000_MSF_TRAIN_FLOW_CONTROL IXP2000_MSF_REG(0x00a8) | ||
434 | #define IXP2000_MSF_TX_CALENDAR_0 IXP2000_MSF_REG(0x1000) | ||
435 | #define IXP2000_MSF_RX_PORT_CALENDAR_STATUS IXP2000_MSF_REG(0x1400) | ||
436 | |||
437 | |||
395 | #endif /* _IXP2000_H_ */ | 438 | #endif /* _IXP2000_H_ */ |
diff --git a/include/asm-arm/arch-ixp2000/memory.h b/include/asm-arm/arch-ixp2000/memory.h index d0f415c6dae9..21e1de51e3f6 100644 --- a/include/asm-arm/arch-ixp2000/memory.h +++ b/include/asm-arm/arch-ixp2000/memory.h | |||
@@ -13,7 +13,7 @@ | |||
13 | #ifndef __ASM_ARCH_MEMORY_H | 13 | #ifndef __ASM_ARCH_MEMORY_H |
14 | #define __ASM_ARCH_MEMORY_H | 14 | #define __ASM_ARCH_MEMORY_H |
15 | 15 | ||
16 | #define PHYS_OFFSET (0x00000000UL) | 16 | #define PHYS_OFFSET UL(0x00000000) |
17 | 17 | ||
18 | /* | 18 | /* |
19 | * Virtual view <-> DMA view memory address translations | 19 | * Virtual view <-> DMA view memory address translations |
diff --git a/include/asm-arm/arch-ixp2000/platform.h b/include/asm-arm/arch-ixp2000/platform.h index abdcf51bd283..a66317ab2071 100644 --- a/include/asm-arm/arch-ixp2000/platform.h +++ b/include/asm-arm/arch-ixp2000/platform.h | |||
@@ -15,40 +15,40 @@ | |||
15 | 15 | ||
16 | #ifndef __ASSEMBLY__ | 16 | #ifndef __ASSEMBLY__ |
17 | 17 | ||
18 | static inline unsigned long ixp2000_reg_read(volatile void *reg) | ||
19 | { | ||
20 | return *((volatile unsigned long *)reg); | ||
21 | } | ||
22 | |||
23 | static inline void ixp2000_reg_write(volatile void *reg, unsigned long val) | ||
24 | { | ||
25 | *((volatile unsigned long *)reg) = val; | ||
26 | } | ||
27 | |||
18 | /* | 28 | /* |
19 | * The IXP2400 B0 silicon contains an erratum (#66) that causes writes | 29 | * On the IXP2400, we can't use XCB=000 due to chip bugs. We use |
20 | * to on-chip I/O register to not complete fully. What this means is | 30 | * XCB=101 instead, but that makes all I/O accesses bufferable. This |
21 | * that if you have a write to on-chip I/O followed by a back-to-back | 31 | * is not a problem in general, but we do have to be slightly more |
22 | * read or write, the first write will happen twice. OR...if it's | 32 | * careful because I/O writes are no longer automatically flushed out |
23 | * not a back-to-back transaction, the read or write will generate | 33 | * of the write buffer. |
24 | * incorrect data. | ||
25 | * | ||
26 | * The official work around for this is to set the on-chip I/O regions | ||
27 | * as XCB=101 and then force a read-back from the register. | ||
28 | * | 34 | * |
35 | * In cases where we want to make sure that a write has been flushed | ||
36 | * out of the write buffer before we proceed, for example when masking | ||
37 | * a device interrupt before re-enabling IRQs in CPSR, we can use this | ||
38 | * function, ixp2000_reg_wrb, which performs a write, a readback, and | ||
39 | * issues a dummy instruction dependent on the value of the readback | ||
40 | * (mov rX, rX) to make sure that the readback has completed before we | ||
41 | * continue. | ||
29 | */ | 42 | */ |
30 | #if defined(CONFIG_ARCH_ENP2611) || defined(CONFIG_ARCH_IXDP2400) || defined(CONFIG_ARCH_IXDP2401) | 43 | static inline void ixp2000_reg_wrb(volatile void *reg, unsigned long val) |
31 | |||
32 | #include <asm/system.h> /* Pickup local_irq_ functions */ | ||
33 | |||
34 | static inline void ixp2000_reg_write(volatile void *reg, unsigned long val) | ||
35 | { | 44 | { |
36 | unsigned long dummy; | 45 | unsigned long dummy; |
37 | unsigned long flags; | ||
38 | 46 | ||
39 | local_irq_save(flags); | ||
40 | *((volatile unsigned long *)reg) = val; | 47 | *((volatile unsigned long *)reg) = val; |
41 | barrier(); | 48 | |
42 | dummy = *((volatile unsigned long *)reg); | 49 | dummy = *((volatile unsigned long *)reg); |
43 | local_irq_restore(flags); | 50 | __asm__ __volatile__("mov %0, %0" : "+r" (dummy)); |
44 | } | ||
45 | #else | ||
46 | static inline void ixp2000_reg_write(volatile void *reg, unsigned long val) | ||
47 | { | ||
48 | *((volatile unsigned long *)reg) = val; | ||
49 | } | 51 | } |
50 | #endif /* IXDP2400 || IXDP2401 */ | ||
51 | #define ixp2000_reg_read(reg) (*((volatile unsigned long *)reg)) | ||
52 | 52 | ||
53 | /* | 53 | /* |
54 | * Boards may multiplex different devices on the 2nd channel of | 54 | * Boards may multiplex different devices on the 2nd channel of |
diff --git a/include/asm-arm/arch-ixp4xx/io.h b/include/asm-arm/arch-ixp4xx/io.h index e350dcb544e8..80d05ecad2f0 100644 --- a/include/asm-arm/arch-ixp4xx/io.h +++ b/include/asm-arm/arch-ixp4xx/io.h | |||
@@ -113,7 +113,7 @@ __ixp4xx_writeb(u8 value, u32 addr) | |||
113 | } | 113 | } |
114 | 114 | ||
115 | static inline void | 115 | static inline void |
116 | __ixp4xx_writesb(u32 bus_addr, u8 *vaddr, int count) | 116 | __ixp4xx_writesb(u32 bus_addr, const u8 *vaddr, int count) |
117 | { | 117 | { |
118 | while (count--) | 118 | while (count--) |
119 | writeb(*vaddr++, bus_addr); | 119 | writeb(*vaddr++, bus_addr); |
@@ -136,7 +136,7 @@ __ixp4xx_writew(u16 value, u32 addr) | |||
136 | } | 136 | } |
137 | 137 | ||
138 | static inline void | 138 | static inline void |
139 | __ixp4xx_writesw(u32 bus_addr, u16 *vaddr, int count) | 139 | __ixp4xx_writesw(u32 bus_addr, const u16 *vaddr, int count) |
140 | { | 140 | { |
141 | while (count--) | 141 | while (count--) |
142 | writew(*vaddr++, bus_addr); | 142 | writew(*vaddr++, bus_addr); |
@@ -154,7 +154,7 @@ __ixp4xx_writel(u32 value, u32 addr) | |||
154 | } | 154 | } |
155 | 155 | ||
156 | static inline void | 156 | static inline void |
157 | __ixp4xx_writesl(u32 bus_addr, u32 *vaddr, int count) | 157 | __ixp4xx_writesl(u32 bus_addr, const u32 *vaddr, int count) |
158 | { | 158 | { |
159 | while (count--) | 159 | while (count--) |
160 | writel(*vaddr++, bus_addr); | 160 | writel(*vaddr++, bus_addr); |
diff --git a/include/asm-arm/arch-ixp4xx/ixp4xx-regs.h b/include/asm-arm/arch-ixp4xx/ixp4xx-regs.h index 004696a95bdb..2b149ed59149 100644 --- a/include/asm-arm/arch-ixp4xx/ixp4xx-regs.h +++ b/include/asm-arm/arch-ixp4xx/ixp4xx-regs.h | |||
@@ -36,11 +36,11 @@ | |||
36 | * | 36 | * |
37 | * 0x6000000 0x00004000 ioremap'd QMgr | 37 | * 0x6000000 0x00004000 ioremap'd QMgr |
38 | * | 38 | * |
39 | * 0xC0000000 0x00001000 0xffbfe000 PCI CFG | 39 | * 0xC0000000 0x00001000 0xffbff000 PCI CFG |
40 | * | 40 | * |
41 | * 0xC4000000 0x00001000 0xffbfd000 EXP CFG | 41 | * 0xC4000000 0x00001000 0xffbfe000 EXP CFG |
42 | * | 42 | * |
43 | * 0xC8000000 0x0000C000 0xffbf2000 On-Chip Peripherals | 43 | * 0xC8000000 0x00013000 0xffbeb000 On-Chip Peripherals |
44 | */ | 44 | */ |
45 | 45 | ||
46 | /* | 46 | /* |
@@ -52,22 +52,22 @@ | |||
52 | * Expansion BUS Configuration registers | 52 | * Expansion BUS Configuration registers |
53 | */ | 53 | */ |
54 | #define IXP4XX_EXP_CFG_BASE_PHYS (0xC4000000) | 54 | #define IXP4XX_EXP_CFG_BASE_PHYS (0xC4000000) |
55 | #define IXP4XX_EXP_CFG_BASE_VIRT (0xFFBFD000) | 55 | #define IXP4XX_EXP_CFG_BASE_VIRT (0xFFBFE000) |
56 | #define IXP4XX_EXP_CFG_REGION_SIZE (0x00001000) | 56 | #define IXP4XX_EXP_CFG_REGION_SIZE (0x00001000) |
57 | 57 | ||
58 | /* | 58 | /* |
59 | * PCI Config registers | 59 | * PCI Config registers |
60 | */ | 60 | */ |
61 | #define IXP4XX_PCI_CFG_BASE_PHYS (0xC0000000) | 61 | #define IXP4XX_PCI_CFG_BASE_PHYS (0xC0000000) |
62 | #define IXP4XX_PCI_CFG_BASE_VIRT (0xFFBFE000) | 62 | #define IXP4XX_PCI_CFG_BASE_VIRT (0xFFBFF000) |
63 | #define IXP4XX_PCI_CFG_REGION_SIZE (0x00001000) | 63 | #define IXP4XX_PCI_CFG_REGION_SIZE (0x00001000) |
64 | 64 | ||
65 | /* | 65 | /* |
66 | * Peripheral space | 66 | * Peripheral space |
67 | */ | 67 | */ |
68 | #define IXP4XX_PERIPHERAL_BASE_PHYS (0xC8000000) | 68 | #define IXP4XX_PERIPHERAL_BASE_PHYS (0xC8000000) |
69 | #define IXP4XX_PERIPHERAL_BASE_VIRT (0xFFBF2000) | 69 | #define IXP4XX_PERIPHERAL_BASE_VIRT (0xFFBEB000) |
70 | #define IXP4XX_PERIPHERAL_REGION_SIZE (0x0000C000) | 70 | #define IXP4XX_PERIPHERAL_REGION_SIZE (0x00013000) |
71 | 71 | ||
72 | /* | 72 | /* |
73 | * Debug UART | 73 | * Debug UART |
@@ -115,25 +115,48 @@ | |||
115 | /* | 115 | /* |
116 | * Peripheral Space Register Region Base Addresses | 116 | * Peripheral Space Register Region Base Addresses |
117 | */ | 117 | */ |
118 | #define IXP4XX_UART1_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x0000) | 118 | #define IXP4XX_UART1_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x0000) |
119 | #define IXP4XX_UART2_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x1000) | 119 | #define IXP4XX_UART2_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x1000) |
120 | #define IXP4XX_PMU_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x2000) | 120 | #define IXP4XX_PMU_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x2000) |
121 | #define IXP4XX_INTC_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x3000) | 121 | #define IXP4XX_INTC_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x3000) |
122 | #define IXP4XX_GPIO_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x4000) | 122 | #define IXP4XX_GPIO_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x4000) |
123 | #define IXP4XX_TIMER_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x5000) | 123 | #define IXP4XX_TIMER_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x5000) |
124 | #define IXP4XX_EthA_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x9000) | 124 | #define IXP4XX_NPEA_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x6000) |
125 | #define IXP4XX_EthB_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0xA000) | 125 | #define IXP4XX_NPEB_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x7000) |
126 | #define IXP4XX_USB_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0xB000) | 126 | #define IXP4XX_NPEC_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x8000) |
127 | 127 | #define IXP4XX_EthB_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x9000) | |
128 | #define IXP4XX_UART1_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x0000) | 128 | #define IXP4XX_EthC_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0xA000) |
129 | #define IXP4XX_UART2_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x1000) | 129 | #define IXP4XX_USB_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0xB000) |
130 | #define IXP4XX_PMU_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x2000) | 130 | /* ixp46X only */ |
131 | #define IXP4XX_INTC_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x3000) | 131 | #define IXP4XX_EthA_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0xC000) |
132 | #define IXP4XX_GPIO_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x4000) | 132 | #define IXP4XX_EthB1_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0xD000) |
133 | #define IXP4XX_TIMER_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x5000) | 133 | #define IXP4XX_EthB2_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0xE000) |
134 | #define IXP4XX_EthA_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x9000) | 134 | #define IXP4XX_EthB3_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0xF000) |
135 | #define IXP4XX_EthB_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0xA000) | 135 | #define IXP4XX_TIMESYNC_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x10000) |
136 | #define IXP4XX_USB_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0xB000) | 136 | #define IXP4XX_I2C_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x11000) |
137 | #define IXP4XX_SSP_BASE_PHYS (IXP4XX_PERIPHERAL_BASE_PHYS + 0x12000) | ||
138 | |||
139 | |||
140 | #define IXP4XX_UART1_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x0000) | ||
141 | #define IXP4XX_UART2_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x1000) | ||
142 | #define IXP4XX_PMU_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x2000) | ||
143 | #define IXP4XX_INTC_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x3000) | ||
144 | #define IXP4XX_GPIO_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x4000) | ||
145 | #define IXP4XX_TIMER_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x5000) | ||
146 | #define IXP4XX_NPEA_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_PHYS + 0x6000) | ||
147 | #define IXP4XX_NPEB_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_PHYS + 0x7000) | ||
148 | #define IXP4XX_NPEC_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_PHYS + 0x8000) | ||
149 | #define IXP4XX_EthB_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x9000) | ||
150 | #define IXP4XX_EthC_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0xA000) | ||
151 | #define IXP4XX_USB_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0xB000) | ||
152 | /* ixp46X only */ | ||
153 | #define IXP4XX_EthA_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0xC000) | ||
154 | #define IXP4XX_EthB1_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0xD000) | ||
155 | #define IXP4XX_EthB2_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0xE000) | ||
156 | #define IXP4XX_EthB3_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0xF000) | ||
157 | #define IXP4XX_TIMESYNC_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x10000) | ||
158 | #define IXP4XX_I2C_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x11000) | ||
159 | #define IXP4XX_SSP_BASE_VIRT (IXP4XX_PERIPHERAL_BASE_VIRT + 0x12000) | ||
137 | 160 | ||
138 | /* | 161 | /* |
139 | * Constants to make it easy to access Interrupt Controller registers | 162 | * Constants to make it easy to access Interrupt Controller registers |
diff --git a/include/asm-arm/arch-ixp4xx/memory.h b/include/asm-arm/arch-ixp4xx/memory.h index d348548b592b..e024d0a1a669 100644 --- a/include/asm-arm/arch-ixp4xx/memory.h +++ b/include/asm-arm/arch-ixp4xx/memory.h | |||
@@ -12,7 +12,7 @@ | |||
12 | /* | 12 | /* |
13 | * Physical DRAM offset. | 13 | * Physical DRAM offset. |
14 | */ | 14 | */ |
15 | #define PHYS_OFFSET (0x00000000UL) | 15 | #define PHYS_OFFSET UL(0x00000000) |
16 | 16 | ||
17 | #ifndef __ASSEMBLY__ | 17 | #ifndef __ASSEMBLY__ |
18 | 18 | ||
diff --git a/include/asm-arm/arch-l7200/io.h b/include/asm-arm/arch-l7200/io.h index fc012a39e2cb..cab8ad0adf09 100644 --- a/include/asm-arm/arch-l7200/io.h +++ b/include/asm-arm/arch-l7200/io.h | |||
@@ -10,7 +10,7 @@ | |||
10 | #ifndef __ASM_ARM_ARCH_IO_H | 10 | #ifndef __ASM_ARM_ARCH_IO_H |
11 | #define __ASM_ARM_ARCH_IO_H | 11 | #define __ASM_ARM_ARCH_IO_H |
12 | 12 | ||
13 | #include <asm/arch/hardware.h> | 13 | #include <asm/hardware.h> |
14 | 14 | ||
15 | #define IO_SPACE_LIMIT 0xffffffff | 15 | #define IO_SPACE_LIMIT 0xffffffff |
16 | 16 | ||
diff --git a/include/asm-arm/arch-l7200/memory.h b/include/asm-arm/arch-l7200/memory.h index c5b9608cb137..9e50a171f78a 100644 --- a/include/asm-arm/arch-l7200/memory.h +++ b/include/asm-arm/arch-l7200/memory.h | |||
@@ -15,7 +15,7 @@ | |||
15 | /* | 15 | /* |
16 | * Physical DRAM offset on the L7200 SDB. | 16 | * Physical DRAM offset on the L7200 SDB. |
17 | */ | 17 | */ |
18 | #define PHYS_OFFSET (0xf0000000UL) | 18 | #define PHYS_OFFSET UL(0xf0000000) |
19 | 19 | ||
20 | #define __virt_to_bus(x) __virt_to_phys(x) | 20 | #define __virt_to_bus(x) __virt_to_phys(x) |
21 | #define __bus_to_virt(x) __phys_to_virt(x) | 21 | #define __bus_to_virt(x) __phys_to_virt(x) |
diff --git a/include/asm-arm/arch-lh7a40x/io.h b/include/asm-arm/arch-lh7a40x/io.h index c13bdd9add92..bbcd4335f441 100644 --- a/include/asm-arm/arch-lh7a40x/io.h +++ b/include/asm-arm/arch-lh7a40x/io.h | |||
@@ -11,6 +11,8 @@ | |||
11 | #ifndef __ASM_ARCH_IO_H | 11 | #ifndef __ASM_ARCH_IO_H |
12 | #define __ASM_ARCH_IO_H | 12 | #define __ASM_ARCH_IO_H |
13 | 13 | ||
14 | #include <asm/hardware.h> | ||
15 | |||
14 | #define IO_SPACE_LIMIT 0xffffffff | 16 | #define IO_SPACE_LIMIT 0xffffffff |
15 | 17 | ||
16 | /* No ISA or PCI bus on this machine. */ | 18 | /* No ISA or PCI bus on this machine. */ |
diff --git a/include/asm-arm/arch-lh7a40x/memory.h b/include/asm-arm/arch-lh7a40x/memory.h index c650e6feb9d5..c92bcb837629 100644 --- a/include/asm-arm/arch-lh7a40x/memory.h +++ b/include/asm-arm/arch-lh7a40x/memory.h | |||
@@ -17,7 +17,7 @@ | |||
17 | /* | 17 | /* |
18 | * Physical DRAM offset. | 18 | * Physical DRAM offset. |
19 | */ | 19 | */ |
20 | #define PHYS_OFFSET (0xc0000000UL) | 20 | #define PHYS_OFFSET UL(0xc0000000) |
21 | 21 | ||
22 | /* | 22 | /* |
23 | * Virtual view <-> DMA view memory address translations | 23 | * Virtual view <-> DMA view memory address translations |
diff --git a/include/asm-arm/arch-omap/io.h b/include/asm-arm/arch-omap/io.h index 11fbf629bf75..3d5bcd545082 100644 --- a/include/asm-arm/arch-omap/io.h +++ b/include/asm-arm/arch-omap/io.h | |||
@@ -34,6 +34,8 @@ | |||
34 | #ifndef __ASM_ARM_ARCH_IO_H | 34 | #ifndef __ASM_ARM_ARCH_IO_H |
35 | #define __ASM_ARM_ARCH_IO_H | 35 | #define __ASM_ARM_ARCH_IO_H |
36 | 36 | ||
37 | #include <asm/hardware.h> | ||
38 | |||
37 | #define IO_SPACE_LIMIT 0xffffffff | 39 | #define IO_SPACE_LIMIT 0xffffffff |
38 | 40 | ||
39 | /* | 41 | /* |
diff --git a/include/asm-arm/arch-omap/memory.h b/include/asm-arm/arch-omap/memory.h index ef32d61eec7a..bf545b6e0a26 100644 --- a/include/asm-arm/arch-omap/memory.h +++ b/include/asm-arm/arch-omap/memory.h | |||
@@ -37,9 +37,9 @@ | |||
37 | * Physical DRAM offset. | 37 | * Physical DRAM offset. |
38 | */ | 38 | */ |
39 | #if defined(CONFIG_ARCH_OMAP1) | 39 | #if defined(CONFIG_ARCH_OMAP1) |
40 | #define PHYS_OFFSET (0x10000000UL) | 40 | #define PHYS_OFFSET UL(0x10000000) |
41 | #elif defined(CONFIG_ARCH_OMAP2) | 41 | #elif defined(CONFIG_ARCH_OMAP2) |
42 | #define PHYS_OFFSET (0x80000000UL) | 42 | #define PHYS_OFFSET UL(0x80000000) |
43 | #endif | 43 | #endif |
44 | 44 | ||
45 | /* | 45 | /* |
@@ -66,7 +66,7 @@ | |||
66 | /* | 66 | /* |
67 | * OMAP-1510 Local Bus address offset | 67 | * OMAP-1510 Local Bus address offset |
68 | */ | 68 | */ |
69 | #define OMAP1510_LB_OFFSET (0x30000000UL) | 69 | #define OMAP1510_LB_OFFSET UL(0x30000000) |
70 | 70 | ||
71 | #define virt_to_lbus(x) ((x) - PAGE_OFFSET + OMAP1510_LB_OFFSET) | 71 | #define virt_to_lbus(x) ((x) - PAGE_OFFSET + OMAP1510_LB_OFFSET) |
72 | #define lbus_to_virt(x) ((x) - OMAP1510_LB_OFFSET + PAGE_OFFSET) | 72 | #define lbus_to_virt(x) ((x) - OMAP1510_LB_OFFSET + PAGE_OFFSET) |
diff --git a/include/asm-arm/arch-pxa/hardware.h b/include/asm-arm/arch-pxa/hardware.h index cf35721cfa45..3e70bd95472c 100644 --- a/include/asm-arm/arch-pxa/hardware.h +++ b/include/asm-arm/arch-pxa/hardware.h | |||
@@ -44,12 +44,12 @@ | |||
44 | 44 | ||
45 | #ifndef __ASSEMBLY__ | 45 | #ifndef __ASSEMBLY__ |
46 | 46 | ||
47 | # define __REG(x) (*((volatile unsigned long *)io_p2v(x))) | 47 | # define __REG(x) (*((volatile u32 *)io_p2v(x))) |
48 | 48 | ||
49 | /* With indexed regs we don't want to feed the index through io_p2v() | 49 | /* With indexed regs we don't want to feed the index through io_p2v() |
50 | especially if it is a variable, otherwise horrible code will result. */ | 50 | especially if it is a variable, otherwise horrible code will result. */ |
51 | # define __REG2(x,y) \ | 51 | # define __REG2(x,y) \ |
52 | (*(volatile unsigned long *)((unsigned long)&__REG(x) + (y))) | 52 | (*(volatile u32 *)((u32)&__REG(x) + (y))) |
53 | 53 | ||
54 | # define __PREG(x) (io_v2p((u32)&(x))) | 54 | # define __PREG(x) (io_v2p((u32)&(x))) |
55 | 55 | ||
diff --git a/include/asm-arm/arch-pxa/io.h b/include/asm-arm/arch-pxa/io.h index c3bdbe44e21f..eb2dd58d397f 100644 --- a/include/asm-arm/arch-pxa/io.h +++ b/include/asm-arm/arch-pxa/io.h | |||
@@ -6,6 +6,8 @@ | |||
6 | #ifndef __ASM_ARM_ARCH_IO_H | 6 | #ifndef __ASM_ARM_ARCH_IO_H |
7 | #define __ASM_ARM_ARCH_IO_H | 7 | #define __ASM_ARM_ARCH_IO_H |
8 | 8 | ||
9 | #include <asm/hardware.h> | ||
10 | |||
9 | #define IO_SPACE_LIMIT 0xffffffff | 11 | #define IO_SPACE_LIMIT 0xffffffff |
10 | 12 | ||
11 | /* | 13 | /* |
diff --git a/include/asm-arm/arch-pxa/irda.h b/include/asm-arm/arch-pxa/irda.h new file mode 100644 index 000000000000..748406f384c2 --- /dev/null +++ b/include/asm-arm/arch-pxa/irda.h | |||
@@ -0,0 +1,17 @@ | |||
1 | #ifndef ASMARM_ARCH_IRDA_H | ||
2 | #define ASMARM_ARCH_IRDA_H | ||
3 | |||
4 | /* board specific transceiver capabilities */ | ||
5 | |||
6 | #define IR_OFF 1 | ||
7 | #define IR_SIRMODE 2 | ||
8 | #define IR_FIRMODE 4 | ||
9 | |||
10 | struct pxaficp_platform_data { | ||
11 | int transceiver_cap; | ||
12 | void (*transceiver_mode)(struct device *dev, int mode); | ||
13 | }; | ||
14 | |||
15 | extern void pxa_set_ficp_info(struct pxaficp_platform_data *info); | ||
16 | |||
17 | #endif | ||
diff --git a/include/asm-arm/arch-pxa/memory.h b/include/asm-arm/arch-pxa/memory.h index 58bad9748b5c..eaf6d43939e9 100644 --- a/include/asm-arm/arch-pxa/memory.h +++ b/include/asm-arm/arch-pxa/memory.h | |||
@@ -15,7 +15,7 @@ | |||
15 | /* | 15 | /* |
16 | * Physical DRAM offset. | 16 | * Physical DRAM offset. |
17 | */ | 17 | */ |
18 | #define PHYS_OFFSET (0xa0000000UL) | 18 | #define PHYS_OFFSET UL(0xa0000000) |
19 | 19 | ||
20 | /* | 20 | /* |
21 | * Virtual view <-> DMA view memory address translations | 21 | * Virtual view <-> DMA view memory address translations |
diff --git a/include/asm-arm/arch-pxa/pxa-regs.h b/include/asm-arm/arch-pxa/pxa-regs.h index 3af7165ab0d7..a75a2470f4f5 100644 --- a/include/asm-arm/arch-pxa/pxa-regs.h +++ b/include/asm-arm/arch-pxa/pxa-regs.h | |||
@@ -326,6 +326,25 @@ | |||
326 | #define STDLL __REG(0x40700000) /* Divisor Latch Low Register (DLAB = 1) (read/write) */ | 326 | #define STDLL __REG(0x40700000) /* Divisor Latch Low Register (DLAB = 1) (read/write) */ |
327 | #define STDLH __REG(0x40700004) /* Divisor Latch High Register (DLAB = 1) (read/write) */ | 327 | #define STDLH __REG(0x40700004) /* Divisor Latch High Register (DLAB = 1) (read/write) */ |
328 | 328 | ||
329 | /* Hardware UART (HWUART) */ | ||
330 | #define HWUART HWRBR | ||
331 | #define HWRBR __REG(0x41600000) /* Receive Buffer Register (read only) */ | ||
332 | #define HWTHR __REG(0x41600000) /* Transmit Holding Register (write only) */ | ||
333 | #define HWIER __REG(0x41600004) /* Interrupt Enable Register (read/write) */ | ||
334 | #define HWIIR __REG(0x41600008) /* Interrupt ID Register (read only) */ | ||
335 | #define HWFCR __REG(0x41600008) /* FIFO Control Register (write only) */ | ||
336 | #define HWLCR __REG(0x4160000C) /* Line Control Register (read/write) */ | ||
337 | #define HWMCR __REG(0x41600010) /* Modem Control Register (read/write) */ | ||
338 | #define HWLSR __REG(0x41600014) /* Line Status Register (read only) */ | ||
339 | #define HWMSR __REG(0x41600018) /* Modem Status Register (read only) */ | ||
340 | #define HWSPR __REG(0x4160001C) /* Scratch Pad Register (read/write) */ | ||
341 | #define HWISR __REG(0x41600020) /* Infrared Selection Register (read/write) */ | ||
342 | #define HWFOR __REG(0x41600024) /* Receive FIFO Occupancy Register (read only) */ | ||
343 | #define HWABR __REG(0x41600028) /* Auto-Baud Control Register (read/write) */ | ||
344 | #define HWACR __REG(0x4160002C) /* Auto-Baud Count Register (read only) */ | ||
345 | #define HWDLL __REG(0x41600000) /* Divisor Latch Low Register (DLAB = 1) (read/write) */ | ||
346 | #define HWDLH __REG(0x41600004) /* Divisor Latch High Register (DLAB = 1) (read/write) */ | ||
347 | |||
329 | #define IER_DMAE (1 << 7) /* DMA Requests Enable */ | 348 | #define IER_DMAE (1 << 7) /* DMA Requests Enable */ |
330 | #define IER_UUE (1 << 6) /* UART Unit Enable */ | 349 | #define IER_UUE (1 << 6) /* UART Unit Enable */ |
331 | #define IER_NRZE (1 << 5) /* NRZ coding Enable */ | 350 | #define IER_NRZE (1 << 5) /* NRZ coding Enable */ |
@@ -1013,14 +1032,12 @@ | |||
1013 | #define ICCR0_LBM (1 << 1) /* Loopback mode */ | 1032 | #define ICCR0_LBM (1 << 1) /* Loopback mode */ |
1014 | #define ICCR0_ITR (1 << 0) /* IrDA transmission */ | 1033 | #define ICCR0_ITR (1 << 0) /* IrDA transmission */ |
1015 | 1034 | ||
1016 | #ifdef CONFIG_PXA27x | ||
1017 | #define ICCR2_RXP (1 << 3) /* Receive Pin Polarity select */ | 1035 | #define ICCR2_RXP (1 << 3) /* Receive Pin Polarity select */ |
1018 | #define ICCR2_TXP (1 << 2) /* Transmit Pin Polarity select */ | 1036 | #define ICCR2_TXP (1 << 2) /* Transmit Pin Polarity select */ |
1019 | #define ICCR2_TRIG (3 << 0) /* Receive FIFO Trigger threshold */ | 1037 | #define ICCR2_TRIG (3 << 0) /* Receive FIFO Trigger threshold */ |
1020 | #define ICCR2_TRIG_8 (0 << 0) /* >= 8 bytes */ | 1038 | #define ICCR2_TRIG_8 (0 << 0) /* >= 8 bytes */ |
1021 | #define ICCR2_TRIG_16 (1 << 0) /* >= 16 bytes */ | 1039 | #define ICCR2_TRIG_16 (1 << 0) /* >= 16 bytes */ |
1022 | #define ICCR2_TRIG_32 (2 << 0) /* >= 32 bytes */ | 1040 | #define ICCR2_TRIG_32 (2 << 0) /* >= 32 bytes */ |
1023 | #endif | ||
1024 | 1041 | ||
1025 | #ifdef CONFIG_PXA27x | 1042 | #ifdef CONFIG_PXA27x |
1026 | #define ICSR0_EOC (1 << 6) /* DMA End of Descriptor Chain */ | 1043 | #define ICSR0_EOC (1 << 6) /* DMA End of Descriptor Chain */ |
@@ -1250,9 +1267,13 @@ | |||
1250 | #define GPIO40_FFDTR 40 /* FFUART data terminal Ready */ | 1267 | #define GPIO40_FFDTR 40 /* FFUART data terminal Ready */ |
1251 | #define GPIO41_FFRTS 41 /* FFUART request to send */ | 1268 | #define GPIO41_FFRTS 41 /* FFUART request to send */ |
1252 | #define GPIO42_BTRXD 42 /* BTUART receive data */ | 1269 | #define GPIO42_BTRXD 42 /* BTUART receive data */ |
1270 | #define GPIO42_HWRXD 42 /* HWUART receive data */ | ||
1253 | #define GPIO43_BTTXD 43 /* BTUART transmit data */ | 1271 | #define GPIO43_BTTXD 43 /* BTUART transmit data */ |
1272 | #define GPIO43_HWTXD 43 /* HWUART transmit data */ | ||
1254 | #define GPIO44_BTCTS 44 /* BTUART clear to send */ | 1273 | #define GPIO44_BTCTS 44 /* BTUART clear to send */ |
1274 | #define GPIO44_HWCTS 44 /* HWUART clear to send */ | ||
1255 | #define GPIO45_BTRTS 45 /* BTUART request to send */ | 1275 | #define GPIO45_BTRTS 45 /* BTUART request to send */ |
1276 | #define GPIO45_HWRTS 45 /* HWUART request to send */ | ||
1256 | #define GPIO45_AC97_SYSCLK 45 /* AC97 System Clock */ | 1277 | #define GPIO45_AC97_SYSCLK 45 /* AC97 System Clock */ |
1257 | #define GPIO46_ICPRXD 46 /* ICP receive data */ | 1278 | #define GPIO46_ICPRXD 46 /* ICP receive data */ |
1258 | #define GPIO46_STRXD 46 /* STD_UART receive data */ | 1279 | #define GPIO46_STRXD 46 /* STD_UART receive data */ |
@@ -1378,17 +1399,26 @@ | |||
1378 | #define GPIO40_FFDTR_MD (40 | GPIO_ALT_FN_2_OUT) | 1399 | #define GPIO40_FFDTR_MD (40 | GPIO_ALT_FN_2_OUT) |
1379 | #define GPIO41_FFRTS_MD (41 | GPIO_ALT_FN_2_OUT) | 1400 | #define GPIO41_FFRTS_MD (41 | GPIO_ALT_FN_2_OUT) |
1380 | #define GPIO42_BTRXD_MD (42 | GPIO_ALT_FN_1_IN) | 1401 | #define GPIO42_BTRXD_MD (42 | GPIO_ALT_FN_1_IN) |
1402 | #define GPIO42_HWRXD_MD (42 | GPIO_ALT_FN_3_IN) | ||
1381 | #define GPIO43_BTTXD_MD (43 | GPIO_ALT_FN_2_OUT) | 1403 | #define GPIO43_BTTXD_MD (43 | GPIO_ALT_FN_2_OUT) |
1404 | #define GPIO43_HWTXD_MD (43 | GPIO_ALT_FN_3_OUT) | ||
1382 | #define GPIO44_BTCTS_MD (44 | GPIO_ALT_FN_1_IN) | 1405 | #define GPIO44_BTCTS_MD (44 | GPIO_ALT_FN_1_IN) |
1406 | #define GPIO44_HWCTS_MD (44 | GPIO_ALT_FN_3_IN) | ||
1383 | #define GPIO45_BTRTS_MD (45 | GPIO_ALT_FN_2_OUT) | 1407 | #define GPIO45_BTRTS_MD (45 | GPIO_ALT_FN_2_OUT) |
1408 | #define GPIO45_HWRTS_MD (45 | GPIO_ALT_FN_3_OUT) | ||
1384 | #define GPIO45_SYSCLK_AC97_MD (45 | GPIO_ALT_FN_1_OUT) | 1409 | #define GPIO45_SYSCLK_AC97_MD (45 | GPIO_ALT_FN_1_OUT) |
1385 | #define GPIO46_ICPRXD_MD (46 | GPIO_ALT_FN_1_IN) | 1410 | #define GPIO46_ICPRXD_MD (46 | GPIO_ALT_FN_1_IN) |
1386 | #define GPIO46_STRXD_MD (46 | GPIO_ALT_FN_2_IN) | 1411 | #define GPIO46_STRXD_MD (46 | GPIO_ALT_FN_2_IN) |
1387 | #define GPIO47_ICPTXD_MD (47 | GPIO_ALT_FN_2_OUT) | 1412 | #define GPIO47_ICPTXD_MD (47 | GPIO_ALT_FN_2_OUT) |
1388 | #define GPIO47_STTXD_MD (47 | GPIO_ALT_FN_1_OUT) | 1413 | #define GPIO47_STTXD_MD (47 | GPIO_ALT_FN_1_OUT) |
1389 | #define GPIO48_nPOE_MD (48 | GPIO_ALT_FN_2_OUT) | 1414 | #define GPIO48_nPOE_MD (48 | GPIO_ALT_FN_2_OUT) |
1415 | #define GPIO48_HWTXD_MD (48 | GPIO_ALT_FN_1_OUT) | ||
1416 | #define GPIO48_nPOE_MD (48 | GPIO_ALT_FN_2_OUT) | ||
1417 | #define GPIO49_HWRXD_MD (49 | GPIO_ALT_FN_1_IN) | ||
1390 | #define GPIO49_nPWE_MD (49 | GPIO_ALT_FN_2_OUT) | 1418 | #define GPIO49_nPWE_MD (49 | GPIO_ALT_FN_2_OUT) |
1391 | #define GPIO50_nPIOR_MD (50 | GPIO_ALT_FN_2_OUT) | 1419 | #define GPIO50_nPIOR_MD (50 | GPIO_ALT_FN_2_OUT) |
1420 | #define GPIO50_HWCTS_MD (50 | GPIO_ALT_FN_1_IN) | ||
1421 | #define GPIO51_HWRTS_MD (51 | GPIO_ALT_FN_1_OUT) | ||
1392 | #define GPIO51_nPIOW_MD (51 | GPIO_ALT_FN_2_OUT) | 1422 | #define GPIO51_nPIOW_MD (51 | GPIO_ALT_FN_2_OUT) |
1393 | #define GPIO52_nPCE_1_MD (52 | GPIO_ALT_FN_2_OUT) | 1423 | #define GPIO52_nPCE_1_MD (52 | GPIO_ALT_FN_2_OUT) |
1394 | #define GPIO53_nPCE_2_MD (53 | GPIO_ALT_FN_2_OUT) | 1424 | #define GPIO53_nPCE_2_MD (53 | GPIO_ALT_FN_2_OUT) |
@@ -1763,6 +1793,7 @@ | |||
1763 | #define CKEN7_BTUART (1 << 7) /* BTUART Unit Clock Enable */ | 1793 | #define CKEN7_BTUART (1 << 7) /* BTUART Unit Clock Enable */ |
1764 | #define CKEN6_FFUART (1 << 6) /* FFUART Unit Clock Enable */ | 1794 | #define CKEN6_FFUART (1 << 6) /* FFUART Unit Clock Enable */ |
1765 | #define CKEN5_STUART (1 << 5) /* STUART Unit Clock Enable */ | 1795 | #define CKEN5_STUART (1 << 5) /* STUART Unit Clock Enable */ |
1796 | #define CKEN4_HWUART (1 << 4) /* HWUART Unit Clock Enable */ | ||
1766 | #define CKEN4_SSP3 (1 << 4) /* SSP3 Unit Clock Enable */ | 1797 | #define CKEN4_SSP3 (1 << 4) /* SSP3 Unit Clock Enable */ |
1767 | #define CKEN3_SSP (1 << 3) /* SSP Unit Clock Enable */ | 1798 | #define CKEN3_SSP (1 << 3) /* SSP Unit Clock Enable */ |
1768 | #define CKEN3_SSP2 (1 << 3) /* SSP2 Unit Clock Enable */ | 1799 | #define CKEN3_SSP2 (1 << 3) /* SSP2 Unit Clock Enable */ |
@@ -2282,4 +2313,11 @@ | |||
2282 | 2313 | ||
2283 | #endif | 2314 | #endif |
2284 | 2315 | ||
2316 | /* PWRMODE register M field values */ | ||
2317 | |||
2318 | #define PWRMODE_IDLE 0x1 | ||
2319 | #define PWRMODE_STANDBY 0x2 | ||
2320 | #define PWRMODE_SLEEP 0x3 | ||
2321 | #define PWRMODE_DEEPSLEEP 0x7 | ||
2322 | |||
2285 | #endif | 2323 | #endif |
diff --git a/include/asm-arm/arch-pxa/uncompress.h b/include/asm-arm/arch-pxa/uncompress.h index 4428d3eb7432..fe38090444e0 100644 --- a/include/asm-arm/arch-pxa/uncompress.h +++ b/include/asm-arm/arch-pxa/uncompress.h | |||
@@ -12,6 +12,7 @@ | |||
12 | #define FFUART ((volatile unsigned long *)0x40100000) | 12 | #define FFUART ((volatile unsigned long *)0x40100000) |
13 | #define BTUART ((volatile unsigned long *)0x40200000) | 13 | #define BTUART ((volatile unsigned long *)0x40200000) |
14 | #define STUART ((volatile unsigned long *)0x40700000) | 14 | #define STUART ((volatile unsigned long *)0x40700000) |
15 | #define HWUART ((volatile unsigned long *)0x41600000) | ||
15 | 16 | ||
16 | #define UART FFUART | 17 | #define UART FFUART |
17 | 18 | ||
diff --git a/include/asm-arm/arch-rpc/io.h b/include/asm-arm/arch-rpc/io.h index 24453c405a87..b4da08d7a336 100644 --- a/include/asm-arm/arch-rpc/io.h +++ b/include/asm-arm/arch-rpc/io.h | |||
@@ -13,6 +13,8 @@ | |||
13 | #ifndef __ASM_ARM_ARCH_IO_H | 13 | #ifndef __ASM_ARM_ARCH_IO_H |
14 | #define __ASM_ARM_ARCH_IO_H | 14 | #define __ASM_ARM_ARCH_IO_H |
15 | 15 | ||
16 | #include <asm/hardware.h> | ||
17 | |||
16 | #define IO_SPACE_LIMIT 0xffffffff | 18 | #define IO_SPACE_LIMIT 0xffffffff |
17 | 19 | ||
18 | /* | 20 | /* |
diff --git a/include/asm-arm/arch-rpc/memory.h b/include/asm-arm/arch-rpc/memory.h index 33fc75cdead0..0592cb3f0c74 100644 --- a/include/asm-arm/arch-rpc/memory.h +++ b/include/asm-arm/arch-rpc/memory.h | |||
@@ -21,7 +21,7 @@ | |||
21 | /* | 21 | /* |
22 | * Physical DRAM offset. | 22 | * Physical DRAM offset. |
23 | */ | 23 | */ |
24 | #define PHYS_OFFSET (0x10000000UL) | 24 | #define PHYS_OFFSET UL(0x10000000) |
25 | 25 | ||
26 | /* | 26 | /* |
27 | * These are exactly the same on the RiscPC as the | 27 | * These are exactly the same on the RiscPC as the |
diff --git a/include/asm-arm/arch-s3c2410/fb.h b/include/asm-arm/arch-s3c2410/fb.h index ac57bc887d82..4790491ba9d0 100644 --- a/include/asm-arm/arch-s3c2410/fb.h +++ b/include/asm-arm/arch-s3c2410/fb.h | |||
@@ -13,6 +13,7 @@ | |||
13 | * 07-Sep-2004 RTP Created file | 13 | * 07-Sep-2004 RTP Created file |
14 | * 03-Nov-2004 BJD Updated and minor cleanups | 14 | * 03-Nov-2004 BJD Updated and minor cleanups |
15 | * 03-Aug-2005 RTP Renamed to fb.h | 15 | * 03-Aug-2005 RTP Renamed to fb.h |
16 | * 26-Oct-2005 BJD Changed name of platdata init | ||
16 | */ | 17 | */ |
17 | 18 | ||
18 | #ifndef __ASM_ARM_FB_H | 19 | #ifndef __ASM_ARM_FB_H |
@@ -64,6 +65,6 @@ struct s3c2410fb_mach_info { | |||
64 | unsigned long lpcsel; | 65 | unsigned long lpcsel; |
65 | }; | 66 | }; |
66 | 67 | ||
67 | void __init set_s3c2410fb_info(struct s3c2410fb_mach_info *hard_s3c2410fb_info); | 68 | extern void __init s3c24xx_fb_set_platdata(struct s3c2410fb_mach_info *); |
68 | 69 | ||
69 | #endif /* __ASM_ARM_FB_H */ | 70 | #endif /* __ASM_ARM_FB_H */ |
diff --git a/include/asm-arm/arch-s3c2410/io.h b/include/asm-arm/arch-s3c2410/io.h index 4bf272ed9add..16fbc8afffd9 100644 --- a/include/asm-arm/arch-s3c2410/io.h +++ b/include/asm-arm/arch-s3c2410/io.h | |||
@@ -15,6 +15,8 @@ | |||
15 | #ifndef __ASM_ARM_ARCH_IO_H | 15 | #ifndef __ASM_ARM_ARCH_IO_H |
16 | #define __ASM_ARM_ARCH_IO_H | 16 | #define __ASM_ARM_ARCH_IO_H |
17 | 17 | ||
18 | #include <asm/hardware.h> | ||
19 | |||
18 | #define IO_SPACE_LIMIT 0xffffffff | 20 | #define IO_SPACE_LIMIT 0xffffffff |
19 | 21 | ||
20 | /* | 22 | /* |
diff --git a/include/asm-arm/arch-s3c2410/memory.h b/include/asm-arm/arch-s3c2410/memory.h index 3380ab1d0749..6ab834a14c8e 100644 --- a/include/asm-arm/arch-s3c2410/memory.h +++ b/include/asm-arm/arch-s3c2410/memory.h | |||
@@ -28,9 +28,9 @@ | |||
28 | * and at 0x0C000000 for S3C2400 | 28 | * and at 0x0C000000 for S3C2400 |
29 | */ | 29 | */ |
30 | #ifdef CONFIG_CPU_S3C2400 | 30 | #ifdef CONFIG_CPU_S3C2400 |
31 | #define PHYS_OFFSET (0x0C000000UL) | 31 | #define PHYS_OFFSET UL(0x0C000000) |
32 | #else | 32 | #else |
33 | #define PHYS_OFFSET (0x30000000UL) | 33 | #define PHYS_OFFSET UL(0x30000000) |
34 | #endif | 34 | #endif |
35 | 35 | ||
36 | /* | 36 | /* |
diff --git a/include/asm-arm/arch-s3c2410/regs-gpio.h b/include/asm-arm/arch-s3c2410/regs-gpio.h index 2053cbacffc3..cb33d57c146c 100644 --- a/include/asm-arm/arch-s3c2410/regs-gpio.h +++ b/include/asm-arm/arch-s3c2410/regs-gpio.h | |||
@@ -20,6 +20,7 @@ | |||
20 | * 18-11-2004 BJD Added S3C2440 AC97 controls | 20 | * 18-11-2004 BJD Added S3C2440 AC97 controls |
21 | * 10-Mar-2005 LCVR Changed S3C2410_VA to S3C24XX_VA | 21 | * 10-Mar-2005 LCVR Changed S3C2410_VA to S3C24XX_VA |
22 | * 28-Mar-2005 LCVR Fixed definition of GPB10 | 22 | * 28-Mar-2005 LCVR Fixed definition of GPB10 |
23 | * 26-Oct-2005 BJD Added generic configuration types | ||
23 | */ | 24 | */ |
24 | 25 | ||
25 | 26 | ||
@@ -43,6 +44,11 @@ | |||
43 | /* general configuration options */ | 44 | /* general configuration options */ |
44 | 45 | ||
45 | #define S3C2410_GPIO_LEAVE (0xFFFFFFFF) | 46 | #define S3C2410_GPIO_LEAVE (0xFFFFFFFF) |
47 | #define S3C2410_GPIO_INPUT (0xFFFFFFF0) | ||
48 | #define S3C2410_GPIO_OUTPUT (0xFFFFFFF1) | ||
49 | #define S3C2410_GPIO_IRQ (0xFFFFFFF2) /* not available for all */ | ||
50 | #define S3C2410_GPIO_SFN2 (0xFFFFFFF2) /* not available on A */ | ||
51 | #define S3C2410_GPIO_SFN3 (0xFFFFFFF3) /* not available on A */ | ||
46 | 52 | ||
47 | /* configure GPIO ports A..G */ | 53 | /* configure GPIO ports A..G */ |
48 | 54 | ||
diff --git a/include/asm-arm/arch-sa1100/hardware.h b/include/asm-arm/arch-sa1100/hardware.h index 19c3b1e186bb..28711aaa4968 100644 --- a/include/asm-arm/arch-sa1100/hardware.h +++ b/include/asm-arm/arch-sa1100/hardware.h | |||
@@ -22,13 +22,6 @@ | |||
22 | 22 | ||
23 | 23 | ||
24 | /* | 24 | /* |
25 | * We requires absolute addresses i.e. (PCMCIA_IO_0_BASE + 0x3f8) for | ||
26 | * in*()/out*() macros to be usable for all cases. | ||
27 | */ | ||
28 | #define PCIO_BASE 0 | ||
29 | |||
30 | |||
31 | /* | ||
32 | * SA1100 internal I/O mappings | 25 | * SA1100 internal I/O mappings |
33 | * | 26 | * |
34 | * We have the following mapping: | 27 | * We have the following mapping: |
diff --git a/include/asm-arm/arch-sa1100/io.h b/include/asm-arm/arch-sa1100/io.h index 7d969ffbd3bb..9d4fe6cf205b 100644 --- a/include/asm-arm/arch-sa1100/io.h +++ b/include/asm-arm/arch-sa1100/io.h | |||
@@ -10,13 +10,19 @@ | |||
10 | #ifndef __ASM_ARM_ARCH_IO_H | 10 | #ifndef __ASM_ARM_ARCH_IO_H |
11 | #define __ASM_ARM_ARCH_IO_H | 11 | #define __ASM_ARM_ARCH_IO_H |
12 | 12 | ||
13 | #include <asm/hardware.h> | ||
14 | |||
13 | #define IO_SPACE_LIMIT 0xffffffff | 15 | #define IO_SPACE_LIMIT 0xffffffff |
14 | 16 | ||
15 | /* | 17 | /* |
16 | * We don't actually have real ISA nor PCI buses, but there is so many | 18 | * We don't actually have real ISA nor PCI buses, but there is so many |
17 | * drivers out there that might just work if we fake them... | 19 | * drivers out there that might just work if we fake them... |
18 | */ | 20 | */ |
19 | #define __io(a) ((void __iomem *)(PCIO_BASE + (a))) | 21 | static inline void __iomem *__io(unsigned long addr) |
22 | { | ||
23 | return (void __iomem *)addr; | ||
24 | } | ||
25 | #define __io(a) __io(a) | ||
20 | #define __mem_pci(a) (a) | 26 | #define __mem_pci(a) (a) |
21 | #define __mem_isa(a) (a) | 27 | #define __mem_isa(a) (a) |
22 | 28 | ||
diff --git a/include/asm-arm/arch-sa1100/memory.h b/include/asm-arm/arch-sa1100/memory.h index 8743ff5c1b23..0fc555b4c912 100644 --- a/include/asm-arm/arch-sa1100/memory.h +++ b/include/asm-arm/arch-sa1100/memory.h | |||
@@ -13,7 +13,7 @@ | |||
13 | /* | 13 | /* |
14 | * Physical DRAM offset is 0xc0000000 on the SA1100 | 14 | * Physical DRAM offset is 0xc0000000 on the SA1100 |
15 | */ | 15 | */ |
16 | #define PHYS_OFFSET (0xc0000000UL) | 16 | #define PHYS_OFFSET UL(0xc0000000) |
17 | 17 | ||
18 | #ifndef __ASSEMBLY__ | 18 | #ifndef __ASSEMBLY__ |
19 | 19 | ||
diff --git a/include/asm-arm/arch-sa1100/system.h b/include/asm-arm/arch-sa1100/system.h index 6f52118ba1a4..0f0612f79b2b 100644 --- a/include/asm-arm/arch-sa1100/system.h +++ b/include/asm-arm/arch-sa1100/system.h | |||
@@ -4,6 +4,7 @@ | |||
4 | * Copyright (c) 1999 Nicolas Pitre <nico@cam.org> | 4 | * Copyright (c) 1999 Nicolas Pitre <nico@cam.org> |
5 | */ | 5 | */ |
6 | #include <linux/config.h> | 6 | #include <linux/config.h> |
7 | #include <asm/hardware.h> | ||
7 | 8 | ||
8 | static inline void arch_idle(void) | 9 | static inline void arch_idle(void) |
9 | { | 10 | { |
diff --git a/include/asm-arm/arch-shark/io.h b/include/asm-arm/arch-shark/io.h index 5e6ed0038b2b..87ffa27f2962 100644 --- a/include/asm-arm/arch-shark/io.h +++ b/include/asm-arm/arch-shark/io.h | |||
@@ -11,6 +11,8 @@ | |||
11 | #ifndef __ASM_ARM_ARCH_IO_H | 11 | #ifndef __ASM_ARM_ARCH_IO_H |
12 | #define __ASM_ARM_ARCH_IO_H | 12 | #define __ASM_ARM_ARCH_IO_H |
13 | 13 | ||
14 | #include <asm/hardware.h> | ||
15 | |||
14 | #define IO_SPACE_LIMIT 0xffffffff | 16 | #define IO_SPACE_LIMIT 0xffffffff |
15 | 17 | ||
16 | /* | 18 | /* |
diff --git a/include/asm-arm/arch-shark/memory.h b/include/asm-arm/arch-shark/memory.h index 8ff956d25463..95a29b4bc5d0 100644 --- a/include/asm-arm/arch-shark/memory.h +++ b/include/asm-arm/arch-shark/memory.h | |||
@@ -15,7 +15,7 @@ | |||
15 | /* | 15 | /* |
16 | * Physical DRAM offset. | 16 | * Physical DRAM offset. |
17 | */ | 17 | */ |
18 | #define PHYS_OFFSET (0x08000000UL) | 18 | #define PHYS_OFFSET UL(0x08000000) |
19 | 19 | ||
20 | #ifndef __ASSEMBLY__ | 20 | #ifndef __ASSEMBLY__ |
21 | 21 | ||
diff --git a/include/asm-arm/arch-versatile/memory.h b/include/asm-arm/arch-versatile/memory.h index 7b8b7cc422fa..a9370976cc5e 100644 --- a/include/asm-arm/arch-versatile/memory.h +++ b/include/asm-arm/arch-versatile/memory.h | |||
@@ -23,7 +23,7 @@ | |||
23 | /* | 23 | /* |
24 | * Physical DRAM offset. | 24 | * Physical DRAM offset. |
25 | */ | 25 | */ |
26 | #define PHYS_OFFSET (0x00000000UL) | 26 | #define PHYS_OFFSET UL(0x00000000) |
27 | 27 | ||
28 | /* | 28 | /* |
29 | * Virtual view <-> DMA view memory address translations | 29 | * Virtual view <-> DMA view memory address translations |
diff --git a/include/asm-arm/dma-mapping.h b/include/asm-arm/dma-mapping.h index d62ade4e4cbb..e3e8541ee63b 100644 --- a/include/asm-arm/dma-mapping.h +++ b/include/asm-arm/dma-mapping.h | |||
@@ -70,7 +70,7 @@ static inline int dma_mapping_error(dma_addr_t dma_addr) | |||
70 | * device-viewed address. | 70 | * device-viewed address. |
71 | */ | 71 | */ |
72 | extern void * | 72 | extern void * |
73 | dma_alloc_coherent(struct device *dev, size_t size, dma_addr_t *handle, int gfp); | 73 | dma_alloc_coherent(struct device *dev, size_t size, dma_addr_t *handle, gfp_t gfp); |
74 | 74 | ||
75 | /** | 75 | /** |
76 | * dma_free_coherent - free memory allocated by dma_alloc_coherent | 76 | * dma_free_coherent - free memory allocated by dma_alloc_coherent |
@@ -117,7 +117,7 @@ int dma_mmap_coherent(struct device *dev, struct vm_area_struct *vma, | |||
117 | * device-viewed address. | 117 | * device-viewed address. |
118 | */ | 118 | */ |
119 | extern void * | 119 | extern void * |
120 | dma_alloc_writecombine(struct device *dev, size_t size, dma_addr_t *handle, int gfp); | 120 | dma_alloc_writecombine(struct device *dev, size_t size, dma_addr_t *handle, gfp_t gfp); |
121 | 121 | ||
122 | #define dma_free_writecombine(dev,size,cpu_addr,handle) \ | 122 | #define dma_free_writecombine(dev,size,cpu_addr,handle) \ |
123 | dma_free_coherent(dev,size,cpu_addr,handle) | 123 | dma_free_coherent(dev,size,cpu_addr,handle) |
diff --git a/include/asm-arm/io.h b/include/asm-arm/io.h index 5c4ae8f5dbb0..2e6799632f12 100644 --- a/include/asm-arm/io.h +++ b/include/asm-arm/io.h | |||
@@ -26,7 +26,6 @@ | |||
26 | #include <linux/types.h> | 26 | #include <linux/types.h> |
27 | #include <asm/byteorder.h> | 27 | #include <asm/byteorder.h> |
28 | #include <asm/memory.h> | 28 | #include <asm/memory.h> |
29 | #include <asm/arch/hardware.h> | ||
30 | 29 | ||
31 | /* | 30 | /* |
32 | * ISA I/O bus memory addresses are 1:1 with the physical address. | 31 | * ISA I/O bus memory addresses are 1:1 with the physical address. |
diff --git a/include/asm-arm/mach/arch.h b/include/asm-arm/mach/arch.h index 4fa95084a8c0..eb262e078c46 100644 --- a/include/asm-arm/mach/arch.h +++ b/include/asm-arm/mach/arch.h | |||
@@ -48,10 +48,11 @@ struct machine_desc { | |||
48 | * Set of macros to define architecture features. This is built into | 48 | * Set of macros to define architecture features. This is built into |
49 | * a table by the linker. | 49 | * a table by the linker. |
50 | */ | 50 | */ |
51 | #define MACHINE_START(_type,_name) \ | 51 | #define MACHINE_START(_type,_name) \ |
52 | const struct machine_desc __mach_desc_##_type \ | 52 | static const struct machine_desc __mach_desc_##_type \ |
53 | __attribute_used__ \ | ||
53 | __attribute__((__section__(".arch.info.init"))) = { \ | 54 | __attribute__((__section__(".arch.info.init"))) = { \ |
54 | .nr = MACH_TYPE_##_type, \ | 55 | .nr = MACH_TYPE_##_type, \ |
55 | .name = _name, | 56 | .name = _name, |
56 | 57 | ||
57 | #define MACHINE_END \ | 58 | #define MACHINE_END \ |
diff --git a/include/asm-arm/mach/flash.h b/include/asm-arm/mach/flash.h index a92887d4b2cb..cd57436d9874 100644 --- a/include/asm-arm/mach/flash.h +++ b/include/asm-arm/mach/flash.h | |||
@@ -14,6 +14,7 @@ struct mtd_partition; | |||
14 | 14 | ||
15 | /* | 15 | /* |
16 | * map_name: the map probe function name | 16 | * map_name: the map probe function name |
17 | * name: flash device name (eg, as used with mtdparts=) | ||
17 | * width: width of mapped device | 18 | * width: width of mapped device |
18 | * init: method called at driver/device initialisation | 19 | * init: method called at driver/device initialisation |
19 | * exit: method called at driver/device removal | 20 | * exit: method called at driver/device removal |
@@ -23,6 +24,7 @@ struct mtd_partition; | |||
23 | */ | 24 | */ |
24 | struct flash_platform_data { | 25 | struct flash_platform_data { |
25 | const char *map_name; | 26 | const char *map_name; |
27 | const char *name; | ||
26 | unsigned int width; | 28 | unsigned int width; |
27 | int (*init)(void); | 29 | int (*init)(void); |
28 | void (*exit)(void); | 30 | void (*exit)(void); |
diff --git a/include/asm-arm/mach/map.h b/include/asm-arm/mach/map.h index 9ac47cf8d2e4..b338936bde4f 100644 --- a/include/asm-arm/mach/map.h +++ b/include/asm-arm/mach/map.h | |||
@@ -11,7 +11,7 @@ | |||
11 | */ | 11 | */ |
12 | struct map_desc { | 12 | struct map_desc { |
13 | unsigned long virtual; | 13 | unsigned long virtual; |
14 | unsigned long physical; | 14 | unsigned long pfn; |
15 | unsigned long length; | 15 | unsigned long length; |
16 | unsigned int type; | 16 | unsigned int type; |
17 | }; | 17 | }; |
@@ -27,6 +27,9 @@ struct meminfo; | |||
27 | #define MT_ROM 6 | 27 | #define MT_ROM 6 |
28 | #define MT_IXP2000_DEVICE 7 | 28 | #define MT_IXP2000_DEVICE 7 |
29 | 29 | ||
30 | #define __phys_to_pfn(paddr) ((paddr) >> PAGE_SHIFT) | ||
31 | #define __pfn_to_phys(pfn) ((pfn) << PAGE_SHIFT) | ||
32 | |||
30 | extern void create_memmap_holes(struct meminfo *); | 33 | extern void create_memmap_holes(struct meminfo *); |
31 | extern void memtable_init(struct meminfo *); | 34 | extern void memtable_init(struct meminfo *); |
32 | extern void iotable_init(struct map_desc *, int); | 35 | extern void iotable_init(struct map_desc *, int); |
diff --git a/include/asm-arm/memory.h b/include/asm-arm/memory.h index a8a933a775db..a547ee598c6c 100644 --- a/include/asm-arm/memory.h +++ b/include/asm-arm/memory.h | |||
@@ -12,6 +12,16 @@ | |||
12 | #ifndef __ASM_ARM_MEMORY_H | 12 | #ifndef __ASM_ARM_MEMORY_H |
13 | #define __ASM_ARM_MEMORY_H | 13 | #define __ASM_ARM_MEMORY_H |
14 | 14 | ||
15 | /* | ||
16 | * Allow for constants defined here to be used from assembly code | ||
17 | * by prepending the UL suffix only with actual C code compilation. | ||
18 | */ | ||
19 | #ifndef __ASSEMBLY__ | ||
20 | #define UL(x) (x##UL) | ||
21 | #else | ||
22 | #define UL(x) (x) | ||
23 | #endif | ||
24 | |||
15 | #include <linux/config.h> | 25 | #include <linux/config.h> |
16 | #include <linux/compiler.h> | 26 | #include <linux/compiler.h> |
17 | #include <asm/arch/memory.h> | 27 | #include <asm/arch/memory.h> |
@@ -21,20 +31,20 @@ | |||
21 | * TASK_SIZE - the maximum size of a user space task. | 31 | * TASK_SIZE - the maximum size of a user space task. |
22 | * TASK_UNMAPPED_BASE - the lower boundary of the mmap VM area | 32 | * TASK_UNMAPPED_BASE - the lower boundary of the mmap VM area |
23 | */ | 33 | */ |
24 | #define TASK_SIZE (0xbf000000UL) | 34 | #define TASK_SIZE UL(0xbf000000) |
25 | #define TASK_UNMAPPED_BASE (0x40000000UL) | 35 | #define TASK_UNMAPPED_BASE UL(0x40000000) |
26 | #endif | 36 | #endif |
27 | 37 | ||
28 | /* | 38 | /* |
29 | * The maximum size of a 26-bit user space task. | 39 | * The maximum size of a 26-bit user space task. |
30 | */ | 40 | */ |
31 | #define TASK_SIZE_26 (0x04000000UL) | 41 | #define TASK_SIZE_26 UL(0x04000000) |
32 | 42 | ||
33 | /* | 43 | /* |
34 | * Page offset: 3GB | 44 | * Page offset: 3GB |
35 | */ | 45 | */ |
36 | #ifndef PAGE_OFFSET | 46 | #ifndef PAGE_OFFSET |
37 | #define PAGE_OFFSET (0xc0000000UL) | 47 | #define PAGE_OFFSET UL(0xc0000000) |
38 | #endif | 48 | #endif |
39 | 49 | ||
40 | /* | 50 | /* |
@@ -58,6 +68,13 @@ | |||
58 | #error Top of user space clashes with start of module space | 68 | #error Top of user space clashes with start of module space |
59 | #endif | 69 | #endif |
60 | 70 | ||
71 | /* | ||
72 | * The XIP kernel gets mapped at the bottom of the module vm area. | ||
73 | * Since we use sections to map it, this macro replaces the physical address | ||
74 | * with its virtual address while keeping offset from the base section. | ||
75 | */ | ||
76 | #define XIP_VIRT_ADDR(physaddr) (MODULE_START + ((physaddr) & 0x000fffff)) | ||
77 | |||
61 | #ifndef __ASSEMBLY__ | 78 | #ifndef __ASSEMBLY__ |
62 | 79 | ||
63 | /* | 80 | /* |
diff --git a/include/asm-arm/pgtable.h b/include/asm-arm/pgtable.h index 366bafbdfbb1..5a0d19b466b0 100644 --- a/include/asm-arm/pgtable.h +++ b/include/asm-arm/pgtable.h | |||
@@ -397,9 +397,6 @@ static inline pte_t *pmd_page_kernel(pmd_t pmd) | |||
397 | #define pgd_clear(pgdp) do { } while (0) | 397 | #define pgd_clear(pgdp) do { } while (0) |
398 | #define set_pgd(pgd,pgdp) do { } while (0) | 398 | #define set_pgd(pgd,pgdp) do { } while (0) |
399 | 399 | ||
400 | #define page_pte_prot(page,prot) mk_pte(page, prot) | ||
401 | #define page_pte(page) mk_pte(page, __pgprot(0)) | ||
402 | |||
403 | /* to find an entry in a page-table-directory */ | 400 | /* to find an entry in a page-table-directory */ |
404 | #define pgd_index(addr) ((addr) >> PGDIR_SHIFT) | 401 | #define pgd_index(addr) ((addr) >> PGDIR_SHIFT) |
405 | 402 | ||
diff --git a/include/asm-arm/semaphore.h b/include/asm-arm/semaphore.h index 60f33e6eb800..71ca7d412687 100644 --- a/include/asm-arm/semaphore.h +++ b/include/asm-arm/semaphore.h | |||
@@ -24,8 +24,6 @@ struct semaphore { | |||
24 | .wait = __WAIT_QUEUE_HEAD_INITIALIZER((name).wait), \ | 24 | .wait = __WAIT_QUEUE_HEAD_INITIALIZER((name).wait), \ |
25 | } | 25 | } |
26 | 26 | ||
27 | #define __MUTEX_INITIALIZER(name) __SEMAPHORE_INIT(name,1) | ||
28 | |||
29 | #define __DECLARE_SEMAPHORE_GENERIC(name,count) \ | 27 | #define __DECLARE_SEMAPHORE_GENERIC(name,count) \ |
30 | struct semaphore name = __SEMAPHORE_INIT(name,count) | 28 | struct semaphore name = __SEMAPHORE_INIT(name,count) |
31 | 29 | ||
diff --git a/include/asm-arm/tlb.h b/include/asm-arm/tlb.h index 9bb325c54645..f49bfb78c221 100644 --- a/include/asm-arm/tlb.h +++ b/include/asm-arm/tlb.h | |||
@@ -27,11 +27,7 @@ | |||
27 | */ | 27 | */ |
28 | struct mmu_gather { | 28 | struct mmu_gather { |
29 | struct mm_struct *mm; | 29 | struct mm_struct *mm; |
30 | unsigned int freed; | ||
31 | unsigned int fullmm; | 30 | unsigned int fullmm; |
32 | |||
33 | unsigned int flushes; | ||
34 | unsigned int avoided_flushes; | ||
35 | }; | 31 | }; |
36 | 32 | ||
37 | DECLARE_PER_CPU(struct mmu_gather, mmu_gathers); | 33 | DECLARE_PER_CPU(struct mmu_gather, mmu_gathers); |
@@ -39,11 +35,9 @@ DECLARE_PER_CPU(struct mmu_gather, mmu_gathers); | |||
39 | static inline struct mmu_gather * | 35 | static inline struct mmu_gather * |
40 | tlb_gather_mmu(struct mm_struct *mm, unsigned int full_mm_flush) | 36 | tlb_gather_mmu(struct mm_struct *mm, unsigned int full_mm_flush) |
41 | { | 37 | { |
42 | int cpu = smp_processor_id(); | 38 | struct mmu_gather *tlb = &get_cpu_var(mmu_gathers); |
43 | struct mmu_gather *tlb = &per_cpu(mmu_gathers, cpu); | ||
44 | 39 | ||
45 | tlb->mm = mm; | 40 | tlb->mm = mm; |
46 | tlb->freed = 0; | ||
47 | tlb->fullmm = full_mm_flush; | 41 | tlb->fullmm = full_mm_flush; |
48 | 42 | ||
49 | return tlb; | 43 | return tlb; |
@@ -52,24 +46,13 @@ tlb_gather_mmu(struct mm_struct *mm, unsigned int full_mm_flush) | |||
52 | static inline void | 46 | static inline void |
53 | tlb_finish_mmu(struct mmu_gather *tlb, unsigned long start, unsigned long end) | 47 | tlb_finish_mmu(struct mmu_gather *tlb, unsigned long start, unsigned long end) |
54 | { | 48 | { |
55 | struct mm_struct *mm = tlb->mm; | ||
56 | unsigned long freed = tlb->freed; | ||
57 | int rss = get_mm_counter(mm, rss); | ||
58 | |||
59 | if (rss < freed) | ||
60 | freed = rss; | ||
61 | add_mm_counter(mm, rss, -freed); | ||
62 | |||
63 | if (tlb->fullmm) | 49 | if (tlb->fullmm) |
64 | flush_tlb_mm(mm); | 50 | flush_tlb_mm(tlb->mm); |
65 | 51 | ||
66 | /* keep the page table cache within bounds */ | 52 | /* keep the page table cache within bounds */ |
67 | check_pgt_cache(); | 53 | check_pgt_cache(); |
68 | } | ||
69 | 54 | ||
70 | static inline unsigned int tlb_is_full_mm(struct mmu_gather *tlb) | 55 | put_cpu_var(mmu_gathers); |
71 | { | ||
72 | return tlb->fullmm; | ||
73 | } | 56 | } |
74 | 57 | ||
75 | #define tlb_remove_tlb_entry(tlb,ptep,address) do { } while (0) | 58 | #define tlb_remove_tlb_entry(tlb,ptep,address) do { } while (0) |
diff --git a/include/asm-arm/unistd.h b/include/asm-arm/unistd.h index c49df635a80f..d626e70faded 100644 --- a/include/asm-arm/unistd.h +++ b/include/asm-arm/unistd.h | |||
@@ -544,7 +544,6 @@ asmlinkage int sys_clone(unsigned long clone_flags, unsigned long newsp, | |||
544 | asmlinkage int sys_fork(struct pt_regs *regs); | 544 | asmlinkage int sys_fork(struct pt_regs *regs); |
545 | asmlinkage int sys_vfork(struct pt_regs *regs); | 545 | asmlinkage int sys_vfork(struct pt_regs *regs); |
546 | asmlinkage int sys_pipe(unsigned long *fildes); | 546 | asmlinkage int sys_pipe(unsigned long *fildes); |
547 | asmlinkage int sys_ptrace(long request, long pid, long addr, long data); | ||
548 | struct sigaction; | 547 | struct sigaction; |
549 | asmlinkage long sys_rt_sigaction(int sig, | 548 | asmlinkage long sys_rt_sigaction(int sig, |
550 | const struct sigaction __user *act, | 549 | const struct sigaction __user *act, |