Commit 477b2bac authored by Fabio Estevam's avatar Fabio Estevam Committed by Mark Brown

regulator: wm831x-dcdc: Remove unneeded 'err' label

There is no need to jump to the 'err' label.

Returnn the error directly instead.
Signed-off-by: default avatarFabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent 6ce4eac1
...@@ -762,8 +762,7 @@ static int wm831x_boostp_probe(struct platform_device *pdev) ...@@ -762,8 +762,7 @@ static int wm831x_boostp_probe(struct platform_device *pdev)
res = platform_get_resource(pdev, IORESOURCE_REG, 0); res = platform_get_resource(pdev, IORESOURCE_REG, 0);
if (res == NULL) { if (res == NULL) {
dev_err(&pdev->dev, "No REG resource\n"); dev_err(&pdev->dev, "No REG resource\n");
ret = -EINVAL; return -EINVAL;
goto err;
} }
dcdc->base = res->start; dcdc->base = res->start;
...@@ -788,7 +787,7 @@ static int wm831x_boostp_probe(struct platform_device *pdev) ...@@ -788,7 +787,7 @@ static int wm831x_boostp_probe(struct platform_device *pdev)
ret = PTR_ERR(dcdc->regulator); ret = PTR_ERR(dcdc->regulator);
dev_err(wm831x->dev, "Failed to register DCDC%d: %d\n", dev_err(wm831x->dev, "Failed to register DCDC%d: %d\n",
id + 1, ret); id + 1, ret);
goto err; return ret;
} }
irq = wm831x_irq(wm831x, platform_get_irq_byname(pdev, "UV")); irq = wm831x_irq(wm831x, platform_get_irq_byname(pdev, "UV"));
...@@ -799,15 +798,12 @@ static int wm831x_boostp_probe(struct platform_device *pdev) ...@@ -799,15 +798,12 @@ static int wm831x_boostp_probe(struct platform_device *pdev)
if (ret != 0) { if (ret != 0) {
dev_err(&pdev->dev, "Failed to request UV IRQ %d: %d\n", dev_err(&pdev->dev, "Failed to request UV IRQ %d: %d\n",
irq, ret); irq, ret);
goto err; return ret;
} }
platform_set_drvdata(pdev, dcdc); platform_set_drvdata(pdev, dcdc);
return 0; return 0;
err:
return ret;
} }
static struct platform_driver wm831x_boostp_driver = { static struct platform_driver wm831x_boostp_driver = {
......
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