Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 292003
b: refs/heads/master
c: b29c769
h: refs/heads/master
i:
  292001: 3eb9174
  291999: 491d814
v: v3
  • Loading branch information
Axel Lin authored and Mark Brown committed Feb 20, 2012
1 parent 3d3b74b commit c37ba8e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: fde297bb4d8075229b8985e9d4f96d32339a8e68
refs/heads/master: b29c7690a764b9829b1034f873f97b7bbfa19565
11 changes: 4 additions & 7 deletions trunk/drivers/regulator/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -2397,7 +2397,7 @@ int regulator_bulk_get(struct device *dev, int num_consumers,
return 0;

err:
for (i = 0; i < num_consumers && consumers[i].consumer; i++)
while (--i >= 0)
regulator_put(consumers[i].consumer);

return ret;
Expand Down Expand Up @@ -2447,12 +2447,9 @@ int regulator_bulk_enable(int num_consumers,
return 0;

err:
for (i = 0; i < num_consumers; i++)
if (consumers[i].ret == 0)
regulator_disable(consumers[i].consumer);
else
pr_err("Failed to enable %s: %d\n",
consumers[i].supply, consumers[i].ret);
pr_err("Failed to enable %s: %d\n", consumers[i].supply, ret);
while (--i >= 0)
regulator_disable(consumers[i].consumer);

return ret;
}
Expand Down

0 comments on commit c37ba8e

Please sign in to comment.