summaryrefslogtreecommitdiffstats
path: root/drivers/mtd/maps/bfin-async-flash.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mtd/maps/bfin-async-flash.c')
-rw-r--r--drivers/mtd/maps/bfin-async-flash.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/maps/bfin-async-flash.c b/drivers/mtd/maps/bfin-async-flash.c
index d4297a9..67815ee 100644
--- a/drivers/mtd/maps/bfin-async-flash.c
+++ b/drivers/mtd/maps/bfin-async-flash.c
@@ -142,7 +142,7 @@ static int __devinit bfin_flash_probe(struct platform_device *pdev)
state->map.write = bfin_flash_write;
state->map.copy_to = bfin_flash_copy_to;
state->map.bankwidth = pdata->width;
- state->map.size = memory->end - memory->start + 1;
+ state->map.size = resource_size(memory);
state->map.virt = (void __iomem *)memory->start;
state->map.phys = memory->start;
state->map.map_priv_1 = (unsigned long)state;
OpenPOWER on IntegriCloud