watchdog: coh901327_wdt: Simplify error handling in probe function
[sfrench/cifs-2.6.git] / drivers / watchdog / coh901327_wdt.c
index a099b77fc0b91a076302f6657aaf87d4be9ed159..dc97b2fd6c49028e6a38ff15f1493aa1512a744d 100644 (file)
@@ -360,12 +360,10 @@ static int __init coh901327_probe(struct platform_device *pdev)
 
        coh901327_wdt.parent = &pdev->dev;
        ret = watchdog_register_device(&coh901327_wdt);
-       if (ret == 0)
-               dev_info(&pdev->dev,
-                        "initialized. timer margin=%d sec\n", margin);
-       else
+       if (ret)
                goto out_no_wdog;
 
+       dev_info(&pdev->dev, "initialized. timer margin=%d sec\n", margin);
        return 0;
 
 out_no_wdog: