diff --git a/Makefile b/Makefile
index b3f8b2f..62c6a74 100644
--- a/Makefile
+++ b/Makefile
@@ -32,28 +32,27 @@ OS_ARCH	= $(shell uname)
 ifneq ($(OS_ARCH), SunOS)
 STRIP_ARGS = -s
 endif
 ifeq ($(OS_ARCH), Darwin)
 CPPFLAGS += -I/opt/local/include -I/usr/local/include
 LDFLAGS += -framework IOKit -framework DirectIO -L/opt/local/lib -L/usr/local/lib
 endif
 ifeq ($(OS_ARCH), FreeBSD)
 CPPFLAGS += -I/usr/local/include
 LDFLAGS += -L/usr/local/lib
 endif
 
 CHIP_OBJS = jedec.o stm50flw0x0x.o w39v080fa.o sharplhf00l04.o w29ee011.o \
-	sst28sf040.o am29f040b.o mx29f002.o m29f400bt.o pm29f002.o w39v040c.o \
-	w49f002u.o 82802ab.o pm49fl00x.o sst49lf040.o en29f002a.o m29f002.o \
+	sst28sf040.o m29f400bt.o 82802ab.o pm49fl00x.o \
 	sst49lfxxxc.o sst_fwhub.o flashchips.o spi.o
 
 LIB_OBJS = layout.o
 
 CLI_OBJS = flashrom.o cli_classic.o cli_output.o print.o
 
 PROGRAMMER_OBJS = udelay.o programmer.o
 
 all: pciutils features dep $(PROGRAM)
 
 # Set the flashrom version string from the highest revision number
 # of the checked out flashrom files.
 # Note to packagers: Any tree exported with "make export" or "make tarball"
diff --git a/flash.h b/flash.h
index f0ac246..290a91a 100644
--- a/flash.h
+++ b/flash.h
@@ -144,28 +144,34 @@ enum chipbustype {
 /*
  * How many different contiguous runs of erase blocks with one size each do
  * we have for a given erase function?
  */
 #define NUM_ERASEREGIONS 5
 
 /*
  * How many different erase functions do we have per chip?
  */
 #define NUM_ERASEFUNCTIONS 5
 
 #define FEATURE_REGISTERMAP	(1 << 0)
 #define FEATURE_BYTEWRITES	(1 << 1)
+#define FEATURE_EITHER_RESET	(0 << 4)
+#define FEATURE_SHORT_RESET	(1 << 4)
+#define FEATURE_LONG_RESET	FEATURE_EITHER_RESET
 #define FEATURE_ADDR_FULL	(0 << 2)
 #define FEATURE_ADDR_MASK	(3 << 2)
+#define FEATURE_ADDR_2AA	(1 << 2)
+#define FEATURE_ADDR_AAA	(2 << 2)
+#define FEATURE_ADDR_SHIFTED	0
 
 struct flashchip {
 	const char *vendor;
 	const char *name;
 
 	enum chipbustype bustype;
 
 	/*
 	 * With 32bit manufacture_id and model_id we can cover IDs up to
 	 * (including) the 4th bank of JEDEC JEP106W Standard Manufacturer's
 	 * Identification code.
 	 */
 	uint32_t manufacture_id;
diff --git a/flashchips.c b/flashchips.c
index 03686e6..53d053a 100644
--- a/flashchips.c
+++ b/flashchips.c
@@ -52,52 +52,54 @@ struct flashchip flashchips[] = {
 	 * }
 	 * .write		= Chip write function
 	 * .read		= Chip read function
 	 */
 
 	{
 		.vendor		= "AMD",
 		.name		= "Am29F010A/B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= AMD_ID,
 		.model_id	= AM_29F010B,	/* Same as Am29F010A */
 		.total_size	= 128,
 		.page_size	= 16 * 1024,
-		.tested		= TEST_OK_PRW,
-		.probe		= probe_29f040b,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {16 * 1024, 8} },
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {128 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_pm29f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "AMD",
 		.name		= "Am29F002(N)BB",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= AMD_ID,
 		.model_id	= AM_29F002BB,
 		.total_size	= 256,
 		.page_size	= 256,
+		.feature_bits	= FEATURE_SHORT_RESET | FEATURE_ADDR_2AA,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{16 * 1024, 1},
 					{8 * 1024, 2},
 					{32 * 1024, 1},
 					{64 * 1024, 3},
 				},
@@ -109,27 +111,28 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "AMD",
 		.name		= "Am29F002(N)BT",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= AMD_ID,
 		.model_id	= AM_29F002BT,
 		.total_size	= 256,
 		.page_size	= 256,
-		.tested		= TEST_OK_PR,
+		.feature_bits	= FEATURE_EITHER_RESET | FEATURE_ADDR_2AA,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{64 * 1024, 3},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
 				.block_erase = erase_sector_jedec,
@@ -140,156 +143,162 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "AMD",
 		.name		= "Am29F016D",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= AMD_ID,
 		.model_id	= AM_29F016D,
 		.total_size	= 2 * 1024,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
 		.tested		= TEST_UNTESTED,
-		.probe		= probe_29f040b,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (am29f040b.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 32} },
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {2048 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_29f040b,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "AMD",
 		.name		= "Am29F040B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= AMD_ID,
 		.model_id	= AM_29F040B,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PRW,
-		.probe		= probe_29f040b,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (am29f040b.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8} },
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_29f040b,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "AMD",
 		.name		= "Am29F080B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= AMD_ID,
 		.model_id	= AM_29F080B,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 16} },
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {1024 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_29f040b,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "AMD",
 		.name		= "Am29LV040B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= AMD_ID,
 		.model_id	= AM_29LV040B,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
 		.tested		= TEST_UNTESTED,
-		.probe		= probe_29f040b,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (am29f040b.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8} },
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_29f040b,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "AMD",
 		.name		= "Am29LV081B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= AMD_ID,
 		.model_id	= AM_29LV080B,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
 		.tested		= TEST_UNTESTED,
