Skip to content

Commit

Permalink
Reinstate lost flush_ioremap_region() fix to pxa2xx-flash driver
Browse files Browse the repository at this point in the history
Commit 90833fd ("[ARM] 4554/1: replace
consistent_sync() with flush_ioremap_region()") introduced a new
"flush_ioremap_region()" function to be used by the MTD mainstone-flash
and lubbock-flash drivers to fix a regression from around 2.6.18.

Those drivers were independently merged into a single driver by Todd
Poynor in commit e644f7d ("[MTD] MAPS:
Merge Lubbock and Mainstone drivers into common PXA2xx driver")

Later, those two commits were merged into the main MTD tree by commit
b160292 ("Merge Linux 2.6.23") by David
Woodhouse, but in that merge, the fix to use flush_iomap_region() got
lost (as it was to files that now no longer existed).

This reinstates the fix in the new driver.

Noticed-by: Russell King <[email protected]>
Tested-and-acked-by: Nicolas Pitre <[email protected]>
Cc: David Woodhouse <[email protected]>
Cc: Jared Hulbert <[email protected]>
Cc: Todd Poynor <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Linus Torvalds committed Oct 15, 2007
1 parent c596cc4 commit 355aaff
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/mtd/maps/pxa2xx-flash.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,20 +14,20 @@
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/platform_device.h>
#include <linux/dma-mapping.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/map.h>
#include <linux/mtd/partitions.h>

#include <asm/io.h>
#include <asm/hardware.h>
#include <asm/cacheflush.h>

#include <asm/mach/flash.h>

static void pxa2xx_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);
}

struct pxa2xx_flash_info {
Expand Down

0 comments on commit 355aaff

Please sign in to comment.