diff options
author | Heiko Stübner <heiko@sntech.de> | 2013-06-26 22:04:31 +0400 |
---|---|---|
committer | Wim Van Sebroeck <wim@iguana.be> | 2013-11-17 22:33:56 +0400 |
commit | 280103e6b5de6ae1e23d9067202cdd67dd06b490 (patch) | |
tree | 84c68e89e3b12c87b98e885f1b889f187992b4b6 | |
parent | ad83c6cbf30eba322fbc822453316a4954d9b607 (diff) | |
download | linux-280103e6b5de6ae1e23d9067202cdd67dd06b490.tar.xz |
watchdog: dw_wdt: use clk_prepare_enable and clk_disable_unprepare
This is necessary to make the driver work with platforms using the
common clock framework.
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
-rw-r--r-- | drivers/watchdog/dw_wdt.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/watchdog/dw_wdt.c b/drivers/watchdog/dw_wdt.c index 4d3906d7c9a5..b922bec45d15 100644 --- a/drivers/watchdog/dw_wdt.c +++ b/drivers/watchdog/dw_wdt.c @@ -255,14 +255,14 @@ static int dw_wdt_release(struct inode *inode, struct file *filp) #ifdef CONFIG_PM_SLEEP static int dw_wdt_suspend(struct device *dev) { - clk_disable(dw_wdt.clk); + clk_disable_unprepare(dw_wdt.clk); return 0; } static int dw_wdt_resume(struct device *dev) { - int err = clk_enable(dw_wdt.clk); + int err = clk_prepare_enable(dw_wdt.clk); if (err) return err; @@ -306,7 +306,7 @@ static int dw_wdt_drv_probe(struct platform_device *pdev) if (IS_ERR(dw_wdt.clk)) return PTR_ERR(dw_wdt.clk); - ret = clk_enable(dw_wdt.clk); + ret = clk_prepare_enable(dw_wdt.clk); if (ret) return ret; @@ -323,7 +323,7 @@ static int dw_wdt_drv_probe(struct platform_device *pdev) return 0; out_disable_clk: - clk_disable(dw_wdt.clk); + clk_disable_unprepare(dw_wdt.clk); return ret; } @@ -332,7 +332,7 @@ static int dw_wdt_drv_remove(struct platform_device *pdev) { misc_deregister(&dw_wdt_miscdev); - clk_disable(dw_wdt.clk); + clk_disable_unprepare(dw_wdt.clk); return 0; } |