summaryrefslogtreecommitdiffstats
path: root/chipdrivers.h
diff options
context:
space:
mode:
authorNikolai Artemiev <nartemiev@google.com>2020-10-06 16:59:51 +1100
committerEdward O'Callaghan <quasisec@chromium.org>2020-12-03 12:31:33 +0000
commitadbae0e2681a994520ea551bd2f66b06de0b0899 (patch)
treea9ac2edd308fac78303ab0c2347b8a919720d6c0 /chipdrivers.h
parentf745d0e6ab85f84b482aeac2ac4975e26db57389 (diff)
downloadflashrom-adbae0e2681a994520ea551bd2f66b06de0b0899.tar.gz
flashrom-adbae0e2681a994520ea551bd2f66b06de0b0899.tar.bz2
flashrom-adbae0e2681a994520ea551bd2f66b06de0b0899.zip
s25f.c: implement probing and block erasers for Spansion
This adds support for Spansion 25Fxxxxx chips. These chips require their own probing logic because the first 6 bytes returned by RDID must be examined to identify the chip. New erase functions are required as the chips support multiple sector layouts, and the default layout must be changed to be able to erase the entire flash. Adapted from cros flashrom at `9c4c9a56b6a0370b383df9c75d71b3bd469e672d`. BUG=b:153800073 TEST=builds Signed-off-by: Nikolai Artemiev <nartemiev@google.com> Change-Id: I2d23f9c36ce8b2959807fbeee7f60e02444e3763 Reviewed-on: https://review.coreboot.org/c/flashrom/+/46140 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Edward O'Callaghan <quasisec@chromium.org>
Diffstat (limited to 'chipdrivers.h')
-rw-r--r--chipdrivers.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/chipdrivers.h b/chipdrivers.h
index cf0381172..b42c36387 100644
--- a/chipdrivers.h
+++ b/chipdrivers.h
@@ -170,6 +170,11 @@ int erase_sector_49lfxxxc(struct flashctx *flash, unsigned int address, unsigned
int printlock_sst_fwhub(struct flashctx *flash);
int unlock_sst_fwhub(struct flashctx *flash);
+/* s25f.c */
+int probe_spi_big_spansion(struct flashctx *flash);
+int s25fl_block_erase(struct flashctx *flash, unsigned int addr, unsigned int blocklen);
+int s25fs_block_erase_d8(struct flashctx *flash, unsigned int addr, unsigned int blocklen);
+
/* w39.c */
int printlock_w39f010(struct flashctx * flash);
int printlock_w39l010(struct flashctx * flash);