aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-msm
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-05-02 12:03:55 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2013-05-02 12:03:55 -0400
commita7726350e06401929eac0aa0677a5467106565fc (patch)
treee189513e5014bdfccd73a3af731a6b57733743fa /arch/arm/mach-msm
parent4d26aa305414dbb33b3c32fb205b68004cda8ffc (diff)
parentafcf7924ecab726dab0227188783c4a40d9f0eec (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-msm')
-rw-r--r--arch/arm/mach-msm/board-halibut.c1
-rw-r--r--arch/arm/mach-msm/board-msm7x30.c1
-rw-r--r--arch/arm/mach-msm/board-qsd8x50.c1
-rw-r--r--arch/arm/mach-msm/board-trout.c1
-rw-r--r--arch/arm/mach-msm/devices-msm7x00.c31
-rw-r--r--arch/arm/mach-msm/devices-msm7x30.c31
-rw-r--r--arch/arm/mach-msm/devices-qsd8x50.c31
-rw-r--r--arch/arm/mach-msm/devices.h4
-rw-r--r--arch/arm/mach-msm/dma.c26
-rw-r--r--arch/arm/mach-msm/include/mach/cpu.h54
-rw-r--r--arch/arm/mach-msm/include/mach/dma.h26
-rw-r--r--arch/arm/mach-msm/platsmp.c8
12 files changed, 127 insertions, 88 deletions
diff --git a/arch/arm/mach-msm/board-halibut.c b/arch/arm/mach-msm/board-halibut.c
index 84d720af34ab..82eaf88d2026 100644
--- a/arch/arm/mach-msm/board-halibut.c
+++ b/arch/arm/mach-msm/board-halibut.c
@@ -59,6 +59,7 @@ static struct platform_device smc91x_device = {
59}; 59};
60 60
61static struct platform_device *devices[] __initdata = { 61static struct platform_device *devices[] __initdata = {
62 &msm_device_gpio_7201,
62 &msm_device_uart3, 63 &msm_device_uart3,
63 &msm_device_smd, 64 &msm_device_smd,
64 &msm_device_nand, 65 &msm_device_nand,
diff --git a/arch/arm/mach-msm/board-msm7x30.c b/arch/arm/mach-msm/board-msm7x30.c
index 7bc3f82e3ec9..520c141acd03 100644
--- a/arch/arm/mach-msm/board-msm7x30.c
+++ b/arch/arm/mach-msm/board-msm7x30.c
@@ -89,6 +89,7 @@ struct msm_gpiomux_config msm_gpiomux_configs[GPIOMUX_NGPIOS] = {
89}; 89};
90 90
91static struct platform_device *devices[] __initdata = { 91static struct platform_device *devices[] __initdata = {
92 &msm_device_gpio_7x30,
92#if defined(CONFIG_SERIAL_MSM) || defined(CONFIG_MSM_SERIAL_DEBUGGER) 93#if defined(CONFIG_SERIAL_MSM) || defined(CONFIG_MSM_SERIAL_DEBUGGER)
93 &msm_device_uart2, 94 &msm_device_uart2,
94#endif 95#endif
diff --git a/arch/arm/mach-msm/board-qsd8x50.c b/arch/arm/mach-msm/board-qsd8x50.c
index 686e7949a73a..38a532d6937c 100644
--- a/arch/arm/mach-msm/board-qsd8x50.c
+++ b/arch/arm/mach-msm/board-qsd8x50.c
@@ -89,6 +89,7 @@ static struct msm_otg_platform_data msm_otg_pdata = {
89}; 89};
90 90
91static struct platform_device *devices[] __initdata = { 91static struct platform_device *devices[] __initdata = {
92 &msm_device_gpio_8x50,
92 &msm_device_uart3, 93 &msm_device_uart3,
93 &msm_device_smd, 94 &msm_device_smd,
94 &msm_device_otg, 95 &msm_device_otg,
diff --git a/arch/arm/mach-msm/board-trout.c b/arch/arm/mach-msm/board-trout.c
index 919bfa32871a..80fe1c5ff5c1 100644
--- a/arch/arm/mach-msm/board-trout.c
+++ b/arch/arm/mach-msm/board-trout.c
@@ -36,6 +36,7 @@
36extern int trout_init_mmc(unsigned int); 36extern int trout_init_mmc(unsigned int);
37 37
38static struct platform_device *devices[] __initdata = { 38static struct platform_device *devices[] __initdata = {
39 &msm_device_gpio_7201,
39 &msm_device_uart3, 40 &msm_device_uart3,
40 &msm_device_smd, 41 &msm_device_smd,
41 &msm_device_nand, 42 &msm_device_nand,
diff --git a/arch/arm/mach-msm/devices-msm7x00.c b/arch/arm/mach-msm/devices-msm7x00.c
index f66ee6ea8720..1a0a2306b115 100644
--- a/arch/arm/mach-msm/devices-msm7x00.c
+++ b/arch/arm/mach-msm/devices-msm7x00.c
@@ -29,6 +29,37 @@
29#include "clock-pcom.h" 29#include "clock-pcom.h"
30#include <linux/platform_data/mmc-msm_sdcc.h> 30#include <linux/platform_data/mmc-msm_sdcc.h>
31 31
32static struct resource msm_gpio_resources[] = {
33 {
34 .start = 32 + 0,
35 .end = 32 + 0,
36 .flags = IORESOURCE_IRQ,
37 },
38 {
39 .start = 32 + 1,
40 .end = 32 + 1,
41 .flags = IORESOURCE_IRQ,
42 },
43 {
44 .start = 0xa9200800,
45 .end = 0xa9200800 + SZ_4K - 1,
46 .flags = IORESOURCE_MEM,
47 .name = "gpio1"
48 },
49 {
50 .start = 0xa9300C00,
51 .end = 0xa9300C00 + SZ_4K - 1,
52 .flags = IORESOURCE_MEM,
53 .name = "gpio2"
54 },
55};
56
57struct platform_device msm_device_gpio_7201 = {
58 .name = "gpio-msm-7201",
59 .num_resources = ARRAY_SIZE(msm_gpio_resources),
60 .resource = msm_gpio_resources,
61};
62
32static struct resource resources_uart1[] = { 63static struct resource resources_uart1[] = {
33 { 64 {
34 .start = INT_UART1, 65 .start = INT_UART1,
diff --git a/arch/arm/mach-msm/devices-msm7x30.c b/arch/arm/mach-msm/devices-msm7x30.c
index e90ab5938c5f..12f482c07740 100644
--- a/arch/arm/mach-msm/devices-msm7x30.c
+++ b/arch/arm/mach-msm/devices-msm7x30.c
@@ -33,6 +33,37 @@
33 33
34#include <linux/platform_data/mmc-msm_sdcc.h> 34#include <linux/platform_data/mmc-msm_sdcc.h>
35 35
36static struct resource msm_gpio_resources[] = {
37 {
38 .start = 32 + 18,
39 .end = 32 + 18,
40 .flags = IORESOURCE_IRQ,
41 },
42 {
43 .start = 32 + 19,
44 .end = 32 + 19,
45 .flags = IORESOURCE_IRQ,
46 },
47 {
48 .start = 0xac001000,
49 .end = 0xac001000 + SZ_4K - 1,
50 .flags = IORESOURCE_MEM,
51 .name = "gpio1"
52 },
53 {
54 .start = 0xac101400,
55 .end = 0xac101400 + SZ_4K - 1,
56 .flags = IORESOURCE_MEM,
57 .name = "gpio2"
58 },
59};
60
61struct platform_device msm_device_gpio_7x30 = {
62 .name = "gpio-msm-7x30",
63 .num_resources = ARRAY_SIZE(msm_gpio_resources),
64 .resource = msm_gpio_resources,
65};
66
36static struct resource resources_uart2[] = { 67static struct resource resources_uart2[] = {
37 { 68 {
38 .start = INT_UART2, 69 .start = INT_UART2,
diff --git a/arch/arm/mach-msm/devices-qsd8x50.c b/arch/arm/mach-msm/devices-qsd8x50.c
index 4db61d5fe317..2e1b3ec9dfc7 100644
--- a/arch/arm/mach-msm/devices-qsd8x50.c
+++ b/arch/arm/mach-msm/devices-qsd8x50.c
@@ -30,6 +30,37 @@
30#include <linux/platform_data/mmc-msm_sdcc.h> 30#include <linux/platform_data/mmc-msm_sdcc.h>
31#include "clock-pcom.h" 31#include "clock-pcom.h"
32 32
33static struct resource msm_gpio_resources[] = {
34 {
35 .start = 64 + 165 + 9,
36 .end = 64 + 165 + 9,
37 .flags = IORESOURCE_IRQ,
38 },
39 {
40 .start = 64 + 165 + 10,
41 .end = 64 + 165 + 10,
42 .flags = IORESOURCE_IRQ,
43 },
44 {
45 .start = 0xa9000800,
46 .end = 0xa9000800 + SZ_4K - 1,
47 .flags = IORESOURCE_MEM,
48 .name = "gpio1"
49 },
50 {
51 .start = 0xa9100C00,
52 .end = 0xa9100C00 + SZ_4K - 1,
53 .flags = IORESOURCE_MEM,
54 .name = "gpio2"
55 },
56};
57
58struct platform_device msm_device_gpio_8x50 = {
59 .name = "gpio-msm-8x50",
60 .num_resources = ARRAY_SIZE(msm_gpio_resources),
61 .resource = msm_gpio_resources,
62};
63
33static struct resource resources_uart3[] = { 64static struct resource resources_uart3[] = {
34 { 65 {
35 .start = INT_UART3, 66 .start = INT_UART3,
diff --git a/arch/arm/mach-msm/devices.h b/arch/arm/mach-msm/devices.h
index 9545c196c6e8..da902cf51161 100644
--- a/arch/arm/mach-msm/devices.h
+++ b/arch/arm/mach-msm/devices.h
@@ -20,6 +20,10 @@
20 20
21#include "clock.h" 21#include "clock.h"
22 22
23extern struct platform_device msm_device_gpio_7201;
24extern struct platform_device msm_device_gpio_7x30;
25extern struct platform_device msm_device_gpio_8x50;
26
23extern struct platform_device msm_device_uart1; 27extern struct platform_device msm_device_uart1;
24extern struct platform_device msm_device_uart2; 28extern struct platform_device msm_device_uart2;
25extern struct platform_device msm_device_uart3; 29extern struct platform_device msm_device_uart3;
diff --git a/arch/arm/mach-msm/dma.c b/arch/arm/mach-msm/dma.c
index 354b91d4c3ac..b279fd8a31b1 100644
--- a/arch/arm/mach-msm/dma.c
+++ b/arch/arm/mach-msm/dma.c
@@ -19,9 +19,35 @@
19#include <linux/interrupt.h> 19#include <linux/interrupt.h>
20#include <linux/completion.h> 20#include <linux/completion.h>
21#include <mach/dma.h> 21#include <mach/dma.h>
22#include <mach/msm_iomap.h>
22 23
23#define MSM_DMOV_CHANNEL_COUNT 16 24#define MSM_DMOV_CHANNEL_COUNT 16
24 25
26#define DMOV_SD0(off, ch) (MSM_DMOV_BASE + 0x0000 + (off) + ((ch) << 2))
27#define DMOV_SD1(off, ch) (MSM_DMOV_BASE + 0x0400 + (off) + ((ch) << 2))
28#define DMOV_SD2(off, ch) (MSM_DMOV_BASE + 0x0800 + (off) + ((ch) << 2))
29#define DMOV_SD3(off, ch) (MSM_DMOV_BASE + 0x0C00 + (off) + ((ch) << 2))
30
31#if defined(CONFIG_ARCH_MSM7X30)
32#define DMOV_SD_AARM DMOV_SD2
33#else
34#define DMOV_SD_AARM DMOV_SD3
35#endif
36
37#define DMOV_CMD_PTR(ch) DMOV_SD_AARM(0x000, ch)
38#define DMOV_RSLT(ch) DMOV_SD_AARM(0x040, ch)
39#define DMOV_FLUSH0(ch) DMOV_SD_AARM(0x080, ch)
40#define DMOV_FLUSH1(ch) DMOV_SD_AARM(0x0C0, ch)
41#define DMOV_FLUSH2(ch) DMOV_SD_AARM(0x100, ch)
42#define DMOV_FLUSH3(ch) DMOV_SD_AARM(0x140, ch)
43#define DMOV_FLUSH4(ch) DMOV_SD_AARM(0x180, ch)
44#define DMOV_FLUSH5(ch) DMOV_SD_AARM(0x1C0, ch)
45
46#define DMOV_STATUS(ch) DMOV_SD_AARM(0x200, ch)
47#define DMOV_ISR DMOV_SD_AARM(0x380, 0)
48
49#define DMOV_CONFIG(ch) DMOV_SD_AARM(0x300, ch)
50
25enum { 51enum {
26 MSM_DMOV_PRINT_ERRORS = 1, 52 MSM_DMOV_PRINT_ERRORS = 1,
27 MSM_DMOV_PRINT_IO = 2, 53 MSM_DMOV_PRINT_IO = 2,
diff --git a/arch/arm/mach-msm/include/mach/cpu.h b/arch/arm/mach-msm/include/mach/cpu.h
deleted file mode 100644
index a9481b08d5c7..000000000000
--- a/arch/arm/mach-msm/include/mach/cpu.h
+++ /dev/null
@@ -1,54 +0,0 @@
1/* Copyright (c) 2011, Code Aurora Forum. All rights reserved.
2 *
3 * This program is free software; you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License version 2 and
5 * only version 2 as published by the Free Software Foundation.
6 *
7 * This program is distributed in the hope that it will be useful,
8 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10 * GNU General Public License for more details.
11 *
12 * You should have received a copy of the GNU General Public License
13 * along with this program; if not, write to the Free Software
14 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
15 * 02110-1301, USA.
16 */
17
18#ifndef __ARCH_ARM_MACH_MSM_CPU_H__
19#define __ARCH_ARM_MACH_MSM_CPU_H__
20
21/* TODO: For now, only one CPU can be compiled at a time. */
22
23#define cpu_is_msm7x01() 0
24#define cpu_is_msm7x30() 0
25#define cpu_is_qsd8x50() 0
26#define cpu_is_msm8x60() 0
27#define cpu_is_msm8960() 0
28
29#ifdef CONFIG_ARCH_MSM7X00A
30# undef cpu_is_msm7x01
31# define cpu_is_msm7x01() 1
32#endif
33
34#ifdef CONFIG_ARCH_MSM7X30
35# undef cpu_is_msm7x30
36# define cpu_is_msm7x30() 1
37#endif
38
39#ifdef CONFIG_ARCH_QSD8X50
40# undef cpu_is_qsd8x50
41# define cpu_is_qsd8x50() 1
42#endif
43
44#ifdef CONFIG_ARCH_MSM8X60
45# undef cpu_is_msm8x60
46# define cpu_is_msm8x60() 1
47#endif
48
49#ifdef CONFIG_ARCH_MSM8960
50# undef cpu_is_msm8960
51# define cpu_is_msm8960() 1
52#endif
53
54#endif
diff --git a/arch/arm/mach-msm/include/mach/dma.h b/arch/arm/mach-msm/include/mach/dma.h
index 05583f569524..a72d48d42342 100644
--- a/arch/arm/mach-msm/include/mach/dma.h
+++ b/arch/arm/mach-msm/include/mach/dma.h
@@ -16,7 +16,6 @@
16#ifndef __ASM_ARCH_MSM_DMA_H 16#ifndef __ASM_ARCH_MSM_DMA_H
17 17
18#include <linux/list.h> 18#include <linux/list.h>
19#include <mach/msm_iomap.h>
20 19
21struct msm_dmov_errdata { 20struct msm_dmov_errdata {
22 uint32_t flush[6]; 21 uint32_t flush[6];
@@ -45,48 +44,23 @@ static inline
45int msm_dmov_exec_cmd(unsigned id, unsigned int cmdptr) { return -EIO; } 44int msm_dmov_exec_cmd(unsigned id, unsigned int cmdptr) { return -EIO; }
46#endif 45#endif
47 46
48
49#define DMOV_SD0(off, ch) (MSM_DMOV_BASE + 0x0000 + (off) + ((ch) << 2))
50#define DMOV_SD1(off, ch) (MSM_DMOV_BASE + 0x0400 + (off) + ((ch) << 2))
51#define DMOV_SD2(off, ch) (MSM_DMOV_BASE + 0x0800 + (off) + ((ch) << 2))
52#define DMOV_SD3(off, ch) (MSM_DMOV_BASE + 0x0C00 + (off) + ((ch) << 2))
53
54#if defined(CONFIG_ARCH_MSM7X30)
55#define DMOV_SD_AARM DMOV_SD2
56#else
57#define DMOV_SD_AARM DMOV_SD3
58#endif
59
60#define DMOV_CMD_PTR(ch) DMOV_SD_AARM(0x000, ch)
61#define DMOV_CMD_LIST (0 << 29) /* does not work */ 47#define DMOV_CMD_LIST (0 << 29) /* does not work */
62#define DMOV_CMD_PTR_LIST (1 << 29) /* works */ 48#define DMOV_CMD_PTR_LIST (1 << 29) /* works */
63#define DMOV_CMD_INPUT_CFG (2 << 29) /* untested */ 49#define DMOV_CMD_INPUT_CFG (2 << 29) /* untested */
64#define DMOV_CMD_OUTPUT_CFG (3 << 29) /* untested */ 50#define DMOV_CMD_OUTPUT_CFG (3 << 29) /* untested */
65#define DMOV_CMD_ADDR(addr) ((addr) >> 3) 51#define DMOV_CMD_ADDR(addr) ((addr) >> 3)
66 52
67#define DMOV_RSLT(ch) DMOV_SD_AARM(0x040, ch)
68#define DMOV_RSLT_VALID (1 << 31) /* 0 == host has empties result fifo */ 53#define DMOV_RSLT_VALID (1 << 31) /* 0 == host has empties result fifo */
69#define DMOV_RSLT_ERROR (1 << 3) 54#define DMOV_RSLT_ERROR (1 << 3)
70#define DMOV_RSLT_FLUSH (1 << 2) 55#define DMOV_RSLT_FLUSH (1 << 2)
71#define DMOV_RSLT_DONE (1 << 1) /* top pointer done */ 56#define DMOV_RSLT_DONE (1 << 1) /* top pointer done */
72#define DMOV_RSLT_USER (1 << 0) /* command with FR force result */ 57#define DMOV_RSLT_USER (1 << 0) /* command with FR force result */
73 58
74#define DMOV_FLUSH0(ch) DMOV_SD_AARM(0x080, ch)
75#define DMOV_FLUSH1(ch) DMOV_SD_AARM(0x0C0, ch)
76#define DMOV_FLUSH2(ch) DMOV_SD_AARM(0x100, ch)
77#define DMOV_FLUSH3(ch) DMOV_SD_AARM(0x140, ch)
78#define DMOV_FLUSH4(ch) DMOV_SD_AARM(0x180, ch)
79#define DMOV_FLUSH5(ch) DMOV_SD_AARM(0x1C0, ch)
80
81#define DMOV_STATUS(ch) DMOV_SD_AARM(0x200, ch)
82#define DMOV_STATUS_RSLT_COUNT(n) (((n) >> 29)) 59#define DMOV_STATUS_RSLT_COUNT(n) (((n) >> 29))
83#define DMOV_STATUS_CMD_COUNT(n) (((n) >> 27) & 3) 60#define DMOV_STATUS_CMD_COUNT(n) (((n) >> 27) & 3)
84#define DMOV_STATUS_RSLT_VALID (1 << 1) 61#define DMOV_STATUS_RSLT_VALID (1 << 1)
85#define DMOV_STATUS_CMD_PTR_RDY (1 << 0) 62#define DMOV_STATUS_CMD_PTR_RDY (1 << 0)
86 63
87#define DMOV_ISR DMOV_SD_AARM(0x380, 0)
88
89#define DMOV_CONFIG(ch) DMOV_SD_AARM(0x300, ch)
90#define DMOV_CONFIG_FORCE_TOP_PTR_RSLT (1 << 2) 64#define DMOV_CONFIG_FORCE_TOP_PTR_RSLT (1 << 2)
91#define DMOV_CONFIG_FORCE_FLUSH_RSLT (1 << 1) 65#define DMOV_CONFIG_FORCE_FLUSH_RSLT (1 << 1)
92#define DMOV_CONFIG_IRQ_EN (1 << 0) 66#define DMOV_CONFIG_IRQ_EN (1 << 0)
diff --git a/arch/arm/mach-msm/platsmp.c b/arch/arm/mach-msm/platsmp.c
index 42932865416a..00cdb0a5dac8 100644
--- a/arch/arm/mach-msm/platsmp.c
+++ b/arch/arm/mach-msm/platsmp.c
@@ -15,7 +15,6 @@
15#include <linux/jiffies.h> 15#include <linux/jiffies.h>
16#include <linux/smp.h> 16#include <linux/smp.h>
17#include <linux/io.h> 17#include <linux/io.h>
18#include <linux/irqchip/arm-gic.h>
19 18
20#include <asm/cacheflush.h> 19#include <asm/cacheflush.h>
21#include <asm/cputype.h> 20#include <asm/cputype.h>
@@ -42,13 +41,6 @@ static inline int get_core_count(void)
42static void __cpuinit msm_secondary_init(unsigned int cpu) 41static void __cpuinit msm_secondary_init(unsigned int cpu)
43{ 42{
44 /* 43 /*
45 * if any interrupts are already enabled for the primary
46 * core (e.g. timer irq), then they will not have been enabled
47 * for us: do so
48 */
49 gic_secondary_init(0);
50
51 /*
52 * let the primary processor know we're out of the 44 * let the primary processor know we're out of the
53 * pen, then head off into the C entry point 45 * pen, then head off into the C entry point
54 */ 46 */