aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-s3c2410/mach-otom.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-16 18:20:36 -0400
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-16 18:20:36 -0400
commit1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 (patch)
tree0bba044c4ce775e45a88a51686b5d9f90697ea9d /arch/arm/mach-s3c2410/mach-otom.c
Linux-2.6.12-rc2v2.6.12-rc2
Initial git repository build. I'm not bothering with the full history, even though we have it. We can create a separate "historical" git archive of that later if we want to, and in the meantime it's about 3.2GB when imported into git - space that would just make the early git days unnecessarily complicated, when we don't have a lot of good infrastructure for it. Let it rip!
Diffstat (limited to 'arch/arm/mach-s3c2410/mach-otom.c')
-rw-r--r--arch/arm/mach-s3c2410/mach-otom.c124
1 files changed, 124 insertions, 0 deletions
diff --git a/arch/arm/mach-s3c2410/mach-otom.c b/arch/arm/mach-s3c2410/mach-otom.c
new file mode 100644
index 000000000000..67d8ce8fb00f
--- /dev/null
+++ b/arch/arm/mach-s3c2410/mach-otom.c
@@ -0,0 +1,124 @@
1/* linux/arch/arm/mach-s3c2410/mach-otom.c
2 *
3 * Copyright (c) 2004 Nex Vision
4 * Guillaume GOURAT <guillaume.gourat@nexvision.fr>
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 version 2 as
8 * published by the Free Software Foundation.
9 *
10 */
11
12#include <linux/kernel.h>
13#include <linux/types.h>
14#include <linux/interrupt.h>
15#include <linux/list.h>
16#include <linux/timer.h>
17#include <linux/init.h>
18#include <linux/device.h>
19
20#include <asm/mach/arch.h>
21#include <asm/mach/map.h>
22#include <asm/mach/irq.h>
23
24#include <asm/arch/otom-map.h>
25
26#include <asm/hardware.h>
27#include <asm/io.h>
28#include <asm/irq.h>
29#include <asm/mach-types.h>
30
31#include <asm/arch/regs-serial.h>
32#include <asm/arch/regs-gpio.h>
33
34#include "s3c2410.h"
35#include "clock.h"
36#include "devs.h"
37#include "cpu.h"
38
39static struct map_desc otom11_iodesc[] __initdata = {
40 /* Device area */
41 { (u32)OTOM_VA_CS8900A_BASE, OTOM_PA_CS8900A_BASE, SZ_16M, MT_DEVICE },
42};
43
44#define UCON S3C2410_UCON_DEFAULT
45#define ULCON S3C2410_LCON_CS8 | S3C2410_LCON_PNONE | S3C2410_LCON_STOPB
46#define UFCON S3C2410_UFCON_RXTRIG12 | S3C2410_UFCON_FIFOMODE
47
48static struct s3c2410_uartcfg otom11_uartcfgs[] = {
49 [0] = {
50 .hwport = 0,
51 .flags = 0,
52 .ucon = UCON,
53 .ulcon = ULCON,
54 .ufcon = UFCON,
55 },
56 [1] = {
57 .hwport = 1,
58 .flags = 0,
59 .ucon = UCON,
60 .ulcon = ULCON,
61 .ufcon = UFCON,
62 },
63 /* port 2 is not actually used */
64 [2] = {
65 .hwport = 2,
66 .flags = 0,
67 .ucon = UCON,
68 .ulcon = ULCON,
69 .ufcon = UFCON,
70 }
71};
72
73/* NOR Flash on NexVision OTOM board */
74
75static struct resource otom_nor_resource[] = {
76 [0] = {
77 .start = S3C2410_CS0,
78 .end = S3C2410_CS0 + (4*1024*1024) - 1,
79 .flags = IORESOURCE_MEM,
80 }
81};
82
83static struct platform_device otom_device_nor = {
84 .name = "mtd-flash",
85 .id = -1,
86 .num_resources = ARRAY_SIZE(otom_nor_resource),
87 .resource = otom_nor_resource,
88};
89
90/* Standard OTOM devices */
91
92static struct platform_device *otom11_devices[] __initdata = {
93 &s3c_device_usb,
94 &s3c_device_lcd,
95 &s3c_device_wdt,
96 &s3c_device_i2c,
97 &s3c_device_iis,
98 &s3c_device_rtc,
99 &otom_device_nor,
100};
101
102static struct s3c24xx_board otom11_board __initdata = {
103 .devices = otom11_devices,
104 .devices_count = ARRAY_SIZE(otom11_devices)
105};
106
107
108void __init otom11_map_io(void)
109{
110 s3c24xx_init_io(otom11_iodesc, ARRAY_SIZE(otom11_iodesc));
111 s3c24xx_init_clocks(0);
112 s3c24xx_init_uarts(otom11_uartcfgs, ARRAY_SIZE(otom11_uartcfgs));
113 s3c24xx_set_board(&otom11_board);
114}
115
116
117MACHINE_START(OTOM, "Nex Vision - Otom 1.1")
118 MAINTAINER("Guillaume GOURAT <guillaume.gourat@nexvision.tv>")
119 BOOT_MEM(S3C2410_SDRAM_PA, S3C2410_PA_UART, (u32)S3C24XX_VA_UART)
120 BOOT_PARAMS(S3C2410_SDRAM_PA + 0x100)
121 .map_io = otom11_map_io,
122 .init_irq = s3c24xx_init_irq,
123 .timer = &s3c24xx_timer,
124MACHINE_END