summaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi-s3c24xx.c
diff options
context:
space:
mode:
authorAxel Lin <axel.lin@ingics.com>2014-03-05 15:17:23 +0800
committerMark Brown <broonie@linaro.org>2014-03-07 14:00:02 +0800
commit380603712072145785f19040b9791f4f6cde414e (patch)
treed29335387af88f328f9f6eaf8f43a1ed4aa254d4 /drivers/spi/spi-s3c24xx.c
parent08850fa94831d374f4d827a85088f6087836dfc8 (diff)
downloadblackbird-op-linux-380603712072145785f19040b9791f4f6cde414e.tar.gz
blackbird-op-linux-380603712072145785f19040b9791f4f6cde414e.zip
spi: s3c24xx: Add missing spi_master_{resume,suspend} calls to PM callbacks
This is required since commit 2025172e3280 "spi/bitbang: Use core message pump". spi-bitbang now uses core message pump, so it needs to call spi_master_suspend/ spi_master_resume to start/stop the queue while suspend/resume. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'drivers/spi/spi-s3c24xx.c')
-rw-r--r--drivers/spi/spi-s3c24xx.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/spi/spi-s3c24xx.c b/drivers/spi/spi-s3c24xx.c
index f1ffbfa6acef..b7f5c349a3c0 100644
--- a/drivers/spi/spi-s3c24xx.c
+++ b/drivers/spi/spi-s3c24xx.c
@@ -634,6 +634,11 @@ static int s3c24xx_spi_remove(struct platform_device *dev)
static int s3c24xx_spi_suspend(struct device *dev)
{
struct s3c24xx_spi *hw = dev_get_drvdata(dev);
+ int ret;
+
+ ret = spi_master_suspend(hw->master);
+ if (ret)
+ return ret;
if (hw->pdata && hw->pdata->gpio_setup)
hw->pdata->gpio_setup(hw->pdata, 0);
@@ -647,7 +652,7 @@ static int s3c24xx_spi_resume(struct device *dev)
struct s3c24xx_spi *hw = dev_get_drvdata(dev);
s3c24xx_spi_initialsetup(hw);
- return 0;
+ return spi_master_resume(hw->master);
}
static const struct dev_pm_ops s3c24xx_spi_pmops = {
OpenPOWER on IntegriCloud