summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/hwmon/jc42.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/hwmon/jc42.c b/drivers/hwmon/jc42.c
index f362cead837e..6013611e4f21 100644
--- a/drivers/hwmon/jc42.c
+++ b/drivers/hwmon/jc42.c
@@ -518,10 +518,7 @@ static int jc42_probe(struct i2c_client *client, const struct i2c_device_id *id)
hwmon_dev = devm_hwmon_device_register_with_groups(dev, client->name,
data,
jc42_groups);
- if (IS_ERR(hwmon_dev))
- return PTR_ERR(hwmon_dev);
-
- return 0;
+ return PTR_ERR_OR_ZERO(hwmon_dev);
}
static int jc42_remove(struct i2c_client *client)