diff options
author | wanzongshun <mcuos.com@gmail.com> | 2009-08-21 02:08:24 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2009-09-02 06:22:24 -0400 |
commit | 936fbe9efc96d40c8cdc23bba31a3beaad4f96c1 (patch) | |
tree | 47cedb7937032dca3aa6b7055046a1f9d7ae70b6 /arch/arm/mach-w90x900 | |
parent | 35c9221acb133ecc9abd701a1fb6fa909d177a77 (diff) |
ARM: 5683/1: Add nuc950 platform to w90x900
Add nuc950 platform to w90x900.
Signed-off-by: Wan ZongShun <mcuos.com@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-w90x900')
-rw-r--r-- | arch/arm/mach-w90x900/Kconfig | 15 | ||||
-rw-r--r-- | arch/arm/mach-w90x900/Makefile | 2 | ||||
-rw-r--r-- | arch/arm/mach-w90x900/mach-nuc950evb.c | 44 | ||||
-rw-r--r-- | arch/arm/mach-w90x900/nuc950.c | 54 | ||||
-rw-r--r-- | arch/arm/mach-w90x900/nuc950.h | 28 |
5 files changed, 143 insertions, 0 deletions
diff --git a/arch/arm/mach-w90x900/Kconfig b/arch/arm/mach-w90x900/Kconfig index 8e4178fe5ec2..163b8010e575 100644 --- a/arch/arm/mach-w90x900/Kconfig +++ b/arch/arm/mach-w90x900/Kconfig | |||
@@ -5,6 +5,11 @@ config CPU_W90P910 | |||
5 | help | 5 | help |
6 | Support for W90P910 of Nuvoton W90X900 CPUs. | 6 | Support for W90P910 of Nuvoton W90X900 CPUs. |
7 | 7 | ||
8 | config CPU_NUC950 | ||
9 | bool | ||
10 | help | ||
11 | Support for NUCP950 of Nuvoton NUC900 CPUs. | ||
12 | |||
8 | menu "W90P910 Machines" | 13 | menu "W90P910 Machines" |
9 | 14 | ||
10 | config MACH_W90P910EVB | 15 | config MACH_W90P910EVB |
@@ -16,4 +21,14 @@ config MACH_W90P910EVB | |||
16 | 21 | ||
17 | endmenu | 22 | endmenu |
18 | 23 | ||
24 | menu "NUC950 Machines" | ||
25 | |||
26 | config MACH_W90P950EVB | ||
27 | bool "Nuvoton NUC950 Evaluation Board" | ||
28 | select CPU_NUC950 | ||
29 | help | ||
30 | Say Y here if you are using the Nuvoton NUC950EVB | ||
31 | |||
32 | endmenu | ||
33 | |||
19 | endif | 34 | endif |
diff --git a/arch/arm/mach-w90x900/Makefile b/arch/arm/mach-w90x900/Makefile index e38aa328e608..a4622b577a2c 100644 --- a/arch/arm/mach-w90x900/Makefile +++ b/arch/arm/mach-w90x900/Makefile | |||
@@ -9,7 +9,9 @@ obj-y += clksel.o dev.o cpu.o | |||
9 | # W90X900 CPU support files | 9 | # W90X900 CPU support files |
10 | 10 | ||
11 | obj-$(CONFIG_CPU_W90P910) += nuc910.o | 11 | obj-$(CONFIG_CPU_W90P910) += nuc910.o |
12 | obj-$(CONFIG_CPU_NUC950) += nuc950.o | ||
12 | 13 | ||
13 | # machine support | 14 | # machine support |
14 | 15 | ||
15 | obj-$(CONFIG_MACH_W90P910EVB) += mach-nuc910evb.o | 16 | obj-$(CONFIG_MACH_W90P910EVB) += mach-nuc910evb.o |
17 | obj-$(CONFIG_MACH_W90P950EVB) += mach-nuc950evb.o | ||
diff --git a/arch/arm/mach-w90x900/mach-nuc950evb.c b/arch/arm/mach-w90x900/mach-nuc950evb.c new file mode 100644 index 000000000000..cef903bcccd1 --- /dev/null +++ b/arch/arm/mach-w90x900/mach-nuc950evb.c | |||
@@ -0,0 +1,44 @@ | |||
1 | /* | ||
2 | * linux/arch/arm/mach-w90x900/mach-nuc950evb.c | ||
3 | * | ||
4 | * Based on mach-s3c2410/mach-smdk2410.c by Jonas Dietsche | ||
5 | * | ||
6 | * Copyright (C) 2008 Nuvoton technology corporation. | ||
7 | * | ||
8 | * Wan ZongShun <mcuos.com@gmail.com> | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or | ||
11 | * modify it under the terms of the GNU General Public License as | ||
12 | * published by the Free Software Foundation;version 2 of the License. | ||
13 | * | ||
14 | */ | ||
15 | |||
16 | #include <linux/platform_device.h> | ||
17 | #include <asm/mach/arch.h> | ||
18 | #include <asm/mach/map.h> | ||
19 | #include <asm/mach-types.h> | ||
20 | #include <mach/map.h> | ||
21 | |||
22 | #include "nuc950.h" | ||
23 | |||
24 | static void __init nuc950evb_map_io(void) | ||
25 | { | ||
26 | nuc950_map_io(); | ||
27 | nuc950_init_clocks(); | ||
28 | } | ||
29 | |||
30 | static void __init nuc950evb_init(void) | ||
31 | { | ||
32 | nuc950_board_init(); | ||
33 | } | ||
34 | |||
35 | MACHINE_START(W90P950EVB, "W90P950EVB") | ||
36 | /* Maintainer: Wan ZongShun */ | ||
37 | .phys_io = W90X900_PA_UART, | ||
38 | .io_pg_offst = (((u32)W90X900_VA_UART) >> 18) & 0xfffc, | ||
39 | .boot_params = 0, | ||
40 | .map_io = nuc950evb_map_io, | ||
41 | .init_irq = nuc900_init_irq, | ||
42 | .init_machine = nuc950evb_init, | ||
43 | .timer = &nuc900_timer, | ||
44 | MACHINE_END | ||
diff --git a/arch/arm/mach-w90x900/nuc950.c b/arch/arm/mach-w90x900/nuc950.c new file mode 100644 index 000000000000..149508116d18 --- /dev/null +++ b/arch/arm/mach-w90x900/nuc950.c | |||
@@ -0,0 +1,54 @@ | |||
1 | /* | ||
2 | * linux/arch/arm/mach-w90x900/nuc950.c | ||
3 | * | ||
4 | * Based on linux/arch/arm/plat-s3c24xx/s3c244x.c by Ben Dooks | ||
5 | * | ||
6 | * Copyright (c) 2008 Nuvoton technology corporation. | ||
7 | * | ||
8 | * Wan ZongShun <mcuos.com@gmail.com> | ||
9 | * | ||
10 | * NUC950 cpu support | ||
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;version 2 of the License. | ||
15 | * | ||
16 | */ | ||
17 | |||
18 | #include <linux/platform_device.h> | ||
19 | #include <asm/mach/map.h> | ||
20 | #include <mach/hardware.h> | ||
21 | #include "cpu.h" | ||
22 | |||
23 | /* define specific CPU platform device */ | ||
24 | |||
25 | static struct platform_device *nuc950_dev[] __initdata = { | ||
26 | &nuc900_device_kpi, | ||
27 | &nuc900_device_fmi, | ||
28 | }; | ||
29 | |||
30 | /* define specific CPU platform io map */ | ||
31 | |||
32 | static struct map_desc nuc950evb_iodesc[] __initdata = { | ||
33 | }; | ||
34 | |||
35 | /*Init NUC950 evb io*/ | ||
36 | |||
37 | void __init nuc950_map_io(void) | ||
38 | { | ||
39 | nuc900_map_io(nuc950evb_iodesc, ARRAY_SIZE(nuc950evb_iodesc)); | ||
40 | } | ||
41 | |||
42 | /*Init NUC950 clock*/ | ||
43 | |||
44 | void __init nuc950_init_clocks(void) | ||
45 | { | ||
46 | nuc900_init_clocks(); | ||
47 | } | ||
48 | |||
49 | /*Init NUC950 board info*/ | ||
50 | |||
51 | void __init nuc950_board_init(void) | ||
52 | { | ||
53 | nuc900_board_init(nuc950_dev, ARRAY_SIZE(nuc950_dev)); | ||
54 | } | ||
diff --git a/arch/arm/mach-w90x900/nuc950.h b/arch/arm/mach-w90x900/nuc950.h new file mode 100644 index 000000000000..98a1148bc5ae --- /dev/null +++ b/arch/arm/mach-w90x900/nuc950.h | |||
@@ -0,0 +1,28 @@ | |||
1 | /* | ||
2 | * arch/arm/mach-w90x900/nuc950.h | ||
3 | * | ||
4 | * Copyright (c) 2008 Nuvoton corporation | ||
5 | * | ||
6 | * Header file for NUC900 CPU support | ||
7 | * | ||
8 | * Wan ZongShun <mcuos.com@gmail.com> | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License version 2 as | ||
12 | * published by the Free Software Foundation. | ||
13 | * | ||
14 | */ | ||
15 | |||
16 | struct map_desc; | ||
17 | struct sys_timer; | ||
18 | |||
19 | /* core initialisation functions */ | ||
20 | |||
21 | extern void nuc900_init_irq(void); | ||
22 | extern struct sys_timer nuc900_timer; | ||
23 | |||
24 | /* extern file from nuc950.c */ | ||
25 | |||
26 | extern void nuc950_board_init(void); | ||
27 | extern void nuc950_init_clocks(void); | ||
28 | extern void nuc950_map_io(void); | ||