]> git.sur5r.net Git - u-boot/commitdiff
cfi_flash: Fix typo in cfi_flash.c
authorStefan Roese <sr@denx.de>
Thu, 5 Feb 2009 10:44:52 +0000 (11:44 +0100)
committerStefan Roese <sr@denx.de>
Thu, 5 Feb 2009 10:44:52 +0000 (11:44 +0100)
Patch "flash/cfi_flash: Use virtual sector start address, not phys"
introduced a small typo and compilation warning for systems with CFI
legacy support (e.g. hcu4). This patch fixes it.

Signed-off-by: Stefan Roese <sr@denx.de>
drivers/mtd/cfi_flash.c

index 3a8f8e42e267425aa20d71a58cfbbe4f82147440..bdfad98244475b4b3560924815b49a2d66f9f589 100644 (file)
@@ -1622,7 +1622,7 @@ static int flash_detect_legacy(phys_addr_t base, int banknum)
                                info->vendor = modes[i];
                                info->start[0] =
                                        (ulong)map_physmem(base,
-                                                          info->portwith,
+                                                          info->portwidth,
                                                           MAP_NOCACHE);
                                if (info->portwidth == FLASH_CFI_8BIT
                                        && info->interface == FLASH_CFI_X8X16) {
@@ -1640,7 +1640,7 @@ static int flash_detect_legacy(phys_addr_t base, int banknum)
                                if (jedec_flash_match(info, info->start[0]))
                                        break;
                                else
-                                       unmap_physmem(info->start[0],
+                                       unmap_physmem((void *)info->start[0],
                                                      MAP_NOCACHE);
                        }
                }