diff options
author | Holger Schurig <hs4233@mail.mn-solutions.de> | 2009-01-26 10:34:52 -0500 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2009-03-13 05:33:45 -0400 |
commit | 5512e88f3a1f1b498fd07181f14596ee117b3471 (patch) | |
tree | c764b8ebbc0030147d7b7bf9a150a464d4d5904d /arch | |
parent | ccfe30a7c8329e85ae426813a1060e27e2547dd1 (diff) |
arm/imx21: add kbuild support for the Freescale i.MX21
* adds Kconfig variables
* specifies different physical address for i.MX21 because of the
different memory layouts
* disables support for UART5/UART6 in the i.MX serial driver
(the i.MX21 doesn't have those modules)
Based on code from "Martin Fuzzey" <mfuzzey@gmail.com>
Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/mach-mx2/Kconfig | 13 | ||||
-rw-r--r-- | arch/arm/mach-mx2/Makefile.boot | 10 | ||||
-rw-r--r-- | arch/arm/mach-mx2/serial.c | 2 | ||||
-rw-r--r-- | arch/arm/plat-mxc/include/mach/memory.h | 5 | ||||
-rw-r--r-- | arch/arm/plat-mxc/include/mach/mxc.h | 4 |
5 files changed, 31 insertions, 3 deletions
diff --git a/arch/arm/mach-mx2/Kconfig b/arch/arm/mach-mx2/Kconfig index 1eaa97cb716d..412d2d55b08c 100644 --- a/arch/arm/mach-mx2/Kconfig +++ b/arch/arm/mach-mx2/Kconfig | |||
@@ -1,12 +1,25 @@ | |||
1 | comment "MX2 family CPU support" | 1 | comment "MX2 family CPU support" |
2 | depends on ARCH_MX2 | 2 | depends on ARCH_MX2 |
3 | 3 | ||
4 | choice | ||
5 | prompt "MX2 Type" | ||
6 | depends on ARCH_MX2 | ||
7 | default MACH_MX21 | ||
8 | |||
9 | config MACH_MX21 | ||
10 | bool "i.MX21 support" | ||
11 | depends on ARCH_MX2 | ||
12 | help | ||
13 | This enables support for Freescale's MX2 based i.MX21 processor. | ||
14 | |||
4 | config MACH_MX27 | 15 | config MACH_MX27 |
5 | bool "i.MX27 support" | 16 | bool "i.MX27 support" |
6 | depends on ARCH_MX2 | 17 | depends on ARCH_MX2 |
7 | help | 18 | help |
8 | This enables support for Freescale's MX2 based i.MX27 processor. | 19 | This enables support for Freescale's MX2 based i.MX27 processor. |
9 | 20 | ||
21 | endchoice | ||
22 | |||
10 | comment "MX2 Platforms" | 23 | comment "MX2 Platforms" |
11 | depends on ARCH_MX2 | 24 | depends on ARCH_MX2 |
12 | 25 | ||
diff --git a/arch/arm/mach-mx2/Makefile.boot b/arch/arm/mach-mx2/Makefile.boot index 696831dcd485..e867398a8fdb 100644 --- a/arch/arm/mach-mx2/Makefile.boot +++ b/arch/arm/mach-mx2/Makefile.boot | |||
@@ -1,3 +1,7 @@ | |||
1 | zreladdr-y := 0xA0008000 | 1 | zreladdr-$(CONFIG_MACH_MX21) := 0xC0008000 |
2 | params_phys-y := 0xA0000100 | 2 | params_phys-$(CONFIG_MACH_MX21) := 0xC0000100 |
3 | initrd_phys-y := 0xA0800000 | 3 | initrd_phys-$(CONFIG_MACH_MX21) := 0xC0800000 |
4 | |||
5 | zreladdr-$(CONFIG_MACH_MX27) := 0xA0008000 | ||
6 | params_phys-$(CONFIG_MACH_MX27) := 0xA0000100 | ||
7 | initrd_phys-$(CONFIG_MACH_MX27) := 0xA0800000 | ||
diff --git a/arch/arm/mach-mx2/serial.c b/arch/arm/mach-mx2/serial.c index 16debc296dad..b9e66fb11860 100644 --- a/arch/arm/mach-mx2/serial.c +++ b/arch/arm/mach-mx2/serial.c | |||
@@ -99,6 +99,7 @@ struct platform_device mxc_uart_device3 = { | |||
99 | .num_resources = ARRAY_SIZE(uart3), | 99 | .num_resources = ARRAY_SIZE(uart3), |
100 | }; | 100 | }; |
101 | 101 | ||
102 | #ifdef CONFIG_MACH_MX27 | ||
102 | static struct resource uart4[] = { | 103 | static struct resource uart4[] = { |
103 | { | 104 | { |
104 | .start = UART5_BASE_ADDR, | 105 | .start = UART5_BASE_ADDR, |
@@ -136,3 +137,4 @@ struct platform_device mxc_uart_device5 = { | |||
136 | .resource = uart5, | 137 | .resource = uart5, |
137 | .num_resources = ARRAY_SIZE(uart5), | 138 | .num_resources = ARRAY_SIZE(uart5), |
138 | }; | 139 | }; |
140 | #endif | ||
diff --git a/arch/arm/plat-mxc/include/mach/memory.h b/arch/arm/plat-mxc/include/mach/memory.h index 0b808399097f..e0783e619580 100644 --- a/arch/arm/plat-mxc/include/mach/memory.h +++ b/arch/arm/plat-mxc/include/mach/memory.h | |||
@@ -14,7 +14,12 @@ | |||
14 | #if defined CONFIG_ARCH_MX1 | 14 | #if defined CONFIG_ARCH_MX1 |
15 | #define PHYS_OFFSET UL(0x08000000) | 15 | #define PHYS_OFFSET UL(0x08000000) |
16 | #elif defined CONFIG_ARCH_MX2 | 16 | #elif defined CONFIG_ARCH_MX2 |
17 | #ifdef CONFIG_MACH_MX21 | ||
18 | #define PHYS_OFFSET UL(0xC0000000) | ||
19 | #endif | ||
20 | #ifdef CONFIG_MACH_MX27 | ||
17 | #define PHYS_OFFSET UL(0xA0000000) | 21 | #define PHYS_OFFSET UL(0xA0000000) |
22 | #endif | ||
18 | #elif defined CONFIG_ARCH_MX3 | 23 | #elif defined CONFIG_ARCH_MX3 |
19 | #define PHYS_OFFSET UL(0x80000000) | 24 | #define PHYS_OFFSET UL(0x80000000) |
20 | #endif | 25 | #endif |
diff --git a/arch/arm/plat-mxc/include/mach/mxc.h b/arch/arm/plat-mxc/include/mach/mxc.h index f6caab062131..bbd848e004d7 100644 --- a/arch/arm/plat-mxc/include/mach/mxc.h +++ b/arch/arm/plat-mxc/include/mach/mxc.h | |||
@@ -29,6 +29,10 @@ | |||
29 | # define cpu_is_mx31() (0) | 29 | # define cpu_is_mx31() (0) |
30 | #endif | 30 | #endif |
31 | 31 | ||
32 | #ifndef CONFIG_MACH_MX21 | ||
33 | # define cpu_is_mx21() (0) | ||
34 | #endif | ||
35 | |||
32 | #ifndef CONFIG_MACH_MX27 | 36 | #ifndef CONFIG_MACH_MX27 |
33 | # define cpu_is_mx27() (0) | 37 | # define cpu_is_mx27() (0) |
34 | #endif | 38 | #endif |