summaryrefslogtreecommitdiff
path: root/drivers/regulator/palmas-regulator.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/regulator/palmas-regulator.c')
-rw-r--r--drivers/regulator/palmas-regulator.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/regulator/palmas-regulator.c b/drivers/regulator/palmas-regulator.c
index 6c9670ff6be5..b5278ac4e6bd 100644
--- a/drivers/regulator/palmas-regulator.c
+++ b/drivers/regulator/palmas-regulator.c
@@ -1037,10 +1037,8 @@ static int palmas_regulators_probe(struct platform_device *pdev)
else
ret = palmas_extreg_init(palmas,
id, reg_init);
- if (ret) {
- regulator_unregister(pmic->rdev[id]);
+ if (ret)
return ret;
- }
}
}
}