Skip to content

Commit

Permalink
unreachable code in drms_uA_update()
Browse files Browse the repository at this point in the history
I removed the extra semi-colon and indented the return statement.

The unreachable code was found by smatch (http://repo.or.cz/w/smatch.git).
The patch was compile tested.

regards,
dan carpenter

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
  • Loading branch information
Dan Carpenter authored and Liam Girdwood committed Apr 28, 2009
1 parent 9f65325 commit 036de8e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/regulator/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -540,8 +540,8 @@ static void drms_uA_update(struct regulator_dev *rdev)

err = regulator_check_drms(rdev);
if (err < 0 || !rdev->desc->ops->get_optimum_mode ||
!rdev->desc->ops->get_voltage || !rdev->desc->ops->set_mode);
return;
!rdev->desc->ops->get_voltage || !rdev->desc->ops->set_mode)
return;

/* get output voltage */
output_uV = rdev->desc->ops->get_voltage(rdev);
Expand Down

0 comments on commit 036de8e

Please sign in to comment.