summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2011-04-10 16:06:29 -0400
committerStefan Roese <sr@denx.de>2011-04-21 15:51:17 +0200
commit6a011ce851a0ba23ad50f9bac06dc323a863d0c5 (patch)
tree1709e1cbbee8c81647ad6b8ecf9d38be975b0327 /drivers
parent735eb0f0e66b544b1dfaf6c43ce6e4bd9ae64b5e (diff)
downloadu-boot-imx-6a011ce851a0ba23ad50f9bac06dc323a863d0c5.zip
u-boot-imx-6a011ce851a0ba23ad50f9bac06dc323a863d0c5.tar.gz
u-boot-imx-6a011ce851a0ba23ad50f9bac06dc323a863d0c5.tar.bz2
cfi_flash: reverse geometry for M29W800DT parts
The M29W800DT parts also report their geometry with the sector layout reversed. So add that ID to the flash_fixup_stm function. Otherwise, we get: bfin> flinfo Bank # 1: CFI conformant FLASH (16 x 16) Size: 1 MB in 19 Sectors AMD Standard command set, Manufacturer ID: 0x20, Device ID: 0x22D7 Erase timeout: 8192 ms, write timeout: 1 ms Sector Start Addresses: 20000000 20004000 20006000 20008000 20010000 20020000 20030000 20040000 20050000 20060000 20070000 20080000 20090000 200A0000 200B0000 200C0000 200D0000 200E0000 200F0000 Reported-by: Jianxi Fu <fujianxi@gmail.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Stefan Roese <sr@denx.de>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/mtd/cfi_flash.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/mtd/cfi_flash.c b/drivers/mtd/cfi_flash.c
index 91ddcb4..b1110a1 100644
--- a/drivers/mtd/cfi_flash.c
+++ b/drivers/mtd/cfi_flash.c
@@ -1852,9 +1852,10 @@ static void flash_fixup_stm(flash_info_t *info, struct cfi_qry *qry)
if (qry->num_erase_regions > 1) {
/* reverse geometry if top boot part */
if (info->cfi_version < 0x3131) {
- /* CFI < 1.1, guess by device id (M29W320{DT,ET} only) */
- if (info->device_id == 0x22CA ||
- info->device_id == 0x2256) {
+ /* CFI < 1.1, guess by device id */
+ if (info->device_id == 0x22CA || /* M29W320DT */
+ info->device_id == 0x2256 || /* M29W320ET */
+ info->device_id == 0x22D7) { /* M29W800DT */
cfi_reverse_geometry(qry);
}
}