-		.probe		= probe_29f040b,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (am29f040b.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 16} },
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {1024 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_29f040b,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ASD",
 		.name		= "AE49F2008",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ASD_ID,
 		.model_id	= ASD_AE49F2008,
 		.total_size	= 256,
 		.page_size	= 128,
+		.feature_bits	= FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_FIXME, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{128 * 1024, 1},
 					{96 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
@@ -831,96 +840,100 @@ struct flashchip flashchips[] = {
 		},
 		.write		= NULL /* Incompatible Page write */,
 		.read		= spi_chip_read,
 	},
 
 	{
 		.vendor		= "Atmel",
 		.name		= "AT29C512",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ATMEL_ID,
 		.model_id	= AT_29C512,
 		.total_size	= 64,
 		.page_size	= 128,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_LONG_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10000, /* 10mS, Enter=Exec */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,
 		.read		= read_memmapped,
 
 	},
 
 	{
 		.vendor		= "Atmel",
 		.name		= "AT29C010A",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ATMEL_ID,
 		.model_id	= AT_29C010A,
 		.total_size	= 128,
 		.page_size	= 128,
-		.tested		= TEST_OK_PR,
+		.feature_bits	= FEATURE_LONG_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10000, /* 10mS, Enter=Exec */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {128 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,	/* FIXME */
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Atmel",
 		.name		= "AT29C020",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ATMEL_ID,
 		.model_id	= AT_29C020,
 		.total_size	= 256,
 		.page_size	= 256,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_LONG_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10000,			/* 10ms */ 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Atmel",
 		.name		= "AT29C040A",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ATMEL_ID,
 		.model_id	= AT_29C040A,
 		.total_size	= 512,
 		.page_size	= 256,
+		.feature_bits	= FEATURE_LONG_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10000,			/* 10 ms */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,
 		.read		= read_memmapped,
@@ -1068,100 +1081,103 @@ struct flashchip flashchips[] = {
 		.erase		= NULL,
 		.write		= NULL,
 		.read		= NULL,
 	},
 
 	{
 		.vendor		= "Atmel",
 		.name		= "AT49BV512",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ATMEL_ID,
 		.model_id	= AT_49BV512,
 		.total_size	= 64,
 		.page_size	= 64,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Atmel",
 		.name		= "AT49F002(N)",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ATMEL_ID,
 		.model_id	= AT_49F002N,
 		.total_size	= 256,
 		.page_size	= 256,
+		.feature_bits	= FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{16 * 1024, 1},
 					{8 * 1024, 2},
 					{96 * 1024, 1},
 					{128 * 1024, 1},
 				},
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Atmel",
 		.name		= "AT49F002(N)T",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ATMEL_ID,
 		.model_id	= AT_49F002NT,
 		.total_size	= 256,
 		.page_size	= 256,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{128 * 1024, 1},
 					{96 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	/* The next two chip definitions have top/bottom boot blocks, but has no
 	device differenciation between the two */
 	{
 		.vendor		= "AMIC",
 		.name		= "A25L40PT",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= AMIC_ID,
 		.model_id	= AMIC_A25L40P,
 		.total_size	= 512,
 		.page_size	= 256,
@@ -1219,161 +1235,165 @@ struct flashchip flashchips[] = {
 		},
 		.write		= spi_chip_write_256,
 		.read		= spi_chip_read,
 	},
 
 	{
 		.vendor		= "AMIC",
 		.name		= "A29002B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= AMIC_ID_NOPREFIX,
 		.model_id	= AMIC_A29002B,
 		.total_size	= 256,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
 		.tested		= TEST_UNTESTED,
-		.probe		= probe_29f002,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{16 * 1024, 1},
 					{8 * 1024, 2},
 					{32 * 1024, 1},
 					{64 * 1024, 3},
 				},
-				.block_erase = erase_sector_29f002,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
-				.block_erase = erase_chip_29f002,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
 		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "AMIC",
 		.name		= "A29002T",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= AMIC_ID_NOPREFIX,
 		.model_id	= AMIC_A29002T,
 		.total_size	= 256,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PR,
-		.probe		= probe_29f002,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{64 * 1024, 3},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
-				.block_erase = erase_sector_29f002,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
-				.block_erase = erase_chip_29f002,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
 		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "AMIC",
 		.name		= "A29040B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= AMIC_ID_NOPREFIX,
 		.model_id	= AMIC_A29040B,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PR,
-		.probe		= probe_29f040b,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (am29f040b.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8} },
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_29f040b,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "AMIC",
 		.name		= "A49LF040A",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= AMIC_ID_NOPREFIX,
 		.model_id	= AMIC_A49LF040A,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* routine is wrapper to probe_jedec (pm49fl00x.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8} },
 				.block_erase = erase_block_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_49fl00x,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "EMST",
 		.name		= "F49B002UA",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= EMST_ID,
 		.model_id	= EMST_F49B002UA,
 		.total_size	= 256,
 		.page_size	= 4096,
+		.feature_bits	= FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{128 * 1024, 1},
 					{96 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Eon",
 		.name		= "EN25B05",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= EON_ID_NOPREFIX,
 		.model_id	= EN_25B05,
 		.total_size	= 64,
 		.page_size	= 256,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_spi_rdid,
@@ -2141,26 +2161,27 @@ struct flashchip flashchips[] = {
 		},
 		.write		= spi_chip_write_256,
 		.read		= spi_chip_read,
 	},
 
 	{
 		.vendor		= "EON",
 		.name		= "EN29F002(A)(N)B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= EON_ID,
 		.model_id	= EN_29F002B,
 		.total_size	= 256,
 		.page_size	= 256,
+		.feature_bits	= FEATURE_ADDR_AAA | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{64 * 1024, 3},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
@@ -2172,27 +2193,28 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "EON",
 		.name		= "EN29F002(A)(N)T",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= EON_ID,
 		.model_id	= EN_29F002T,
 		.total_size	= 256,
 		.page_size	= 256,
-		.tested		= TEST_OK_PR,
+		.feature_bits	= FEATURE_ADDR_AAA | FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{16 * 1024, 1},
 					{8 * 1024, 2},
 					{32 * 1024, 1},
 					{64 * 1024, 3},
 				},
 				.block_erase = erase_sector_jedec,
@@ -2203,88 +2225,92 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Fujitsu",
 		.name		= "MBM29F004BC",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= FUJITSU_ID,
 		.model_id	= MBM29F004BC,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{16 * 1024, 1},
 					{8 * 1024, 2},
 					{32 * 1024, 1},
 					{64 * 1024, 7},
 				},
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
 		.write		= NULL,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Fujitsu",
 		.name		= "MBM29F004TC",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= FUJITSU_ID,
 		.model_id	= MBM29F004TC,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{64 * 1024, 7},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
 		.write		= NULL,
 		.read		= read_memmapped,
 	},
 
 	{
+		/* FIXME: this has WORD/BYTE sequences; 2AA for word, 555 for byte */
 		.vendor		= "Fujitsu",
 		.name		= "MBM29F400BC",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= FUJITSU_ID,
 		.model_id	= MBM29F400BC,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_SHIFTED | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_m29f400bt,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (m29f400bt.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{16 * 1024, 1},
 					{8 * 1024, 2},
 					{32 * 1024, 1},
 					{64 * 1024, 7},
 				},
@@ -2296,26 +2322,27 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_coreboot_m29f400bt,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Fujitsu",
 		.name		= "MBM29F400TC",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= FUJITSU_ID,
 		.model_id	= MBM29F400TC,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_SHIFTED | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_m29f400bt,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (m29f400bt.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{64 * 1024, 7},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
@@ -2327,26 +2354,27 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_coreboot_m29f400bt,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Intel",
 		.name		= "28F001BX-B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= INTEL_ID,
 		.model_id	= P28F001BXB,
 		.total_size	= 128,
 		.page_size	= 128 * 1024, /* 8k + 2x4k + 112k */
+		.feature_bits	= 0,
 		.tested		= TEST_BAD_WRITE,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{8 * 1024, 1},
 					{4 * 1024, 2},
 					{112 * 1024, 1},
 				},
 				.block_erase = erase_82802ab_block,
@@ -2354,76 +2382,79 @@ struct flashchip flashchips[] = {
 		},
 		.write		= NULL,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Intel",
 		.name		= "28F001BX-T",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= INTEL_ID,
 		.model_id	= P28F001BXT,
 		.total_size	= 128,
 		.page_size	= 128 * 1024, /* 112k + 2x4k + 8k */
-		.tested		= TEST_OK_PR|TEST_BAD_WRITE,
+		.feature_bits	= 0,
+		.tested		= TEST_BAD_WRITE,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{112 * 1024, 1},
 					{4 * 1024, 2},
 					{8 * 1024, 1},
 				},
 				.block_erase = erase_82802ab_block,
 			},
 		},
 		.write		= NULL,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Intel",
 		.name		= "82802AB",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= INTEL_ID,
 		.model_id	= I_82802AB,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
