[RFC] bcm63xx-rng: use clk_{prepare_enable,disable_unprepare}

From: Jonas Gorski
Date: Sun Nov 11 2012 - 07:53:44 EST


Use proper clk_prepare/unprepare calls in preparation for switching to
the generic clock framework.

Signed-off-by: Jonas Gorski <jonas.gorski@xxxxxxxxx>
---
drivers/char/hw_random/bcm63xx-rng.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/char/hw_random/bcm63xx-rng.c b/drivers/char/hw_random/bcm63xx-rng.c
index aec6a42..3693f56 100644
--- a/drivers/char/hw_random/bcm63xx-rng.c
+++ b/drivers/char/hw_random/bcm63xx-rng.c
@@ -122,7 +122,7 @@ static int __devinit bcm63xx_rng_probe(struct platform_device *pdev)
goto out_free_rng;
}

- clk_enable(clk);
+ clk_prepare_enable(clk);

ret = hwrng_register(rng);
if (ret) {
@@ -135,7 +135,7 @@ static int __devinit bcm63xx_rng_probe(struct platform_device *pdev)
return 0;

out_clk_disable:
- clk_disable(clk);
+ clk_disable_unprepare(clk);
out_free_rng:
platform_set_drvdata(pdev, NULL);
kfree(rng);
@@ -151,7 +151,7 @@ static int __devexit bcm63xx_rng_remove(struct platform_device *pdev)
struct bcm63xx_rng_priv *priv = to_rng_priv(rng);

hwrng_unregister(rng);
- clk_disable(priv->clk);
+ clk_disable_unprepare(priv->clk);
kfree(priv);
kfree(rng);
platform_set_drvdata(pdev, NULL);
--
1.7.2.5

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/