diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2015-10-07 09:11:47 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2015-10-07 09:11:47 -0400 |
commit | 21f3c96188f1a1e592174bef3180d147e06f7b89 (patch) | |
tree | 8d35b5caf18798c1550bff7cabc4b828945b1c32 | |
parent | 79c7c7acd25689b1d7669bdb33fb3cb7c64541fe (diff) | |
parent | 22ca03a3ad63bb08d543af462b741b6bf2c329ed (diff) |
Merge tag 'regulator-fix-v4.3-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator
Pull regulator fixes from Mark Brown:
"Two fixes here, one device specific fix for axp20x and a core fix for
cases where one regulator is supplying another which broke probe
deferral, substituting in a dummy regulator too aggressively"
* tag 'regulator-fix-v4.3-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator:
regulator: core: Handle probe deferral from DT when resolving supplies
regulator: axp20x: Fix enable bit indexes for DCDC4 and DCDC5
-rw-r--r-- | drivers/regulator/axp20x-regulator.c | 4 | ||||
-rw-r--r-- | drivers/regulator/core.c | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/drivers/regulator/axp20x-regulator.c b/drivers/regulator/axp20x-regulator.c index 01bf3476a791..a9567af7cec0 100644 --- a/drivers/regulator/axp20x-regulator.c +++ b/drivers/regulator/axp20x-regulator.c | |||
@@ -192,9 +192,9 @@ static const struct regulator_desc axp22x_regulators[] = { | |||
192 | AXP_DESC(AXP22X, DCDC3, "dcdc3", "vin3", 600, 1860, 20, | 192 | AXP_DESC(AXP22X, DCDC3, "dcdc3", "vin3", 600, 1860, 20, |
193 | AXP22X_DCDC3_V_OUT, 0x3f, AXP22X_PWR_OUT_CTRL1, BIT(3)), | 193 | AXP22X_DCDC3_V_OUT, 0x3f, AXP22X_PWR_OUT_CTRL1, BIT(3)), |
194 | AXP_DESC(AXP22X, DCDC4, "dcdc4", "vin4", 600, 1540, 20, | 194 | AXP_DESC(AXP22X, DCDC4, "dcdc4", "vin4", 600, 1540, 20, |
195 | AXP22X_DCDC4_V_OUT, 0x3f, AXP22X_PWR_OUT_CTRL1, BIT(3)), | 195 | AXP22X_DCDC4_V_OUT, 0x3f, AXP22X_PWR_OUT_CTRL1, BIT(4)), |
196 | AXP_DESC(AXP22X, DCDC5, "dcdc5", "vin5", 1000, 2550, 50, | 196 | AXP_DESC(AXP22X, DCDC5, "dcdc5", "vin5", 1000, 2550, 50, |
197 | AXP22X_DCDC5_V_OUT, 0x1f, AXP22X_PWR_OUT_CTRL1, BIT(4)), | 197 | AXP22X_DCDC5_V_OUT, 0x1f, AXP22X_PWR_OUT_CTRL1, BIT(5)), |
198 | /* secondary switchable output of DCDC1 */ | 198 | /* secondary switchable output of DCDC1 */ |
199 | AXP_DESC_SW(AXP22X, DC1SW, "dc1sw", "dcdc1", 1600, 3400, 100, | 199 | AXP_DESC_SW(AXP22X, DC1SW, "dc1sw", "dcdc1", 1600, 3400, 100, |
200 | AXP22X_DCDC1_V_OUT, 0x1f, AXP22X_PWR_OUT_CTRL2, BIT(7)), | 200 | AXP22X_DCDC1_V_OUT, 0x1f, AXP22X_PWR_OUT_CTRL2, BIT(7)), |
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c index 7849187d91ae..8a34f6acc801 100644 --- a/drivers/regulator/core.c +++ b/drivers/regulator/core.c | |||
@@ -1403,6 +1403,10 @@ static int regulator_resolve_supply(struct regulator_dev *rdev) | |||
1403 | return 0; | 1403 | return 0; |
1404 | } | 1404 | } |
1405 | 1405 | ||
1406 | /* Did the lookup explicitly defer for us? */ | ||
1407 | if (ret == -EPROBE_DEFER) | ||
1408 | return ret; | ||
1409 | |||
1406 | if (have_full_constraints()) { | 1410 | if (have_full_constraints()) { |
1407 | r = dummy_regulator_rdev; | 1411 | r = dummy_regulator_rdev; |
1408 | } else { | 1412 | } else { |