diff options
author | Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de> | 2009-11-27 17:49:42 +0000 |
---|---|---|
committer | Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> | 2009-11-27 17:49:42 +0000 |
commit | 859a2167790eebd01b9b4dcf860c8a69e8278063 (patch) | |
tree | ccbfa84c583ef476bca4aa6015d65b63ad291679 /flashchips.c | |
parent | a70a5cec0c68f08fb9204483fb47071e6c09e316 (diff) | |
download | flashrom-859a2167790eebd01b9b4dcf860c8a69e8278063.zip flashrom-859a2167790eebd01b9b4dcf860c8a69e8278063.tar.gz |
Use common jedec functionality where appropriate
The deleted function in en29f002a.c is reintroduced as write_by_byte_jedec
in jedec.c as it contains no chip-specific instructions. It is not yet
used in other chip drivers, as key addresses (0x2AAA/0x5555) are often
specified with less bits. After crosschecking datasheets, most of the
fixmes can probably be resolved as indicated in them, causing significant
code reduction. The common JEDEC code for bytewise programming does
not program 0xFF at all. The chips that had a dedicated bytewise flash
function which has been changed to write_jedec_1 thus changed flashing
behaviour and the "write" test flag has been removed. This applies to:
AMD Am29F002BB/Am29F002NBB AMD Am29F002BT/Am29F002NBT (TEST_OK_PREW before)
AMIC A29002B AMIC A29002T (TEST_OK_PREW before) EON EN29F002(A)(N)B EON
EN29F002(A)(N)T (TEST_OK_PREW before) Macronix MX29F001B (TEST_OK_PREW before)
Macronix MX29F001T (TEST_OK_PREW before) Macronix MX29F002B Macronix MX29F002T
(TEST_OK_PREW before) Macronix MX29LV040 Similar analysis should be performed
for the read id stuff.
Corresponding to flashrom svn r785.
Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Diffstat (limited to 'flashchips.c')
-rw-r--r-- | flashchips.c | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/flashchips.c b/flashchips.c index 8618c46..5e74ccf 100644 --- a/flashchips.c +++ b/flashchips.c @@ -81,7 +81,7 @@ struct flashchip flashchips[] = { .probe = probe_jedec, .probe_timing = TIMING_ZERO, .erase = erase_chip_jedec, - .write = write_en29f002a, + .write = write_jedec_1, .read = read_memmapped, }, @@ -93,11 +93,11 @@ struct flashchip flashchips[] = { .model_id = AM_29F002BT, .total_size = 256, .page_size = 256, - .tested = TEST_OK_PREW, + .tested = TEST_OK_PRE, .probe = probe_jedec, .probe_timing = TIMING_ZERO, .erase = erase_chip_jedec, - .write = write_en29f002a, + .write = write_jedec_1, .read = read_memmapped, }, @@ -739,7 +739,7 @@ struct flashchip flashchips[] = { .probe = probe_29f002, .probe_timing = TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */ .erase = erase_29f002, - .write = write_29f002, + .write = write_jedec_1, .read = read_memmapped, }, @@ -751,11 +751,11 @@ struct flashchip flashchips[] = { .model_id = AMIC_A29002T, .total_size = 256, .page_size = 64 * 1024, - .tested = TEST_OK_PREW, + .tested = TEST_OK_PRE, .probe = probe_29f002, .probe_timing = TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */ .erase = erase_29f002, - .write = write_29f002, + .write = write_jedec_1, .read = read_memmapped, }, @@ -1075,7 +1075,7 @@ struct flashchip flashchips[] = { .probe = probe_jedec, .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */ .erase = erase_chip_jedec, - .write = write_en29f002a, + .write = write_jedec_1, .read = read_memmapped, }, @@ -1087,11 +1087,11 @@ struct flashchip flashchips[] = { .model_id = EN_29F002T, .total_size = 256, .page_size = 256, - .tested = TEST_OK_PREW, + .tested = TEST_OK_PRE, .probe = probe_jedec, .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */ .erase = erase_chip_jedec, - .write = write_en29f002a, + .write = write_jedec_1, .read = read_memmapped, }, @@ -1518,11 +1518,11 @@ struct flashchip flashchips[] = { .model_id = MX_29F001B, .total_size = 128, .page_size = 32 * 1024, - .tested = TEST_OK_PREW, + .tested = TEST_OK_PRE, .probe = probe_29f002, .probe_timing = TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */ .erase = erase_29f002, - .write = write_29f002, + .write = write_jedec_1, .read = read_memmapped, }, @@ -1534,11 +1534,11 @@ struct flashchip flashchips[] = { .model_id = MX_29F001T, .total_size = 128, .page_size = 32 * 1024, - .tested = TEST_OK_PREW, + .tested = TEST_OK_PRE, .probe = probe_29f002, .probe_timing = TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */ .erase = erase_29f002, - .write = write_29f002, + .write = write_jedec_1, .read = read_memmapped, }, @@ -1554,7 +1554,7 @@ struct flashchip flashchips[] = { .probe = probe_29f002, .probe_timing = TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */ .erase = erase_29f002, - .write = write_29f002, + .write = write_jedec_1, .read = read_memmapped, }, @@ -1566,11 +1566,11 @@ struct flashchip flashchips[] = { .model_id = MX_29F002T, .total_size = 256, .page_size = 64 * 1024, - .tested = TEST_OK_PREW, + .tested = TEST_OK_PRE, .probe = probe_29f002, .probe_timing = TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */ .erase = erase_29f002, - .write = write_29f002, + .write = write_jedec_1, .read = read_memmapped, }, @@ -1586,7 +1586,7 @@ struct flashchip flashchips[] = { .probe = probe_29f002, .probe_timing = TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */ .erase = erase_29f002, - .write = write_29f002, + .write = write_jedec_1, .read = read_memmapped, }, |