mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-31 04:01:48 -04:00
watchdog: davinci: Handle return value of clk_prepare_enable
clk_prepare_enable() can fail here and we must check its return value. Signed-off-by: Arvind Yadav <[email protected]> Reviewed-by: Guenter Roeck <[email protected]> Signed-off-by: Guenter Roeck <[email protected]> Signed-off-by: Wim Van Sebroeck <[email protected]>
This commit is contained in:
parent
65360944c1
commit
8f11eb58ad
1 changed files with 5 additions and 1 deletions
|
|
@ -173,7 +173,11 @@ static int davinci_wdt_probe(struct platform_device *pdev)
|
|||
return PTR_ERR(davinci_wdt->clk);
|
||||
}
|
||||
|
||||
clk_prepare_enable(davinci_wdt->clk);
|
||||
ret = clk_prepare_enable(davinci_wdt->clk);
|
||||
if (ret) {
|
||||
dev_err(&pdev->dev, "failed to prepare clock\n");
|
||||
return ret;
|
||||
}
|
||||
|
||||
platform_set_drvdata(pdev, davinci_wdt);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue