diff options
author | Akinobu Mita <akinobu.mita@gmail.com> | 2006-12-19 03:51:44 -0500 |
---|---|---|
committer | Wim Van Sebroeck <wim@iguana.be> | 2006-12-19 16:16:51 -0500 |
commit | 9cd446198e7646431a7f2ce7dbeec8df9f77012b (patch) | |
tree | ab2bb2cf8eff7c7e75b8cf34174692c02ebdd8be /drivers/char/watchdog/s3c2410_wdt.c | |
parent | 0b6dd8a640fbaf73b74949b6dc2be50263532576 (diff) |
[WATCHDOG] fix clk_get() error check
The return value of clk_get() should be checked by IS_ERR().
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
Diffstat (limited to 'drivers/char/watchdog/s3c2410_wdt.c')
-rw-r--r-- | drivers/char/watchdog/s3c2410_wdt.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/char/watchdog/s3c2410_wdt.c b/drivers/char/watchdog/s3c2410_wdt.c index d3c073787f5b..5a5cc2a2c5af 100644 --- a/drivers/char/watchdog/s3c2410_wdt.c +++ b/drivers/char/watchdog/s3c2410_wdt.c | |||
@@ -393,9 +393,9 @@ static int s3c2410wdt_probe(struct platform_device *pdev) | |||
393 | } | 393 | } |
394 | 394 | ||
395 | wdt_clock = clk_get(&pdev->dev, "watchdog"); | 395 | wdt_clock = clk_get(&pdev->dev, "watchdog"); |
396 | if (wdt_clock == NULL) { | 396 | if (IS_ERR(wdt_clock)) { |
397 | printk(KERN_INFO PFX "failed to find watchdog clock source\n"); | 397 | printk(KERN_INFO PFX "failed to find watchdog clock source\n"); |
398 | ret = -ENOENT; | 398 | ret = PTR_ERR(wdt_clock); |
399 | goto err_irq; | 399 | goto err_irq; |
400 | } | 400 | } |
401 | 401 | ||