]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/mips/au1000/common/platform.c
[MIPS] Alchemy common code style cleanup
[linux-2.6-omap-h63xx.git] / arch / mips / au1000 / common / platform.c
index 7167972b1277d059f977c1b675b60c7f6c851f1b..8cae7753ef79931612eb5070e2236014df07fe78 100644 (file)
@@ -233,19 +233,6 @@ static struct resource au1200_lcd_resources[] = {
        }
 };
 
-static struct resource au1200_ide0_resources[] = {
-       [0] = {
-               .start          = AU1XXX_ATA_PHYS_ADDR,
-               .end            = AU1XXX_ATA_PHYS_ADDR + AU1XXX_ATA_PHYS_LEN - 1,
-               .flags          = IORESOURCE_MEM,
-       },
-       [1] = {
-               .start          = AU1XXX_ATA_INT,
-               .end            = AU1XXX_ATA_INT,
-               .flags          = IORESOURCE_IRQ,
-       }
-};
-
 static u64 au1200_lcd_dmamask = ~(u32)0;
 
 static struct platform_device au1200_lcd_device = {
@@ -259,20 +246,6 @@ static struct platform_device au1200_lcd_device = {
        .resource       = au1200_lcd_resources,
 };
 
-
-static u64 ide0_dmamask = ~(u32)0;
-
-static struct platform_device au1200_ide0_device = {
-       .name           = "au1200-ide",
-       .id             = 0,
-       .dev = {
-               .dma_mask               = &ide0_dmamask,
-               .coherent_dma_mask      = 0xffffffff,
-       },
-       .num_resources = ARRAY_SIZE(au1200_ide0_resources),
-       .resource       = au1200_ide0_resources,
-};
-
 static u64 au1xxx_mmc_dmamask =  ~(u32)0;
 
 static struct platform_device au1xxx_mmc_device = {
@@ -292,37 +265,12 @@ static struct platform_device au1x00_pcmcia_device = {
        .id             = 0,
 };
 
-#ifdef CONFIG_MIPS_DB1200
-
-static struct resource smc91x_resources[] = {
-       [0] = {
-               .name   = "smc91x-regs",
-               .start  = AU1XXX_SMC91111_PHYS_ADDR,
-               .end    = AU1XXX_SMC91111_PHYS_ADDR + 0xfffff,
-               .flags  = IORESOURCE_MEM,
-       },
-       [1] = {
-               .start  = AU1XXX_SMC91111_IRQ,
-               .end    = AU1XXX_SMC91111_IRQ,
-               .flags  = IORESOURCE_IRQ,
-       },
-};
-
-static struct platform_device smc91x_device = {
-       .name           = "smc91x",
-       .id             = -1,
-       .num_resources  = ARRAY_SIZE(smc91x_resources),
-       .resource       = smc91x_resources,
-};
-
-#endif
-
 /* All Alchemy demoboards with I2C have this #define in their headers */
 #ifdef SMBUS_PSC_BASE
 static struct resource pbdb_smbus_resources[] = {
        {
-               .start  = SMBUS_PSC_BASE,
-               .end    = SMBUS_PSC_BASE + 0x24 - 1,
+               .start  = CPHYSADDR(SMBUS_PSC_BASE),
+               .end    = CPHYSADDR(SMBUS_PSC_BASE + 0xfffff),
                .flags  = IORESOURCE_MEM,
        },
 };
@@ -347,27 +295,24 @@ static struct platform_device *au1xxx_platform_devices[] __initdata = {
        &au1xxx_usb_gdt_device,
        &au1xxx_usb_otg_device,
        &au1200_lcd_device,
-       &au1200_ide0_device,
        &au1xxx_mmc_device,
 #endif
-#ifdef CONFIG_MIPS_DB1200
-       &smc91x_device,
-#endif
 #ifdef SMBUS_PSC_BASE
        &pbdb_smbus_device,
 #endif
 };
 
-int __init au1xxx_platform_init(void)
+static int __init au1xxx_platform_init(void)
 {
        unsigned int uartclk = get_au1x00_uart_baud_base() * 16;
        int i;
 
        /* Fill up uartclk. */
-       for (i = 0; au1x00_uart_data[i].flags ; i++)
+       for (i = 0; au1x00_uart_data[i].flags; i++)
                au1x00_uart_data[i].uartclk = uartclk;
 
-       return platform_add_devices(au1xxx_platform_devices, ARRAY_SIZE(au1xxx_platform_devices));
+       return platform_add_devices(au1xxx_platform_devices,
+                                   ARRAY_SIZE(au1xxx_platform_devices));
 }
 
 arch_initcall(au1xxx_platform_init);