diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-05-02 12:38:16 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-05-02 12:38:16 -0400 |
commit | 99c6bcf46d2233d33e441834e958ed0bc22b190a (patch) | |
tree | 25abf5e856bc0f08d75e623715eb5acc4d4de2b2 /arch/arm/mach-mxs | |
parent | 97b1007a2924aaa9126398623f6755a8c3c6a616 (diff) | |
parent | 2fdfe1c26fb9f24cfdf124384abb35396ca2cd3f (diff) |
Merge tag 'multiplatform-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc
Pull ARM SoC multiplatform updates from Olof Johansson:
"More multiplatform enablement for ARM platforms. The ones converted
in this branch are:
- bcm2835
- cns3xxx
- sirf
- nomadik
- msx
- spear
- tegra
- ux500
We're getting close to having most of them converted!
One of the larger platforms remaining is Samsung Exynos, and there are
a bunch of supporting patches in this merge window for it. There was
a patch in this branch to a early version of multiplatform conversion,
but it ended up being reverted due to need of more bake time. The
revert commit is part of the branch since it would have required
rebasing multiple dependent branches and they were stable by then"
* tag 'multiplatform-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (70 commits)
mmc: sdhci-s3c: Fix operation on non-single image Samsung platforms
clocksource: nomadik-mtu: fix up clocksource/timer
Revert "ARM: exynos: enable multiplatform support"
ARM: SPEAr13xx: Fix typo "ARCH_HAVE_CPUFREQ"
ARM: exynos: enable multiplatform support
rtc: s3c: make header file local
mtd: onenand/samsung: make regs-onenand.h file local
thermal/exynos: remove unnecessary header inclusions
mmc: sdhci-s3c: remove platform dependencies
ARM: samsung: move mfc device definition to s5p-dev-mfc.c
ARM: exynos: move debug-macro.S to include/debug/
ARM: exynos: prepare for sparse IRQ
ARM: exynos: introduce EXYNOS_ATAGS symbol
ARM: tegra: build assembly files with -march=armv7-a
ARM: Push selects for TWD/SCU into machine entries
ARM: ux500: build hotplug.o for ARMv7-a
ARM: ux500: move to multiplatform
ARM: ux500: make remaining headers local
ARM: ux500: make irqs.h local to platform
ARM: ux500: get rid of <mach/[hardware|db8500-regs].h>
...
Diffstat (limited to 'arch/arm/mach-mxs')
-rw-r--r-- | arch/arm/mach-mxs/Kconfig | 22 | ||||
-rw-r--r-- | arch/arm/mach-mxs/Makefile | 2 | ||||
-rw-r--r-- | arch/arm/mach-mxs/Makefile.boot | 1 | ||||
-rw-r--r-- | arch/arm/mach-mxs/include/mach/debug-macro.S | 27 | ||||
-rw-r--r-- | arch/arm/mach-mxs/include/mach/timex.h | 21 | ||||
-rw-r--r-- | arch/arm/mach-mxs/include/mach/uncompress.h | 76 | ||||
-rw-r--r-- | arch/arm/mach-mxs/mach-mxs.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-mxs/pm.c | 4 | ||||
-rw-r--r-- | arch/arm/mach-mxs/pm.h | 14 |
9 files changed, 31 insertions, 139 deletions
diff --git a/arch/arm/mach-mxs/Kconfig b/arch/arm/mach-mxs/Kconfig index c4495a13751a..4dc2fbba0ecd 100644 --- a/arch/arm/mach-mxs/Kconfig +++ b/arch/arm/mach-mxs/Kconfig | |||
@@ -1,5 +1,3 @@ | |||
1 | if ARCH_MXS | ||
2 | |||
3 | config SOC_IMX23 | 1 | config SOC_IMX23 |
4 | bool | 2 | bool |
5 | select ARM_AMBA | 3 | select ARM_AMBA |
@@ -17,14 +15,18 @@ config SOC_IMX28 | |||
17 | select HAVE_PWM | 15 | select HAVE_PWM |
18 | select PINCTRL_IMX28 | 16 | select PINCTRL_IMX28 |
19 | 17 | ||
20 | comment "MXS platforms:" | 18 | config ARCH_MXS |
21 | 19 | bool "Freescale MXS (i.MX23, i.MX28) support" | |
22 | config MACH_MXS_DT | 20 | depends on ARCH_MULTI_V5 |
23 | bool "Support MXS platforms from device tree" | 21 | select ARCH_REQUIRE_GPIOLIB |
22 | select CLKDEV_LOOKUP | ||
23 | select CLKSRC_MMIO | ||
24 | select CLKSRC_OF | ||
25 | select GENERIC_CLOCKEVENTS | ||
26 | select HAVE_CLK_PREPARE | ||
27 | select PINCTRL | ||
24 | select SOC_IMX23 | 28 | select SOC_IMX23 |
25 | select SOC_IMX28 | 29 | select SOC_IMX28 |
30 | select STMP_DEVICE | ||
26 | help | 31 | help |
27 | Include support for Freescale MXS platforms(i.MX23 and i.MX28) | 32 | Support for Freescale MXS-based family of processors |
28 | using the device tree for discovery | ||
29 | |||
30 | endif | ||
diff --git a/arch/arm/mach-mxs/Makefile b/arch/arm/mach-mxs/Makefile index 80db7269760e..cc2bf6748ade 100644 --- a/arch/arm/mach-mxs/Makefile +++ b/arch/arm/mach-mxs/Makefile | |||
@@ -1,2 +1,2 @@ | |||
1 | obj-$(CONFIG_PM) += pm.o | 1 | obj-$(CONFIG_PM) += pm.o |
2 | obj-$(CONFIG_MACH_MXS_DT) += mach-mxs.o | 2 | obj-$(CONFIG_ARCH_MXS) += mach-mxs.o |
diff --git a/arch/arm/mach-mxs/Makefile.boot b/arch/arm/mach-mxs/Makefile.boot deleted file mode 100644 index 07b11fe6453f..000000000000 --- a/arch/arm/mach-mxs/Makefile.boot +++ /dev/null | |||
@@ -1 +0,0 @@ | |||
1 | zreladdr-y += 0x40008000 | ||
diff --git a/arch/arm/mach-mxs/include/mach/debug-macro.S b/arch/arm/mach-mxs/include/mach/debug-macro.S deleted file mode 100644 index d86951551ca1..000000000000 --- a/arch/arm/mach-mxs/include/mach/debug-macro.S +++ /dev/null | |||
@@ -1,27 +0,0 @@ | |||
1 | /* arch/arm/mach-mxs/include/mach/debug-macro.S | ||
2 | * | ||
3 | * Debugging macro include header | ||
4 | * | ||
5 | * Copyright (C) 1994-1999 Russell King | ||
6 | * Moved from linux/arch/arm/kernel/debug.S by Ben Dooks | ||
7 | * | ||
8 | * This program is free software; you can redistribute it and/or modify | ||
9 | * it under the terms of the GNU General Public License version 2 as | ||
10 | * published by the Free Software Foundation. | ||
11 | * | ||
12 | */ | ||
13 | |||
14 | #ifdef CONFIG_DEBUG_IMX23_UART | ||
15 | #define UART_PADDR 0x80070000 | ||
16 | #elif defined (CONFIG_DEBUG_IMX28_UART) | ||
17 | #define UART_PADDR 0x80074000 | ||
18 | #endif | ||
19 | |||
20 | #define UART_VADDR 0xfe100000 | ||
21 | |||
22 | .macro addruart, rp, rv, tmp | ||
23 | ldr \rp, =UART_PADDR @ physical | ||
24 | ldr \rv, =UART_VADDR @ virtual | ||
25 | .endm | ||
26 | |||
27 | #include <asm/hardware/debug-pl01x.S> | ||
diff --git a/arch/arm/mach-mxs/include/mach/timex.h b/arch/arm/mach-mxs/include/mach/timex.h deleted file mode 100644 index 734ce8984a64..000000000000 --- a/arch/arm/mach-mxs/include/mach/timex.h +++ /dev/null | |||
@@ -1,21 +0,0 @@ | |||
1 | /* | ||
2 | * Copyright (C) 1999 ARM Limited | ||
3 | * Copyright 2004-2007 Freescale Semiconductor, Inc. All Rights Reserved. | ||
4 | * | ||
5 | * This program is free software; you can redistribute it and/or modify | ||
6 | * it under the terms of the GNU General Public License as published by | ||
7 | * the Free Software Foundation; either version 2 of the License, or | ||
8 | * (at your option) any later version. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | */ | ||
15 | |||
16 | #ifndef __MACH_MXS_TIMEX_H__ | ||
17 | #define __MACH_MXS_TIMEX_H__ | ||
18 | |||
19 | #define CLOCK_TICK_RATE 32000 /* 32K */ | ||
20 | |||
21 | #endif /* __MACH_MXS_TIMEX_H__ */ | ||
diff --git a/arch/arm/mach-mxs/include/mach/uncompress.h b/arch/arm/mach-mxs/include/mach/uncompress.h deleted file mode 100644 index 533f5186e200..000000000000 --- a/arch/arm/mach-mxs/include/mach/uncompress.h +++ /dev/null | |||
@@ -1,76 +0,0 @@ | |||
1 | /* | ||
2 | * arch/arm/mach-mxs/include/mach/uncompress.h | ||
3 | * | ||
4 | * Copyright (C) 1999 ARM Limited | ||
5 | * Copyright (C) Shane Nay (shane@minirl.com) | ||
6 | * Copyright 2010 Freescale Semiconductor, Inc. All Rights Reserved. | ||
7 | * | ||
8 | * This program is free software; you can redistribute it and/or modify | ||
9 | * it under the terms of the GNU General Public License as published by | ||
10 | * the Free Software Foundation; either version 2 of the License, or | ||
11 | * (at your option) any later version. | ||
12 | * | ||
13 | * This program is distributed in the hope that it will be useful, | ||
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
16 | * GNU General Public License for more details. | ||
17 | */ | ||
18 | #ifndef __MACH_MXS_UNCOMPRESS_H__ | ||
19 | #define __MACH_MXS_UNCOMPRESS_H__ | ||
20 | |||
21 | unsigned long mxs_duart_base; | ||
22 | |||
23 | #define MXS_DUART(x) (*(volatile unsigned long *)(mxs_duart_base + (x))) | ||
24 | |||
25 | #define MXS_DUART_DR 0x00 | ||
26 | #define MXS_DUART_FR 0x18 | ||
27 | #define MXS_DUART_FR_TXFE (1 << 7) | ||
28 | #define MXS_DUART_CR 0x30 | ||
29 | #define MXS_DUART_CR_UARTEN (1 << 0) | ||
30 | |||
31 | /* | ||
32 | * The following code assumes the serial port has already been | ||
33 | * initialized by the bootloader. If it's not, the output is | ||
34 | * simply discarded. | ||
35 | */ | ||
36 | |||
37 | static void putc(int ch) | ||
38 | { | ||
39 | if (!mxs_duart_base) | ||
40 | return; | ||
41 | if (!(MXS_DUART(MXS_DUART_CR) & MXS_DUART_CR_UARTEN)) | ||
42 | return; | ||
43 | |||
44 | while (!(MXS_DUART(MXS_DUART_FR) & MXS_DUART_FR_TXFE)) | ||
45 | barrier(); | ||
46 | |||
47 | MXS_DUART(MXS_DUART_DR) = ch; | ||
48 | } | ||
49 | |||
50 | static inline void flush(void) | ||
51 | { | ||
52 | } | ||
53 | |||
54 | #define MX23_DUART_BASE_ADDR 0x80070000 | ||
55 | #define MX28_DUART_BASE_ADDR 0x80074000 | ||
56 | #define MXS_DIGCTL_CHIPID 0x8001c310 | ||
57 | |||
58 | static inline void __arch_decomp_setup(unsigned long arch_id) | ||
59 | { | ||
60 | u16 chipid = (*(volatile unsigned long *) MXS_DIGCTL_CHIPID) >> 16; | ||
61 | |||
62 | switch (chipid) { | ||
63 | case 0x3780: | ||
64 | mxs_duart_base = MX23_DUART_BASE_ADDR; | ||
65 | break; | ||
66 | case 0x2800: | ||
67 | mxs_duart_base = MX28_DUART_BASE_ADDR; | ||
68 | break; | ||
69 | default: | ||
70 | break; | ||
71 | } | ||
72 | } | ||
73 | |||
74 | #define arch_decomp_setup() __arch_decomp_setup(arch_id) | ||
75 | |||
76 | #endif /* __MACH_MXS_UNCOMPRESS_H__ */ | ||
diff --git a/arch/arm/mach-mxs/mach-mxs.c b/arch/arm/mach-mxs/mach-mxs.c index 16870bf853b8..b5c1bdd3dcdf 100644 --- a/arch/arm/mach-mxs/mach-mxs.c +++ b/arch/arm/mach-mxs/mach-mxs.c | |||
@@ -32,6 +32,8 @@ | |||
32 | #include <asm/mach/time.h> | 32 | #include <asm/mach/time.h> |
33 | #include <asm/system_misc.h> | 33 | #include <asm/system_misc.h> |
34 | 34 | ||
35 | #include "pm.h" | ||
36 | |||
35 | /* MXS DIGCTL SAIF CLKMUX */ | 37 | /* MXS DIGCTL SAIF CLKMUX */ |
36 | #define MXS_DIGCTL_SAIF_CLKMUX_DIRECT 0x0 | 38 | #define MXS_DIGCTL_SAIF_CLKMUX_DIRECT 0x0 |
37 | #define MXS_DIGCTL_SAIF_CLKMUX_CROSSINPUT 0x1 | 39 | #define MXS_DIGCTL_SAIF_CLKMUX_CROSSINPUT 0x1 |
@@ -607,6 +609,7 @@ DT_MACHINE_START(MXS, "Freescale MXS (Device Tree)") | |||
607 | .handle_irq = icoll_handle_irq, | 609 | .handle_irq = icoll_handle_irq, |
608 | .init_time = mxs_timer_init, | 610 | .init_time = mxs_timer_init, |
609 | .init_machine = mxs_machine_init, | 611 | .init_machine = mxs_machine_init, |
612 | .init_late = mxs_pm_init, | ||
610 | .dt_compat = mxs_dt_compat, | 613 | .dt_compat = mxs_dt_compat, |
611 | .restart = mxs_restart, | 614 | .restart = mxs_restart, |
612 | MACHINE_END | 615 | MACHINE_END |
diff --git a/arch/arm/mach-mxs/pm.c b/arch/arm/mach-mxs/pm.c index a9b4bbcdafb4..b2494d2db2c4 100644 --- a/arch/arm/mach-mxs/pm.c +++ b/arch/arm/mach-mxs/pm.c | |||
@@ -34,9 +34,7 @@ static struct platform_suspend_ops mxs_suspend_ops = { | |||
34 | .valid = suspend_valid_only_mem, | 34 | .valid = suspend_valid_only_mem, |
35 | }; | 35 | }; |
36 | 36 | ||
37 | static int __init mxs_pm_init(void) | 37 | void __init mxs_pm_init(void) |
38 | { | 38 | { |
39 | suspend_set_ops(&mxs_suspend_ops); | 39 | suspend_set_ops(&mxs_suspend_ops); |
40 | return 0; | ||
41 | } | 40 | } |
42 | device_initcall(mxs_pm_init); | ||
diff --git a/arch/arm/mach-mxs/pm.h b/arch/arm/mach-mxs/pm.h new file mode 100644 index 000000000000..f57e7cdece2e --- /dev/null +++ b/arch/arm/mach-mxs/pm.h | |||
@@ -0,0 +1,14 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2013 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 | #ifndef __ARCH_MXS_PM_H | ||
10 | #define __ARCH_MXS_PM_H | ||
11 | |||
12 | void mxs_pm_init(void); | ||
13 | |||
14 | #endif | ||