1 /* linux/arch/arm/mach-s3c2410/mach-vstms.c
3 * (C) 2006 Thomas Gleixner <tglx@linutronix.de>
5 * Derived from mach-smdk2413.c - (C) 2006 Simtec Electronics
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License version 2 as
9 * published by the Free Software Foundation.
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/platform_device.h>
20 #include <linux/mtd/mtd.h>
21 #include <linux/mtd/nand.h>
22 #include <linux/mtd/nand_ecc.h>
23 #include <linux/mtd/partitions.h>
25 #include <asm/mach/arch.h>
26 #include <asm/mach/map.h>
27 #include <asm/mach/irq.h>
29 #include <asm/hardware.h>
30 #include <asm/hardware/iomd.h>
31 #include <asm/setup.h>
34 #include <asm/mach-types.h>
36 #include <asm/arch/regs-serial.h>
37 #include <asm/arch/regs-gpio.h>
38 #include <asm/arch/regs-lcd.h>
40 #include <asm/arch/idle.h>
41 #include <asm/arch/fb.h>
43 #include <asm/arch/nand.h>
52 static struct map_desc vstms_iodesc[] __initdata = {
55 static struct s3c2410_uartcfg vstms_uartcfgs[] __initdata = {
79 static struct mtd_partition vstms_nand_part[] = {
86 .name = "UBoot Config",
102 static struct s3c2410_nand_set vstms_nand_sets[] = {
106 .nr_partitions = ARRAY_SIZE(vstms_nand_part),
107 .partitions = vstms_nand_part,
111 /* choose a set of timings which should suit most 512Mbit
115 static struct s3c2410_platform_nand vstms_nand_info = {
119 .nr_sets = ARRAY_SIZE(vstms_nand_sets),
120 .sets = vstms_nand_sets,
123 static struct platform_device *vstms_devices[] __initdata = {
132 static struct s3c24xx_board vstms_board __initdata = {
133 .devices = vstms_devices,
134 .devices_count = ARRAY_SIZE(vstms_devices)
137 static void __init vstms_fixup(struct machine_desc *desc,
138 struct tag *tags, char **cmdline,
141 if (tags != phys_to_virt(S3C2410_SDRAM_PA + 0x100)) {
143 mi->bank[0].start = 0x30000000;
144 mi->bank[0].size = SZ_64M;
145 mi->bank[0].node = 0;
149 static void __init vstms_map_io(void)
151 s3c_device_nand.dev.platform_data = &vstms_nand_info;
153 s3c24xx_init_io(vstms_iodesc, ARRAY_SIZE(vstms_iodesc));
154 s3c24xx_init_clocks(12000000);
155 s3c24xx_init_uarts(vstms_uartcfgs, ARRAY_SIZE(vstms_uartcfgs));
156 s3c24xx_set_board(&vstms_board);
159 MACHINE_START(VSTMS, "VSTMS")
160 .phys_io = S3C2410_PA_UART,
161 .io_pg_offst = (((u32)S3C24XX_VA_UART) >> 18) & 0xfffc,
162 .boot_params = S3C2410_SDRAM_PA + 0x100,
164 .fixup = vstms_fixup,
165 .init_irq = s3c24xx_init_irq,
166 .map_io = vstms_map_io,
167 .timer = &s3c24xx_timer,