[ARM] 3231/1: mx1ads board support cleanup

Patch from Sascha Hauer

- remove unnecessary mappings
- rename mx1ads_device to cs89x0_device, because
  that's what it is
- fix io/irq resource for cs89x0 device

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
This commit is contained in:
Sascha Hauer 2006-01-05 20:44:58 +00:00 committed by Russell King
parent 945b957972
commit 6a2273d6fc

View file

@ -29,27 +29,27 @@
#include "generic.h" #include "generic.h"
#include <asm/serial.h> #include <asm/serial.h>
static struct resource mx1ads_resources[] = { static struct resource cs89x0_resources[] = {
[0] = { [0] = {
.start = IMX_CS4_VIRT, .start = IMX_CS4_PHYS + 0x300,
.end = IMX_CS4_VIRT + 16, .end = IMX_CS4_PHYS + 0x300 + 16,
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
[1] = { [1] = {
.start = 13, .start = IRQ_GPIOC(17),
.end = 13, .end = IRQ_GPIOC(17),
.flags = IORESOURCE_IRQ, .flags = IORESOURCE_IRQ,
}, },
}; };
static struct platform_device mx1ads_device = { static struct platform_device cs89x0_device = {
.name = "mx1ads", .name = "cirrus-cs89x0",
.num_resources = ARRAY_SIZE(mx1ads_resources), .num_resources = ARRAY_SIZE(cs89x0_resources),
.resource = mx1ads_resources, .resource = cs89x0_resources,
}; };
static struct platform_device *devices[] __initdata = { static struct platform_device *devices[] __initdata = {
&mx1ads_device, &cs89x0_device,
}; };
static void __init static void __init
@ -61,45 +61,10 @@ mx1ads_init(void)
platform_add_devices(devices, ARRAY_SIZE(devices)); platform_add_devices(devices, ARRAY_SIZE(devices));
} }
static struct map_desc mx1ads_io_desc[] __initdata = {
{
.virtual = IMX_CS0_VIRT,
.pfn = __phys_to_pfn(IMX_CS0_PHYS),
.length = IMX_CS0_SIZE,
.type = MT_DEVICE
}, {
.virtual = IMX_CS1_VIRT,
.pfn = __phys_to_pfn(IMX_CS1_PHYS),
.length = IMX_CS1_SIZE,
.type = MT_DEVICE
}, {
.virtual = IMX_CS2_VIRT,
.pfn = __phys_to_pfn(IMX_CS2_PHYS),
.length = IMX_CS2_SIZE,
.type = MT_DEVICE
}, {
.virtual = IMX_CS3_VIRT,
.pfn = __phys_to_pfn(IMX_CS3_PHYS),
.length = IMX_CS3_SIZE,
.type = MT_DEVICE
}, {
.virtual = IMX_CS4_VIRT,
.pfn = __phys_to_pfn(IMX_CS4_PHYS),
.length = IMX_CS4_SIZE,
.type = MT_DEVICE
}, {
.virtual = IMX_CS5_VIRT,
.pfn = __phys_to_pfn(IMX_CS5_PHYS),
.length = IMX_CS5_SIZE,
.type = MT_DEVICE
}
};
static void __init static void __init
mx1ads_map_io(void) mx1ads_map_io(void)
{ {
imx_map_io(); imx_map_io();
iotable_init(mx1ads_io_desc, ARRAY_SIZE(mx1ads_io_desc));
} }
MACHINE_START(MX1ADS, "Motorola MX1ADS") MACHINE_START(MX1ADS, "Motorola MX1ADS")