diff options
author | Rusty Russell <rusty@rustcorp.com.au> | 2008-12-31 07:35:57 -0500 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2008-12-31 07:35:57 -0500 |
commit | 2ca1a615835d9f4990f42102ab1f2ef434e7e89c (patch) | |
tree | 726cf3d5f29a6c66c44e4bd68e7ebed2fd83d059 /arch/arm/mach-w90x900/cpu.h | |
parent | e12f0102ac81d660c9f801d0a0e10ccf4537a9de (diff) | |
parent | 6a94cb73064c952255336cc57731904174b2c58f (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Conflicts:
arch/x86/kernel/io_apic.c
Diffstat (limited to 'arch/arm/mach-w90x900/cpu.h')
-rw-r--r-- | arch/arm/mach-w90x900/cpu.h | 77 |
1 files changed, 77 insertions, 0 deletions
diff --git a/arch/arm/mach-w90x900/cpu.h b/arch/arm/mach-w90x900/cpu.h new file mode 100644 index 000000000000..40ff40845df0 --- /dev/null +++ b/arch/arm/mach-w90x900/cpu.h | |||
@@ -0,0 +1,77 @@ | |||
1 | /* | ||
2 | * arch/arm/mach-w90x900/cpu.h | ||
3 | * | ||
4 | * Based on linux/include/asm-arm/plat-s3c24xx/cpu.h by Ben Dooks | ||
5 | * | ||
6 | * Copyright (c) 2008 Nuvoton technology corporation | ||
7 | * All rights reserved. | ||
8 | * | ||
9 | * Header file for W90X900 CPU support | ||
10 | * | ||
11 | * Wan ZongShun <mcuos.com@gmail.com> | ||
12 | * | ||
13 | * This program is free software; you can redistribute it and/or modify | ||
14 | * it under the terms of the GNU General Public License version 2 as | ||
15 | * published by the Free Software Foundation. | ||
16 | * | ||
17 | */ | ||
18 | |||
19 | #define IODESC_ENT(y) \ | ||
20 | { \ | ||
21 | .virtual = (unsigned long)W90X900_VA_##y, \ | ||
22 | .pfn = __phys_to_pfn(W90X900_PA_##y), \ | ||
23 | .length = W90X900_SZ_##y, \ | ||
24 | .type = MT_DEVICE, \ | ||
25 | } | ||
26 | |||
27 | /*Cpu identifier register*/ | ||
28 | |||
29 | #define W90X900PDID W90X900_VA_GCR | ||
30 | #define W90P910_CPUID 0x02900910 | ||
31 | #define W90P920_CPUID 0x02900920 | ||
32 | #define W90P950_CPUID 0x02900950 | ||
33 | #define W90N960_CPUID 0x02900960 | ||
34 | |||
35 | struct w90x900_uartcfg; | ||
36 | struct map_desc; | ||
37 | struct sys_timer; | ||
38 | |||
39 | /* core initialisation functions */ | ||
40 | |||
41 | extern void w90x900_init_irq(void); | ||
42 | extern void w90p910_init_io(struct map_desc *mach_desc, int size); | ||
43 | extern void w90p910_init_uarts(struct w90x900_uartcfg *cfg, int no); | ||
44 | extern void w90p910_init_clocks(int xtal); | ||
45 | extern void w90p910_map_io(struct map_desc *mach_desc, int size); | ||
46 | extern struct sys_timer w90x900_timer; | ||
47 | |||
48 | #define W90X900_RES(name) \ | ||
49 | struct resource w90x900_##name##_resource[] = { \ | ||
50 | [0] = { \ | ||
51 | .start = name##_PA, \ | ||
52 | .end = name##_PA + 0x0ff, \ | ||
53 | .flags = IORESOURCE_MEM, \ | ||
54 | }, \ | ||
55 | [1] = { \ | ||
56 | .start = IRQ_##name, \ | ||
57 | .end = IRQ_##name, \ | ||
58 | .flags = IORESOURCE_IRQ, \ | ||
59 | } \ | ||
60 | } | ||
61 | |||
62 | #define W90X900_DEVICE(devname, regname, devid, platdevname) \ | ||
63 | struct platform_device w90x900_##devname = { \ | ||
64 | .name = platdevname, \ | ||
65 | .id = devid, \ | ||
66 | .num_resources = ARRAY_SIZE(w90x900_##regname##_resource), \ | ||
67 | .resource = w90x900_##regname##_resource, \ | ||
68 | } | ||
69 | |||
70 | #define W90X900_UARTCFG(port, flag, uc, ulc, ufc) \ | ||
71 | { \ | ||
72 | .hwport = port, \ | ||
73 | .flags = flag, \ | ||
74 | .ucon = uc, \ | ||
75 | .ulcon = ulc, \ | ||
76 | .ufcon = ufc, \ | ||
77 | } | ||