diff options
author | Stepan Moskovchenko <stepanm@codeaurora.org> | 2010-12-01 22:31:16 -0500 |
---|---|---|
committer | David Brown <davidb@codeaurora.org> | 2011-01-21 18:27:55 -0500 |
commit | f441ca2d403cf74ebffbc07a3ccd402efd995799 (patch) | |
tree | 0c69923877d5036121606f14fb1cb6f038f62151 /arch/arm/mach-msm/board-msm8960.c | |
parent | decd4a9d3671cd95a46ca0e004700077d81c370d (diff) |
msm: Support for the MSM8960 Simulator target
Add the board file, Kconfig options, and Makefile options
needed to build for the MSM8960 Simulator target.
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Diffstat (limited to 'arch/arm/mach-msm/board-msm8960.c')
-rw-r--r-- | arch/arm/mach-msm/board-msm8960.c | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/arch/arm/mach-msm/board-msm8960.c b/arch/arm/mach-msm/board-msm8960.c new file mode 100644 index 000000000000..90efd5472be1 --- /dev/null +++ b/arch/arm/mach-msm/board-msm8960.c | |||
@@ -0,0 +1,58 @@ | |||
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 | #include <linux/kernel.h> | ||
19 | #include <linux/platform_device.h> | ||
20 | #include <linux/io.h> | ||
21 | #include <linux/irq.h> | ||
22 | |||
23 | #include <asm/mach-types.h> | ||
24 | #include <asm/mach/arch.h> | ||
25 | #include <asm/hardware/gic.h> | ||
26 | |||
27 | #include <mach/board.h> | ||
28 | #include <mach/msm_iomap.h> | ||
29 | |||
30 | static void __init msm8960_map_io(void) | ||
31 | { | ||
32 | msm_map_msm8960_io(); | ||
33 | } | ||
34 | |||
35 | static void __init msm8960_init_irq(void) | ||
36 | { | ||
37 | unsigned int i; | ||
38 | gic_init(0, GIC_PPI_START, MSM_QGIC_DIST_BASE, | ||
39 | (void *)MSM_QGIC_CPU_BASE); | ||
40 | |||
41 | /* Edge trigger PPIs except AVS_SVICINT and AVS_SVICINTSWDONE */ | ||
42 | writel(0xFFFFD7FF, MSM_QGIC_DIST_BASE + GIC_DIST_CONFIG + 4); | ||
43 | |||
44 | /* FIXME: Not installing AVS_SVICINT and AVS_SVICINTSWDONE yet | ||
45 | * as they are configured as level, which does not play nice with | ||
46 | * handle_percpu_irq. | ||
47 | */ | ||
48 | for (i = GIC_PPI_START; i < GIC_SPI_START; i++) { | ||
49 | if (i != AVS_SVICINT && i != AVS_SVICINTSWDONE) | ||
50 | set_irq_handler(i, handle_percpu_irq); | ||
51 | } | ||
52 | } | ||
53 | |||
54 | MACHINE_START(MSM8960_SIM, "QCT MSM8960 SIMULATOR") | ||
55 | .map_io = msm8960_map_io, | ||
56 | .init_irq = msm8960_init_irq, | ||
57 | .timer = &msm_timer, | ||
58 | MACHINE_END | ||