Bug in physmap driver?
David Howells
dhowells at redhat.com
Thu Apr 16 11:00:19 EDT 2009
In physmap_flash_probe(), isn't the '+ 1' in:
info->map[i].size = dev->resource[i].end - dev->resource[i].start + 1;
incorrect? It results in an artificially inflated size:
(gdb) p info->map[0]
$7 = {name = 0xc08aa520 "physmap-flash.0", size = 0x200001, phys = 0xff000000, virt = 0x0, cached = 0x0, bankwidth = 0x4, read = 0, copy_from = 0, write = 0, copy_to = 0, inval_cache = 0, set_vpp = 0, pfow_base = 0x0, map_priv_1 = 0x0, map_priv_2 = 0x0, fldrv_priv = 0x0, fldrv = 0x0}
which is then handed to devm_ioremap().
David
More information about the linux-mtd
mailing list