+		.feature_bits	= 0,
 		.tested		= TEST_OK_PRW,
 		.probe		= probe_82802ab,
 		.probe_timing	= TIMING_IGNORED, /* routine does not use probe_timing (82802ab.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8} },
 				.block_erase = erase_82802ab_block,
 			},
 		},
 		.write		= write_82802ab,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Intel",
 		.name		= "82802AC",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= INTEL_ID,
 		.model_id	= I_82802AC,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
+		.feature_bits	= 0,
 		.tested		= TEST_OK_PRW,
 		.probe		= probe_82802ab,
 		.probe_timing	= TIMING_IGNORED, /* routine does not use probe_timing (82802ab.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 16} },
 				.block_erase = erase_82802ab_block,
 			},
 		},
 		.write		= write_82802ab,
 		.read		= read_memmapped,
@@ -2794,164 +2825,169 @@ struct flashchip flashchips[] = {
 		},
 		.write		= spi_chip_write_256,
 		.read		= spi_chip_read,
 	},
 
 	{
 		.vendor		= "Macronix",
 		.name		= "MX29F001B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= MX_ID,
 		.model_id	= MX_29F001B,
 		.total_size	= 128,
 		.page_size	= 32 * 1024,
-		.tested		= TEST_OK_PR,
-		.probe		= probe_29f002,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{8 * 1024, 1},
 					{4 * 1024, 2},
 					{8 * 1024, 2},
 					{32 * 1024, 1},
 					{64 * 1024, 1},
 				},
-				.block_erase = erase_sector_29f002,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {128 * 1024, 1} },
-				.block_erase = erase_chip_29f002,
+				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Macronix",
 		.name		= "MX29F001T",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= MX_ID,
 		.model_id	= MX_29F001T,
 		.total_size	= 128,
 		.page_size	= 32 * 1024,
-		.tested		= TEST_OK_PR,
-		.probe		= probe_29f002,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { 
 					{64 * 1024, 1},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{4 * 1024, 2},
 					{8 * 1024, 1},
 				},
-				.block_erase = erase_sector_29f002,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {128 * 1024, 1} },
-				.block_erase = erase_chip_29f002,
+				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Macronix",
 		.name		= "MX29F002B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= MX_ID,
 		.model_id	= MX_29F002B,
 		.total_size	= 256,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
 		.tested		= TEST_UNTESTED,
-		.probe		= probe_29f002,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{16 * 1024, 1},
 					{8 * 1024, 2},
 					{32 * 1024, 1},
 					{64 * 1024, 3},
 				},
-				.block_erase = erase_sector_29f002,	/* This erase function has 64k blocksize for eLiteFlash */
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
-				.block_erase = erase_chip_29f002,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
 		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Macronix",
 		.name		= "MX29F002T",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= MX_ID,
 		.model_id	= MX_29F002T,
 		.total_size	= 256,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PR,
-		.probe		= probe_29f002,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{64 * 1024, 3},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
-				.block_erase = erase_sector_29f002,	/* This erase function has 64k blocksize for eLiteFlash */
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
-				.block_erase = erase_chip_29f002,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
 		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Macronix",
 		.name		= "MX29LV040",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= MX_ID,
 		.model_id	= MX_29LV040,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PR,
-		.probe		= probe_29f002,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (mx29f002.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8}, },
-				.block_erase = erase_sector_29f002,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
-				.block_erase = erase_chip_29f002,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
 		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Numonyx",
 		.name		= "M25PE10",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M25PE10,
 		.total_size	= 128,
