Skip to contentSkip to conversation

regulator: tps65023: Fix mask for LDOs output voltage select control

PATCH Applied Axel Lin 2 participants 2 messages Jun 14, 2012 – Jun 17, 2012 Voltage and current regulator framework

lore
Share & tools
lore

Axel Lin

author
#0 lore raw

PATCH 1/1 regulator: tps65023: Fix mask for LDOs output voltage select control

According to the datasheet:
The LDO_CTRL registers are used to set the output voltage of LDO1 and LDO2. LDO_CTRL[7] and LDO_CTRL[3] are reserved and should always be written to 0.

Thus the mask for TPS65023_LDO_1 and TPS65023_LDO_2 should be 0x07 and 0x70 respectively.

---
 drivers/regulator/tps65023-regulator.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/regulator/tps65023-regulator.c +1 -1
index df8b70d..6fab428 100644
@@ -71,7 +71,7 @@
 
 /* LDO_CTRL bitfields */
 #define TPS65023_LDO_CTRL_LDOx_SHIFT(ldo_id)	((ldo_id)*4)
-#define TPS65023_LDO_CTRL_LDOx_MASK(ldo_id)	(0x0F << ((ldo_id)*4))
+#define TPS65023_LDO_CTRL_LDOx_MASK(ldo_id)	(0x07 << ((ldo_id)*4))
 
 /* Number of step-down converters available */
 #define TPS65023_NUM_DCDC		3
Signature · 1 line
1.7.9.5
Applied
#1 lore raw
Quoted 3 lines · Axel Lin

According to the datasheet:
The LDO_CTRL registers are used to set the output voltage of LDO1 and LDO2. LDO_CTRL[7] and LDO_CTRL[3] are reserved and should always be written to 0.

Applied, thanks.