mirror of https://github.com/hak5/openwrt-owl.git
ar71xx: spi-rb4xx: balance clk_prepare_enable() call
Commitowlc312cef223
("ar71xx: spi-rb4xx fix.") replaced the clk_enable() call with clk_prepare_enable() to meet the common clock framework requirements. However it did not change the clk_disable() call in the error patch which thus leads to imbalance. Fix the code by using the correct counterpart of clk_prepare_enable() in both places. Fixes:c312cef223
("ar71xx: spi-rb4xx fix.") Signed-off-by: Gabor Juhos <juhosg@freemail.hu>
parent
df68e63a4f
commit
6456999731
|
@ -379,7 +379,7 @@ static int rb4xx_spi_probe(struct platform_device *pdev)
|
||||||
err_iounmap:
|
err_iounmap:
|
||||||
iounmap(rbspi->base);
|
iounmap(rbspi->base);
|
||||||
err_clk_disable:
|
err_clk_disable:
|
||||||
clk_disable(rbspi->ahb_clk);
|
clk_disable_unprepare(rbspi->ahb_clk);
|
||||||
err_clk_put:
|
err_clk_put:
|
||||||
clk_put(rbspi->ahb_clk);
|
clk_put(rbspi->ahb_clk);
|
||||||
err_put_master:
|
err_put_master:
|
||||||
|
@ -394,7 +394,7 @@ static int rb4xx_spi_remove(struct platform_device *pdev)
|
||||||
struct rb4xx_spi *rbspi = platform_get_drvdata(pdev);
|
struct rb4xx_spi *rbspi = platform_get_drvdata(pdev);
|
||||||
|
|
||||||
iounmap(rbspi->base);
|
iounmap(rbspi->base);
|
||||||
clk_disable(rbspi->ahb_clk);
|
clk_disable_unprepare(rbspi->ahb_clk);
|
||||||
clk_put(rbspi->ahb_clk);
|
clk_put(rbspi->ahb_clk);
|
||||||
platform_set_drvdata(pdev, NULL);
|
platform_set_drvdata(pdev, NULL);
|
||||||
spi_master_put(rbspi->master);
|
spi_master_put(rbspi->master);
|
||||||
|
|
Loading…
Reference in New Issue