Skip to content

Commit

Permalink
iio: adc: vf610: Return the error code directly
Browse files Browse the repository at this point in the history
There is no need to pass the error clock code to the variable 'ret'.

Just return the error directly.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
  • Loading branch information
Fabio Estevam authored and Jonathan Cameron committed Oct 4, 2014
1 parent 7be178b commit 2e3d667
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/iio/adc/vf610_adc.c
Original file line number Diff line number Diff line change
Expand Up @@ -610,8 +610,7 @@ static int vf610_adc_probe(struct platform_device *pdev)
if (IS_ERR(info->clk)) {
dev_err(&pdev->dev, "failed getting clock, err = %ld\n",
PTR_ERR(info->clk));
ret = PTR_ERR(info->clk);
return ret;
return PTR_ERR(info->clk);
}

info->vref = devm_regulator_get(&pdev->dev, "vref");
Expand Down

0 comments on commit 2e3d667

Please sign in to comment.