summaryrefslogtreecommitdiff
path: root/drivers/mtd
diff options
context:
space:
mode:
authorHan Xu <b45815@freescale.com>2015-07-30 16:35:52 -0500
committerLeonard Crestez <leonard.crestez@nxp.com>2018-08-24 12:20:42 +0300
commit93c576ad6aa44377483a0d8c567525a6f08637dc (patch)
treed1b56155e392141213832da15ee9309c6fe16b9c /drivers/mtd
parentedb5bc25d335709586163d7094786af333416ea4 (diff)
MLK-11335: mtd: qspi: enalbe LPSR for qspi
The LPSR turns off the power for IOMUX when suspending so restore the IOMUX when resuming. Signed-off-by: Han Xu <b45815@freescale.com> (cherry picked from commit 906d0c1381e865dc7c96a4bde6fe694f1ce089a9)
Diffstat (limited to 'drivers/mtd')
-rw-r--r--drivers/mtd/spi-nor/fsl-quadspi.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/mtd/spi-nor/fsl-quadspi.c b/drivers/mtd/spi-nor/fsl-quadspi.c
index 1b04099c5ab5..54f39e383951 100644
--- a/drivers/mtd/spi-nor/fsl-quadspi.c
+++ b/drivers/mtd/spi-nor/fsl-quadspi.c
@@ -1235,6 +1235,7 @@ static int fsl_qspi_remove(struct platform_device *pdev)
static int fsl_qspi_suspend(struct platform_device *pdev, pm_message_t state)
{
+ pinctrl_pm_select_sleep_state(&pdev->dev);
return 0;
}
@@ -1243,6 +1244,8 @@ static int fsl_qspi_resume(struct platform_device *pdev)
int ret;
struct fsl_qspi *q = platform_get_drvdata(pdev);
+ pinctrl_pm_select_default_state(&pdev->dev);
+
ret = fsl_qspi_clk_prep_enable(q);
if (ret)
return ret;