summaryrefslogtreecommitdiffstats
path: root/flashchips.c
diff options
context:
space:
mode:
authorNico Huber <nico.h@gmx.de>2017-11-10 22:54:13 +0100
committerNico Huber <nico.h@gmx.de>2018-01-02 20:15:35 +0000
commitaac81424ebb8234b54cbab8fe47350b562b84fae (patch)
tree2806be52075a5a3a46c5e7be2ccdb6d69b6e1a0f /flashchips.c
parentfe34d2af28bd81aaa1e23ba38febaa98ec4bb90c (diff)
downloadflashrom-aac81424ebb8234b54cbab8fe47350b562b84fae.tar.gz
flashrom-aac81424ebb8234b54cbab8fe47350b562b84fae.tar.bz2
flashrom-aac81424ebb8234b54cbab8fe47350b562b84fae.zip
flashchips: Revise all 4BA chips
Advertise all 4BA features that are currently supported by flashrom, plus add a new feature flag for the 4BA fast-read instruction. Also, list all supported 3BA and 4BA erase-block functions. As this adds a lot of new code paths that could be taken for these chips, mark them all as untested again. Change-Id: I0598496ee7058e3b170684d366f58e4014e0e871 Signed-off-by: Nico Huber <nico.h@gmx.de> Reviewed-on: https://review.coreboot.org/22423 Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: David Hendricks <david.hendricks@gmail.com>
Diffstat (limited to 'flashchips.c')
-rw-r--r--flashchips.c55
1 files changed, 42 insertions, 13 deletions
diff --git a/flashchips.c b/flashchips.c
index 0e16a48ce..e389af667 100644
--- a/flashchips.c
+++ b/flashchips.c
@@ -8127,27 +8127,36 @@ const struct flashchip flashchips[] = {
{
.vendor = "Macronix",
- .name = "MX25L25635F/MX25L25645E/MX25L25665E",
+ .name = "MX25L25635F",
.bustype = BUS_SPI,
.manufacture_id = MACRONIX_ID,
.model_id = MACRONIX_MX25L25635F,
.total_size = 32768,
.page_size = 256,
/* OTP: 512B total; enter 0xB1, exit 0xC1 */
- .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_ENTER,
- .tested = TEST_OK_PREW,
+ .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA,
+ .tested = TEST_UNTESTED,
.probe = probe_spi_rdid,
.probe_timing = TIMING_ZERO,
.block_erasers =
{
{
.eraseblocks = { {4 * 1024, 8192} },
+ .block_erase = spi_block_erase_21,
+ }, {
+ .eraseblocks = { {4 * 1024, 8192} },
.block_erase = spi_block_erase_20,
}, {
.eraseblocks = { {32 * 1024, 1024} },
+ .block_erase = spi_block_erase_5c,
+ }, {
+ .eraseblocks = { {32 * 1024, 1024} },
.block_erase = spi_block_erase_52,
}, {
.eraseblocks = { {64 * 1024, 512} },
+ .block_erase = spi_block_erase_dc,
+ }, {
+ .eraseblocks = { {64 * 1024, 512} },
.block_erase = spi_block_erase_d8,
}, {
.eraseblocks = { {32 * 1024 * 1024, 1} },
@@ -8174,20 +8183,29 @@ const struct flashchip flashchips[] = {
.total_size = 65536,
.page_size = 256,
/* OTP: 512B total; enter 0xB1, exit 0xC1 */
- .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_ENTER,
- .tested = TEST_OK_PREW,
+ .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA,
+ .tested = TEST_UNTESTED,
.probe = probe_spi_rdid,
.probe_timing = TIMING_ZERO,
.block_erasers =
{
{
.eraseblocks = { {4 * 1024, 16384} },
+ .block_erase = spi_block_erase_21,
+ }, {
+ .eraseblocks = { {4 * 1024, 16384} },
.block_erase = spi_block_erase_20,
}, {
.eraseblocks = { {32 * 1024, 2048} },
+ .block_erase = spi_block_erase_5c,
+ }, {
+ .eraseblocks = { {32 * 1024, 2048} },
.block_erase = spi_block_erase_52,
}, {
.eraseblocks = { {64 * 1024, 1024} },
+ .block_erase = spi_block_erase_dc,
+ }, {
+ .eraseblocks = { {64 * 1024, 1024} },
.block_erase = spi_block_erase_d8,
}, {
.eraseblocks = { {64 * 1024 * 1024, 1} },
@@ -9914,9 +9932,8 @@ const struct flashchip flashchips[] = {
.page_size = 256,
/* supports SFDP */
/* OTP: 64B total; read 0x4B, write 0x42 */
- .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP
- | FEATURE_4BA_ENTER_WREN | FEATURE_4BA_READ | FEATURE_4BA_WRITE,
- .tested = TEST_OK_PREW,
+ .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
+ .tested = TEST_UNTESTED,
.probe = probe_spi_rdid,
.probe_timing = TIMING_ZERO,
.block_erasers = {
@@ -9924,9 +9941,15 @@ const struct flashchip flashchips[] = {
.eraseblocks = { {4 * 1024, 8192} },
.block_erase = spi_block_erase_21,
}, {
+ .eraseblocks = { {4 * 1024, 8192} },
+ .block_erase = spi_block_erase_20,
+ }, {
.eraseblocks = { {64 * 1024, 512} },
.block_erase = spi_block_erase_dc,
}, {
+ .eraseblocks = { {64 * 1024, 512} },
+ .block_erase = spi_block_erase_d8,
+ }, {
.eraseblocks = { {32768 * 1024, 1} },
.block_erase = spi_block_erase_c7,
}
@@ -9948,9 +9971,8 @@ const struct flashchip flashchips[] = {
.page_size = 256,
/* supports SFDP */
/* OTP: 64B total; read 0x4B, write 0x42 */
- .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP
- | FEATURE_4BA_ENTER_WREN | FEATURE_4BA_READ | FEATURE_4BA_WRITE,
- .tested = TEST_OK_PREW,
+ .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
+ .tested = TEST_UNTESTED,
.probe = probe_spi_rdid,
.probe_timing = TIMING_ZERO,
.block_erasers = {
@@ -9958,9 +9980,15 @@ const struct flashchip flashchips[] = {
.eraseblocks = { {4 * 1024, 16384} },
.block_erase = spi_block_erase_21,
}, {
+ .eraseblocks = { {4 * 1024, 16384} },
+ .block_erase = spi_block_erase_20,
+ }, {
.eraseblocks = { {64 * 1024, 1024} },
.block_erase = spi_block_erase_dc,
}, {
+ .eraseblocks = { {64 * 1024, 1024} },
+ .block_erase = spi_block_erase_d8,
+ }, {
.eraseblocks = { {65536 * 1024, 1} },
.block_erase = spi_block_erase_c7,
}
@@ -14827,8 +14855,9 @@ const struct flashchip flashchips[] = {
/* supports SFDP */
/* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
/* FOUR_BYTE_ADDR: supports 4-bytes addressing mode */
- .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_ENTER_WREN | FEATURE_4BA_READ,
- .tested = TEST_OK_PREW,
+ .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_ENTER_WREN
+ | FEATURE_4BA_EXT_ADDR | FEATURE_4BA_READ | FEATURE_4BA_FAST_READ,
+ .tested = TEST_UNTESTED,
.probe = probe_spi_rdid,
.probe_timing = TIMING_ZERO,
.block_erasers =