summaryrefslogtreecommitdiff
path: root/drivers/mtd/devices
diff options
context:
space:
mode:
authorBoris Brezillon <boris.brezillon@bootlin.com>2018-02-12 22:03:09 +0100
committerBoris Brezillon <boris.brezillon@bootlin.com>2018-03-15 18:21:07 +0100
commit884cfd9023ce6afe8bcf181ec988d8516eb32bf0 (patch)
treef57f5eafe52a568ac90e25b64f8e6a0e9d37e993 /drivers/mtd/devices
parentdcba51bbb9e0cc7f80d36eb20a033a4dff2ce9cc (diff)
mtd: Stop assuming mtd_erase() is asynchronous
None of the mtd->_erase() implementations work in an asynchronous manner, so let's simplify MTD users that call mtd_erase(). All they need to do is check the value returned by mtd_erase() and assume that != 0 means failure. Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com> Reviewed-by: Richard Weinberger <richard@nod.at>
Diffstat (limited to 'drivers/mtd/devices')
-rw-r--r--drivers/mtd/devices/bcm47xxsflash.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/mtd/devices/bcm47xxsflash.c b/drivers/mtd/devices/bcm47xxsflash.c
index e2bd81817df4..6b84947cfbea 100644
--- a/drivers/mtd/devices/bcm47xxsflash.c
+++ b/drivers/mtd/devices/bcm47xxsflash.c
@@ -95,9 +95,6 @@ static int bcm47xxsflash_erase(struct mtd_info *mtd, struct erase_info *erase)
else
erase->state = MTD_ERASE_DONE;
- if (erase->callback)
- erase->callback(erase);
-
return err;
}