diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-05-02 12:03:55 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-05-02 12:03:55 -0400 |
commit | a7726350e06401929eac0aa0677a5467106565fc (patch) | |
tree | e189513e5014bdfccd73a3af731a6b57733743fa /arch/arm/mach-imx | |
parent | 4d26aa305414dbb33b3c32fb205b68004cda8ffc (diff) | |
parent | afcf7924ecab726dab0227188783c4a40d9f0eec (diff) |
Merge tag 'cleanup-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc
Pull ARM SoC cleanup from Olof Johansson:
"Here is a collection of cleanup patches. Among the pieces that stand
out are:
- The deletion of h720x platforms
- Split of at91 non-dt platforms to their own Kconfig file to keep
them separate
- General cleanups and refactoring of i.MX and MXS platforms
- Some restructuring of clock tables for OMAP
- Convertion of PMC driver for Tegra to dt-only
- Some renames of sunxi -> sun4i (Allwinner A10)
- ... plus a bunch of other stuff that I haven't mentioned"
* tag 'cleanup-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (119 commits)
ARM: i.MX: remove unused ARCH_* configs
ARM i.MX53: remove platform ahci support
ARM: sunxi: Rework the restart code
irqchip: sunxi: Rename sunxi to sun4i
irqchip: sunxi: Make use of the IRQCHIP_DECLARE macro
clocksource: sunxi: Rename sunxi to sun4i
clocksource: sunxi: make use of CLKSRC_OF
clocksource: sunxi: Cleanup the timer code
ARM: at91: remove trailing semicolon from macros
ARM: at91/setup: fix trivial typos
ARM: EXYNOS: remove "config EXYNOS_DEV_DRM"
ARM: EXYNOS: change the name of USB ohci header
ARM: SAMSUNG: Remove unnecessary code for dma
ARM: S3C24XX: Remove unused GPIO drive strength register definitions
ARM: OMAP4+: PM: Restore CPU power state to ON with clockdomain force wakeup method
ARM: S3C24XX: Removed unneeded dependency on CPU_S3C2412
ARM: S3C24XX: Removed unneeded dependency on CPU_S3C2410
ARM: S3C24XX: Removed unneeded dependency on ARCH_S3C24XX for boards
ARM: SAMSUNG: Fix typo "CONFIG_SAMSUNG_DEV_RTC"
ARM: S5P64X0: Fix typo "CONFIG_S5P64X0_SETUP_SDHCI"
...
Diffstat (limited to 'arch/arm/mach-imx')
-rw-r--r-- | arch/arm/mach-imx/Kconfig | 18 | ||||
-rw-r--r-- | arch/arm/mach-imx/Makefile | 3 | ||||
-rw-r--r-- | arch/arm/mach-imx/Makefile.boot | 35 | ||||
-rw-r--r-- | arch/arm/mach-imx/avic.c | 4 | ||||
-rw-r--r-- | arch/arm/mach-imx/clk-imx27.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-imx/common.h | 3 | ||||
-rw-r--r-- | arch/arm/mach-imx/cpu_op-mx51.c | 31 | ||||
-rw-r--r-- | arch/arm/mach-imx/cpu_op-mx51.h | 14 | ||||
-rw-r--r-- | arch/arm/mach-imx/cpufreq.c | 202 | ||||
-rw-r--r-- | arch/arm/mach-imx/devices/Kconfig | 4 | ||||
-rw-r--r-- | arch/arm/mach-imx/devices/Makefile | 1 | ||||
-rw-r--r-- | arch/arm/mach-imx/devices/devices-common.h | 10 | ||||
-rw-r--r-- | arch/arm/mach-imx/devices/platform-ahci-imx.c | 157 | ||||
-rw-r--r-- | arch/arm/mach-imx/hardware.h | 1 | ||||
-rw-r--r-- | arch/arm/mach-imx/mach-cpuimx51sd.c | 5 | ||||
-rw-r--r-- | arch/arm/mach-imx/mach-imx6q.c | 5 | ||||
-rw-r--r-- | arch/arm/mach-imx/mach-mx51_babbage.c | 4 | ||||
-rw-r--r-- | arch/arm/mach-imx/mx6q.h | 31 | ||||
-rw-r--r-- | arch/arm/mach-imx/platsmp.c | 12 |
19 files changed, 5 insertions, 537 deletions
diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig index 4c9c6f9d2c55..6575e4ebe26e 100644 --- a/arch/arm/mach-imx/Kconfig +++ b/arch/arm/mach-imx/Kconfig | |||
@@ -83,24 +83,12 @@ config ARCH_MXC_IOMUX_V3 | |||
83 | config ARCH_MX1 | 83 | config ARCH_MX1 |
84 | bool | 84 | bool |
85 | 85 | ||
86 | config MACH_MX21 | ||
87 | bool | ||
88 | |||
89 | config ARCH_MX25 | 86 | config ARCH_MX25 |
90 | bool | 87 | bool |
91 | 88 | ||
92 | config MACH_MX27 | 89 | config MACH_MX27 |
93 | bool | 90 | bool |
94 | 91 | ||
95 | config ARCH_MX5 | ||
96 | bool | ||
97 | |||
98 | config ARCH_MX51 | ||
99 | bool | ||
100 | |||
101 | config ARCH_MX53 | ||
102 | bool | ||
103 | |||
104 | config SOC_IMX1 | 92 | config SOC_IMX1 |
105 | bool | 93 | bool |
106 | select ARCH_MX1 | 94 | select ARCH_MX1 |
@@ -114,7 +102,6 @@ config SOC_IMX21 | |||
114 | select COMMON_CLK | 102 | select COMMON_CLK |
115 | select CPU_ARM926T | 103 | select CPU_ARM926T |
116 | select IMX_HAVE_IOMUX_V1 | 104 | select IMX_HAVE_IOMUX_V1 |
117 | select MACH_MX21 | ||
118 | select MXC_AVIC | 105 | select MXC_AVIC |
119 | 106 | ||
120 | config SOC_IMX25 | 107 | config SOC_IMX25 |
@@ -155,7 +142,6 @@ config SOC_IMX35 | |||
155 | config SOC_IMX5 | 142 | config SOC_IMX5 |
156 | bool | 143 | bool |
157 | select ARCH_HAS_CPUFREQ | 144 | select ARCH_HAS_CPUFREQ |
158 | select ARCH_MX5 | ||
159 | select ARCH_MXC_IOMUX_V3 | 145 | select ARCH_MXC_IOMUX_V3 |
160 | select COMMON_CLK | 146 | select COMMON_CLK |
161 | select CPU_V7 | 147 | select CPU_V7 |
@@ -163,8 +149,6 @@ config SOC_IMX5 | |||
163 | 149 | ||
164 | config SOC_IMX51 | 150 | config SOC_IMX51 |
165 | bool | 151 | bool |
166 | select ARCH_MX5 | ||
167 | select ARCH_MX51 | ||
168 | select PINCTRL | 152 | select PINCTRL |
169 | select PINCTRL_IMX51 | 153 | select PINCTRL_IMX51 |
170 | select SOC_IMX5 | 154 | select SOC_IMX5 |
@@ -789,8 +773,6 @@ comment "Device tree only" | |||
789 | 773 | ||
790 | config SOC_IMX53 | 774 | config SOC_IMX53 |
791 | bool "i.MX53 support" | 775 | bool "i.MX53 support" |
792 | select ARCH_MX5 | ||
793 | select ARCH_MX53 | ||
794 | select HAVE_CAN_FLEXCAN if CAN | 776 | select HAVE_CAN_FLEXCAN if CAN |
795 | select IMX_HAVE_PLATFORM_IMX2_WDT | 777 | select IMX_HAVE_PLATFORM_IMX2_WDT |
796 | select PINCTRL | 778 | select PINCTRL |
diff --git a/arch/arm/mach-imx/Makefile b/arch/arm/mach-imx/Makefile index cb70961b6239..fbe60a145344 100644 --- a/arch/arm/mach-imx/Makefile +++ b/arch/arm/mach-imx/Makefile | |||
@@ -12,7 +12,7 @@ obj-$(CONFIG_SOC_IMX31) += mm-imx3.o cpu-imx31.o clk-imx31.o iomux-imx31.o ehci- | |||
12 | obj-$(CONFIG_SOC_IMX35) += mm-imx3.o cpu-imx35.o clk-imx35.o ehci-imx35.o pm-imx3.o | 12 | obj-$(CONFIG_SOC_IMX35) += mm-imx3.o cpu-imx35.o clk-imx35.o ehci-imx35.o pm-imx3.o |
13 | 13 | ||
14 | imx5-pm-$(CONFIG_PM) += pm-imx5.o | 14 | imx5-pm-$(CONFIG_PM) += pm-imx5.o |
15 | obj-$(CONFIG_SOC_IMX5) += cpu-imx5.o mm-imx5.o clk-imx51-imx53.o ehci-imx5.o $(imx5-pm-y) cpu_op-mx51.o | 15 | obj-$(CONFIG_SOC_IMX5) += cpu-imx5.o mm-imx5.o clk-imx51-imx53.o ehci-imx5.o $(imx5-pm-y) |
16 | 16 | ||
17 | obj-$(CONFIG_COMMON_CLK) += clk-pllv1.o clk-pllv2.o clk-pllv3.o clk-gate2.o \ | 17 | obj-$(CONFIG_COMMON_CLK) += clk-pllv1.o clk-pllv2.o clk-pllv3.o clk-gate2.o \ |
18 | clk-pfd.o clk-busy.o clk.o | 18 | clk-pfd.o clk-busy.o clk.o |
@@ -27,7 +27,6 @@ obj-$(CONFIG_IRAM_ALLOC) += iram_alloc.o | |||
27 | obj-$(CONFIG_MXC_ULPI) += ulpi.o | 27 | obj-$(CONFIG_MXC_ULPI) += ulpi.o |
28 | obj-$(CONFIG_MXC_USE_EPIT) += epit.o | 28 | obj-$(CONFIG_MXC_USE_EPIT) += epit.o |
29 | obj-$(CONFIG_MXC_DEBUG_BOARD) += 3ds_debugboard.o | 29 | obj-$(CONFIG_MXC_DEBUG_BOARD) += 3ds_debugboard.o |
30 | obj-$(CONFIG_CPU_FREQ_IMX) += cpufreq.o | ||
31 | 30 | ||
32 | ifeq ($(CONFIG_CPU_IDLE),y) | 31 | ifeq ($(CONFIG_CPU_IDLE),y) |
33 | obj-$(CONFIG_SOC_IMX5) += cpuidle-imx5.o | 32 | obj-$(CONFIG_SOC_IMX5) += cpuidle-imx5.o |
diff --git a/arch/arm/mach-imx/Makefile.boot b/arch/arm/mach-imx/Makefile.boot deleted file mode 100644 index 41ba1bb0437b..000000000000 --- a/arch/arm/mach-imx/Makefile.boot +++ /dev/null | |||
@@ -1,35 +0,0 @@ | |||
1 | zreladdr-$(CONFIG_SOC_IMX1) += 0x08008000 | ||
2 | params_phys-$(CONFIG_SOC_IMX1) := 0x08000100 | ||
3 | initrd_phys-$(CONFIG_SOC_IMX1) := 0x08800000 | ||
4 | |||
5 | zreladdr-$(CONFIG_SOC_IMX21) += 0xC0008000 | ||
6 | params_phys-$(CONFIG_SOC_IMX21) := 0xC0000100 | ||
7 | initrd_phys-$(CONFIG_SOC_IMX21) := 0xC0800000 | ||
8 | |||
9 | zreladdr-$(CONFIG_SOC_IMX25) += 0x80008000 | ||
10 | params_phys-$(CONFIG_SOC_IMX25) := 0x80000100 | ||
11 | initrd_phys-$(CONFIG_SOC_IMX25) := 0x80800000 | ||
12 | |||
13 | zreladdr-$(CONFIG_SOC_IMX27) += 0xA0008000 | ||
14 | params_phys-$(CONFIG_SOC_IMX27) := 0xA0000100 | ||
15 | initrd_phys-$(CONFIG_SOC_IMX27) := 0xA0800000 | ||
16 | |||
17 | zreladdr-$(CONFIG_SOC_IMX31) += 0x80008000 | ||
18 | params_phys-$(CONFIG_SOC_IMX31) := 0x80000100 | ||
19 | initrd_phys-$(CONFIG_SOC_IMX31) := 0x80800000 | ||
20 | |||
21 | zreladdr-$(CONFIG_SOC_IMX35) += 0x80008000 | ||
22 | params_phys-$(CONFIG_SOC_IMX35) := 0x80000100 | ||
23 | initrd_phys-$(CONFIG_SOC_IMX35) := 0x80800000 | ||
24 | |||
25 | zreladdr-$(CONFIG_SOC_IMX51) += 0x90008000 | ||
26 | params_phys-$(CONFIG_SOC_IMX51) := 0x90000100 | ||
27 | initrd_phys-$(CONFIG_SOC_IMX51) := 0x90800000 | ||
28 | |||
29 | zreladdr-$(CONFIG_SOC_IMX53) += 0x70008000 | ||
30 | params_phys-$(CONFIG_SOC_IMX53) := 0x70000100 | ||
31 | initrd_phys-$(CONFIG_SOC_IMX53) := 0x70800000 | ||
32 | |||
33 | zreladdr-$(CONFIG_SOC_IMX6Q) += 0x10008000 | ||
34 | params_phys-$(CONFIG_SOC_IMX6Q) := 0x10000100 | ||
35 | initrd_phys-$(CONFIG_SOC_IMX6Q) := 0x10800000 | ||
diff --git a/arch/arm/mach-imx/avic.c b/arch/arm/mach-imx/avic.c index 9c3e014705b1..e163ec7a8441 100644 --- a/arch/arm/mach-imx/avic.c +++ b/arch/arm/mach-imx/avic.c | |||
@@ -54,8 +54,6 @@ | |||
54 | static void __iomem *avic_base; | 54 | static void __iomem *avic_base; |
55 | static struct irq_domain *domain; | 55 | static struct irq_domain *domain; |
56 | 56 | ||
57 | static u32 avic_saved_mask_reg[2]; | ||
58 | |||
59 | #ifdef CONFIG_MXC_IRQ_PRIOR | 57 | #ifdef CONFIG_MXC_IRQ_PRIOR |
60 | static int avic_irq_set_priority(unsigned char irq, unsigned char prio) | 58 | static int avic_irq_set_priority(unsigned char irq, unsigned char prio) |
61 | { | 59 | { |
@@ -113,6 +111,8 @@ static struct mxc_extra_irq avic_extra_irq = { | |||
113 | }; | 111 | }; |
114 | 112 | ||
115 | #ifdef CONFIG_PM | 113 | #ifdef CONFIG_PM |
114 | static u32 avic_saved_mask_reg[2]; | ||
115 | |||
116 | static void avic_irq_suspend(struct irq_data *d) | 116 | static void avic_irq_suspend(struct irq_data *d) |
117 | { | 117 | { |
118 | struct irq_chip_generic *gc = irq_data_get_irq_chip_data(d); | 118 | struct irq_chip_generic *gc = irq_data_get_irq_chip_data(d); |
diff --git a/arch/arm/mach-imx/clk-imx27.c b/arch/arm/mach-imx/clk-imx27.c index 30b3242a7d49..8e3b65719106 100644 --- a/arch/arm/mach-imx/clk-imx27.c +++ b/arch/arm/mach-imx/clk-imx27.c | |||
@@ -278,8 +278,6 @@ int __init mx27_clocks_init(unsigned long fref) | |||
278 | clk_register_clkdev(clk[scc_ipg_gate], "scc", NULL); | 278 | clk_register_clkdev(clk[scc_ipg_gate], "scc", NULL); |
279 | clk_register_clkdev(clk[cpu_div], "cpu", NULL); | 279 | clk_register_clkdev(clk[cpu_div], "cpu", NULL); |
280 | clk_register_clkdev(clk[emi_ahb_gate], "emi_ahb" , NULL); | 280 | clk_register_clkdev(clk[emi_ahb_gate], "emi_ahb" , NULL); |
281 | clk_register_clkdev(clk[ssi1_baud_gate], "bitrate" , "imx-ssi.0"); | ||
282 | clk_register_clkdev(clk[ssi2_baud_gate], "bitrate" , "imx-ssi.1"); | ||
283 | 281 | ||
284 | mxc_timer_init(MX27_IO_ADDRESS(MX27_GPT1_BASE_ADDR), MX27_INT_GPT1); | 282 | mxc_timer_init(MX27_IO_ADDRESS(MX27_GPT1_BASE_ADDR), MX27_INT_GPT1); |
285 | 283 | ||
diff --git a/arch/arm/mach-imx/common.h b/arch/arm/mach-imx/common.h index 5bf4a97ab241..9fea2522d7a3 100644 --- a/arch/arm/mach-imx/common.h +++ b/arch/arm/mach-imx/common.h | |||
@@ -113,7 +113,6 @@ extern void imx_set_cpu_jump(int cpu, void *jump_addr); | |||
113 | extern u32 imx_get_cpu_arg(int cpu); | 113 | extern u32 imx_get_cpu_arg(int cpu); |
114 | extern void imx_set_cpu_arg(int cpu, u32 arg); | 114 | extern void imx_set_cpu_arg(int cpu, u32 arg); |
115 | extern void v7_cpu_resume(void); | 115 | extern void v7_cpu_resume(void); |
116 | extern u32 *pl310_get_save_ptr(void); | ||
117 | #ifdef CONFIG_SMP | 116 | #ifdef CONFIG_SMP |
118 | extern void v7_secondary_startup(void); | 117 | extern void v7_secondary_startup(void); |
119 | extern void imx_scu_map_io(void); | 118 | extern void imx_scu_map_io(void); |
@@ -124,8 +123,6 @@ static inline void imx_scu_map_io(void) {} | |||
124 | static inline void imx_smp_prepare(void) {} | 123 | static inline void imx_smp_prepare(void) {} |
125 | static inline void imx_scu_standby_enable(void) {} | 124 | static inline void imx_scu_standby_enable(void) {} |
126 | #endif | 125 | #endif |
127 | extern void imx_enable_cpu(int cpu, bool enable); | ||
128 | extern void imx_set_cpu_jump(int cpu, void *jump_addr); | ||
129 | extern void imx_src_init(void); | 126 | extern void imx_src_init(void); |
130 | extern void imx_src_prepare_restart(void); | 127 | extern void imx_src_prepare_restart(void); |
131 | extern void imx_gpc_init(void); | 128 | extern void imx_gpc_init(void); |
diff --git a/arch/arm/mach-imx/cpu_op-mx51.c b/arch/arm/mach-imx/cpu_op-mx51.c deleted file mode 100644 index b9ef692b61a2..000000000000 --- a/arch/arm/mach-imx/cpu_op-mx51.c +++ /dev/null | |||
@@ -1,31 +0,0 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2010 Freescale Semiconductor, Inc. All Rights Reserved. | ||
3 | */ | ||
4 | |||
5 | /* | ||
6 | * The code contained herein is licensed under the GNU General Public | ||
7 | * License. You may obtain a copy of the GNU General Public License | ||
8 | * Version 2 or later at the following locations: | ||
9 | * | ||
10 | * http://www.opensource.org/licenses/gpl-license.html | ||
11 | * http://www.gnu.org/copyleft/gpl.html | ||
12 | */ | ||
13 | |||
14 | #include <linux/bug.h> | ||
15 | #include <linux/types.h> | ||
16 | #include <linux/kernel.h> | ||
17 | |||
18 | #include "hardware.h" | ||
19 | |||
20 | static struct cpu_op mx51_cpu_op[] = { | ||
21 | { | ||
22 | .cpu_rate = 160000000,}, | ||
23 | { | ||
24 | .cpu_rate = 800000000,}, | ||
25 | }; | ||
26 | |||
27 | struct cpu_op *mx51_get_cpu_op(int *op) | ||
28 | { | ||
29 | *op = ARRAY_SIZE(mx51_cpu_op); | ||
30 | return mx51_cpu_op; | ||
31 | } | ||
diff --git a/arch/arm/mach-imx/cpu_op-mx51.h b/arch/arm/mach-imx/cpu_op-mx51.h deleted file mode 100644 index 97477fecb469..000000000000 --- a/arch/arm/mach-imx/cpu_op-mx51.h +++ /dev/null | |||
@@ -1,14 +0,0 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2010 Freescale Semiconductor, Inc. All Rights Reserved. | ||
3 | */ | ||
4 | |||
5 | /* | ||
6 | * The code contained herein is licensed under the GNU General Public | ||
7 | * License. You may obtain a copy of the GNU General Public License | ||
8 | * Version 2 or later at the following locations: | ||
9 | * | ||
10 | * http://www.opensource.org/licenses/gpl-license.html | ||
11 | * http://www.gnu.org/copyleft/gpl.html | ||
12 | */ | ||
13 | |||
14 | extern struct cpu_op *mx51_get_cpu_op(int *op); | ||
diff --git a/arch/arm/mach-imx/cpufreq.c b/arch/arm/mach-imx/cpufreq.c deleted file mode 100644 index 387dc4cceca2..000000000000 --- a/arch/arm/mach-imx/cpufreq.c +++ /dev/null | |||
@@ -1,202 +0,0 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2010 Freescale Semiconductor, Inc. All Rights Reserved. | ||
3 | */ | ||
4 | |||
5 | /* | ||
6 | * The code contained herein is licensed under the GNU General Public | ||
7 | * License. You may obtain a copy of the GNU General Public License | ||
8 | * Version 2 or later at the following locations: | ||
9 | * | ||
10 | * http://www.opensource.org/licenses/gpl-license.html | ||
11 | * http://www.gnu.org/copyleft/gpl.html | ||
12 | */ | ||
13 | |||
14 | /* | ||
15 | * A driver for the Freescale Semiconductor i.MXC CPUfreq module. | ||
16 | * The CPUFREQ driver is for controlling CPU frequency. It allows you to change | ||
17 | * the CPU clock speed on the fly. | ||
18 | */ | ||
19 | |||
20 | #include <linux/module.h> | ||
21 | #include <linux/cpufreq.h> | ||
22 | #include <linux/clk.h> | ||
23 | #include <linux/err.h> | ||
24 | #include <linux/slab.h> | ||
25 | |||
26 | #include "hardware.h" | ||
27 | |||
28 | #define CLK32_FREQ 32768 | ||
29 | #define NANOSECOND (1000 * 1000 * 1000) | ||
30 | |||
31 | struct cpu_op *(*get_cpu_op)(int *op); | ||
32 | |||
33 | static int cpu_freq_khz_min; | ||
34 | static int cpu_freq_khz_max; | ||
35 | |||
36 | static struct clk *cpu_clk; | ||
37 | static struct cpufreq_frequency_table *imx_freq_table; | ||
38 | |||
39 | static int cpu_op_nr; | ||
40 | static struct cpu_op *cpu_op_tbl; | ||
41 | |||
42 | static int set_cpu_freq(int freq) | ||
43 | { | ||
44 | int ret = 0; | ||
45 | int org_cpu_rate; | ||
46 | |||
47 | org_cpu_rate = clk_get_rate(cpu_clk); | ||
48 | if (org_cpu_rate == freq) | ||
49 | return ret; | ||
50 | |||
51 | ret = clk_set_rate(cpu_clk, freq); | ||
52 | if (ret != 0) { | ||
53 | printk(KERN_DEBUG "cannot set CPU clock rate\n"); | ||
54 | return ret; | ||
55 | } | ||
56 | |||
57 | return ret; | ||
58 | } | ||
59 | |||
60 | static int mxc_verify_speed(struct cpufreq_policy *policy) | ||
61 | { | ||
62 | if (policy->cpu != 0) | ||
63 | return -EINVAL; | ||
64 | |||
65 | return cpufreq_frequency_table_verify(policy, imx_freq_table); | ||
66 | } | ||
67 | |||
68 | static unsigned int mxc_get_speed(unsigned int cpu) | ||
69 | { | ||
70 | if (cpu) | ||
71 | return 0; | ||
72 | |||
73 | return clk_get_rate(cpu_clk) / 1000; | ||
74 | } | ||
75 | |||
76 | static int mxc_set_target(struct cpufreq_policy *policy, | ||
77 | unsigned int target_freq, unsigned int relation) | ||
78 | { | ||
79 | struct cpufreq_freqs freqs; | ||
80 | int freq_Hz; | ||
81 | int ret = 0; | ||
82 | unsigned int index; | ||
83 | |||
84 | cpufreq_frequency_table_target(policy, imx_freq_table, | ||
85 | target_freq, relation, &index); | ||
86 | freq_Hz = imx_freq_table[index].frequency * 1000; | ||
87 | |||
88 | freqs.old = clk_get_rate(cpu_clk) / 1000; | ||
89 | freqs.new = freq_Hz / 1000; | ||
90 | freqs.flags = 0; | ||
91 | cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE); | ||
92 | |||
93 | ret = set_cpu_freq(freq_Hz); | ||
94 | |||
95 | cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE); | ||
96 | |||
97 | return ret; | ||
98 | } | ||
99 | |||
100 | static int mxc_cpufreq_init(struct cpufreq_policy *policy) | ||
101 | { | ||
102 | int ret; | ||
103 | int i; | ||
104 | |||
105 | printk(KERN_INFO "i.MXC CPU frequency driver\n"); | ||
106 | |||
107 | if (policy->cpu != 0) | ||
108 | return -EINVAL; | ||
109 | |||
110 | if (!get_cpu_op) | ||
111 | return -EINVAL; | ||
112 | |||
113 | cpu_clk = clk_get(NULL, "cpu_clk"); | ||
114 | if (IS_ERR(cpu_clk)) { | ||
115 | printk(KERN_ERR "%s: failed to get cpu clock\n", __func__); | ||
116 | return PTR_ERR(cpu_clk); | ||
117 | } | ||
118 | |||
119 | cpu_op_tbl = get_cpu_op(&cpu_op_nr); | ||
120 | |||
121 | cpu_freq_khz_min = cpu_op_tbl[0].cpu_rate / 1000; | ||
122 | cpu_freq_khz_max = cpu_op_tbl[0].cpu_rate / 1000; | ||
123 | |||
124 | imx_freq_table = kmalloc( | ||
125 | sizeof(struct cpufreq_frequency_table) * (cpu_op_nr + 1), | ||
126 | GFP_KERNEL); | ||
127 | if (!imx_freq_table) { | ||
128 | ret = -ENOMEM; | ||
129 | goto err1; | ||
130 | } | ||
131 | |||
132 | for (i = 0; i < cpu_op_nr; i++) { | ||
133 | imx_freq_table[i].index = i; | ||
134 | imx_freq_table[i].frequency = cpu_op_tbl[i].cpu_rate / 1000; | ||
135 | |||
136 | if ((cpu_op_tbl[i].cpu_rate / 1000) < cpu_freq_khz_min) | ||
137 | cpu_freq_khz_min = cpu_op_tbl[i].cpu_rate / 1000; | ||
138 | |||
139 | if ((cpu_op_tbl[i].cpu_rate / 1000) > cpu_freq_khz_max) | ||
140 | cpu_freq_khz_max = cpu_op_tbl[i].cpu_rate / 1000; | ||
141 | } | ||
142 | |||
143 | imx_freq_table[i].index = i; | ||
144 | imx_freq_table[i].frequency = CPUFREQ_TABLE_END; | ||
145 | |||
146 | policy->cur = clk_get_rate(cpu_clk) / 1000; | ||
147 | |||
148 | /* Manual states, that PLL stabilizes in two CLK32 periods */ | ||
149 | policy->cpuinfo.transition_latency = 2 * NANOSECOND / CLK32_FREQ; | ||
150 | |||
151 | ret = cpufreq_frequency_table_cpuinfo(policy, imx_freq_table); | ||
152 | if (ret < 0) { | ||
153 | printk(KERN_ERR "%s: failed to register i.MXC CPUfreq with error code %d\n", | ||
154 | __func__, ret); | ||
155 | goto err; | ||
156 | } | ||
157 | |||
158 | cpufreq_frequency_table_get_attr(imx_freq_table, policy->cpu); | ||
159 | return 0; | ||
160 | err: | ||
161 | kfree(imx_freq_table); | ||
162 | err1: | ||
163 | clk_put(cpu_clk); | ||
164 | return ret; | ||
165 | } | ||
166 | |||
167 | static int mxc_cpufreq_exit(struct cpufreq_policy *policy) | ||
168 | { | ||
169 | cpufreq_frequency_table_put_attr(policy->cpu); | ||
170 | |||
171 | set_cpu_freq(cpu_freq_khz_max * 1000); | ||
172 | clk_put(cpu_clk); | ||
173 | kfree(imx_freq_table); | ||
174 | return 0; | ||
175 | } | ||
176 | |||
177 | static struct cpufreq_driver mxc_driver = { | ||
178 | .flags = CPUFREQ_STICKY, | ||
179 | .verify = mxc_verify_speed, | ||
180 | .target = mxc_set_target, | ||
181 | .get = mxc_get_speed, | ||
182 | .init = mxc_cpufreq_init, | ||
183 | .exit = mxc_cpufreq_exit, | ||
184 | .name = "imx", | ||
185 | }; | ||
186 | |||
187 | static int mxc_cpufreq_driver_init(void) | ||
188 | { | ||
189 | return cpufreq_register_driver(&mxc_driver); | ||
190 | } | ||
191 | |||
192 | static void mxc_cpufreq_driver_exit(void) | ||
193 | { | ||
194 | cpufreq_unregister_driver(&mxc_driver); | ||
195 | } | ||
196 | |||
197 | module_init(mxc_cpufreq_driver_init); | ||
198 | module_exit(mxc_cpufreq_driver_exit); | ||
199 | |||
200 | MODULE_AUTHOR("Freescale Semiconductor Inc. Yong Shen <yong.shen@linaro.org>"); | ||
201 | MODULE_DESCRIPTION("CPUfreq driver for i.MX"); | ||
202 | MODULE_LICENSE("GPL"); | ||
diff --git a/arch/arm/mach-imx/devices/Kconfig b/arch/arm/mach-imx/devices/Kconfig index 9b9ba1f4ffe1..3dd2b1b041d1 100644 --- a/arch/arm/mach-imx/devices/Kconfig +++ b/arch/arm/mach-imx/devices/Kconfig | |||
@@ -86,7 +86,3 @@ config IMX_HAVE_PLATFORM_SDHCI_ESDHC_IMX | |||
86 | 86 | ||
87 | config IMX_HAVE_PLATFORM_SPI_IMX | 87 | config IMX_HAVE_PLATFORM_SPI_IMX |
88 | bool | 88 | bool |
89 | |||
90 | config IMX_HAVE_PLATFORM_AHCI | ||
91 | bool | ||
92 | default y if ARCH_MX53 | ||
diff --git a/arch/arm/mach-imx/devices/Makefile b/arch/arm/mach-imx/devices/Makefile index 6acf37e0c119..67416fb1dc69 100644 --- a/arch/arm/mach-imx/devices/Makefile +++ b/arch/arm/mach-imx/devices/Makefile | |||
@@ -29,5 +29,4 @@ obj-$(CONFIG_IMX_HAVE_PLATFORM_MXC_RTC) += platform-mxc_rtc.o | |||
29 | obj-$(CONFIG_IMX_HAVE_PLATFORM_MXC_W1) += platform-mxc_w1.o | 29 | obj-$(CONFIG_IMX_HAVE_PLATFORM_MXC_W1) += platform-mxc_w1.o |
30 | obj-$(CONFIG_IMX_HAVE_PLATFORM_SDHCI_ESDHC_IMX) += platform-sdhci-esdhc-imx.o | 30 | obj-$(CONFIG_IMX_HAVE_PLATFORM_SDHCI_ESDHC_IMX) += platform-sdhci-esdhc-imx.o |
31 | obj-$(CONFIG_IMX_HAVE_PLATFORM_SPI_IMX) += platform-spi_imx.o | 31 | obj-$(CONFIG_IMX_HAVE_PLATFORM_SPI_IMX) += platform-spi_imx.o |
32 | obj-$(CONFIG_IMX_HAVE_PLATFORM_AHCI) += platform-ahci-imx.o | ||
33 | obj-$(CONFIG_IMX_HAVE_PLATFORM_MX2_EMMA) += platform-mx2-emma.o | 32 | obj-$(CONFIG_IMX_HAVE_PLATFORM_MX2_EMMA) += platform-mx2-emma.o |
diff --git a/arch/arm/mach-imx/devices/devices-common.h b/arch/arm/mach-imx/devices/devices-common.h index 9bd5777ff0e7..453e20bc2657 100644 --- a/arch/arm/mach-imx/devices/devices-common.h +++ b/arch/arm/mach-imx/devices/devices-common.h | |||
@@ -344,13 +344,3 @@ struct platform_device *imx_add_imx_dma(char *name, resource_size_t iobase, | |||
344 | int irq, int irq_err); | 344 | int irq, int irq_err); |
345 | struct platform_device *imx_add_imx_sdma(char *name, | 345 | struct platform_device *imx_add_imx_sdma(char *name, |
346 | resource_size_t iobase, int irq, struct sdma_platform_data *pdata); | 346 | resource_size_t iobase, int irq, struct sdma_platform_data *pdata); |
347 | |||
348 | #include <linux/ahci_platform.h> | ||
349 | struct imx_ahci_imx_data { | ||
350 | const char *devid; | ||
351 | resource_size_t iobase; | ||
352 | resource_size_t irq; | ||
353 | }; | ||
354 | struct platform_device *__init imx_add_ahci_imx( | ||
355 | const struct imx_ahci_imx_data *data, | ||
356 | const struct ahci_platform_data *pdata); | ||
diff --git a/arch/arm/mach-imx/devices/platform-ahci-imx.c b/arch/arm/mach-imx/devices/platform-ahci-imx.c deleted file mode 100644 index 3d87dd9c284a..000000000000 --- a/arch/arm/mach-imx/devices/platform-ahci-imx.c +++ /dev/null | |||
@@ -1,157 +0,0 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2011 Freescale Semiconductor, Inc. All Rights Reserved. | ||
3 | */ | ||
4 | |||
5 | /* | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License as published by | ||
8 | * the Free Software Foundation; either version 2 of the License, or | ||
9 | * (at your option) any later version. | ||
10 | |||
11 | * This program is distributed in the hope that it will be useful, | ||
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
14 | * GNU General Public License for more details. | ||
15 | |||
16 | * You should have received a copy of the GNU General Public License along | ||
17 | * with this program; if not, write to the Free Software Foundation, Inc., | ||
18 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. | ||
19 | */ | ||
20 | |||
21 | #include <linux/io.h> | ||
22 | #include <linux/clk.h> | ||
23 | #include <linux/err.h> | ||
24 | #include <linux/device.h> | ||
25 | #include <linux/dma-mapping.h> | ||
26 | #include <asm/sizes.h> | ||
27 | |||
28 | #include "../hardware.h" | ||
29 | #include "devices-common.h" | ||
30 | |||
31 | #define imx_ahci_imx_data_entry_single(soc, _devid) \ | ||
32 | { \ | ||
33 | .devid = _devid, \ | ||
34 | .iobase = soc ## _SATA_BASE_ADDR, \ | ||
35 | .irq = soc ## _INT_SATA, \ | ||
36 | } | ||
37 | |||
38 | #ifdef CONFIG_SOC_IMX53 | ||
39 | const struct imx_ahci_imx_data imx53_ahci_imx_data __initconst = | ||
40 | imx_ahci_imx_data_entry_single(MX53, "imx53-ahci"); | ||
41 | #endif | ||
42 | |||
43 | enum { | ||
44 | HOST_CAP = 0x00, | ||
45 | HOST_CAP_SSS = (1 << 27), /* Staggered Spin-up */ | ||
46 | HOST_PORTS_IMPL = 0x0c, | ||
47 | HOST_TIMER1MS = 0xe0, /* Timer 1-ms */ | ||
48 | }; | ||
49 | |||
50 | static struct clk *sata_clk, *sata_ref_clk; | ||
51 | |||
52 | /* AHCI module Initialization, if return 0, initialization is successful. */ | ||
53 | static int imx_sata_init(struct device *dev, void __iomem *addr) | ||
54 | { | ||
55 | u32 tmpdata; | ||
56 | int ret = 0; | ||
57 | struct clk *clk; | ||
58 | |||
59 | sata_clk = clk_get(dev, "ahci"); | ||
60 | if (IS_ERR(sata_clk)) { | ||
61 | dev_err(dev, "no sata clock.\n"); | ||
62 | return PTR_ERR(sata_clk); | ||
63 | } | ||
64 | ret = clk_prepare_enable(sata_clk); | ||
65 | if (ret) { | ||
66 | dev_err(dev, "can't prepare/enable sata clock.\n"); | ||
67 | goto put_sata_clk; | ||
68 | } | ||
69 | |||
70 | /* Get the AHCI SATA PHY CLK */ | ||
71 | sata_ref_clk = clk_get(dev, "ahci_phy"); | ||
72 | if (IS_ERR(sata_ref_clk)) { | ||
73 | dev_err(dev, "no sata ref clock.\n"); | ||
74 | ret = PTR_ERR(sata_ref_clk); | ||
75 | goto release_sata_clk; | ||
76 | } | ||
77 | ret = clk_prepare_enable(sata_ref_clk); | ||
78 | if (ret) { | ||
79 | dev_err(dev, "can't prepare/enable sata ref clock.\n"); | ||
80 | goto put_sata_ref_clk; | ||
81 | } | ||
82 | |||
83 | /* Get the AHB clock rate, and configure the TIMER1MS reg later */ | ||
84 | clk = clk_get(dev, "ahci_dma"); | ||
85 | if (IS_ERR(clk)) { | ||
86 | dev_err(dev, "no dma clock.\n"); | ||
87 | ret = PTR_ERR(clk); | ||
88 | goto release_sata_ref_clk; | ||
89 | } | ||
90 | tmpdata = clk_get_rate(clk) / 1000; | ||
91 | clk_put(clk); | ||
92 | |||
93 | writel(tmpdata, addr + HOST_TIMER1MS); | ||
94 | |||
95 | tmpdata = readl(addr + HOST_CAP); | ||
96 | if (!(tmpdata & HOST_CAP_SSS)) { | ||
97 | tmpdata |= HOST_CAP_SSS; | ||
98 | writel(tmpdata, addr + HOST_CAP); | ||
99 | } | ||
100 | |||
101 | if (!(readl(addr + HOST_PORTS_IMPL) & 0x1)) | ||
102 | writel((readl(addr + HOST_PORTS_IMPL) | 0x1), | ||
103 | addr + HOST_PORTS_IMPL); | ||
104 | |||
105 | return 0; | ||
106 | |||
107 | release_sata_ref_clk: | ||
108 | clk_disable_unprepare(sata_ref_clk); | ||
109 | put_sata_ref_clk: | ||
110 | clk_put(sata_ref_clk); | ||
111 | release_sata_clk: | ||
112 | clk_disable_unprepare(sata_clk); | ||
113 | put_sata_clk: | ||
114 | clk_put(sata_clk); | ||
115 | |||
116 | return ret; | ||
117 | } | ||
118 | |||
119 | static void imx_sata_exit(struct device *dev) | ||
120 | { | ||
121 | clk_disable_unprepare(sata_ref_clk); | ||
122 | clk_put(sata_ref_clk); | ||
123 | |||
124 | clk_disable_unprepare(sata_clk); | ||
125 | clk_put(sata_clk); | ||
126 | |||
127 | } | ||
128 | struct platform_device *__init imx_add_ahci_imx( | ||
129 | const struct imx_ahci_imx_data *data, | ||
130 | const struct ahci_platform_data *pdata) | ||
131 | { | ||
132 | struct resource res[] = { | ||
133 | { | ||
134 | .start = data->iobase, | ||
135 | .end = data->iobase + SZ_4K - 1, | ||
136 | .flags = IORESOURCE_MEM, | ||
137 | }, { | ||
138 | .start = data->irq, | ||
139 | .end = data->irq, | ||
140 | .flags = IORESOURCE_IRQ, | ||
141 | }, | ||
142 | }; | ||
143 | |||
144 | return imx_add_platform_device_dmamask(data->devid, 0, | ||
145 | res, ARRAY_SIZE(res), | ||
146 | pdata, sizeof(*pdata), DMA_BIT_MASK(32)); | ||
147 | } | ||
148 | |||
149 | struct platform_device *__init imx53_add_ahci_imx(void) | ||
150 | { | ||
151 | struct ahci_platform_data pdata = { | ||
152 | .init = imx_sata_init, | ||
153 | .exit = imx_sata_exit, | ||
154 | }; | ||
155 | |||
156 | return imx_add_ahci_imx(&imx53_ahci_imx_data, &pdata); | ||
157 | } | ||
diff --git a/arch/arm/mach-imx/hardware.h b/arch/arm/mach-imx/hardware.h index 911e9b31b03f..356131f7b591 100644 --- a/arch/arm/mach-imx/hardware.h +++ b/arch/arm/mach-imx/hardware.h | |||
@@ -102,7 +102,6 @@ | |||
102 | 102 | ||
103 | #include "mxc.h" | 103 | #include "mxc.h" |
104 | 104 | ||
105 | #include "mx6q.h" | ||
106 | #include "mx51.h" | 105 | #include "mx51.h" |
107 | #include "mx53.h" | 106 | #include "mx53.h" |
108 | #include "mx3x.h" | 107 | #include "mx3x.h" |
diff --git a/arch/arm/mach-imx/mach-cpuimx51sd.c b/arch/arm/mach-imx/mach-cpuimx51sd.c index 9b7393234f6f..9b5ddf5bbd33 100644 --- a/arch/arm/mach-imx/mach-cpuimx51sd.c +++ b/arch/arm/mach-imx/mach-cpuimx51sd.c | |||
@@ -33,7 +33,6 @@ | |||
33 | 33 | ||
34 | #include "common.h" | 34 | #include "common.h" |
35 | #include "devices-imx51.h" | 35 | #include "devices-imx51.h" |
36 | #include "cpu_op-mx51.h" | ||
37 | #include "eukrea-baseboards.h" | 36 | #include "eukrea-baseboards.h" |
38 | #include "hardware.h" | 37 | #include "hardware.h" |
39 | #include "iomux-mx51.h" | 38 | #include "iomux-mx51.h" |
@@ -285,10 +284,6 @@ static void __init eukrea_cpuimx51sd_init(void) | |||
285 | mxc_iomux_v3_setup_multiple_pads(eukrea_cpuimx51sd_pads, | 284 | mxc_iomux_v3_setup_multiple_pads(eukrea_cpuimx51sd_pads, |
286 | ARRAY_SIZE(eukrea_cpuimx51sd_pads)); | 285 | ARRAY_SIZE(eukrea_cpuimx51sd_pads)); |
287 | 286 | ||
288 | #if defined(CONFIG_CPU_FREQ_IMX) | ||
289 | get_cpu_op = mx51_get_cpu_op; | ||
290 | #endif | ||
291 | |||
292 | imx51_add_imx_uart(0, &uart_pdata); | 287 | imx51_add_imx_uart(0, &uart_pdata); |
293 | imx51_add_mxc_nand(&eukrea_cpuimx51sd_nand_board_info); | 288 | imx51_add_mxc_nand(&eukrea_cpuimx51sd_nand_board_info); |
294 | imx51_add_imx2_wdt(0); | 289 | imx51_add_imx2_wdt(0); |
diff --git a/arch/arm/mach-imx/mach-imx6q.c b/arch/arm/mach-imx/mach-imx6q.c index fe1b7aafabdc..99502eeefdf7 100644 --- a/arch/arm/mach-imx/mach-imx6q.c +++ b/arch/arm/mach-imx/mach-imx6q.c | |||
@@ -12,6 +12,7 @@ | |||
12 | 12 | ||
13 | #include <linux/clk.h> | 13 | #include <linux/clk.h> |
14 | #include <linux/clkdev.h> | 14 | #include <linux/clkdev.h> |
15 | #include <linux/clocksource.h> | ||
15 | #include <linux/cpu.h> | 16 | #include <linux/cpu.h> |
16 | #include <linux/delay.h> | 17 | #include <linux/delay.h> |
17 | #include <linux/export.h> | 18 | #include <linux/export.h> |
@@ -28,11 +29,9 @@ | |||
28 | #include <linux/regmap.h> | 29 | #include <linux/regmap.h> |
29 | #include <linux/micrel_phy.h> | 30 | #include <linux/micrel_phy.h> |
30 | #include <linux/mfd/syscon.h> | 31 | #include <linux/mfd/syscon.h> |
31 | #include <asm/smp_twd.h> | ||
32 | #include <asm/hardware/cache-l2x0.h> | 32 | #include <asm/hardware/cache-l2x0.h> |
33 | #include <asm/mach/arch.h> | 33 | #include <asm/mach/arch.h> |
34 | #include <asm/mach/map.h> | 34 | #include <asm/mach/map.h> |
35 | #include <asm/mach/time.h> | ||
36 | #include <asm/system_misc.h> | 35 | #include <asm/system_misc.h> |
37 | 36 | ||
38 | #include "common.h" | 37 | #include "common.h" |
@@ -292,7 +291,7 @@ static void __init imx6q_init_irq(void) | |||
292 | static void __init imx6q_timer_init(void) | 291 | static void __init imx6q_timer_init(void) |
293 | { | 292 | { |
294 | mx6q_clocks_init(); | 293 | mx6q_clocks_init(); |
295 | twd_local_timer_of_register(); | 294 | clocksource_of_init(); |
296 | imx_print_silicon_rev("i.MX6Q", imx6q_revision()); | 295 | imx_print_silicon_rev("i.MX6Q", imx6q_revision()); |
297 | } | 296 | } |
298 | 297 | ||
diff --git a/arch/arm/mach-imx/mach-mx51_babbage.c b/arch/arm/mach-imx/mach-mx51_babbage.c index 6c4d7feb4520..f3d264a636fa 100644 --- a/arch/arm/mach-imx/mach-mx51_babbage.c +++ b/arch/arm/mach-imx/mach-mx51_babbage.c | |||
@@ -27,7 +27,6 @@ | |||
27 | 27 | ||
28 | #include "common.h" | 28 | #include "common.h" |
29 | #include "devices-imx51.h" | 29 | #include "devices-imx51.h" |
30 | #include "cpu_op-mx51.h" | ||
31 | #include "hardware.h" | 30 | #include "hardware.h" |
32 | #include "iomux-mx51.h" | 31 | #include "iomux-mx51.h" |
33 | 32 | ||
@@ -371,9 +370,6 @@ static void __init mx51_babbage_init(void) | |||
371 | 370 | ||
372 | imx51_soc_init(); | 371 | imx51_soc_init(); |
373 | 372 | ||
374 | #if defined(CONFIG_CPU_FREQ_IMX) | ||
375 | get_cpu_op = mx51_get_cpu_op; | ||
376 | #endif | ||
377 | imx51_babbage_common_init(); | 373 | imx51_babbage_common_init(); |
378 | 374 | ||
379 | imx51_add_imx_uart(0, &uart_pdata); | 375 | imx51_add_imx_uart(0, &uart_pdata); |
diff --git a/arch/arm/mach-imx/mx6q.h b/arch/arm/mach-imx/mx6q.h deleted file mode 100644 index 19d3f54db5af..000000000000 --- a/arch/arm/mach-imx/mx6q.h +++ /dev/null | |||
@@ -1,31 +0,0 @@ | |||
1 | /* | ||
2 | * Copyright 2011 Freescale Semiconductor, Inc. All Rights Reserved. | ||
3 | * Copyright 2011 Linaro Ltd. | ||
4 | * | ||
5 | * The code contained herein is licensed under the GNU General Public | ||
6 | * License. You may obtain a copy of the GNU General Public License | ||
7 | * Version 2 or later at the following locations: | ||
8 | * | ||
9 | * http://www.opensource.org/licenses/gpl-license.html | ||
10 | * http://www.gnu.org/copyleft/gpl.html | ||
11 | */ | ||
12 | |||
13 | #ifndef __MACH_MX6Q_H__ | ||
14 | #define __MACH_MX6Q_H__ | ||
15 | |||
16 | #define MX6Q_IO_P2V(x) IMX_IO_P2V(x) | ||
17 | #define MX6Q_IO_ADDRESS(x) IOMEM(MX6Q_IO_P2V(x)) | ||
18 | |||
19 | /* | ||
20 | * The following are the blocks that need to be statically mapped. | ||
21 | * For other blocks, the base address really should be retrieved from | ||
22 | * device tree. | ||
23 | */ | ||
24 | #define MX6Q_SCU_BASE_ADDR 0x00a00000 | ||
25 | #define MX6Q_SCU_SIZE 0x1000 | ||
26 | #define MX6Q_CCM_BASE_ADDR 0x020c4000 | ||
27 | #define MX6Q_CCM_SIZE 0x4000 | ||
28 | #define MX6Q_ANATOP_BASE_ADDR 0x020c8000 | ||
29 | #define MX6Q_ANATOP_SIZE 0x1000 | ||
30 | |||
31 | #endif /* __MACH_MX6Q_H__ */ | ||
diff --git a/arch/arm/mach-imx/platsmp.c b/arch/arm/mach-imx/platsmp.c index 7c0b03f67b05..77e9a25ed0f6 100644 --- a/arch/arm/mach-imx/platsmp.c +++ b/arch/arm/mach-imx/platsmp.c | |||
@@ -12,7 +12,6 @@ | |||
12 | 12 | ||
13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
14 | #include <linux/smp.h> | 14 | #include <linux/smp.h> |
15 | #include <linux/irqchip/arm-gic.h> | ||
16 | #include <asm/page.h> | 15 | #include <asm/page.h> |
17 | #include <asm/smp_scu.h> | 16 | #include <asm/smp_scu.h> |
18 | #include <asm/mach/map.h> | 17 | #include <asm/mach/map.h> |
@@ -52,16 +51,6 @@ void imx_scu_standby_enable(void) | |||
52 | writel_relaxed(val, scu_base); | 51 | writel_relaxed(val, scu_base); |
53 | } | 52 | } |
54 | 53 | ||
55 | static void __cpuinit imx_secondary_init(unsigned int cpu) | ||
56 | { | ||
57 | /* | ||
58 | * if any interrupts are already enabled for the primary | ||
59 | * core (e.g. timer irq), then they will not have been enabled | ||
60 | * for us: do so | ||
61 | */ | ||
62 | gic_secondary_init(0); | ||
63 | } | ||
64 | |||
65 | static int __cpuinit imx_boot_secondary(unsigned int cpu, struct task_struct *idle) | 54 | static int __cpuinit imx_boot_secondary(unsigned int cpu, struct task_struct *idle) |
66 | { | 55 | { |
67 | imx_set_cpu_jump(cpu, v7_secondary_startup); | 56 | imx_set_cpu_jump(cpu, v7_secondary_startup); |
@@ -96,7 +85,6 @@ static void __init imx_smp_prepare_cpus(unsigned int max_cpus) | |||
96 | struct smp_operations imx_smp_ops __initdata = { | 85 | struct smp_operations imx_smp_ops __initdata = { |
97 | .smp_init_cpus = imx_smp_init_cpus, | 86 | .smp_init_cpus = imx_smp_init_cpus, |
98 | .smp_prepare_cpus = imx_smp_prepare_cpus, | 87 | .smp_prepare_cpus = imx_smp_prepare_cpus, |
99 | .smp_secondary_init = imx_secondary_init, | ||
100 | .smp_boot_secondary = imx_boot_secondary, | 88 | .smp_boot_secondary = imx_boot_secondary, |
101 | #ifdef CONFIG_HOTPLUG_CPU | 89 | #ifdef CONFIG_HOTPLUG_CPU |
102 | .cpu_die = imx_cpu_die, | 90 | .cpu_die = imx_cpu_die, |