diff options
-rw-r--r-- | drivers/hwmon/it87.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/hwmon/it87.c b/drivers/hwmon/it87.c index 68c8d98..9b36987 100644 --- a/drivers/hwmon/it87.c +++ b/drivers/hwmon/it87.c @@ -2898,14 +2898,11 @@ static int __init it87_device_add(unsigned short address, err = acpi_check_resource_conflict(&res); if (err) - goto exit; + return err; pdev = platform_device_alloc(DRVNAME, address); - if (!pdev) { - err = -ENOMEM; - pr_err("Device allocation failed\n"); - goto exit; - } + if (!pdev) + return -ENOMEM; err = platform_device_add_resources(pdev, &res, 1); if (err) { @@ -2930,7 +2927,6 @@ static int __init it87_device_add(unsigned short address, exit_device_put: platform_device_put(pdev); -exit: return err; } |