[PATCH] mach-gta01: remove spi gpio resouces

Ben Dooks ben-linux at fluff.org
Sat Feb 17 01:24:40 CET 2007


The use of IORESOURCE_MEM is an potential bug wrt to
the platform driver which ensures that the ranges
for IORESOURCE_MEM and IORESOURCE_IO are available
when the device is registered.

Temporarily remove these resources until either they
can be removed by moving to the hardware SPI driver
or that an IORESOURCE_GPIO is added to the kernel.

Signed-off-by: Ben Dooks <ben-linux at fluff.org>

diff -urpN -X linux-2.6.20-dev2/Documentation/dontdiff linux-2.6.20-dev2/arch/arm/mach-s3c2410/mach-gta01.c linux-2.6.20-dev3/arch/arm/mach-s3c2410/mach-gta01.c
--- linux-2.6.20-dev2/arch/arm/mach-s3c2410/mach-gta01.c	2007-02-17 00:05:59.000000000 +0000
+++ linux-2.6.20-dev3/arch/arm/mach-s3c2410/mach-gta01.c	2007-02-17 00:21:34.000000000 +0000
@@ -358,34 +358,9 @@ static struct s3c2410_spigpio_info spi_g
 	.chip_select	= &spi_gpio_cs,
 };
 
-static struct resource s3c_spi_lcm_resource[] = {
-	[0] = {
-		.start = S3C2410_GPG3,
-		.end   = S3C2410_GPG3,
-		.flags = IORESOURCE_MEM,
-	},
-	[1] = {
-		.start = S3C2410_GPG5,
-		.end   = S3C2410_GPG5,
-		.flags = IORESOURCE_MEM,
-	},
-	[2] = {
-		.start = S3C2410_GPG6,
-		.end   = S3C2410_GPG6,
-		.flags = IORESOURCE_MEM,
-	},
-	[3] = {
-		.start = S3C2410_GPG7,
-		.end   = S3C2410_GPG7,
-		.flags = IORESOURCE_MEM,
-	},
-};
-
 struct platform_device s3c_device_spi_lcm = {
 	.name		  = "s3c24xx-spi-gpio",
 	.id		  = 1,
-	.num_resources	  = ARRAY_SIZE(s3c_spi_lcm_resource),
-	.resource	  = s3c_spi_lcm_resource,
 	.dev = {
 		.platform_data = &spi_gpio_cfg,
 	},




More information about the openmoko-kernel mailing list