summaryrefslogtreecommitdiffstats
path: root/flashchips.c
diff options
context:
space:
mode:
authorCory Henderson <dcoryh192@gmail.com>2013-10-19 23:09:16 +0000
committerStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>2013-10-19 23:09:16 +0000
commit3c0b736958813656792f11c77618ce5e96b97fa5 (patch)
tree03d8cffab913f4f459e12175302e0872a391b700 /flashchips.c
parentfccb009a8806033d31a482d186ded5fbd1c31a99 (diff)
downloadflashrom-3c0b736958813656792f11c77618ce5e96b97fa5.zip
flashrom-3c0b736958813656792f11c77618ce5e96b97fa5.tar.gz
Refine support for SST25VF family
- Reorder some models and refine comments. - Add SST25VF512A: AAI is available but with an uncommon opcode (0xAF). Fully tested with Bus Pirate 3.5 running 6.2 beta firmware by Cory. - Add SST25VF020 and SST25VF020B. Corresponding to flashrom svn r1758. Signed-off-by: Cory Henderson <dcoryh192@gmail.com> Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
Diffstat (limited to 'flashchips.c')
-rw-r--r--flashchips.c222
1 files changed, 168 insertions, 54 deletions
diff --git a/flashchips.c b/flashchips.c
index 05eb5b3..a6db11e 100644
--- a/flashchips.c
+++ b/flashchips.c
@@ -9551,11 +9551,11 @@ const struct flashchip flashchips[] = {
{
.vendor = "SST",
- .name = "SST25VF010",
+ .name = "SST25VF512A",
.bustype = BUS_SPI,
.manufacture_id = SST_ID,
- .model_id = SST_SST25VF010_REMS,
- .total_size = 128,
+ .model_id = SST_SST25VF512A_REMS,
+ .total_size = 64,
.page_size = 256,
.feature_bits = FEATURE_WRSR_EWSR,
.tested = TEST_OK_PREW,
@@ -9564,134 +9564,134 @@ const struct flashchip flashchips[] = {
.block_erasers =
{
{
- .eraseblocks = { {4 * 1024, 32} },
+ .eraseblocks = { {4 * 1024, 16} },
.block_erase = spi_block_erase_20,
}, {
- .eraseblocks = { {32 * 1024, 4} },
+ .eraseblocks = { {32 * 1024, 2} },
.block_erase = spi_block_erase_52,
}, {
- .eraseblocks = { {128 * 1024, 1} },
+ .eraseblocks = { {32 * 1024, 2} },
+ .block_erase = spi_block_erase_d8,
+ }, {
+ .eraseblocks = { {64 * 1024, 1} },
.block_erase = spi_block_erase_60,
+ }, {
+ .eraseblocks = { {64 * 1024, 1} },
+ .block_erase = spi_block_erase_c7,
},
},
- .printlock = spi_prettyprint_status_register_sst25, /* TODO: check */
+ .printlock = spi_prettyprint_status_register_sst25, /* FIXME: No BP2 & 3 */
.unlock = spi_disable_blockprotect,
- .write = spi_chip_write_1,
- .read = spi_chip_read,
+ .write = spi_chip_write_1, /* AAI supported, but opcode is 0xAF */
+ .read = spi_chip_read, /* Fast read (0x0B) supported */
.voltage = {2700, 3600},
},
{
.vendor = "SST",
- .name = "SST25VF016B",
+ .name = "SST25VF010",
.bustype = BUS_SPI,
.manufacture_id = SST_ID,
- .model_id = SST_SST25VF016B,
- .total_size = 2048,
+ .model_id = SST_SST25VF010_REMS,
+ .total_size = 128,
.page_size = 256,
- .feature_bits = FEATURE_WRSR_EITHER,
+ .feature_bits = FEATURE_WRSR_EWSR,
.tested = TEST_OK_PREW,
- .probe = probe_spi_rdid,
+ .probe = probe_spi_rems,
.probe_timing = TIMING_ZERO,
.block_erasers =
{
{
- .eraseblocks = { {4 * 1024, 512} },
+ .eraseblocks = { {4 * 1024, 32} },
.block_erase = spi_block_erase_20,
}, {
- .eraseblocks = { {32 * 1024, 64} },
+ .eraseblocks = { {32 * 1024, 4} },
.block_erase = spi_block_erase_52,
}, {
- .eraseblocks = { {64 * 1024, 32} },
+ .eraseblocks = { {32 * 1024, 4} },
.block_erase = spi_block_erase_d8,
}, {
- .eraseblocks = { {2 * 1024 * 1024, 1} },
+ .eraseblocks = { {128 * 1024, 1} },
.block_erase = spi_block_erase_60,
}, {
- .eraseblocks = { {2 * 1024 * 1024, 1} },
+ .eraseblocks = { {128 * 1024, 1} },
.block_erase = spi_block_erase_c7,
},
},
- .printlock = spi_prettyprint_status_register_sst25vf016,
+ .printlock = spi_prettyprint_status_register_sst25, /* FIXME: No BP2 & 3 */
.unlock = spi_disable_blockprotect,
- .write = spi_aai_write,
- .read = spi_chip_read,
+ .write = spi_chip_write_1, /* AAI supported, but opcode is 0xAF */
+ .read = spi_chip_read, /* Fast read (0x0B) supported */
.voltage = {2700, 3600},
},
{
.vendor = "SST",
- .name = "SST25VF032B",
+ .name = "SST25VF020",
.bustype = BUS_SPI,
.manufacture_id = SST_ID,
- .model_id = SST_SST25VF032B,
- .total_size = 4096,
+ .model_id = SST_SST25VF020_REMS,
+ .total_size = 256,
.page_size = 256,
.feature_bits = FEATURE_WRSR_EWSR,
- .tested = TEST_OK_PREW,
- .probe = probe_spi_rdid,
+ .tested = TEST_UNTESTED,
+ .probe = probe_spi_rems,
.probe_timing = TIMING_ZERO,
.block_erasers =
{
{
- .eraseblocks = { {4 * 1024, 1024} },
+ .eraseblocks = { {4 * 1024, 64} },
.block_erase = spi_block_erase_20,
}, {
- .eraseblocks = { {32 * 1024, 128} },
+ .eraseblocks = { {32 * 1024, 8} },
.block_erase = spi_block_erase_52,
}, {
- .eraseblocks = { {64 * 1024, 64} },
- .block_erase = spi_block_erase_d8,
- }, {
- .eraseblocks = { {4 * 1024 * 1024, 1} },
+ .eraseblocks = { {256 * 1024, 1} },
.block_erase = spi_block_erase_60,
- }, {
- .eraseblocks = { {4 * 1024 * 1024, 1} },
- .block_erase = spi_block_erase_c7,
},
},
- .printlock = spi_prettyprint_status_register_sst25, /* TODO: check */
+ .printlock = spi_prettyprint_status_register_sst25, /* FIXME: No BP2 & 3 */
.unlock = spi_disable_blockprotect,
- .write = spi_aai_write,
- .read = spi_chip_read,
+ .write = spi_chip_write_1, /* AAI supported, but opcode is 0xAF */
+ .read = spi_chip_read, /* only */
.voltage = {2700, 3600},
},
{
.vendor = "SST",
- .name = "SST25VF064C",
+ .name = "SST25VF020B",
.bustype = BUS_SPI,
.manufacture_id = SST_ID,
- .model_id = SST_SST25VF064C,
- .total_size = 8192,
+ .model_id = SST_SST25VF020B,
+ .total_size = 256,
.page_size = 256,
.feature_bits = FEATURE_WRSR_EWSR,
- .tested = TEST_OK_PREW,
+ .tested = TEST_UNTESTED,
.probe = probe_spi_rdid,
.probe_timing = TIMING_ZERO,
.block_erasers =
{
{
- .eraseblocks = { {4 * 1024, 2048} },
+ .eraseblocks = { {4 * 1024, 64} },
.block_erase = spi_block_erase_20,
}, {
- .eraseblocks = { {32 * 1024, 256} },
+ .eraseblocks = { {32 * 1024, 8} },
.block_erase = spi_block_erase_52,
}, {
- .eraseblocks = { {64 * 1024, 128} },
+ .eraseblocks = { {64 * 1024, 4} },
.block_erase = spi_block_erase_d8,
}, {
- .eraseblocks = { {8 * 1024 * 1024, 1} },
+ .eraseblocks = { {256 * 1024, 1} },
.block_erase = spi_block_erase_60,
}, {
- .eraseblocks = { {8 * 1024 * 1024, 1} },
+ .eraseblocks = { {256 * 1024, 1} },
.block_erase = spi_block_erase_c7,
},
},
- .printlock = spi_prettyprint_status_register_sst25, /* TODO: check */
- .unlock = spi_disable_blockprotect,
- .write = spi_chip_write_256,
- .read = spi_chip_read,
+ .printlock = spi_prettyprint_status_register_sst25, /* FIXME: No BP2 & 3 and 2nd SR */
+ .unlock = spi_disable_blockprotect, /* FIXME: 2nd SR */
+ .write = spi_aai_write, /* AAI supported (0xAD) */
+ .read = spi_chip_read, /* Fast read (0x0B) supported */
.voltage = {2700, 3600},
},
@@ -9760,8 +9760,8 @@ const struct flashchip flashchips[] = {
},
.printlock = spi_prettyprint_status_register_sst25vf040b,
.unlock = spi_disable_blockprotect,
- .write = spi_aai_write,
- .read = spi_chip_read,
+ .write = spi_aai_write, /* AAI supported (0xAD) */
+ .read = spi_chip_read, /* Fast read (0x0B) supported */
.voltage = {2700, 3600},
},
@@ -9843,6 +9843,120 @@ const struct flashchip flashchips[] = {
{
.vendor = "SST",
+ .name = "SST25VF016B",
+ .bustype = BUS_SPI,
+ .manufacture_id = SST_ID,
+ .model_id = SST_SST25VF016B,
+ .total_size = 2048,
+ .page_size = 256,
+ .feature_bits = FEATURE_WRSR_EITHER,
+ .tested = TEST_OK_PREW,
+ .probe = probe_spi_rdid,
+ .probe_timing = TIMING_ZERO,
+ .block_erasers =
+ {
+ {
+ .eraseblocks = { {4 * 1024, 512} },
+ .block_erase = spi_block_erase_20,
+ }, {
+ .eraseblocks = { {32 * 1024, 64} },
+ .block_erase = spi_block_erase_52,
+ }, {
+ .eraseblocks = { {64 * 1024, 32} },
+ .block_erase = spi_block_erase_d8,
+ }, {
+ .eraseblocks = { {2 * 1024 * 1024, 1} },
+ .block_erase = spi_block_erase_60,
+ }, {
+ .eraseblocks = { {2 * 1024 * 1024, 1} },
+ .block_erase = spi_block_erase_c7,
+ },
+ },
+ .printlock = spi_prettyprint_status_register_sst25vf016,
+ .unlock = spi_disable_blockprotect,
+ .write = spi_aai_write,
+ .read = spi_chip_read,
+ .voltage = {2700, 3600},
+ },
+
+ {
+ .vendor = "SST",
+ .name = "SST25VF032B",
+ .bustype = BUS_SPI,
+ .manufacture_id = SST_ID,
+ .model_id = SST_SST25VF032B,
+ .total_size = 4096,
+ .page_size = 256,
+ .feature_bits = FEATURE_WRSR_EWSR,
+ .tested = TEST_OK_PREW,
+ .probe = probe_spi_rdid,
+ .probe_timing = TIMING_ZERO,
+ .block_erasers =
+ {
+ {
+ .eraseblocks = { {4 * 1024, 1024} },
+ .block_erase = spi_block_erase_20,
+ }, {
+ .eraseblocks = { {32 * 1024, 128} },
+ .block_erase = spi_block_erase_52,
+ }, {
+ .eraseblocks = { {64 * 1024, 64} },
+ .block_erase = spi_block_erase_d8,
+ }, {
+ .eraseblocks = { {4 * 1024 * 1024, 1} },
+ .block_erase = spi_block_erase_60,
+ }, {
+ .eraseblocks = { {4 * 1024 * 1024, 1} },
+ .block_erase = spi_block_erase_c7,
+ },
+ },
+ .printlock = spi_prettyprint_status_register_sst25, /* TODO: check */
+ .unlock = spi_disable_blockprotect,
+ .write = spi_aai_write,
+ .read = spi_chip_read,
+ .voltage = {2700, 3600},
+ },
+
+ {
+ .vendor = "SST",
+ .name = "SST25VF064C",
+ .bustype = BUS_SPI,
+ .manufacture_id = SST_ID,
+ .model_id = SST_SST25VF064C,
+ .total_size = 8192,
+ .page_size = 256,
+ .feature_bits = FEATURE_WRSR_EWSR,
+ .tested = TEST_OK_PREW,
+ .probe = probe_spi_rdid,
+ .probe_timing = TIMING_ZERO,
+ .block_erasers =
+ {
+ {
+ .eraseblocks = { {4 * 1024, 2048} },
+ .block_erase = spi_block_erase_20,
+ }, {
+ .eraseblocks = { {32 * 1024, 256} },
+ .block_erase = spi_block_erase_52,
+ }, {
+ .eraseblocks = { {64 * 1024, 128} },
+ .block_erase = spi_block_erase_d8,
+ }, {
+ .eraseblocks = { {8 * 1024 * 1024, 1} },
+ .block_erase = spi_block_erase_60,
+ }, {
+ .eraseblocks = { {8 * 1024 * 1024, 1} },
+ .block_erase = spi_block_erase_c7,
+ },
+ },
+ .printlock = spi_prettyprint_status_register_sst25, /* TODO: check */
+ .unlock = spi_disable_blockprotect,
+ .write = spi_chip_write_256,
+ .read = spi_chip_read,
+ .voltage = {2700, 3600},
+ },
+
+ {
+ .vendor = "SST",
.name = "SST25WF512",
.bustype = BUS_SPI,
.manufacture_id = SST_ID,
OpenPOWER on IntegriCloud