regulator: cpr3-util: add missing error code return statement
Change 64fec1f302ee21759bb4c6d7178a5d8a0aefe779 ("regulator: cpr3-regulator: add support for CPRh-compliant controllers") refactored cpr3_parse_common_ctrl_data() and introduced a bug returning the error code after a VDD regulator get failure. Fix this. Change-Id: I486151ce61dab3c3f5a05daa2325386aacdd9960 CRs-Fixed: 984037 Signed-off-by: Osvaldo Banuelos <osvaldob@codeaurora.org>
This commit is contained in:
parent
a6edd41539
commit
70dcea8217
1 changed files with 2 additions and 3 deletions
|
@ -1059,11 +1059,10 @@ int cpr3_parse_common_ctrl_data(struct cpr3_controller *ctrl)
|
|||
ctrl->vdd_regulator = devm_regulator_get(ctrl->dev, "vdd");
|
||||
if (IS_ERR(ctrl->vdd_regulator)) {
|
||||
rc = PTR_ERR(ctrl->vdd_regulator);
|
||||
if (rc != -EPROBE_DEFER) {
|
||||
if (rc != -EPROBE_DEFER)
|
||||
cpr3_err(ctrl, "unable request vdd regulator, rc=%d\n",
|
||||
rc);
|
||||
return rc;
|
||||
}
|
||||
return rc;
|
||||
}
|
||||
|
||||
ctrl->system_regulator = devm_regulator_get_optional(ctrl->dev,
|
||||
|
|
Loading…
Add table
Reference in a new issue