diff options
author | Sean Nelson <audiohacked@gmail.com> | 2009-12-23 17:05:59 +0000 |
---|---|---|
committer | Sean Nelson <audiohacked@gmail.com> | 2009-12-23 17:05:59 +0000 |
commit | f1f154e7f628f17ef09f392b7f8a82192814e7b9 (patch) | |
tree | 98d3e3a122064430879d129ec0cd7a231379caaa /m29f400bt.c | |
parent | b34f9d0fb4ae7cdcd7643d88d599eba91c838a66 (diff) | |
download | flashrom-f1f154e7f628f17ef09f392b7f8a82192814e7b9.zip flashrom-f1f154e7f628f17ef09f392b7f8a82192814e7b9.tar.gz |
Convert the following chips to use struct eraseblock
AMIC_A29002B
AMIC_A29002T
EN_29F002B
EN_29F002T
MBM29F004BC
MBM29F004TC
MBM29F400BC
MBM29F400TC
MX_25L3205
MX_25L6405
MX_29F002B
MX_29F002T
Add block erasers for m29f400bt and mx29f002.
Change programmer delays from 2 seconds to 10us in mx29f002 and am29f040b.
Corresponding to flashrom svn r819.
Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Diffstat (limited to 'm29f400bt.c')
-rw-r--r-- | m29f400bt.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/m29f400bt.c b/m29f400bt.c index c327f44..e77572a 100644 --- a/m29f400bt.c +++ b/m29f400bt.c @@ -102,7 +102,7 @@ int erase_m29f400bt(struct flashchip *flash) return 0; } -int block_erase_m29f400bt(struct flashchip *flash, int start, int len) +int block_erase_m29f400bt(struct flashchip *flash, unsigned int start, unsigned int len) { chipaddr bios = flash->virtual_memory; chipaddr dst = bios + start; @@ -126,6 +126,16 @@ int block_erase_m29f400bt(struct flashchip *flash, int start, int len) return 0; } +int block_erase_chip_m29f400bt(struct flashchip *flash, unsigned int address, unsigned int blocklen) +{ + if ((address != 0) || (blocklen != flash->total_size * 1024)) { + fprintf(stderr, "%s called with incorrect arguments\n", + __func__); + return -1; + } + return erase_m29f400bt(flash); +} + int write_m29f400bt(struct flashchip *flash, uint8_t *buf) { int i; |