summaryrefslogtreecommitdiff
path: root/drivers/spi/spi-bcm-qspi.c
diff options
context:
space:
mode:
authorKamal Dasu <kdasu.kdev@gmail.com>2020-04-20 15:08:50 -0400
committerMark Brown <broonie@kernel.org>2020-04-21 16:05:55 +0100
commit1b7ad8c405c3dc0ad6c2dc61fe21fe7a446cceeb (patch)
tree5b4219cf7e16987831c92d9af97050c6f9ed7a72 /drivers/spi/spi-bcm-qspi.c
parent742d5958062488d03082a9ff01a6afb3cf7bd634 (diff)
spi: bcm-qspi: Make PM suspend/resume work with SCMI clock management
SCMI only passes clk_prepare_enable() and clk_disable_unprepare(), made changes to suspend/resume ops to use the appropriate calls so that PM works for ARM and ARM64 platforms. Signed-off-by: Kamal Dasu <kdasu.kdev@gmail.com> Link: https://lore.kernel.org/r/20200420190853.45614-7-kdasu.kdev@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/spi/spi-bcm-qspi.c')
-rw-r--r--drivers/spi/spi-bcm-qspi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/spi/spi-bcm-qspi.c b/drivers/spi/spi-bcm-qspi.c
index a4c70ac80986..22f9fe1bf976 100644
--- a/drivers/spi/spi-bcm-qspi.c
+++ b/drivers/spi/spi-bcm-qspi.c
@@ -1411,7 +1411,7 @@ static int __maybe_unused bcm_qspi_suspend(struct device *dev)
bcm_qspi_read(qspi, BSPI, BSPI_STRAP_OVERRIDE_CTRL);
spi_master_suspend(qspi->master);
- clk_disable(qspi->clk);
+ clk_disable_unprepare(qspi->clk);
bcm_qspi_hw_uninit(qspi);
return 0;
@@ -1429,7 +1429,7 @@ static int __maybe_unused bcm_qspi_resume(struct device *dev)
qspi->soc_intc->bcm_qspi_int_set(qspi->soc_intc, MSPI_DONE,
true);
- ret = clk_enable(qspi->clk);
+ ret = clk_prepare_enable(qspi->clk);
if (!ret)
spi_master_resume(qspi->master);