Skip to content

Commit 6d8d840

Browse files
RishiGupta12broonie
authored andcommitted
regulator: da9063: remove redundant return statement
The devm_request_threaded_irq() already returns 0 on success and negative error code on failure. So return from this itself can be used while preserving error log in case of failure. Signed-off-by: Rishi Gupta <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
1 parent a33b25f commit 6d8d840

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

drivers/regulator/da9063-regulator.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -877,12 +877,10 @@ static int da9063_regulator_probe(struct platform_device *pdev)
877877
NULL, da9063_ldo_lim_event,
878878
IRQF_TRIGGER_LOW | IRQF_ONESHOT,
879879
"LDO_LIM", regulators);
880-
if (ret) {
880+
if (ret)
881881
dev_err(&pdev->dev, "Failed to request LDO_LIM IRQ.\n");
882-
return ret;
883-
}
884882

885-
return 0;
883+
return ret;
886884
}
887885

888886
static struct platform_driver da9063_regulator_driver = {

0 commit comments

Comments
 (0)