aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--drivers/char/tlclk.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/char/tlclk.c b/drivers/char/tlclk.c
index 2444a0e24b3..244d30a03fe 100644
--- a/drivers/char/tlclk.c
+++ b/drivers/char/tlclk.c
@@ -792,15 +792,14 @@ static int __init tlclk_init(void)
ret = misc_register(&tlclk_miscdev);
if (ret < 0) {
printk(KERN_ERR "tlclk: misc_register returns %d.\n", ret);
- ret = -EBUSY;
goto out3;
}
tlclk_device = platform_device_register_simple("telco_clock",
-1, NULL, 0);
- if (!tlclk_device) {
+ if (IS_ERR(tlclk_device)) {
printk(KERN_ERR "tlclk: platform_device_register failed.\n");
- ret = -EBUSY;
+ ret = PTR_ERR(tlclk_device);
goto out4;
}