[PATCHv7 5/7] mfd: twl-core: pass driver data from pdata to add_regulator for VDD1 and VDD2

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

 



This way, we can add custom flags for VDD1 and VDD2 regulators that
get passed all the way to regulator init. This is needed for SMPS
regulator support to select used controller mode for these regulators
(either voltage processor or default.)

Signed-off-by: Tero Kristo <t-kristo@xxxxxx>
Cc: Samuel Ortiz <sameo@xxxxxxxxxxxxxxx>
---
 drivers/mfd/twl-core.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/mfd/twl-core.c b/drivers/mfd/twl-core.c
index 01ecfee..af93fce 100644
--- a/drivers/mfd/twl-core.c
+++ b/drivers/mfd/twl-core.c
@@ -846,12 +846,14 @@ add_children(struct twl4030_platform_data *pdata, unsigned long features)
 			return PTR_ERR(child);
 
 		child = add_regulator(TWL4030_REG_VDD1, pdata->vdd1,
-					features);
+					features |
+					(u32)pdata->vdd1->driver_data);
 		if (IS_ERR(child))
 			return PTR_ERR(child);
 
 		child = add_regulator(TWL4030_REG_VDD2, pdata->vdd2,
-					features);
+					features |
+					(u32)pdata->vdd2->driver_data);
 		if (IS_ERR(child))
 			return PTR_ERR(child);
 
-- 
1.7.4.1

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


[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux