diff options
author | Sean Nelson <audiohacked@gmail.com> | 2010-03-20 15:15:36 +0000 |
---|---|---|
committer | Sean Nelson <audiohacked@gmail.com> | 2010-03-20 15:15:36 +0000 |
commit | 46313198d8bb111325910b627b7d1dde6dba9ef8 (patch) | |
tree | ec2d5b9fda859d48a51909a752a17501e3d7532a | |
parent | fcc4f749f355aa3ee48a0d0a13c37adaefbc0f09 (diff) | |
download | ast2050-flashrom-46313198d8bb111325910b627b7d1dde6dba9ef8.zip ast2050-flashrom-46313198d8bb111325910b627b7d1dde6dba9ef8.tar.gz |
Unlock fixup
Corresponding to flashrom svn r961.
Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
-rw-r--r-- | 82802ab.c | 2 | ||||
-rw-r--r-- | stm50flw0x0x.c | 2 |
2 files changed, 2 insertions, 2 deletions
@@ -97,7 +97,7 @@ int unlock_82802ab(struct flashchip *flash) int i; //chipaddr wrprotect = flash->virtual_registers + page + 2; - for (i = 0; i < flash->total_size; i+= flash->page_size) + for (i = 0; i < flash->total_size * 1024; i+= flash->page_size) { chip_writeb(0, flash->virtual_registers + i + 2); } diff --git a/stm50flw0x0x.c b/stm50flw0x0x.c index 1838efc..3300969 100644 --- a/stm50flw0x0x.c +++ b/stm50flw0x0x.c @@ -85,7 +85,7 @@ int unlock_stm50flw0x0x(struct flashchip *flash) { int i; - for (i = 0; i < flash->total_size; i+= flash->page_size) { + for (i = 0; i < flash->total_size * 1024; i+= flash->page_size) { if(unlock_block_stm50flw0x0x(flash, i)) { fprintf(stderr, "UNLOCK FAILED!\n"); return -1; |