[PATCH] fix compile warnings and remove slowport mode setting from ixp2000 map driver

Lennert Buytenhek buytenh at wantstofly.org
Fri Mar 25 18:08:01 EST 2005


(please CC on replies, not on the list)

Setting the slowport to 8-bit mode is done in the generic IXP2000
code (where it belongs) as of 2.6.11, so there's no need to do it
in the MTD map driver anymore.  Also fix two compile warnings that
occur because of treating two 'unsigned long's as 'void *'s.

Signed-off-by: Lennert Buytenhek <buytenh at wantstofly.org>

diff -urN linux-2.6.12-rc1.orig/drivers/mtd/maps/ixp2000.c linux-2.6.12-rc1/drivers/mtd/maps/ixp2000.c
--- linux-2.6.12-rc1.orig/drivers/mtd/maps/ixp2000.c	2005-03-20 18:33:46.000000000 +0100
+++ linux-2.6.12-rc1/drivers/mtd/maps/ixp2000.c	2005-03-25 22:42:54.000000000 +0100
@@ -191,7 +191,7 @@
 	/*
  	 * map_priv_2 is used to store a ptr to to the bank_setup routine
  	 */
-	info->map.map_priv_2 = (void __iomem *) ixp_data->bank_setup;
+	info->map.map_priv_2 = (unsigned long) ixp_data->bank_setup;
 
 	info->map.name = dev->dev.bus_id;
 	info->map.read = ixp2000_flash_read8;
@@ -208,7 +208,7 @@
 		goto Error;
 	}
 
-	info->map.map_priv_1 = ioremap(dev->resource->start, 
+	info->map.map_priv_1 = (unsigned long) ioremap(dev->resource->start, 
 			    	dev->resource->end - dev->resource->start + 1);
 	if (!info->map.map_priv_1) {
 		dev_err(_dev, "Failed to ioremap flash region\n");
@@ -216,11 +216,6 @@
 		goto Error;
 	}
 
-	/*
-	 * Setup read mode for FLASH
-	 */
-	*IXP2000_SLOWPORT_FRM = 1;
-
 #if defined(__ARMEB__)
 	/*
 	 * Enable erratum 44 workaround for NPUs with broken slowport





More information about the linux-mtd mailing list