diff options
author | Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> | 2009-07-23 01:40:20 +0000 |
---|---|---|
committer | Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> | 2009-07-23 01:40:20 +0000 |
commit | 785ede988e5c8ab924da7607d6d0f2665aaabf28 (patch) | |
tree | bcd535a1f032ade49c32e46ce82effe6d60326db /flashchips.c | |
parent | 97bb2139063bea42532324e04de3f1285b7864cb (diff) | |
download | flashrom-785ede988e5c8ab924da7607d6d0f2665aaabf28.zip flashrom-785ede988e5c8ab924da7607d6d0f2665aaabf28.tar.gz |
Add support for old ST M25P05/M25P10 chips which only respond to the RES command and not the RDID command
Unfortunately, either the datasheets are wrong or both chips have exactly
the same ID.
Corresponding to flashrom svn r662.
Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Acked-by: Stefan Reinauer <stepan@coresystems.de>
Diffstat (limited to 'flashchips.c')
-rw-r--r-- | flashchips.c | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/flashchips.c b/flashchips.c index d3c1831..fa5fdff 100644 --- a/flashchips.c +++ b/flashchips.c @@ -2249,6 +2249,27 @@ struct flashchip flashchips[] = { .read = spi_chip_read, }, + /* The ST M25P05 is a bit of a problem. It has the same ID as the + * ST M25P05-A in RES mode, but supports only 128 byte writes instead + * of 256 byte writes. We rely heavily on the fact that probe_spi_res + * only is successful if RDID does not work. + */ + { + .vendor = "ST", + .name = "M25P05.RES", + .bustype = CHIP_BUSTYPE_SPI, + .manufacture_id = ST_ID, + .model_id = ST_M25P05_RES, + .total_size = 64, + .page_size = 256, + .tested = TEST_UNTESTED, + .probe = probe_spi_res, + .probe_timing = TIMING_ZERO, + .erase = spi_chip_erase_c7, + .write = spi_chip_write_1, /* 128 */ + .read = spi_chip_read, + }, + { .vendor = "ST", .name = "M25P10-A", @@ -2265,6 +2286,23 @@ struct flashchip flashchips[] = { .read = spi_chip_read, }, + /* The ST M25P10 has the same problem as the M25P05. */ + { + .vendor = "ST", + .name = "M25P10.RES", + .bustype = CHIP_BUSTYPE_SPI, + .manufacture_id = ST_ID, + .model_id = ST_M25P10_RES, + .total_size = 128, + .page_size = 256, + .tested = TEST_UNTESTED, + .probe = probe_spi_res, + .probe_timing = TIMING_ZERO, + .erase = spi_chip_erase_c7, + .write = spi_chip_write_1, /* 128 */ + .read = spi_chip_read, + }, + { .vendor = "ST", .name = "M25P20", |