Browse Source

regulator: da9055: Do not hardcode return value

Propagate the error value returned by the function instead.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@linaro.org>
Sachin Kamat 11 years ago
parent
commit
fe2eb72218
1 changed files with 1 additions and 1 deletions
  1. 1 1
      drivers/regulator/da9055-regulator.c

+ 1 - 1
drivers/regulator/da9055-regulator.c

@@ -567,7 +567,7 @@ static int da9055_regulator_dt_init(struct platform_device *pdev,
 	of_node_put(nproot);
 	if (ret < 0) {
 		dev_err(&pdev->dev, "Error matching regulator: %d\n", ret);
-		return -ENODEV;
+		return ret;
 	}
 
 	config->init_data = da9055_reg_matches[regid].init_data;