diff options
author | Shawn Guo <shawn.guo@freescale.com> | 2014-05-13 09:46:16 -0400 |
---|---|---|
committer | Shawn Guo <shawn.guo@freescale.com> | 2014-05-16 03:35:25 -0400 |
commit | d9654dceb315ccdabf4a5494109a4cc0fb2408a4 (patch) | |
tree | 4e17d1e5d9621e18602c9553a0db5fabd6a38fab | |
parent | d55135689019c3a0b26bccd400d90c6d2fd13439 (diff) |
ARM: imx: add basic imx6sx SoC support
Add basic suppport for i.MX6 SoloX SoC.
Signed-off-by: Anson Huang <b20788@freescale.com>
Signed-off-by: Shawn Guo <shawn.guo@freescale.com>
-rw-r--r-- | arch/arm/mach-imx/Kconfig | 8 | ||||
-rw-r--r-- | arch/arm/mach-imx/Makefile | 1 | ||||
-rw-r--r-- | arch/arm/mach-imx/cpu.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-imx/mach-imx6sx.c | 51 | ||||
-rw-r--r-- | arch/arm/mach-imx/mxc.h | 6 |
5 files changed, 69 insertions, 0 deletions
diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig index 839ef51fd390..4776e1ffacd5 100644 --- a/arch/arm/mach-imx/Kconfig +++ b/arch/arm/mach-imx/Kconfig | |||
@@ -763,6 +763,14 @@ config SOC_IMX6SL | |||
763 | help | 763 | help |
764 | This enables support for Freescale i.MX6 SoloLite processor. | 764 | This enables support for Freescale i.MX6 SoloLite processor. |
765 | 765 | ||
766 | config SOC_IMX6SX | ||
767 | bool "i.MX6 SoloX support" | ||
768 | select PINCTRL_IMX6SX | ||
769 | select SOC_IMX6 | ||
770 | |||
771 | help | ||
772 | This enables support for Freescale i.MX6 SoloX processor. | ||
773 | |||
766 | config SOC_VF610 | 774 | config SOC_VF610 |
767 | bool "Vybrid Family VF610 support" | 775 | bool "Vybrid Family VF610 support" |
768 | select ARM_GIC | 776 | select ARM_GIC |
diff --git a/arch/arm/mach-imx/Makefile b/arch/arm/mach-imx/Makefile index 572e1ab02c14..bbe93bbfd003 100644 --- a/arch/arm/mach-imx/Makefile +++ b/arch/arm/mach-imx/Makefile | |||
@@ -101,6 +101,7 @@ obj-$(CONFIG_SMP) += headsmp.o platsmp.o | |||
101 | obj-$(CONFIG_HOTPLUG_CPU) += hotplug.o | 101 | obj-$(CONFIG_HOTPLUG_CPU) += hotplug.o |
102 | obj-$(CONFIG_SOC_IMX6Q) += clk-imx6q.o mach-imx6q.o | 102 | obj-$(CONFIG_SOC_IMX6Q) += clk-imx6q.o mach-imx6q.o |
103 | obj-$(CONFIG_SOC_IMX6SL) += clk-imx6sl.o mach-imx6sl.o | 103 | obj-$(CONFIG_SOC_IMX6SL) += clk-imx6sl.o mach-imx6sl.o |
104 | obj-$(CONFIG_SOC_IMX6SX) += clk-imx6sx.o mach-imx6sx.o | ||
104 | 105 | ||
105 | ifeq ($(CONFIG_SUSPEND),y) | 106 | ifeq ($(CONFIG_SUSPEND),y) |
106 | AFLAGS_suspend-imx6.o :=-Wa,-march=armv7-a | 107 | AFLAGS_suspend-imx6.o :=-Wa,-march=armv7-a |
diff --git a/arch/arm/mach-imx/cpu.c b/arch/arm/mach-imx/cpu.c index ba3b498a67ec..bbe8ff1f0412 100644 --- a/arch/arm/mach-imx/cpu.c +++ b/arch/arm/mach-imx/cpu.c | |||
@@ -111,6 +111,9 @@ struct device * __init imx_soc_device_init(void) | |||
111 | case MXC_CPU_IMX6DL: | 111 | case MXC_CPU_IMX6DL: |
112 | soc_id = "i.MX6DL"; | 112 | soc_id = "i.MX6DL"; |
113 | break; | 113 | break; |
114 | case MXC_CPU_IMX6SX: | ||
115 | soc_id = "i.MX6SX"; | ||
116 | break; | ||
114 | case MXC_CPU_IMX6Q: | 117 | case MXC_CPU_IMX6Q: |
115 | soc_id = "i.MX6Q"; | 118 | soc_id = "i.MX6Q"; |
116 | break; | 119 | break; |
diff --git a/arch/arm/mach-imx/mach-imx6sx.c b/arch/arm/mach-imx/mach-imx6sx.c new file mode 100644 index 000000000000..02fccf6033ac --- /dev/null +++ b/arch/arm/mach-imx/mach-imx6sx.c | |||
@@ -0,0 +1,51 @@ | |||
1 | /* | ||
2 | * Copyright 2014 Freescale Semiconductor, Inc. | ||
3 | * | ||
4 | * This program is free software; you can redistribute it and/or modify | ||
5 | * it under the terms of the GNU General Public License version 2 as | ||
6 | * published by the Free Software Foundation. | ||
7 | */ | ||
8 | |||
9 | #include <linux/irqchip.h> | ||
10 | #include <linux/of_platform.h> | ||
11 | #include <asm/mach/arch.h> | ||
12 | #include <asm/mach/map.h> | ||
13 | |||
14 | #include "common.h" | ||
15 | |||
16 | static void __init imx6sx_init_machine(void) | ||
17 | { | ||
18 | struct device *parent; | ||
19 | |||
20 | mxc_arch_reset_init_dt(); | ||
21 | |||
22 | parent = imx_soc_device_init(); | ||
23 | if (parent == NULL) | ||
24 | pr_warn("failed to initialize soc device\n"); | ||
25 | |||
26 | of_platform_populate(NULL, of_default_bus_match_table, NULL, parent); | ||
27 | |||
28 | imx_anatop_init(); | ||
29 | } | ||
30 | |||
31 | static void __init imx6sx_init_irq(void) | ||
32 | { | ||
33 | imx_init_revision_from_anatop(); | ||
34 | imx_init_l2cache(); | ||
35 | imx_src_init(); | ||
36 | imx_gpc_init(); | ||
37 | irqchip_init(); | ||
38 | } | ||
39 | |||
40 | static const char *imx6sx_dt_compat[] __initconst = { | ||
41 | "fsl,imx6sx", | ||
42 | NULL, | ||
43 | }; | ||
44 | |||
45 | DT_MACHINE_START(IMX6SX, "Freescale i.MX6 SoloX (Device Tree)") | ||
46 | .map_io = debug_ll_io_init, | ||
47 | .init_irq = imx6sx_init_irq, | ||
48 | .init_machine = imx6sx_init_machine, | ||
49 | .dt_compat = imx6sx_dt_compat, | ||
50 | .restart = mxc_restart, | ||
51 | MACHINE_END | ||
diff --git a/arch/arm/mach-imx/mxc.h b/arch/arm/mach-imx/mxc.h index b08ab3ad4a6d..75d6a37e1ae4 100644 --- a/arch/arm/mach-imx/mxc.h +++ b/arch/arm/mach-imx/mxc.h | |||
@@ -36,6 +36,7 @@ | |||
36 | #define MXC_CPU_MX53 53 | 36 | #define MXC_CPU_MX53 53 |
37 | #define MXC_CPU_IMX6SL 0x60 | 37 | #define MXC_CPU_IMX6SL 0x60 |
38 | #define MXC_CPU_IMX6DL 0x61 | 38 | #define MXC_CPU_IMX6DL 0x61 |
39 | #define MXC_CPU_IMX6SX 0x62 | ||
39 | #define MXC_CPU_IMX6Q 0x63 | 40 | #define MXC_CPU_IMX6Q 0x63 |
40 | 41 | ||
41 | #define IMX_CHIP_REVISION_1_0 0x10 | 42 | #define IMX_CHIP_REVISION_1_0 0x10 |
@@ -163,6 +164,11 @@ static inline bool cpu_is_imx6dl(void) | |||
163 | return __mxc_cpu_type == MXC_CPU_IMX6DL; | 164 | return __mxc_cpu_type == MXC_CPU_IMX6DL; |
164 | } | 165 | } |
165 | 166 | ||
167 | static inline bool cpu_is_imx6sx(void) | ||
168 | { | ||
169 | return __mxc_cpu_type == MXC_CPU_IMX6SX; | ||
170 | } | ||
171 | |||
166 | static inline bool cpu_is_imx6q(void) | 172 | static inline bool cpu_is_imx6q(void) |
167 | { | 173 | { |
168 | return __mxc_cpu_type == MXC_CPU_IMX6Q; | 174 | return __mxc_cpu_type == MXC_CPU_IMX6Q; |