[coreboot] r3331 - trunk/util/flashrom

svn at coreboot.org svn at coreboot.org
Fri May 16 23:11:54 CEST 2008


Author: hailfinger
Date: 2008-05-16 23:11:53 +0200 (Fri, 16 May 2008)
New Revision: 3331

Modified:
   trunk/util/flashrom/sst39sf020.c
Log:
I looked at the datasheet and erase_sector_39sf020() is totally and
completely wrong. It was a straight cut'n'paste from SST 28SF040 code
and the person doing the cut'n'paste didn't even bother to check the
data sheet. The SST 39SF020 is completely incompatible with the 28SF040.

No need for replacement. According to the data sheet, standard JEDEC
commands will work and we have those commands in the tree already.

Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006 at gmx.net>
Acked-by: Joseph Smith <joe at settoplinux.org>


Modified: trunk/util/flashrom/sst39sf020.c
===================================================================
--- trunk/util/flashrom/sst39sf020.c	2008-05-16 18:56:24 UTC (rev 3330)
+++ trunk/util/flashrom/sst39sf020.c	2008-05-16 21:11:53 UTC (rev 3331)
@@ -22,21 +22,6 @@
 #include <stdint.h>
 #include "flash.h"
 
-#define AUTO_PG_ERASE1		0x20
-#define AUTO_PG_ERASE2		0xD0
-
-static __inline__ int erase_sector_39sf020(volatile uint8_t *bios,
-					   unsigned long address)
-{
-	*bios = AUTO_PG_ERASE1;
-	*(bios + address) = AUTO_PG_ERASE2;
-
-	/* wait for Toggle bit ready         */
-	toggle_ready_jedec(bios);
-
-	return 0;
-}
-
 int write_39sf020(struct flashchip *flash, uint8_t *buf)
 {
 	int i;





More information about the coreboot mailing list