diff options
author | Felix Fietkau <nbd@openwrt.org> | 2006-10-22 21:16:15 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2006-10-22 21:16:15 +0000 |
commit | 367b01ad5c1f4e51d1612fa84f35761c6519216b (patch) | |
tree | 11d16de27175c65d38696b0c6196433f2f563b1a /target/linux | |
parent | ed081b6cd3ea85789e6dde22b0c84f12b839c875 (diff) | |
download | upstream-367b01ad5c1f4e51d1612fa84f35761c6519216b.tar.gz upstream-367b01ad5c1f4e51d1612fa84f35761c6519216b.tar.bz2 upstream-367b01ad5c1f4e51d1612fa84f35761c6519216b.zip |
fix a timeout on amd flash chips (patch from #874)
SVN-Revision: 5262
Diffstat (limited to 'target/linux')
-rw-r--r-- | target/linux/generic-2.4/patches/115-amd_flash_timeout.patch | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/target/linux/generic-2.4/patches/115-amd_flash_timeout.patch b/target/linux/generic-2.4/patches/115-amd_flash_timeout.patch new file mode 100644 index 0000000000..188aa1c88a --- /dev/null +++ b/target/linux/generic-2.4/patches/115-amd_flash_timeout.patch @@ -0,0 +1,39 @@ +diff -u linux-2.4.30/drivers/mtd/chips/cfi_cmdset_0002.c.orig linux-2.4.30/drivers/mtd/chips/cfi_cmdset_0002.c +--- linux-2.4.30/drivers/mtd/chips/cfi_cmdset_0002.c.orig 2004-11-17 12:54:21.000000000 +0100 ++++ linux-2.4.30/drivers/mtd/chips/cfi_cmdset_0002.c 2006-10-21 17:55:25.000000000 +0200 +@@ -510,7 +510,7 @@ + or tells us why it failed. */ + dq6 = CMD(1<<6); + dq5 = CMD(1<<5); +- timeo = jiffies + (HZ/1000); /* setting timeout to 1ms for now */ ++ timeo = jiffies + (HZ/1000) + 1; /* setting timeout to 1ms for now */ + + oldstatus = cfi_read(map, adr); + status = cfi_read(map, adr); +@@ -547,7 +547,7 @@ + printk(KERN_WARNING "Internal flash device timeout occurred or write operation was performed while flash was programming.\n" ); + } + } else { +- printk(KERN_WARNING "Waiting for write to complete timed out in do_write_oneword."); ++ printk(KERN_WARNING "Waiting for write to complete timed out in do_write_oneword.\n"); + + chip->state = FL_READY; + wake_up(&chip->wq); +@@ -825,7 +825,7 @@ + chip->state = FL_READY; + wake_up(&chip->wq); + cfi_spin_unlock(chip->mutex); +- printk("waiting for erase to complete timed out."); ++ printk("waiting for erase to complete timed out.\n"); + DISABLE_VPP(map); + return -EIO; + } +@@ -963,7 +963,7 @@ + } + else + { +- printk( "Waiting for erase to complete timed out in do_erase_oneblock."); ++ printk( "Waiting for erase to complete timed out in do_erase_oneblock.\n"); + + chip->state = FL_READY; + wake_up(&chip->wq); |