diff options
author | Baruch Siach <baruch@tkos.co.il> | 2013-12-30 20:30:45 +0200 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2013-12-31 12:30:22 +0000 |
commit | 020fe3fe11255cc3d8e67d5e53705c48deb19376 (patch) | |
tree | a6c977c63929b67011349d0c76e33baf84433d34 /drivers/spi/spi-dw-mmio.c | |
parent | 04f421e7b0b10de3fae543dac4d324b449a1db6b (diff) |
spi: dw-mmio: prepare the clock before enabling
This is required for common clock support.
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'drivers/spi/spi-dw-mmio.c')
-rw-r--r-- | drivers/spi/spi-dw-mmio.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/spi/spi-dw-mmio.c b/drivers/spi/spi-dw-mmio.c index 569adf877b16..9af56cdf1540 100644 --- a/drivers/spi/spi-dw-mmio.c +++ b/drivers/spi/spi-dw-mmio.c @@ -62,7 +62,7 @@ static int dw_spi_mmio_probe(struct platform_device *pdev) dwsmmio->clk = devm_clk_get(&pdev->dev, NULL); if (IS_ERR(dwsmmio->clk)) return PTR_ERR(dwsmmio->clk); - ret = clk_enable(dwsmmio->clk); + ret = clk_prepare_enable(dwsmmio->clk); if (ret) return ret; @@ -78,7 +78,7 @@ static int dw_spi_mmio_probe(struct platform_device *pdev) return 0; out: - clk_disable(dwsmmio->clk); + clk_disable_unprepare(dwsmmio->clk); return ret; } @@ -86,7 +86,7 @@ static int dw_spi_mmio_remove(struct platform_device *pdev) { struct dw_spi_mmio *dwsmmio = platform_get_drvdata(pdev); - clk_disable(dwsmmio->clk); + clk_disable_unprepare(dwsmmio->clk); dw_spi_remove_host(&dwsmmio->dws); return 0; |