X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=arch%2Farm%2Fmach-s3c2410%2Fmach-smdk2410.c;h=2db932d72c5ae1047f75d880af5b6fd21f75e9c3;hb=43bc926fffd92024b46cafaf7350d669ba9ca884;hp=bfadbd4254f831b0129ecb02f54b4e3fbfdf6b18;hpb=9bf4aaab3e101692164d49b7ca357651eb691cb6;p=linux-2.6.git diff --git a/arch/arm/mach-s3c2410/mach-smdk2410.c b/arch/arm/mach-s3c2410/mach-smdk2410.c index bfadbd425..2db932d72 100644 --- a/arch/arm/mach-s3c2410/mach-smdk2410.c +++ b/arch/arm/mach-s3c2410/mach-smdk2410.c @@ -26,6 +26,11 @@ * @History: * derived from linux/arch/arm/mach-s3c2410/mach-bast.c, written by * Ben Dooks + * + * 10-Mar-2005 LCVR Changed S3C2410_VA to S3C24XX_VA + * 20-Sep-2005 BJD Added static to non-exported items + * 01-Apr-2006 BJD Moved init code to common smdk + * ***********************************************************************/ #include @@ -34,6 +39,7 @@ #include #include #include +#include #include #include @@ -46,8 +52,10 @@ #include -#include "s3c2410.h" +#include "devs.h" +#include "cpu.h" +#include "common-smdk.h" static struct map_desc smdk2410_iodesc[] __initdata = { /* nothing here yet */ @@ -57,14 +65,10 @@ static struct map_desc smdk2410_iodesc[] __initdata = { #define ULCON S3C2410_LCON_CS8 | S3C2410_LCON_PNONE | S3C2410_LCON_STOPB #define UFCON S3C2410_UFCON_RXTRIG8 | S3C2410_UFCON_FIFOMODE -/* base baud rate for all our UARTs */ -static unsigned long smdk2410_serial_clock = 24*1000*1000; - static struct s3c2410_uartcfg smdk2410_uartcfgs[] = { [0] = { .hwport = 0, .flags = 0, - .clock = &smdk2410_serial_clock, .ucon = UCON, .ulcon = ULCON, .ufcon = UFCON, @@ -72,7 +76,6 @@ static struct s3c2410_uartcfg smdk2410_uartcfgs[] = { [1] = { .hwport = 1, .flags = 0, - .clock = &smdk2410_serial_clock, .ucon = UCON, .ulcon = ULCON, .ufcon = UFCON, @@ -80,36 +83,43 @@ static struct s3c2410_uartcfg smdk2410_uartcfgs[] = { [2] = { .hwport = 2, .flags = 0, - .clock = &smdk2410_serial_clock, .ucon = UCON, .ulcon = ULCON, .ufcon = UFCON, } }; +static struct platform_device *smdk2410_devices[] __initdata = { + &s3c_device_usb, + &s3c_device_lcd, + &s3c_device_wdt, + &s3c_device_i2c, + &s3c_device_iis, +}; -void __init smdk2410_map_io(void) -{ - s3c2410_map_io(smdk2410_iodesc, ARRAY_SIZE(smdk2410_iodesc)); - s3c2410_uartcfgs = smdk2410_uartcfgs; -} - -void __init smdk2410_init_irq(void) -{ - s3c2410_init_irq(); -} +static struct s3c24xx_board smdk2410_board __initdata = { + .devices = smdk2410_devices, + .devices_count = ARRAY_SIZE(smdk2410_devices) +}; -void __init smdk2410_init_time(void) +static void __init smdk2410_map_io(void) { - s3c2410_init_time(); + s3c24xx_init_io(smdk2410_iodesc, ARRAY_SIZE(smdk2410_iodesc)); + s3c24xx_init_clocks(0); + s3c24xx_init_uarts(smdk2410_uartcfgs, ARRAY_SIZE(smdk2410_uartcfgs)); + s3c24xx_set_board(&smdk2410_board); } MACHINE_START(SMDK2410, "SMDK2410") /* @TODO: request a new identifier and switch * to SMDK2410 */ - MAINTAINER("Jonas Dietsche") - BOOT_MEM(S3C2410_SDRAM_PA, S3C2410_PA_UART, S3C2410_VA_UART) - BOOT_PARAMS(S3C2410_SDRAM_PA + 0x100) - MAPIO(smdk2410_map_io) - INITIRQ(smdk2410_init_irq) - INITTIME(smdk2410_init_time) + /* Maintainer: Jonas Dietsche */ + .phys_io = S3C2410_PA_UART, + .io_pg_offst = (((u32)S3C24XX_VA_UART) >> 18) & 0xfffc, + .boot_params = S3C2410_SDRAM_PA + 0x100, + .map_io = smdk2410_map_io, + .init_irq = s3c24xx_init_irq, + .init_machine = smdk_machine_init, + .timer = &s3c24xx_timer, MACHINE_END + +