[LinuxBIOS] [PATCH] flashrom: add support for ST M25P80 chips

Carl-Daniel Hailfinger c-d.hailfinger.devel.2006 at gmx.net
Sun Dec 16 01:15:34 CET 2007


Add support for ST M25P80 chips to flashrom. Untested.

Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006 at gmx.net>

Index: flashrom-m25p80/flash.h
===================================================================
--- flashrom-m25p80/flash.h	(Revision 3007)
+++ flashrom-m25p80/flash.h	(Arbeitskopie)
@@ -167,7 +167,12 @@
 #define SST_49LF016C		0x5C
 #define SST_49LF160C		0x4C
 
+/*
+ * ST25P chips are SPI, first byte of device ID is memory type, second
+ * byte of device ID is related to log(bitsize) at least for some chips.
+ */
 #define ST_ID			0x20	/* ST */
+#define ST_M25P80		0x2014
 #define ST_M50FLW040A		0x08
 #define ST_M50FLW040B		0x28
 #define ST_M50FLW080A		0x80
Index: flashrom-m25p80/flashchips.c
===================================================================
--- flashrom-m25p80/flashchips.c	(Revision 3007)
+++ flashrom-m25p80/flashchips.c	(Arbeitskopie)
@@ -140,6 +140,8 @@
 	 probe_jedec,	erase_chip_jedec,	write_jedec},
 	{"M29F040B",	ST_ID, 		ST_M29F040B,	512, 64 * 1024,
 	 probe_29f040b, erase_29f040b,	write_29f040b},
+	{"M25P80",	ST_ID,		ST_M25P80,	1024, 64 * 1024,
+	 probe_spi,	generic_spi_chip_erase,	generic_spi_chip_write},
 	{"82802ab",	137,		173,		512, 64 * 1024,
 	 probe_82802ab, erase_82802ab,	write_82802ab},
 	{"82802ac",	137,		172,		1024, 64 * 1024,






More information about the coreboot mailing list