diff options
Diffstat (limited to 'drivers/mtd')
-rw-r--r-- | drivers/mtd/chips/cfi_cmdset_0002.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/mtd/chips/cfi_cmdset_0002.c b/drivers/mtd/chips/cfi_cmdset_0002.c index c1d4624ce6e7..d02592e6a0f0 100644 --- a/drivers/mtd/chips/cfi_cmdset_0002.c +++ b/drivers/mtd/chips/cfi_cmdset_0002.c | |||
@@ -774,8 +774,6 @@ static void put_chip(struct map_info *map, struct flchip *chip, unsigned long ad | |||
774 | 774 | ||
775 | case FL_READY: | 775 | case FL_READY: |
776 | case FL_STATUS: | 776 | case FL_STATUS: |
777 | /* We should really make set_vpp() count, rather than doing this */ | ||
778 | DISABLE_VPP(map); | ||
779 | break; | 777 | break; |
780 | default: | 778 | default: |
781 | printk(KERN_ERR "MTD: put_chip() called with oldstate %d!!\n", chip->oldstate); | 779 | printk(KERN_ERR "MTD: put_chip() called with oldstate %d!!\n", chip->oldstate); |
@@ -1229,6 +1227,7 @@ static int __xipram do_write_oneword(struct map_info *map, struct flchip *chip, | |||
1229 | xip_enable(map, chip, adr); | 1227 | xip_enable(map, chip, adr); |
1230 | op_done: | 1228 | op_done: |
1231 | chip->state = FL_READY; | 1229 | chip->state = FL_READY; |
1230 | DISABLE_VPP(map); | ||
1232 | put_chip(map, chip, adr); | 1231 | put_chip(map, chip, adr); |
1233 | mutex_unlock(&chip->mutex); | 1232 | mutex_unlock(&chip->mutex); |
1234 | 1233 | ||
@@ -1467,6 +1466,7 @@ static int __xipram do_write_buffer(struct map_info *map, struct flchip *chip, | |||
1467 | ret = -EIO; | 1466 | ret = -EIO; |
1468 | op_done: | 1467 | op_done: |
1469 | chip->state = FL_READY; | 1468 | chip->state = FL_READY; |
1469 | DISABLE_VPP(map); | ||
1470 | put_chip(map, chip, adr); | 1470 | put_chip(map, chip, adr); |
1471 | mutex_unlock(&chip->mutex); | 1471 | mutex_unlock(&chip->mutex); |
1472 | 1472 | ||
@@ -1868,6 +1868,7 @@ static int __xipram do_erase_chip(struct map_info *map, struct flchip *chip) | |||
1868 | 1868 | ||
1869 | chip->state = FL_READY; | 1869 | chip->state = FL_READY; |
1870 | xip_enable(map, chip, adr); | 1870 | xip_enable(map, chip, adr); |
1871 | DISABLE_VPP(map); | ||
1871 | put_chip(map, chip, adr); | 1872 | put_chip(map, chip, adr); |
1872 | mutex_unlock(&chip->mutex); | 1873 | mutex_unlock(&chip->mutex); |
1873 | 1874 | ||
@@ -1958,6 +1959,7 @@ static int __xipram do_erase_oneblock(struct map_info *map, struct flchip *chip, | |||
1958 | } | 1959 | } |
1959 | 1960 | ||
1960 | chip->state = FL_READY; | 1961 | chip->state = FL_READY; |
1962 | DISABLE_VPP(map); | ||
1961 | put_chip(map, chip, adr); | 1963 | put_chip(map, chip, adr); |
1962 | mutex_unlock(&chip->mutex); | 1964 | mutex_unlock(&chip->mutex); |
1963 | return ret; | 1965 | return ret; |