@@ -3277,149 +3313,152 @@ struct flashchip flashchips[] = {
 		},
 		.write		= spi_chip_write_256,
 		.read		= spi_chip_read,
 	},
 
 	{
 		.vendor		= "PMC",
 		.name		= "Pm29F002T",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= PMC_ID_NOPREFIX,
 		.model_id	= PMC_29F002T,
 		.total_size	= 256,
 		.page_size	= 8 * 1024,
-		.tested		= TEST_OK_PRW,
-		.probe		= probe_29f040b,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_FIXME, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{128 * 1024, 1},
 					{96 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_pm29f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "PMC",
 		.name		= "Pm29F002B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= PMC_ID_NOPREFIX,
 		.model_id	= PMC_29F002B,
 		.total_size	= 256,
 		.page_size	= 8 * 1024,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
-		.probe		= probe_29f040b,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_FIXME, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{16 * 1024, 1},
 					{8 * 1024, 2},
 					{96 * 1024, 1},
 					{128 * 1024, 1},
 				},
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_pm29f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "PMC",
 		.name		= "Pm39LV010",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= PMC_ID_NOPREFIX,
 		.model_id	= PMC_39F010,
 		.total_size	= 128,
 		.page_size	= 4096,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 32} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {64 * 1024, 2} },
 				.block_erase = erase_block_jedec,
 			}, {
 				.eraseblocks = { {128 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "PMC",
 		.name		= "Pm49FL002",
-		.bustype	= CHIP_BUSTYPE_LPC|CHIP_BUSTYPE_FWH, /* A/A Mux*/
+		.bustype	= CHIP_BUSTYPE_LPC | CHIP_BUSTYPE_FWH, /* A/A Mux*/
 		.manufacture_id	= PMC_ID_NOPREFIX,
 		.model_id	= PMC_49FL002,
 		.total_size	= 256,
 		.page_size	= 16 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* routine is wrapper to probe_jedec (pm49fl00x.c) */
 		.erase		= NULL, /* Was: erase_49fl00x */
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 64} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {16 * 1024, 16} },
 				.block_erase = erase_block_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_49fl00x,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "PMC",
 		.name		= "Pm49FL004",
-		.bustype	= CHIP_BUSTYPE_LPC|CHIP_BUSTYPE_FWH, /* A/A Mux*/
+		.bustype	= CHIP_BUSTYPE_LPC | CHIP_BUSTYPE_FWH, /* A/A Mux*/
 		.manufacture_id	= PMC_ID_NOPREFIX,
 		.model_id	= PMC_49FL004,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* routine is wrapper to probe_jedec (pm49fl00x.c) */
 		.erase		= NULL, /* Was: erase_49fl00x */
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 128} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {64 * 1024, 8} },
 				.block_erase = erase_block_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
@@ -3454,26 +3493,27 @@ struct flashchip flashchips[] = {
 		},
 		.write		= spi_chip_write_256,
 		.read		= spi_chip_read,
 	},
 
 	{
 		.vendor		= "Sharp",
 		.name		= "LHF00L04",
 		.bustype	= CHIP_BUSTYPE_FWH, /* A/A Mux */
 		.manufacture_id	= SHARP_ID,
 		.model_id	= SHARP_LHF00L04,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_49lfxxxc,
 		.probe_timing	= TIMING_ZERO,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{64 * 1024, 15},
 					{8 * 1024, 8}
 				 },
 				.block_erase = erase_lhf00l04_block,
 			}, {
@@ -3741,382 +3781,396 @@ struct flashchip flashchips[] = {
 		},
 		.write		= spi_chip_write_1,
 		.read		= spi_chip_read,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST28SF040A",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_28SF040,
 		.total_size	= 512,
 		.page_size	= 256,
+		.feature_bits	= 0,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_28sf040,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (sst28sf040.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {128, 4096} },
 				.block_erase = erase_sector_28sf040,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_28sf040,
 			}
 		},
 		.write		= write_28sf040,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST29EE010",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_29EE010,
 		.total_size	= 128,
 		.page_size	= 128,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_LONG_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {128 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST29LE010",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_29LE010,
 		.total_size	= 128,
 		.page_size	= 128,
+		.feature_bits	= FEATURE_LONG_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {128 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST29EE020A",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_29EE020A,
 		.total_size	= 256,
 		.page_size	= 128,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_LONG_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST29LE020",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_29LE020,
 		.total_size	= 256,
 		.page_size	= 128,
+		.feature_bits	= FEATURE_LONG_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST39SF512",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_39SF512,
 		.total_size	= 64,
 		.page_size	= 4096,
-		.tested		= TEST_OK_PREW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 16} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {64 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST39SF010A",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_39SF010,
 		.total_size	= 128,
 		.page_size	= 4096,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 32} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {128 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST39SF020A",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_39SF020,
 		.total_size	= 256,
 		.page_size	= 4096,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns */ 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 64} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST39SF040",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_39SF040,
 		.total_size	= 512,
 		.page_size	= 4096,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns */ 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 128} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST39VF512",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_39VF512,
 		.total_size	= 64,
 		.page_size	= 4096,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns*/ 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 16} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {64 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST39VF010",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_39VF010,
 		.total_size	= 128,
 		.page_size	= 4096,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns */ 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 32} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {128 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST39VF020",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_39VF020,
 		.total_size	= 256,
 		.page_size	= 4096,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns */ 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 64} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST39VF040",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_39VF040,
 		.total_size	= 512,
 		.page_size	= 4096,
-		.tested		= TEST_OK_PROBE,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns */ 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 128} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST39VF080",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_39VF080,
 		.total_size	= 1024,
 		.page_size	= 4096,
