diff --git a/flash_rom.c b/flash_rom.c
index bf338cc..35a9f50 100644
--- a/flash_rom.c
+++ b/flash_rom.c
@@ -194,7 +194,8 @@
 	FILE *image;
 	struct flashchip *flash;
 	int opt;
-	int read_it = 0, write_it = 0, verify_it = 0, verbose = 0;
+	int read_it = 0, write_it = 0, erase_it = 0, verify_it = 0,
+		verbose = 0;
 	char *filename = NULL;
 
 
@@ -211,7 +212,7 @@
 
 	setbuf(stdout, NULL);
 
-	while ((opt = getopt(argc, argv, "rwvVc:s:e:")) != EOF) {
+	while ((opt = getopt(argc, argv, "rwvVEc:s:e:")) != EOF) {
 		switch (opt) {
 		case 'r':
 			read_it = 1;
@@ -228,6 +229,9 @@
 		case 'V':
 			verbose = 1;
 			break;
+		case 'E':
+			erase_it = 1;
+			break;
 		case 's':
 			tempstr = strdup(optarg);
 			sscanf(tempstr,"%x",&exclude_start_position);
@@ -266,14 +270,18 @@
 	}
 
 	printf("Part is %s\n", flash->name);
-	if (!filename) {
+	if (!filename && !erase_it) {
 		printf("OK, only ENABLING flash write, but NOT FLASHING\n");
 		return 0;
 	}
 	size = flash->total_size * 1024;
 	buf = (char *) calloc(size, sizeof(char));
 
-	if (read_it) {
+	if (erase_it) {
+		printf("Erasing flash chip\n");
+		flash->erase(flash);
+		exit(0);		
+	} else if (read_it) {
 		if ((image = fopen(filename, "w")) == NULL) {
 			perror(filename);
 			exit(1);
diff --git a/jedec.c b/jedec.c
index 8cab944..353b17a 100644
--- a/jedec.c
+++ b/jedec.c
@@ -62,26 +62,19 @@
 
 int erase_sector_jedec(volatile unsigned char *bios, unsigned int page)
 {
-	volatile unsigned char *Temp;
-
 	/*  Issue the Sector Erase command   */
-	Temp = bios + 0x5555;	/* set up address to be BASE:5555h      */
-	*Temp = 0xAA;		/* write data 0xAA to the address       */
+	*(volatile char *) (bios + 0x5555) = 0xAA;
 	myusec_delay(10);
-	Temp = bios + 0x2AAA;	/* set up address to be BASE:2AAAh      */
-	*Temp = 0x55;		/* write data 0x55 to the address       */
+	*(volatile char *) (bios + 0x2AAA) = 0x55;
 	myusec_delay(10);
-	Temp = bios + 0x5555;	/* set up address to be BASE:5555h      */
-	*Temp = 0x80;		/* write data 0x80 to the address       */
+	*(volatile char *) (bios + 0x5555) = 0x80;
 	myusec_delay(10);
-	Temp = bios + 0x5555;	/* set up address to be BASE:5555h      */
-	*Temp = 0xAA;		/* write data 0xAA to the address       */
+
+	*(volatile char *) (bios + 0x5555) = 0xAA;
 	myusec_delay(10);
-	Temp = bios + 0x2AAA;	/* set up address to be BASE:2AAAh      */
-	*Temp = 0x55;		/* write data 0x55 to the address       */
+	*(volatile char *) (bios + 0x2AAA) = 0x55;
 	myusec_delay(10);
-	Temp = bios + page;	/* set up address to be the current sector */
-	*Temp = 0x30;		/* write data 0x30 to the address       */
+	*(volatile char *) (bios + page)   = 0x30;
 	myusec_delay(10);
 
 	/* wait for Toggle bit ready         */
@@ -92,26 +85,19 @@
 
 int erase_block_jedec(volatile unsigned char *bios, unsigned int block)
 {
-	volatile unsigned char *Temp;
-
 	/*  Issue the Sector Erase command   */
-	Temp = bios + 0x5555;	/* set up address to be BASE:5555h      */
-	*Temp = 0xAA;		/* write data 0xAA to the address       */
+	*(volatile char *) (bios + 0x5555) = 0xAA;
 	myusec_delay(10);
-	Temp = bios + 0x2AAA;	/* set up address to be BASE:2AAAh      */
-	*Temp = 0x55;		/* write data 0x55 to the address       */
+	*(volatile char *) (bios + 0x2AAA) = 0x55;
 	myusec_delay(10);
-	Temp = bios + 0x5555;	/* set up address to be BASE:5555h      */
-	*Temp = 0x80;		/* write data 0x80 to the address       */
+	*(volatile char *) (bios + 0x5555) = 0x80;
 	myusec_delay(10);
-	Temp = bios + 0x5555;	/* set up address to be BASE:5555h      */
-	*Temp = 0xAA;		/* write data 0xAA to the address       */
+
+	*(volatile char *) (bios + 0x5555) = 0xAA;
 	myusec_delay(10);
-	Temp = bios + 0x2AAA;	/* set up address to be BASE:2AAAh      */
-	*Temp = 0x55;		/* write data 0x55 to the address       */
+	*(volatile char *) (bios + 0x2AAA) = 0x55;
 	myusec_delay(10);
-	Temp = bios + block;	/* set up address to be the current sector */
-	*Temp = 0x50;		/* write data 0x30 to the address       */
+	*(volatile char *) (bios + block)  = 0x50;
 	myusec_delay(10);
 
 	/* wait for Toggle bit ready         */
@@ -123,26 +109,20 @@
 int erase_chip_jedec(struct flashchip *flash)
 {
 	volatile unsigned char *bios = flash->virt_addr;
-	volatile unsigned char *Temp;
 
 	/*  Issue the JEDEC Chip Erase command   */
-	Temp = bios + 0x5555;	/* set up address to be BASE:5555h      */
-	*Temp = 0xAA;		/* write data 0xAA to the address       */
+	*(volatile char *) (bios + 0x5555) = 0xAA;
 	myusec_delay(10);
-	Temp = bios + 0x2AAA;	/* set up address to be BASE:2AAAh      */
-	*Temp = 0x55;		/* write data 0x55 to the address       */
+	*(volatile char *) (bios + 0x2AAA) = 0x55;
 	myusec_delay(10);
-	Temp = bios + 0x5555;	/* set up address to be BASE:5555h      */
-	*Temp = 0x80;		/* write data 0x80 to the address       */
+	*(volatile char *) (bios + 0x5555) = 0x80;
 	myusec_delay(10);
-	Temp = bios + 0x5555;	/* set up address to be BASE:5555h      */
-	*Temp = 0xAA;		/* write data 0xAA to the address       */
+
+	*(volatile char *) (bios + 0x5555) = 0xAA;
 	myusec_delay(10);
-	Temp = bios + 0x2AAA;	/* set up address to be BASE:2AAAh      */
-	*Temp = 0x55;		/* write data 0x55 to the address       */
+	*(volatile char *) (bios + 0x2AAA) = 0x55;
 	myusec_delay(10);
-	Temp = bios + 0x5555;	/* set up address to be BASEy:5555h     */
-	*Temp = 0x10;		/* write data 0x10 to the address       */
+	*(volatile char *) (bios + 0x5555) = 0x10;
 	myusec_delay(10);
 
 	toggle_ready_jedec(bios);
diff --git a/pm49fl004.c b/pm49fl004.c
index a3f42fa..afcd55a 100644
--- a/pm49fl004.c
+++ b/pm49fl004.c
@@ -27,43 +27,13 @@
 #include "jedec.h"
 #include "pm49fl004.h"
 
-static __inline__ int erase_block_49fl004(volatile unsigned char *bios,
-					  unsigned long address)
-{
-	volatile unsigned char *Temp;
-
-	Temp = bios + 0x5555;	/* set up address to be C000:5555h      */
-	*Temp = 0xAA;		/* write data 0xAA to the address       */
-	myusec_delay(10);
-	Temp = bios + 0x2AAA;	/* set up address to be C000:2AAAh      */
-	*Temp = 0x55;		/* write data 0x55 to the address       */
-	myusec_delay(10);
-	Temp = bios + 0x5555;	/* set up address to be C000:5555h      */
-	*Temp = 0x80;		/* write data 0x80 to the address       */
-	myusec_delay(10);
-	Temp = bios + 0x5555;	/* set up address to be C000:5555h      */
-	*Temp = 0xAA;		/* write data 0xAA to the address       */
-	myusec_delay(10);
-	Temp = bios + 0x2AAA;	/* set up address to be C000:2AAAh      */
-	*Temp = 0x55;		/* write data 0x55 to the address       */
-	myusec_delay(10);
-	Temp = bios + address;	/* set up address to be C000:5555h      */
-	*Temp = 0x50;		/* write data 0x50 to the address       */
-
-	/* wait for Toggle bit ready         */
-	toggle_ready_jedec(bios);
-
-	return (0);
-}
-
-
 extern int exclude_start_page, exclude_end_page;
 
 int write_49fl004(struct flashchip *flash, unsigned char *buf)
 {
 	int i;
 	int total_size = flash->total_size * 1024, page_size =
-	    flash->page_size;
+		flash->page_size;
 	volatile char *bios = flash->virt_addr;
 	
 	printf("Programming Page: ");
@@ -72,7 +42,7 @@
 			continue;
 		
 		/* erase the page before programming */
-		erase_block_49fl004(bios, i * page_size);
+		erase_block_jedec(bios, i * page_size);
 
 		/* write to the sector */
 		printf("%04d at address: 0x%08x", i, i * page_size);
diff --git a/sst39sf020.c b/sst39sf020.c
index 401247a..97e87a1 100644
--- a/sst39sf020.c
+++ b/sst39sf020.c
@@ -51,22 +51,18 @@
 {
 	int i;
 	int total_size = flash->total_size * 1024, page_size =
-	    flash->page_size;
+		flash->page_size;
 	volatile char *bios = flash->virt_addr;
 
 	erase_chip_jedec(flash);
 
 	printf("Programming Page: ");
 	for (i = 0; i < total_size / page_size; i++) {
-		/* erase the page before programming */
-		//erase_sector_39sf020(bios, i * page_size);
-
 		/* write to the sector */
 		printf("%04d at address: 0x%08x", i, i * page_size);
 		write_sector_jedec(bios, buf + i * page_size,
 				   bios + i * page_size, page_size);
-		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("\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");
 		fflush(stdout);
 	}
 	printf("\n");
diff --git a/sst_fwhub.c b/sst_fwhub.c
index d9dd467..c064ed6 100644
--- a/sst_fwhub.c
+++ b/sst_fwhub.c
@@ -47,38 +47,14 @@
 }
 
 /* probe_jedec works fine for probing */
-
 int probe_sst_fwhub(struct flashchip *flash)
 {
-	volatile unsigned char *bios = flash->virt_addr;
-	unsigned char id1, id2;
+	volatile unsigned char *bios;
 	size_t size = flash->total_size * 1024;
-	/* Issue JEDEC Product ID Entry command */
-	*(volatile char *) (bios + 0x5555) = 0xAA;
-	myusec_delay(10);
-	*(volatile char *) (bios + 0x2AAA) = 0x55;
-	myusec_delay(10);
-	*(volatile char *) (bios + 0x5555) = 0x90;
-	myusec_delay(10);
 
-	/* Read product ID */
-	id1 = *(volatile unsigned char *) bios;
-	id2 = *(volatile unsigned char *) (bios + 0x01);
-
-	/* Issue JEDEC Product ID Exit command */
-	*(volatile char *) (bios + 0x5555) = 0xAA;
-	myusec_delay(10);
-	*(volatile char *) (bios + 0x2AAA) = 0x55;
-	myusec_delay(10);
-	*(volatile char *) (bios + 0x5555) = 0xF0;
-	myusec_delay(10);
-
-	printf("%s: id1 0x%x, id2 0x%x\n", __FUNCTION__, id1, id2);
-	if (id1 != flash->manufacture_id || id2 != flash->model_id)
+	if (probe_jedec(flash) == 0)
 		return 0;
 
-	myusec_delay(10);
-
 	bios = mmap(0, size, PROT_WRITE | PROT_READ, MAP_SHARED,
 		    flash->fd_mem, (off_t) (0xFFFFFFFF - 0x400000 - size + 1));
 	if (bios == MAP_FAILED) {
@@ -91,23 +67,15 @@
 	return 1;
 }
 
-unsigned char wait_sst_fwhub(volatile unsigned char *bios)
-{
-	toggle_ready_jedec(bios);
-	return 0;
-}
-
 int erase_sst_fwhub_block(struct flashchip *flash, int offset)
 {
 	volatile unsigned char *wrprotect = flash->virt_addr_2 + offset + 2;
-	unsigned char status;
 
-	//printf("Erase at %p\n", bios);
 	// clear write protect
 	*(wrprotect) = 0;
 
 	erase_block_jedec(flash->virt_addr, offset);
-	status = wait_sst_fwhub(flash->virt_addr);
+	toggle_ready_jedec(flash->virt_addr);
 
 	return (0);
 }
@@ -122,19 +90,6 @@
 	return (0);
 }
 
-void write_page_sst_fwhub(volatile char *bios, char *src,
-			  volatile char *dst, int page_size)
-{
-	int i;
-
-	for (i = 0; i < page_size; i++) {
-		/* transfer data from source to destination */
-		write_byte_program_jedec(bios, src, dst);
-		src++;
-		dst++;
-	}
-}
-
 int write_sst_fwhub(struct flashchip *flash, unsigned char *buf)
 {
 	int i;
@@ -150,8 +105,8 @@
 	printf("Programming Page: ");
 	for (i = 0; i < total_size / page_size; i++) {
 		printf("%04d at address: 0x%08x", i, i * page_size);
-		write_page_sst_fwhub(bios, buf + i * page_size,
-				     bios + i * page_size, page_size);
+		write_sector_jedec(bios, buf + i * page_size,
+				   bios + i * page_size, page_size);
 		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");
diff --git a/w49f002u.c b/w49f002u.c
index c6200d0..5325076 100644
--- a/w49f002u.c
+++ b/w49f002u.c
@@ -35,27 +35,20 @@
 int write_49f002(struct flashchip *flash, unsigned char *buf)
 {
 	int i;
-	int total_size = flash->total_size * 1024;
+	int total_size = flash->total_size * 1024, page_size =
+		flash->page_size;
 	volatile char *bios = flash->virt_addr;
-	volatile char *dst = bios;
 
 	erase_chip_jedec(flash);
 
 	printf("Programming Page: ");
 	for (i = 0; i < total_size; i++) {
 		/* write to the sector */
-		if ((i & 0xfff) == 0)
-			printf("address: 0x%08lx", (unsigned long) i);
-		*(bios + 0x5555) = 0xAA;
-		*(bios + 0x2AAA) = 0x55;
-		*(bios + 0x5555) = 0xA0;
-		*dst++ = *buf++;
-
-		/* wait for Toggle bit ready */
-		toggle_ready_jedec(dst);
-
-		if ((i & 0xfff) == 0)
-			printf("\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b");
+		printf("%04d at address: 0x%08x ", i, i * page_size);
+		write_sector_jedec(bios, buf + i * page_size,
+				   bios + i * page_size, page_size);
+		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\b");
+		fflush(stdout);
 	}
 	printf("\n");
 
