X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=arch%2Farm%2Fmach-s3c2440%2Fmach-anubis.c;h=09af8b23500bd787a80068db93bbc29347a80da7;hb=91d0322bef047e2916b3e52741411bffc63929cb;hp=29c163d300d4cc9f78a4f35654e3559b92497efc;hpb=5e16e3f0e24dadb79b96b6134cd3303f0d42f0c5;p=linux-2.6-omap-h63xx.git diff --git a/arch/arm/mach-s3c2440/mach-anubis.c b/arch/arm/mach-s3c2440/mach-anubis.c index 29c163d300d..09af8b23500 100644 --- a/arch/arm/mach-s3c2440/mach-anubis.c +++ b/arch/arm/mach-s3c2440/mach-anubis.c @@ -1,6 +1,6 @@ /* linux/arch/arm/mach-s3c2440/mach-anubis.c * - * Copyright (c) 2003-2005 Simtec Electronics + * Copyright (c) 2003-2005,2008 Simtec Electronics * http://armlinux.simtec.co.uk/ * Ben Dooks * @@ -17,6 +17,8 @@ #include #include #include +#include +#include #include #include @@ -34,11 +36,11 @@ #include #include -#include +#include #include #include #include -#include +#include #include #include @@ -241,14 +243,18 @@ static struct s3c2410_platform_nand anubis_nand_info = { /* IDE channels */ +struct pata_platform_info anubis_ide_platdata = { + .ioport_shift = 5, +}; + static struct resource anubis_ide0_resource[] = { { .start = S3C2410_CS3, .end = S3C2410_CS3 + (8*32) - 1, .flags = IORESOURCE_MEM, }, { - .start = S3C2410_CS3 + (1<<26), - .end = S3C2410_CS3 + (1<<26) + (8*32) - 1, + .start = S3C2410_CS3 + (1<<26) + (6*32), + .end = S3C2410_CS3 + (1<<26) + (7*32) - 1, .flags = IORESOURCE_MEM, }, { .start = IRQ_IDE0, @@ -258,10 +264,14 @@ static struct resource anubis_ide0_resource[] = { }; static struct platform_device anubis_device_ide0 = { - .name = "simtec-ide", + .name = "pata_platform", .id = 0, .num_resources = ARRAY_SIZE(anubis_ide0_resource), .resource = anubis_ide0_resource, + .dev = { + .platform_data = &anubis_ide_platdata, + .coherent_dma_mask = ~0, + }, }; static struct resource anubis_ide1_resource[] = { @@ -270,8 +280,8 @@ static struct resource anubis_ide1_resource[] = { .end = S3C2410_CS4 + (8*32) - 1, .flags = IORESOURCE_MEM, }, { - .start = S3C2410_CS4 + (1<<26), - .end = S3C2410_CS4 + (1<<26) + (8*32) - 1, + .start = S3C2410_CS4 + (1<<26) + (6*32), + .end = S3C2410_CS4 + (1<<26) + (7*32) - 1, .flags = IORESOURCE_MEM, }, { .start = IRQ_IDE0, @@ -280,12 +290,15 @@ static struct resource anubis_ide1_resource[] = { }, }; - static struct platform_device anubis_device_ide1 = { - .name = "simtec-ide", + .name = "pata_platform", .id = 1, .num_resources = ARRAY_SIZE(anubis_ide1_resource), .resource = anubis_ide1_resource, + .dev = { + .platform_data = &anubis_ide_platdata, + .coherent_dma_mask = ~0, + }, }; /* Asix AX88796 10/100 ethernet controller */ @@ -409,14 +422,23 @@ static struct clk *anubis_clocks[] = { &s3c24xx_uclk, }; +/* I2C devices. */ + +static struct i2c_board_info anubis_i2c_devs[] __initdata = { + { + I2C_BOARD_INFO("tps65011", 0x48), + .irq = IRQ_EINT20, + } +}; + static void __init anubis_map_io(void) { /* initialise the clocks */ - s3c24xx_dclk0.parent = NULL; + s3c24xx_dclk0.parent = &clk_upll; s3c24xx_dclk0.rate = 12*1000*1000; - s3c24xx_dclk1.parent = NULL; + s3c24xx_dclk1.parent = &clk_upll; s3c24xx_dclk1.rate = 24*1000*1000; s3c24xx_clkout0.parent = &s3c24xx_dclk0; @@ -448,6 +470,9 @@ static void __init anubis_map_io(void) static void __init anubis_init(void) { platform_add_devices(anubis_devices, ARRAY_SIZE(anubis_devices)); + + i2c_register_board_info(0, anubis_i2c_devs, + ARRAY_SIZE(anubis_i2c_devs)); }