Patchwork mtd: OneNAND: S5PC110: Fix double call suspend & resume function

login
register
mail settings
Submitter Kyungmin Park
Date Oct. 20, 2010, 8:31 a.m.
Message ID <20101020083102.GA30414@july>
Download mbox | patch
Permalink /patch/68399/
State Accepted
Commit 2316d3bc95ff65b7c0c40c70db83455912cf0328
Headers show

Comments

Kyungmin Park - Oct. 20, 2010, 8:31 a.m.
From: Kyungmin Park <kyungmin.park@samsung.com>

The suspend & resume called from mtd core. So no need to call at driver.

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
Artem Bityutskiy - Oct. 21, 2010, 8:57 a.m.
On Wed, 2010-10-20 at 17:31 +0900, Kyungmin Park wrote:
> From: Kyungmin Park <kyungmin.park@samsung.com>
> 
> The suspend & resume called from mtd core. So no need to call at driver.
> 
> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>

Pushed this one to my l2 tree, thanks!

Patch

diff --git a/drivers/mtd/onenand/samsung.c b/drivers/mtd/onenand/samsung.c
index 214ed1e..0de7a05 100644
--- a/drivers/mtd/onenand/samsung.c
+++ b/drivers/mtd/onenand/samsung.c
@@ -1098,7 +1098,7 @@  static int s3c_pm_ops_suspend(struct device *dev)
 	struct onenand_chip *this = mtd->priv;
 
 	this->wait(mtd, FL_PM_SUSPENDED);
-	return mtd->suspend(mtd);
+	return 0;
 }
 
 static  int s3c_pm_ops_resume(struct device *dev)
@@ -1107,7 +1107,6 @@  static  int s3c_pm_ops_resume(struct device *dev)
 	struct mtd_info *mtd = platform_get_drvdata(pdev);
 	struct onenand_chip *this = mtd->priv;
 
-	mtd->resume(mtd);
 	this->unlock_all(mtd);
 	return 0;
 }