[PATCH] regulator: core: use correct device for device supply lookup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



When registering the regulator driver, use the rdev->dev for
getting the regulator device of given supply instead of parent
device.

Signed-off-by: Laxman Dewangan <ldewangan@xxxxxxxxxx>
---
 drivers/regulator/core.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
index 7584a74..f820137 100644
--- a/drivers/regulator/core.c
+++ b/drivers/regulator/core.c
@@ -3150,7 +3150,7 @@ regulator_register(const struct regulator_desc *regulator_desc,
 	if (supply) {
 		struct regulator_dev *r;
 
-		r = regulator_dev_lookup(dev, supply, &ret);
+		r = regulator_dev_lookup(&rdev->dev, supply, &ret);
 
 		if (!r) {
 			dev_err(dev, "Failed to find supply %s\n", supply);
-- 
1.7.1.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[Index of Archives]

  Powered by Linux

[Older Kernel Discussion]     [Yosemite National Park Forum]     [Large Format Photos]     [Gimp]     [Yosemite Photos]     [Stuff]     [Index of Other Archives]