+		.feature_bits	= FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns */ 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 256} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {64 * 1024, 16} },
 				.block_erase = erase_block_jedec,
 			}, {
 				.eraseblocks = { {1024 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF002A/B",
 		.bustype	= CHIP_BUSTYPE_FWH, /* A/A Mux */
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF002A,
 		.total_size	= 256,
 		.page_size	= 16 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
+		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
 		.tested		= TEST_OK_PRW,
 		.probe		= probe_sst_fwhub,
 		.probe_timing	= 1,		/* 150 ns | routine is wrapper to probe_jedec (sst_fwhub.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 64} },
 				.block_erase = erase_sst_fwhub_sector,
 			}, {
 				.eraseblocks = { {16 * 1024, 16} },
 				.block_erase = erase_sst_fwhub_block,
 			}, {
@@ -4126,27 +4180,27 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_sst_fwhub,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF003A/B",
 		.bustype	= CHIP_BUSTYPE_FWH, /* A/A Mux */
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF003A,
 		.total_size	= 384,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
+		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
 		.tested		= TEST_OK_PR,
 		.probe		= probe_sst_fwhub,
 		.probe_timing	= 1,		/* 150 ns | routine is wrapper to probe_jedec (sst_fwhub.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 96} },
 				.block_erase = erase_sst_fwhub_sector,
 			}, {
 				.eraseblocks = { {64 * 1024, 6} },
 				.block_erase = erase_sst_fwhub_block,
 			}, {
@@ -4159,27 +4213,27 @@ struct flashchip flashchips[] = {
 	},
 
 	{
 		/* Contrary to the data sheet, TBL# on the SST49LF004B affects the top 128kB (instead of 64kB)
 		 * and is only honored for 64k block erase, but not 4k sector erase.
 		 */
 		.vendor		= "SST",
 		.name		= "SST49LF004A/B",
 		.bustype	= CHIP_BUSTYPE_FWH, /* A/A Mux */
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF004A,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
+		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
 		.tested		= TEST_OK_PREW,
 		.probe		= probe_sst_fwhub,
 		.probe_timing	= 1,		/* 150 ns | routine is wrapper to probe_jedec (sst_fwhub.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 128} },
 				.block_erase = erase_sector_jedec, /* missing unlock */
 			}, {
 				.eraseblocks = { {64 * 1024, 8} },
 				.block_erase = erase_sst_fwhub_block, /* same as erase_block_jedec, but with unlock */
 			}, {
@@ -4189,26 +4243,27 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_sst_fwhub,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF004C",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF004C,
 		.total_size	= 512,
 		.page_size	= 4 * 1024,
+		.feature_bits	= 0,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_49lfxxxc,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (sst49lfxxxc.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 128} },
 				.block_erase = erase_sector_49lfxxxc,
 			}, {
 				.eraseblocks = { 
 					{64 * 1024, 7},
 					{32 * 1024, 1},
@@ -4220,27 +4275,27 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_49lfxxxc,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF008A",
 		.bustype	= CHIP_BUSTYPE_FWH, /* A/A Mux */
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF008A,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
+		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
 		.tested		= TEST_OK_PRW,
 		.probe		= probe_sst_fwhub,
 		.probe_timing	= 1,		/* 150 ns | routine is wrapper to probe_jedec (sst_fwhub.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 256} },
 				.block_erase = erase_sst_fwhub_sector,
 			}, {
 				.eraseblocks = { {64 * 1024, 16} },
 				.block_erase = erase_sst_fwhub_block,
 			}, {
@@ -4250,26 +4305,27 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_sst_fwhub,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF008C",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF008C,
 		.total_size	= 1024,
 		.page_size	= 4 * 1024,
+		.feature_bits	= 0,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_49lfxxxc,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (sst49lfxxxc.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 256} },
 				.block_erase = erase_sector_49lfxxxc,
 			}, {
 				.eraseblocks = { 
 					{64 * 1024, 15},
 					{32 * 1024, 1},
@@ -4281,26 +4337,27 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_49lfxxxc,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF016C",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF016C,
 		.total_size	= 2048,
 		.page_size	= 4 * 1024,
+		.feature_bits	= 0,
 		.tested		= TEST_OK_PRW,
 		.probe		= probe_49lfxxxc,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (sst49lfxxxc.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 512} },
 				.block_erase = erase_sector_49lfxxxc,
 			}, {
 				.eraseblocks = { 
 					{64 * 1024, 31},
 					{32 * 1024, 1},
@@ -4312,172 +4369,177 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_49lfxxxc,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF020",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF020,
 		.total_size	= 256,
 		.page_size	= 16 * 1024,
-		.tested		= TEST_OK_PR,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns */ 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 64} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {16 * 1024, 16} },
 				.block_erase = erase_block_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = NULL,
 			}
 		},
-		.write		= write_49lf040,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF020A",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF020A,
 		.total_size	= 256,
 		.page_size	= 4 * 1024,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns */ 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 64} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {16 * 1024, 16} },
 				.block_erase = erase_block_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = NULL,
 			}
 		},
-		.write		= write_49lf040,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF040",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF040,
 		.total_size	= 512,
 		.page_size	= 4096,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,			/* 150 ns */ 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 128} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {64 * 1024, 8} },
 				.block_erase = erase_block_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = NULL,
 			}
 		},
-		.write		= write_49lf040,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF040B",
 		.bustype	= CHIP_BUSTYPE_LPC, /* A/A Mux */
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF040B,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
+		.feature_bits	= FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 1,		/* 150ns | routine is wrapper to probe_jedec (sst_fwhub.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 128} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {64 * 1024, 8} },
 				.block_erase = erase_block_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = NULL,
 			}
 		},
-		.write		= write_49lf040,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF080A",
 		.bustype	= CHIP_BUSTYPE_LPC, /* A/A Mux */
 		.manufacture_id	= SST_ID,
  		.model_id	= SST_49LF080A,
 		.total_size	= 1024,
 		.page_size	= 4096,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_FIXME, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 256} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {64 * 1024, 16} },
 				.block_erase = erase_block_jedec,
 			}, {
 				.eraseblocks = { {1024 * 1024, 1} },
 				.block_erase = NULL,
 			}
 		},
-		.write		= write_49lf040,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SST",
 		.name		= "SST49LF160C",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= SST_ID,
 		.model_id	= SST_49LF160C,
 		.total_size	= 2048,
 		.page_size	= 4 * 1024,
+		.feature_bits	= 0,
 		.tested		= TEST_OK_PRW,
 		.probe		= probe_49lfxxxc,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (sst49lfxxxc.c) */
 		.erase		= erase_49lfxxxc,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 512} },
 				.block_erase = erase_sector_49lfxxxc,
 			}, {
 				.eraseblocks = { 
 					{64 * 1024, 31},
@@ -4808,114 +4870,119 @@ struct flashchip flashchips[] = {
 		},
 		.write		= spi_chip_write_256,
 		.read		= spi_chip_read,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M29F002B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M29F002B,
 		.total_size	= 256,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_AAA | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{16 * 1024, 1},
 					{8 * 1024, 2},
 					{32 * 1024, 1},
 					{64 * 1024, 3},
 				},
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_m29f002b,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M29F002T/NT",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M29F002T,
 		.total_size	= 256,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_ADDR_AAA | FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{64 * 1024, 3},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_m29f002t,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M29F040B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M29F040B,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PRW,
-		.probe		= probe_29f040b,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (am29f040b.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8}, },
-				.block_erase = erase_sector_29f040b,
+				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
-				.block_erase = erase_chip_29f040b,
+				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_29f040b,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
+		/* FIXME: this has WORD/BYTE sequences; 2AA for word, 555 for byte */
 		.vendor		= "ST",
 		.name		= "M29F400BT",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M29F400BT,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_SHIFTED | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_m29f400bt,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (m29f400bt.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{64 * 1024, 7},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
@@ -4927,81 +4994,83 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_coreboot_m29f400bt,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M29W010B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M29W010B,
 		.total_size	= 128,
 		.page_size	= 16 * 1024,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {16 * 1024, 8}, },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {128 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_jedec,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M29W040B",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M29W040B,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8}, },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_jedec,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M50FLW040A",
-		.bustype	= CHIP_BUSTYPE_FWH|CHIP_BUSTYPE_LPC, /* A/A Mux */
+		.bustype	= CHIP_BUSTYPE_FWH | CHIP_BUSTYPE_LPC, /* A/A Mux */
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M50FLW040A,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
+		.feature_bits	= 0,
 		.tested		= TEST_UNTESTED,
-		.probe		= probe_jedec,
+		.probe		= probe_82802ab,
 		.probe_timing	= TIMING_FIXME,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{4 * 1024, 16},  /* sector */
 					{64 * 1024, 5}, /* block */
 					{4 * 1024, 16}, /* sector */
 					{4 * 1024, 16}, /* sector */
 				},
 				.block_erase = NULL,
 			}, {
@@ -5009,34 +5078,34 @@ struct flashchip flashchips[] = {
 				.block_erase = erase_block_stm50flw0x0x,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_stm50flw0x0x,
 			}
 		},
 		.write		= write_stm50flw0x0x,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M50FLW040B",
