diff options
Diffstat (limited to 'drivers')
| -rw-r--r-- | drivers/mtd/chips/cfi_cmdset_0002.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/mtd/chips/cfi_cmdset_0002.c b/drivers/mtd/chips/cfi_cmdset_0002.c index 72428b6bfc47..7b7286b4d81e 100644 --- a/drivers/mtd/chips/cfi_cmdset_0002.c +++ b/drivers/mtd/chips/cfi_cmdset_0002.c | |||
| @@ -1876,7 +1876,11 @@ static int __xipram do_write_buffer(struct map_info *map, struct flchip *chip, | |||
| 1876 | continue; | 1876 | continue; |
| 1877 | } | 1877 | } |
| 1878 | 1878 | ||
| 1879 | if (time_after(jiffies, timeo) && !chip_ready(map, adr)) | 1879 | /* |
| 1880 | * We check "time_after" and "!chip_good" before checking "chip_good" to avoid | ||
| 1881 | * the failure due to scheduling. | ||
| 1882 | */ | ||
| 1883 | if (time_after(jiffies, timeo) && !chip_good(map, adr, datum)) | ||
| 1880 | break; | 1884 | break; |
| 1881 | 1885 | ||
| 1882 | if (chip_good(map, adr, datum)) { | 1886 | if (chip_good(map, adr, datum)) { |
