[PATCH] mtd: mtdcore: remove unnecessary mtd->resume check

Brian Norris computersforpeace at gmail.com
Fri Jan 27 15:39:32 EST 2012


We don't need to to check for mtd->resume before calling mtd_resume().
mtd_resume() should take care of that.

Signed-off-by: Brian Norris <computersforpeace at gmail.com>
---
 drivers/mtd/mtdcore.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/mtd/mtdcore.c b/drivers/mtd/mtdcore.c
index de96865..f96c2cd 100644
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
@@ -126,7 +126,7 @@ static int mtd_cls_resume(struct device *dev)
 {
 	struct mtd_info *mtd = dev_get_drvdata(dev);
 
-	if (mtd && mtd->resume)
+	if (mtd)
 		mtd_resume(mtd);
 	return 0;
 }
-- 
1.7.5.4




More information about the linux-mtd mailing list