-		.bustype	= CHIP_BUSTYPE_FWH|CHIP_BUSTYPE_LPC, /* A/A Mux */
+		.bustype	= CHIP_BUSTYPE_FWH | CHIP_BUSTYPE_LPC, /* A/A Mux */
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M50FLW040B,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
+		.feature_bits	= 0,
 		.tested		= TEST_UNTESTED,
-		.probe		= probe_jedec,
+		.probe		= probe_82802ab,
 		.probe_timing	= TIMING_FIXME,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{4 * 1024, 16},  /* sector */
 					{4 * 1024, 16}, /* sector */
 					{64 * 1024, 5}, /* block */
 					{4 * 1024, 16}, /* sector */
 				},
 				.block_erase = NULL,
 			}, {
@@ -5044,34 +5113,34 @@ struct flashchip flashchips[] = {
 				.block_erase = erase_block_stm50flw0x0x,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_stm50flw0x0x,
 			}
 		},
 		.write		= write_stm50flw0x0x,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M50FLW080A",
-		.bustype	= CHIP_BUSTYPE_FWH|CHIP_BUSTYPE_LPC, /* A/A Mux */
+		.bustype	= CHIP_BUSTYPE_FWH | CHIP_BUSTYPE_LPC, /* A/A Mux */
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M50FLW080A,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
-		.tested		= TEST_OK_PRW,
-		.probe		= probe_jedec,
+		.feature_bits	= 0,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_82802ab,
 		.probe_timing	= TIMING_FIXME,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{4 * 1024, 16},  /* sector */
 					{64 * 1024, 13}, /* block */
 					{4 * 1024, 16}, /* sector */
 					{4 * 1024, 16}, /* sector */
 				},
 				.block_erase = NULL,
 			}, {
@@ -5079,34 +5148,34 @@ struct flashchip flashchips[] = {
 				.block_erase = erase_block_stm50flw0x0x,
 			}, {
 				.eraseblocks = { {1024 * 1024, 1} },
 				.block_erase = erase_chip_stm50flw0x0x,
 			}
 		},
 		.write		= write_stm50flw0x0x,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M50FLW080B",
-		.bustype	= CHIP_BUSTYPE_FWH|CHIP_BUSTYPE_LPC, /* A/A Mux */
+		.bustype	= CHIP_BUSTYPE_FWH | CHIP_BUSTYPE_LPC, /* A/A Mux */
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M50FLW080B,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
+		.feature_bits	= 0,
 		.tested		= TEST_UNTESTED,
-		.probe		= probe_jedec,
+		.probe		= probe_82802ab,
 		.probe_timing	= TIMING_FIXME,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{4 * 1024, 16},  /* sector */
 					{4 * 1024, 16}, /* sector */
 					{64 * 1024, 13}, /* block */
 					{4 * 1024, 16}, /* sector */
 				},
 				.block_erase = NULL,
 			}, {
@@ -5119,322 +5188,333 @@ struct flashchip flashchips[] = {
 		},
 		.write		= write_stm50flw0x0x,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M50FW002",
 		.bustype	= CHIP_BUSTYPE_FWH, /* A/A Mux */
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M50FW002,
 		.total_size	= 256,
 		.page_size	= 64 * 1024,
+		.feature_bits	= 0,
 		.tested		= TEST_UNTESTED,
-		.probe		= probe_49lfxxxc,
+		.probe		= probe_82802ab,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (sst49lfxxxc.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{64 * 1024, 3},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
 				.block_erase = erase_block_stm50flw0x0x,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_stm50flw0x0x,
 			}
 		},
-		.write		= NULL,
+		.write		= write_stm50flw0x0x,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M50FW016",
 		.bustype	= CHIP_BUSTYPE_FWH, /* A/A Mux */
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M50FW016,
 		.total_size	= 2048,
 		.page_size	= 64 * 1024,
+		.feature_bits	= 0,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_82802ab,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (82802ab.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 32}, },
 				.block_erase = erase_block_stm50flw0x0x,
 			}, {
 				.eraseblocks = { {2 * 1024 * 1024, 1} },
 				.block_erase = erase_chip_stm50flw0x0x,
 			}
 		},
 		.write		= write_stm50flw0x0x,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M50FW040",
 		.bustype	= CHIP_BUSTYPE_FWH, /* A/A Mux */
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M50FW040,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
+		.feature_bits	= 0,
 		.tested		= TEST_OK_PRW,
 		.probe		= probe_82802ab,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (82802ab.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8}, },
 				.block_erase = erase_block_stm50flw0x0x,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_stm50flw0x0x,
 			}
 		},
 		.write		= write_stm50flw0x0x,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M50FW080",
 		.bustype	= CHIP_BUSTYPE_FWH, /* A/A Mux */
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M50FW080,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
+		.feature_bits	= 0,
 		.tested		= TEST_OK_PRW,
 		.probe		= probe_82802ab,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (82802ab.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 16}, },
 				.block_erase = erase_block_stm50flw0x0x,
 			}, {
 				.eraseblocks = { {1024 * 1024, 1} },
 				.block_erase = erase_chip_stm50flw0x0x,
 			}
 		},
 		.write		= write_stm50flw0x0x,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "ST",
 		.name		= "M50LPW116",
 		.bustype	= CHIP_BUSTYPE_LPC, /* A/A Mux */
 		.manufacture_id	= ST_ID,
 		.model_id	= ST_M50LPW116,
 		.total_size	= 2048,
 		.page_size	= 64 * 1024,
+		.feature_bits	= 0,
 		.tested		= TEST_UNTESTED,
-		.probe		= probe_jedec,
+		.probe		= probe_82802ab,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{4 * 1024, 16},
 					{64 * 1024, 30},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
 				.block_erase = erase_block_stm50flw0x0x,
 			}, {
 				.eraseblocks = { {2 * 1024 * 1024, 1} },
-				.block_erase = erase_chip_block_jedec,
+				.block_erase = erase_chip_stm50flw0x0x,
 			}
 		},
