Index: flashchips.c
===================================================================
--- flashchips.c	(revision 1164)
+++ flashchips.c	(working copy)
@@ -1003,37 +1003,6 @@
 	},
 
 	{
-		.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, 
-		.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_jedec,
-		.read		= read_memmapped,
-	},
-
-	{
 		.vendor		= "Atmel",
 		.name		= "AT25DF021",
 		.bustype	= CHIP_BUSTYPE_SPI,
@@ -6899,7 +6868,7 @@
 		.name		= "W25Q80",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
-		.model_id	= W_25Q80,
+		.model_id	= WINBOND_NEX_W25Q80,
 		.total_size	= 1024,
 		.page_size	= 256,
 		.feature_bits	= FEATURE_WRSR_WREN,
@@ -6935,7 +6904,7 @@
 		.name		= "W25Q16",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
-		.model_id	= W_25Q16,
+		.model_id	= WINBOND_NEX_W25Q16,
 		.total_size	= 2048,
 		.page_size	= 256,
 		.feature_bits	= FEATURE_WRSR_WREN,
@@ -6971,7 +6940,7 @@
 		.name		= "W25Q32",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
-		.model_id	= W_25Q32,
+		.model_id	= WINBOND_NEX_W25Q32,
 		.total_size	= 4096,
 		.page_size	= 256,
 		.feature_bits	= FEATURE_WRSR_WREN,
@@ -7007,7 +6976,7 @@
 		.name		= "W25Q64",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
-		.model_id	= W_25Q64,
+		.model_id	= WINBOND_NEX_W25Q64,
 		.total_size	= 8192,
 		.page_size	= 256,
 		.feature_bits	= FEATURE_WRSR_WREN,
@@ -7043,7 +7012,7 @@
 		.name		= "W25x10",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
-		.model_id	= W_25X10,
+		.model_id	= WINBOND_NEX_W25X10,
 		.total_size	= 128,
 		.page_size	= 256,
 		.feature_bits	= FEATURE_WRSR_WREN,
@@ -7073,7 +7042,7 @@
 		.name		= "W25x20",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
-		.model_id	= W_25X20,
+		.model_id	= WINBOND_NEX_W25X20,
 		.total_size	= 256,
 		.page_size	= 256,
 		.feature_bits	= FEATURE_WRSR_WREN,
@@ -7103,7 +7072,7 @@
 		.name		= "W25x40",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
-		.model_id	= W_25X40,
+		.model_id	= WINBOND_NEX_W25X40,
 		.total_size	= 512,
 		.page_size	= 256,
 		.feature_bits	= FEATURE_WRSR_WREN,
@@ -7133,7 +7102,7 @@
 		.name		= "W25x80",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
-		.model_id	= W_25X80,
+		.model_id	= WINBOND_NEX_W25X80,
 		.total_size	= 1024,
 		.page_size	= 256,
 		.feature_bits	= FEATURE_WRSR_WREN,
@@ -7163,7 +7132,7 @@
 		.name		= "W25x16",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
-		.model_id	= W_25X16,
+		.model_id	= WINBOND_NEX_W25X16,
 		.total_size	= 2048,
 		.page_size	= 256,
 		.feature_bits	= FEATURE_WRSR_WREN,
@@ -7199,7 +7168,7 @@
 		.name		= "W25x32",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
-		.model_id	= W_25X32,
+		.model_id	= WINBOND_NEX_W25X32,
 		.total_size	= 4096,
 		.page_size	= 256,
 		.feature_bits	= FEATURE_WRSR_WREN,
@@ -7235,7 +7204,7 @@
 		.name		= "W25x64",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= WINBOND_NEX_ID,
-		.model_id	= W_25X64,
+		.model_id	= WINBOND_NEX_W25X64,
 		.total_size	= 8192,
 		.page_size	= 256,
 		.feature_bits	= FEATURE_WRSR_WREN,
@@ -7268,14 +7237,14 @@
 
 	{
 		.vendor		= "Winbond",
-		.name		= "W29C011",
+		.name		= "W29C010(M)/W29C011A/W29EE011/W29EE012",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_29C011,
+		.model_id	= WINBOND_W29C010,
 		.total_size	= 128,
 		.page_size	= 128,
 		.feature_bits	= FEATURE_LONG_RESET,
-		.tested		= TEST_OK_PRW,
+		.tested		= TEST_OK_PREW,
 		.probe		= probe_jedec,
 		.probe_timing	= 10,		/* used datasheet for the W29C011A */
 		.block_erasers	=
@@ -7291,20 +7260,20 @@
 
 	{
 		.vendor		= "Winbond",
-		.name		= "W29C020C",
+		.name		= "W29C010(M)/W29C011A/W29EE011/W29EE012",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_29C020C,
-		.total_size	= 256,
+		.model_id	= WINBOND_W29C010,
+		.total_size	= 128,
 		.page_size	= 128,
 		.feature_bits	= FEATURE_LONG_RESET,
 		.tested		= TEST_OK_PREW,
-		.probe		= probe_jedec,
-		.probe_timing	= 10, 
+		.probe		= probe_w29ee011,
+		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (w29ee011.c) */
 		.block_erasers	=
 		{
 			{
-				.eraseblocks = { {256 * 1024, 1} },
+				.eraseblocks = { {128 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
@@ -7314,20 +7283,20 @@
 
 	{
 		.vendor		= "Winbond",
-		.name		= "W29C040P",
+		.name		= "W29C020(C)/W29C022",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_29C040P,
-		.total_size	= 512,
-		.page_size	= 256,
+		.model_id	= WINBOND_W29C020,
+		.total_size	= 256,
+		.page_size	= 128,
 		.feature_bits	= FEATURE_LONG_RESET,
-		.tested		= TEST_UNTESTED,
+		.tested		= TEST_OK_PREW,
 		.probe		= probe_jedec,
 		.probe_timing	= 10, 
 		.block_erasers	=
 		{
 			{
-				.eraseblocks = { {512 * 1024, 1} },
+				.eraseblocks = { {256 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
@@ -7337,20 +7306,20 @@
 
 	{
 		.vendor		= "Winbond",
-		.name		= "W29EE011",
+		.name		= "W29C040/P",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_29C011,
-		.total_size	= 128,
-		.page_size	= 128,
+		.model_id	= WINBOND_W29C040,
+		.total_size	= 512,
+		.page_size	= 256,
 		.feature_bits	= FEATURE_LONG_RESET,
-		.tested		= TEST_OK_PREW,
-		.probe		= probe_w29ee011,
-		.probe_timing	= TIMING_IGNORED, /* routine don't use probe_timing (w29ee011.c) */
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_jedec,
+		.probe_timing	= 10, 
 		.block_erasers	=
 		{
 			{
-				.eraseblocks = { {128 * 1024, 1} },
+				.eraseblocks = { {512 * 1024, 1} },
 				.block_erase = erase_chip_block_jedec,
 			}
 		},
@@ -7363,7 +7332,7 @@
 		.name		= "W39V040A",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_39V040A,
+		.model_id	= WINBOND_W39V040A,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
 		.feature_bits	= FEATURE_EITHER_RESET,
@@ -7386,10 +7355,10 @@
 
 	{
 		.vendor		= "Winbond",
-		.name		= "W39V040B",
+		.name		= "W39V040(F)B",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_39V040B,
+		.model_id	= WINBOND_W39V040B,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
 		.feature_bits	= FEATURE_EITHER_RESET,
@@ -7412,10 +7381,10 @@
 
 	{
 		.vendor		= "Winbond",
-		.name		= "W39V040C",
+		.name		= "W39V040(F)C",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_39V040C,
+		.model_id	= WINBOND_W39V040C,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
 		.feature_bits	= FEATURE_EITHER_RESET,
@@ -7442,7 +7411,7 @@
 		.name		= "W39V040FA",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_39V040FA,
+		.model_id	= WINBOND_W39V040FA,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
 		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
@@ -7473,7 +7442,7 @@
 		.name		= "W39V080A",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_39V080A,
+		.model_id	= WINBOND_W39V080A,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
 		.feature_bits	= FEATURE_EITHER_RESET,
@@ -7496,10 +7465,10 @@
 
 	{
 		.vendor		= "Winbond",
-		.name		= "W49F002U",
+		.name		= "W49F002U/N",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_49F002U,
+		.model_id	= WINBOND_W49F002U,
 		.total_size	= 256,
 		.page_size	= 128,
 		.feature_bits	= FEATURE_EITHER_RESET,
@@ -7530,7 +7499,7 @@
 		.name		= "W49F020",
 		.bustype	= CHIP_BUSTYPE_PARALLEL,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_49F020,
+		.model_id	= WINBOND_W49F020,
 		.total_size	= 256,
 		.page_size	= 128,
 		.feature_bits	= FEATURE_EITHER_RESET,
@@ -7553,7 +7522,7 @@
 		.name		= "W49V002A",
 		.bustype	= CHIP_BUSTYPE_LPC,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_49V002A,
+		.model_id	= WINBOND_W49V002A,
 		.total_size	= 256,
 		.page_size	= 128,
 		.feature_bits	= FEATURE_EITHER_RESET,
@@ -7584,7 +7553,7 @@
 		.name		= "W49V002FA",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_49V002FA,
+		.model_id	= WINBOND_W49V002FA,
 		.total_size	= 256,
 		.page_size	= 128,
 		.feature_bits	= FEATURE_EITHER_RESET,
@@ -7615,7 +7584,7 @@
 		.name		= "W39V080FA",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_39V080FA,
+		.model_id	= WINBOND_W39V080FA,
 		.total_size	= 1024,
 		.page_size	= 64 * 1024,
 		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
@@ -7642,7 +7611,7 @@
 		.name		= "W39V080FA (dual mode)",
 		.bustype	= CHIP_BUSTYPE_FWH,
 		.manufacture_id	= WINBOND_ID,
-		.model_id	= W_39V080FA_DM,
+		.model_id	= WINBOND_W39V080FA_DM,
 		.total_size	= 512,
 		.page_size	= 64 * 1024,
 		.feature_bits	= FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,
Index: flashchips.h
===================================================================
--- flashchips.h	(revision 1164)
+++ flashchips.h	(working copy)
@@ -110,10 +110,6 @@
 #define AMIC_A29L040		0x92
 #define AMIC_A49LF040A		0x9d
 
-/* This chip vendor/device ID is probably a misinterpreted LHA header. */
-#define ASD_ID			0x25	/* ASD, not listed in JEP106W */
-#define ASD_AE49F2008		0x52
-
 #define ATMEL_ID		0x1F	/* Atmel */
 #define AT_25DF021		0x4300
 #define AT_25DF041A		0x4401
@@ -541,35 +537,52 @@
  * W25X chips are SPI, first byte of device ID is memory type, second
  * byte of device ID is related to log(bitsize).
  */
-#define WINBOND_ID		0xDA	/* Winbond */
 #define WINBOND_NEX_ID		0xEF	/* Winbond (ex Nexcom) serial flashes */
-#define W_25X10			0x3011
-#define W_25X20			0x3012
-#define W_25X40			0x3013
-#define W_25X80			0x3014
-#define W_25X16			0x3015
-#define W_25X32			0x3016
-#define W_25X64			0x3017
-#define W_25Q80			0x4014
-#define W_25Q16			0x4015
-#define W_25Q32			0x4016
-#define W_25Q64			0x4017
-#define W_29C011		0xC1
-#define W_29C020C		0x45	/* Same as W29C020 and ASD AE29F2008 */
-#define W_29C040P		0x46	/* Same as W29C040 */
-#define W_29EE011		0xC1
-#define W_39L020		0xB5
-#define W_39L040		0xB6
-#define W_39V040FA		0x34
-#define W_39V040A		0x3D
-#define W_39V040B		0x54
-#define W_39V040C		0x50
-#define W_39V080A		0xD0
-#define W_39V080FA		0xD3
-#define W_39V080FA_DM		0x93
-#define W_49F002U		0x0B
-#define W_49F020		0x8C
-#define W_49V002A		0xB0
-#define W_49V002FA		0x32
+#define WINBOND_NEX_W25X10	0x3011
+#define WINBOND_NEX_W25X20	0x3012
+#define WINBOND_NEX_W25X40	0x3013
+#define WINBOND_NEX_W25X80	0x3014
+#define WINBOND_NEX_W25X16	0x3015
+#define WINBOND_NEX_W25X32	0x3016
+#define WINBOND_NEX_W25X64	0x3017
+#define WINBOND_NEX_W25Q40	0x4013
+#define WINBOND_NEX_W25Q80	0x4014
+#define WINBOND_NEX_W25Q16	0x4015
+#define WINBOND_NEX_W25Q32	0x4016
+#define WINBOND_NEX_W25Q64	0x4017
+#define WINBOND_NEX_W25Q128	0x4018
 
+#define WINBOND_ID		0xDA	/* Winbond */
+#define WINBOND_W19B160BB	0x49
+#define WINBOND_W19B160BT	0xC4
+#define WINBOND_W19B320SB	0x2A    /* Same as W19L320SB */
+#define WINBOND_W19B320ST	0xBA    /* Same as W19L320ST */
+#define WINBOND_W19B322MB	0x92
+#define WINBOND_W19B322MT	0x10
+#define WINBOND_W19B323MB	0x94
+#define WINBOND_W19B323MT	0x13
+#define WINBOND_W19B324MB	0x97
+#define WINBOND_W19B324MT	0x16
+#define WINBOND_W29C010		0xC1    /* Same as W29C010M, W29C011A, W29EE011, W29EE012, and ASD AE29F1008 */
+#define WINBOND_W29C020		0x45    /* Same as W29C020C, W29C022 and ASD AE29F2008 */
+#define WINBOND_W29C040		0x46    /* Same as W29C040P */
+#define WINBOND_W29C512A	0xC8    /* Same as W29EE512 */
+#define WINBOND_W39L010		0x31
+#define WINBOND_W39L020		0xB5
+#define WINBOND_W39L040		0xB6
+#define WINBOND_W39L040A	0xD6
+#define WINBOND_W39L512		0x38
+#define WINBOND_W39V040A	0x3D
+#define WINBOND_W39V040FA	0x34
+#define WINBOND_W39V040B	0x54    /* Same as W39V040FB */
+#define WINBOND_W39V040C	0x50    /* Same as W39V040FC */
+#define WINBOND_W39V080A	0xD0
+#define WINBOND_W39V080FA	0xD3
+#define WINBOND_W39V080FA_DM	0x93    /* W39V080FA dual mode */
+#define WINBOND_W49F002		0x25    /* Same as W49F002B */
+#define WINBOND_W49F002U	0x0B    /* Same as W49F002N and ASD AE49F2008 */
+#define WINBOND_W49F020		0x8C
+#define WINBOND_W49V002A	0xB0
+#define WINBOND_W49V002FA	0x32
+
 #endif /* !FLASHCHIPS_H */
