Mike Banon uploaded patch set #5 to this change.
Add "--dangerous-bruteforce" mode for the unreliable ISP environments
Some in-system-programming environments are very unreliable, e.g.
when you connect a SOIC8 test clip to the flash chip of WR841ND v9
wireless router: because the low power SOC of this router becomes
powered and is constantly trying to boot, the router's flash chip
is correctly detected only 30% of times, and when it is detected
just 30% of the read operations are successful - the rest result in
zeroes or garbage data being read from a flash chip.
While in this new "--dangerous-bruteforce" mode, flashrom will be
constantly probing for a flash chip until it is correctly detected -
and then, depending on the operation selected by a user, at the
moments of chip availability it will be reading or writing by the
small chunks of 256 bytes maximum size, verifying each small chunk
and retrying the operation until the success or timeout (~ 60 sec).
Constant probing between the small chunk operations is also being
done - to avoid a possible situation where we have got two identical
blocks of zeroes while reading a chunk and erroneously accepted it.
Currently this mode is active only for those SPI25 chips which are
".write = spi_chip_write_256" and ".read = spi_chip_read", but later
could be expanded to more functions to become useful for more chips.
NOTE: this mode is experimental! Also, some targets like WR841ND v9
could block the ISP chip access completely if there is no bootable
firmware inside (e.g. after you've tried to erase the chip contents).
In such a situation it could be hard to recover the firmware without
desoldering a flash chip and flashing it separately. Please do not
erase or write to a flash chip using this mode if you are not sure.
Signed-off-by: Mike Banon <mikebdp2@gmail.com>
Change-Id: If47476793721a0061fd65bc6d1f98d48b03dc6c1
---
M cli_classic.c
M flash.h
M flashrom.c
M libflashrom.c
M libflashrom.h
M spi25.c
6 files changed, 150 insertions(+), 15 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/30/31830/5
To view, visit change 31830. To unsubscribe, or for help writing mail filters, visit settings.