-		.write		= write_jedec,
+		.write		= write_stm50flw0x0x,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SyncMOS",
 		.name		= "S29C31004T",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SYNCMOS_ID,
 		.model_id	= S29C31004T,
 		.total_size	= 512,
 		.page_size	= 128,
+		.feature_bits	= FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {1 * 1024, 512} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SyncMOS",
 		.name		= "S29C51001T",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SYNCMOS_ID,
 		.model_id	= S29C51001T,
 		.total_size	= 128,
 		.page_size	= 128,
+		.feature_bits	= FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {512, 256} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {128 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SyncMOS",
 		.name		= "S29C51002T",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SYNCMOS_ID,
 		.model_id	= S29C51002T,
 		.total_size	= 256,
 		.page_size	= 128,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {512, 512} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "SyncMOS",
 		.name		= "S29C51004T",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= SYNCMOS_ID,
 		.model_id	= S29C51004T,
 		.total_size	= 512,
 		.page_size	= 128,
+		.feature_bits	= FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {1 * 1024, 512} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "TI",
 		.name		= "TMS29F002RB",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= TI_OLD_ID,
 		.model_id	= TI_TMS29F002RB,
 		.total_size	= 256,
 		.page_size	= 16384, /* Non-uniform sectors */
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{16 * 1024, 1},
 					{8 * 1024, 2},
 					{32 * 1024, 1},
 					{64 * 1024, 3},
 				},
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= NULL,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "TI",
 		.name		= "TMS29F002RT",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= TI_OLD_ID,
 		.model_id	= TI_TMS29F002RT,
 		.total_size	= 256,
 		.page_size	= 16384, /* Non-uniform sectors */
+		.feature_bits	= FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_ZERO,	/* Datasheet has no timing info specified */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{64 * 1024, 3},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			},
 		},
-		.write		= NULL,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W25x10",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
 		.model_id	= W_25X10,
 		.total_size	= 128,
 		.page_size	= 256,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_spi_rdid,
