Skip to content

Commit

Permalink
watchdog: davinci_wdt: use devm managed clk get
Browse files Browse the repository at this point in the history
Get the clock using devm_clk_get().

Signed-off-by: Mrugesh Katepallewar <mrugesh.mk@ti.com>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
  • Loading branch information
Mrugesh Katepallewar authored and Wim Van Sebroeck committed Mar 1, 2013
1 parent a6a1bcd commit 362ce5a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/watchdog/davinci_wdt.c
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ static int davinci_wdt_probe(struct platform_device *pdev)
int ret = 0, size;
struct device *dev = &pdev->dev;

wdt_clk = clk_get(dev, NULL);
wdt_clk = devm_clk_get(dev, NULL);
if (WARN_ON(IS_ERR(wdt_clk)))
return PTR_ERR(wdt_clk);

Expand Down Expand Up @@ -257,7 +257,6 @@ static int davinci_wdt_remove(struct platform_device *pdev)
}

clk_disable_unprepare(wdt_clk);
clk_put(wdt_clk);

return 0;
}
Expand Down

0 comments on commit 362ce5a

Please sign in to comment.