1
0
mirror of git://projects.qi-hardware.com/openwrt-xburst.git synced 2024-09-04 18:35:50 +03:00
openwrt-xburst/target/linux/ramips/patches-3.3/010-mtd_fix_cfi_cmdset_0002_erase_status_check.patch

21 lines
538 B
Diff
Raw Normal View History

--- a/drivers/mtd/chips/cfi_cmdset_0002.c
+++ b/drivers/mtd/chips/cfi_cmdset_0002.c
@@ -1627,7 +1627,7 @@ static int __xipram do_erase_chip(struct
chip->erase_suspended = 0;
}
- if (chip_ready(map, adr))
+ if (chip_good(map, adr, map_word_ff(map)))
break;
if (time_after(jiffies, timeo)) {
@@ -1715,7 +1715,7 @@ static int __xipram do_erase_oneblock(st
chip->erase_suspended = 0;
}
- if (chip_ready(map, adr)) {
+ if (chip_good(map, adr, map_word_ff(map))) {
xip_enable(map, chip, adr);
break;
}