Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 270765
b: refs/heads/master
c: aa59802
h: refs/heads/master
i:
  270763: 445eab3
v: v3
  • Loading branch information
Mark Brown committed Oct 4, 2011
1 parent 7ee5445 commit 3056b7b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 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: 38f3f31a0a797bdbcc0cdb12553bbecc2f9a91c4
refs/heads/master: aa59802dedac98dc95310a456121cec6a9d6b63f
9 changes: 7 additions & 2 deletions trunk/drivers/regulator/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1599,13 +1599,18 @@ static void regulator_disable_work(struct work_struct *work)
int regulator_disable_deferred(struct regulator *regulator, int ms)
{
struct regulator_dev *rdev = regulator->rdev;
int ret;

mutex_lock(&rdev->mutex);
rdev->deferred_disables++;
mutex_unlock(&rdev->mutex);

return schedule_delayed_work(&rdev->disable_work,
msecs_to_jiffies(ms));
ret = schedule_delayed_work(&rdev->disable_work,
msecs_to_jiffies(ms));
if (ret < 0)
return ret;
else
return 0;
}
EXPORT_SYMBOL_GPL(regulator_disable_deferred);

Expand Down

0 comments on commit 3056b7b

Please sign in to comment.