@@ -5671,387 +5751,399 @@ struct flashchip flashchips[] = {
 		},
 		.write		= spi_chip_write_256,
 		.read		= spi_chip_read,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W29C011",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_29C011,
 		.total_size	= 128,
 		.page_size	= 128,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_LONG_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10,		/* used datasheet for the W29C011A */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {128 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W29C020C",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_29C020C,
 		.total_size	= 256,
 		.page_size	= 128,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_LONG_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W29C040P",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_29C040P,
 		.total_size	= 512,
 		.page_size	= 256,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_LONG_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W29EE011",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_29C011,
 		.total_size	= 128,
 		.page_size	= 128,
+		.feature_bits	= FEATURE_LONG_RESET,
 		.tested		= TEST_OK_PRW,
 		.probe		= probe_w29ee011,
 		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (w29ee011.c) */
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {128 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
 		.write		= write_jedec,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W39V040A",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_39V040A,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W39V040B",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_39V040B,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PR | TEST_BAD_WRITE,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W39V040C",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_39V040C,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PRW,
-		.probe		= probe_w39v040c,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
 		.probe_timing	= TIMING_FIXME,
 		.erase		= NULL, /* Was erase_w39v040c */
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_w39v040c,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W39V040FA",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_39V040FA,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {4 * 1024, 128} },
 				.block_erase = erase_block_jedec,
 			}, {
 				.eraseblocks = { {64 * 1024, 8} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W39V080A",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_39V080A,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 16} },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {1024 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W49F002U",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_49F002U,
 		.total_size	= 256,
 		.page_size	= 128,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{128 * 1024, 1},
 					{96 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W49V002A",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_49V002A,
 		.total_size	= 256,
 		.page_size	= 128,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10, 
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{64 * 1024, 3},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W49V002FA",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_49V002FA,
 		.total_size	= 256,
 		.page_size	= 128,
+		.feature_bits	= FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= 10,
 		.erase		= NULL,
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = {
 					{64 * 1024, 3},
 					{32 * 1024, 1},
 					{8 * 1024, 2},
 					{16 * 1024, 1},
 				},
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_49f002,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W39V080FA",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_39V080FA,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
-		.tested		= TEST_OK_PRW,
+		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
+		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_FIXME,
 		.erase		= NULL, /* Was erase_winbond_fwhub */
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 16}, },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {1024 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_winbond_fwhub,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Winbond",
 		.name		= "W39V080FA (dual mode)",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= WINBOND_ID,
 		.model_id	= W_39V080FA_DM,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
-		.feature_bits	= FEATURE_REGISTERMAP,
+		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
 		.tested		= TEST_UNTESTED,
 		.probe		= probe_jedec,
 		.probe_timing	= TIMING_FIXME,
 		.erase		= NULL, /* Was erase_winbond_fwhub */
 		.block_erasers	=
 		{
 			{
 				.eraseblocks = { {64 * 1024, 8}, },
 				.block_erase = erase_sector_jedec,
 			}, {
 				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
-		.write		= write_winbond_fwhub,
+		.write		= write_jedec_1,
 		.read		= read_memmapped,
 	},
 
 	{
 		.vendor		= "Atmel",
 		.name		= "unknown Atmel SPI chip",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= ATMEL_ID,
 		.model_id	= GENERIC_DEVICE_ID,
 		.total_size	= 0,
 		.page_size	= 256,
 		.tested		= TEST_BAD_PREW,
 		.probe		= probe_spi_rdid,
diff --git a/jedec.c b/jedec.c
index 055fbc3..055e910 100644
--- a/jedec.c
+++ b/jedec.c
@@ -17,26 +17,27 @@
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
  *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
  */
 
 #include "flash.h"
 
 #define MAX_REFLASH_TRIES 0x10
 #define MASK_FULL 0xffff
 #define MASK_2AA 0x7ff
+#define MASK_AAA 0xfff
 
 /* Check one byte for odd parity */
 uint8_t oddparity(uint8_t val)
 {
 	val = (val ^ (val >> 4)) & 0xf;
 	val = (val ^ (val >> 2)) & 0x3;
 	return (val ^ (val >> 1)) & 0x1;
 }
 
 void toggle_ready_jedec_common(chipaddr dst, int delay)
 {
 	unsigned int i = 0;
 	uint8_t tmp1, tmp2;
@@ -88,28 +89,27 @@ void data_polling_jedec(chipaddr dst, uint8_t data)
 	}
 	if (i > 0x100000)
 		printf_debug("%s: excessive loops, i=0x%x\n", __func__, i);
 }
 
 void start_program_jedec_common(struct flashchip *flash, unsigned int mask)
 {
 	chipaddr bios = flash->virtual_memory;
 	chip_writeb(0xAA, bios + (0x5555 & mask));
 	chip_writeb(0x55, bios + (0x2AAA & mask));
 	chip_writeb(0xA0, bios + (0x5555 & mask));
 }
 
-int probe_jedec_common(struct flashchip *flash,
-			unsigned int mask, int long_reset)
+int probe_jedec_common(struct flashchip *flash, unsigned int mask)
 {
 	chipaddr bios = flash->virtual_memory;
 	uint8_t id1, id2;
 	uint32_t largeid1, largeid2;
 	uint32_t flashcontent1, flashcontent2;
 	int probe_timing_enter, probe_timing_exit;
 
 	if (flash->probe_timing > 0) 
 		probe_timing_enter = probe_timing_exit = flash->probe_timing;
 	else if (flash->probe_timing == TIMING_ZERO) { /* No delay. */
 		probe_timing_enter = probe_timing_exit = 0;
 	} else if (flash->probe_timing == TIMING_FIXME) { /* == _IGNORED */
 		printf_debug("Chip lacks correct probe timing information, "
@@ -142,27 +142,27 @@ int probe_jedec_common(struct flashchip *flash,
 	/* Check if it is a continuation ID, this should be a while loop. */
 	if (id1 == 0x7F) {
 		largeid1 <<= 8;
 		id1 = chip_readb(bios + 0x100);
 		largeid1 |= id1;
 	}
 	if (id2 == 0x7F) {
 		largeid2 <<= 8;
 		id2 = chip_readb(bios + 0x101);
 		largeid2 |= id2;
 	}
 
 	/* Issue JEDEC Product ID Exit command */
-	if (long_reset)
+	if ((flash->feature_bits & FEATURE_SHORT_RESET) == FEATURE_LONG_RESET)
 	{
 		chip_writeb(0xAA, bios + (0x5555 & mask));
 		if (probe_timing_exit)
 			programmer_delay(10);
 		chip_writeb(0x55, bios + (0x2AAA & mask));
 		if (probe_timing_exit)
 			programmer_delay(10);
 	}
 	chip_writeb(0xF0, bios + (0x5555 & mask));
 	if (probe_timing_exit)
 		programmer_delay(probe_timing_exit);
 
 	printf_debug("%s: id1 0x%02x, id2 0x%02x", __func__, largeid1, largeid2);
@@ -369,105 +369,129 @@ retry:
 	if (failed) {
 		fprintf(stderr, " page 0x%lx failed!\n",
 			(d - bios) / page_size);
 	}
 	return failed;
 }
 
 int getaddrmask(struct flashchip *flash)
 {
 	switch (flash->feature_bits & FEATURE_ADDR_MASK) {
 	case FEATURE_ADDR_FULL:
 		return MASK_FULL;
 		break;
+	case FEATURE_ADDR_2AA:
+		return MASK_2AA;
+		break;
+	case FEATURE_ADDR_AAA:
+		return MASK_AAA;
+		break;
 	default:
 		fprintf(stderr, "%s called with unknown mask\n", __func__);
 		return 0;
 		break;
 	}
 }
 
 int write_jedec(struct flashchip *flash, uint8_t *buf)
 {
+	int mask;
 	int i, failed = 0;
 	int total_size = flash->total_size * 1024;
 	int page_size = flash->page_size;
 
+	mask = getaddrmask(flash);
+
 	if (erase_chip_jedec(flash)) {
 		fprintf(stderr,"ERASE FAILED!\n");
 		return -1;
 	}
 	
 	printf("Programming page: ");
 	for (i = 0; i < total_size / page_size; i++) {
 		printf("%04d at address: 0x%08x", i, i * page_size);
 		if (write_page_write_jedec_common(flash, buf + i * page_size,
-					   i * page_size, page_size, MASK_FULL))
+					   i * page_size, page_size, mask))
 			failed = 1;
 		printf("\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b");
 	}
 	printf("\n");
 
 	return failed;
 }
 
 int write_jedec_1(struct flashchip *flash, uint8_t * buf)
 {
 	int i;
 	chipaddr bios = flash->virtual_memory;
 	chipaddr dst = bios;
+	int mask;
+
+	mask = getaddrmask(flash);
 
 	programmer_delay(10);
 	if (erase_flash(flash)) {
 		fprintf(stderr, "ERASE FAILED!\n");
 		return -1;
 	}
 
 	printf("Programming page: ");
 	for (i = 0; i < flash->total_size; i++) {
 		if ((i & 0x3) == 0)
 			printf("address: 0x%08lx", (unsigned long)i * 1024);
 
-                write_sector_jedec_common(flash, buf + i * 1024, dst + i * 1024, 1024, MASK_FULL);
+                write_sector_jedec_common(flash, buf + i * 1024, dst + i * 1024, 1024, mask);
 
 		if ((i & 0x3) == 0)
 			printf("\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b");
 	}
 
 	printf("\n");
 	return 0;
 }
 
 /* erase chip with block_erase() prototype */
 int erase_chip_block_jedec(struct flashchip *flash, unsigned int addr,
 			   unsigned int blocksize)
 {
+	int mask;
+
+	mask = getaddrmask(flash);
 	if ((addr != 0) || (blocksize != flash->total_size * 1024)) {
 		fprintf(stderr, "%s called with incorrect arguments\n",
 			__func__);
 		return -1;
 	}
-	return erase_chip_jedec_common(flash, MASK_FULL);
+	return erase_chip_jedec_common(flash, mask);
 }
 
 int probe_jedec(struct flashchip *flash)
 {
 	int mask;
 
 	mask = getaddrmask(flash);
-	return probe_jedec_common(flash, mask, 1);
+	return probe_jedec_common(flash, mask);
 }
 
 int erase_sector_jedec(struct flashchip *flash, unsigned int page, unsigned int size)
 {
-	return erase_sector_jedec_common(flash, page, size, MASK_FULL);
+	int mask;
+
+	mask = getaddrmask(flash);
+	return erase_sector_jedec_common(flash, page, size, mask);
 }
 
 int erase_block_jedec(struct flashchip *flash, unsigned int page, unsigned int size)
 {
-	return erase_block_jedec_common(flash, page, size, MASK_FULL);
+	int mask;
+
+	mask = getaddrmask(flash);
+	return erase_block_jedec_common(flash, page, size, mask);
 }
 
 int erase_chip_jedec(struct flashchip *flash)
 {
-	return erase_chip_jedec_common(flash, MASK_FULL);
+	int mask;
+
+	mask = getaddrmask(flash);
+	return erase_chip_jedec_common(flash, mask);
 }
