diff options
author | Jared Hulbert <jaredeh@gmail.com> | 2007-08-22 17:38:25 +0100 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2007-08-23 12:31:31 +0100 |
commit | 90833fdab89da02fc0276224167f0a42e5176f41 (patch) | |
tree | 98faf88d640260ccd7d4d6f8050d3daac29e4374 /drivers/mtd | |
parent | cb00e99c0abd844b884c64c6b54aa3b7d345ebb1 (diff) | |
download | linux-90833fdab89da02fc0276224167f0a42e5176f41.tar.gz linux-90833fdab89da02fc0276224167f0a42e5176f41.tar.bz2 linux-90833fdab89da02fc0276224167f0a42e5176f41.zip |
[ARM] 4554/1: replace consistent_sync() with flush_ioremap_region()
This fixes a regression from around 2.6.18, consistent_sync() will now BUG()
under these circumstances. The use of consistent_sync() was a hack, replacing
it's usage here with a new function, flush_ioremap_region().
Signed-off-by: Jared Hulbert <jaredeh@gmail.com>
Acked-by: Pavel Pisa <pisa@cmp.felk.cvut.cz>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers/mtd')
-rw-r--r-- | drivers/mtd/maps/lubbock-flash.c | 6 | ||||
-rw-r--r-- | drivers/mtd/maps/mainstone-flash.c | 5 |
2 files changed, 4 insertions, 7 deletions
diff --git a/drivers/mtd/maps/lubbock-flash.c b/drivers/mtd/maps/lubbock-flash.c index 1aa0447c5e66..e8560683b973 100644 --- a/drivers/mtd/maps/lubbock-flash.c +++ b/drivers/mtd/maps/lubbock-flash.c @@ -15,9 +15,7 @@ #include <linux/types.h> #include <linux/kernel.h> #include <linux/init.h> -#include <linux/slab.h> -#include <linux/dma-mapping.h> #include <linux/mtd/mtd.h> #include <linux/mtd/map.h> #include <linux/mtd/partitions.h> @@ -26,7 +24,7 @@ #include <asm/hardware.h> #include <asm/arch/pxa-regs.h> #include <asm/arch/lubbock.h> - +#include <asm/cacheflush.h> #define ROM_ADDR 0x00000000 #define FLASH_ADDR 0x04000000 @@ -35,7 +33,7 @@ static void lubbock_map_inval_cache(struct map_info *map, unsigned long from, ssize_t len) { - consistent_sync((char *)map->cached + from, len, DMA_FROM_DEVICE); + flush_ioremap_region(map->phys, map->cached, from, len); } static struct map_info lubbock_maps[2] = { { diff --git a/drivers/mtd/maps/mainstone-flash.c b/drivers/mtd/maps/mainstone-flash.c index eaa4bbb868a3..d76487d82dcd 100644 --- a/drivers/mtd/maps/mainstone-flash.c +++ b/drivers/mtd/maps/mainstone-flash.c @@ -15,8 +15,6 @@ #include <linux/types.h> #include <linux/kernel.h> #include <linux/init.h> -#include <linux/dma-mapping.h> -#include <linux/slab.h> #include <linux/mtd/mtd.h> #include <linux/mtd/map.h> @@ -26,6 +24,7 @@ #include <asm/hardware.h> #include <asm/arch/pxa-regs.h> #include <asm/arch/mainstone.h> +#include <asm/cacheflush.h> #define ROM_ADDR 0x00000000 @@ -36,7 +35,7 @@ static void mainstone_map_inval_cache(struct map_info *map, unsigned long from, ssize_t len) { - consistent_sync((char *)map->cached + from, len, DMA_FROM_DEVICE); + flush_ioremap_region(map->phys, map->cached, from, len); } static struct map_info mainstone_maps[2] = { { |