diff options
Diffstat (limited to 'drivers/regulator')
-rw-r--r-- | drivers/regulator/core.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c index 711fa1722bce..27d062e1395c 100644 --- a/drivers/regulator/core.c +++ b/drivers/regulator/core.c | |||
@@ -1269,7 +1269,9 @@ static int _regulator_enable(struct regulator_dev *rdev) | |||
1269 | 1269 | ||
1270 | /* do we need to enable the supply regulator first */ | 1270 | /* do we need to enable the supply regulator first */ |
1271 | if (rdev->supply) { | 1271 | if (rdev->supply) { |
1272 | mutex_lock(&rdev->supply->mutex); | ||
1272 | ret = _regulator_enable(rdev->supply); | 1273 | ret = _regulator_enable(rdev->supply); |
1274 | mutex_unlock(&rdev->supply->mutex); | ||
1273 | if (ret < 0) { | 1275 | if (ret < 0) { |
1274 | printk(KERN_ERR "%s: failed to enable %s: %d\n", | 1276 | printk(KERN_ERR "%s: failed to enable %s: %d\n", |
1275 | __func__, rdev_get_name(rdev), ret); | 1277 | __func__, rdev_get_name(rdev), ret); |