Commit 1016daf9 authored by Marek Behún's avatar Marek Behún Committed by Pavel Machek

leds: pm8058: cosmetic change: no need to return in if guard

We can return the last ret value.
Signed-off-by: default avatarMarek Behún <marek.behun@nic.cz>
Cc: Linus Walleij <linus.walleij@linaro.org>
Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: default avatarPavel Machek <pavel@ucw.cz>
parent fb270ba0
......@@ -147,12 +147,10 @@ static int pm8058_led_probe(struct platform_device *pdev)
init_data.fwnode = of_fwnode_handle(np);
ret = devm_led_classdev_register_ext(dev, &led->cdev, &init_data);
if (ret) {
if (ret)
dev_err(dev, "Failed to register LED for %pOF\n", np);
return ret;
}
return 0;
return ret;
}
static const struct of_device_id pm8058_leds_id_table[] = {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment