power: pmic: tps65218: Fix tps65218_voltage_update function
PATCH 1/1 power: pmic: tps65218: Fix tps65218_voltage_update function
Currently while setting the vsel value for dcdc1 and dcdc2 the driver is wrongly masking the entire 8 bits in the process clearing PFM (bit7) field as well. Hence describe an appropriate mask for vsel field and modify only those bits in the vsel mask.
Source: http://www.ti.com/lit/ds/symlink/tps65218.pdf
--- drivers/power/pmic/pmic_tps65218.c | 2 +- include/power/tps65218.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-)
drivers/power/pmic/pmic_tps65218.c +1 -1
@@ -101,7 +101,7 @@ int tps65218_voltage_update(uchar dc_cntrl_reg, uchar volt_sel)/* set voltage level */ if (tps65218_reg_write (TPS65218_PROT_LEVEL_2 , dc_cntrl_reg, volt_sel, -TPS65218_MASK_ALL_BITS )) +TPS65218_DCDC_VSEL_MASK ))return 1 ;/* set GO bit to initiate voltage transition */
include/power/tps65218.h +2 -0
@@ -56,6 +56,8 @@ enum {#define TPS65218_MASK_ALL_BITS 0xFF +#define TPS65218_DCDC_VSEL_MASK 0x3F +#define TPS65218_DCDC_VOLT_SEL_0950MV 0x0a#define TPS65218_DCDC_VOLT_SEL_1100MV 0x19#define TPS65218_DCDC_VOLT_SEL_1200MV 0x23
Signature · 1 line
1.9.1
PATCH 1/1 power: pmic: tps65218: Fix tps65218_voltage_update function
Quoted 10 lines · Keerthy
Currently while setting the vsel value for dcdc1 and dcdc2 the driver is wrongly masking the entire 8 bits in the process clearing PFM (bit7) field as well. Hence describe an appropriate mask for vsel field and modify only those bits in the vsel mask.
Source: http://www.ti.com/lit/ds/symlink/tps65218.pdf
Signed-off-by Keerthy <[email protected]>Fixes 86db550b38 ("power: Add support for the TPS65218 PMIC")
If delegate to me..i will pick this.
Quoted 32 lines
--- drivers/power/pmic/pmic_tps65218.c | 2 +- include/power/tps65218.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-)drivers/power/pmic/pmic_tps65218.c +1
-1@@ -101,7 +101,7 @@ int tps65218_voltage_update(uchar dc_cntrl_reg, uchar volt_sel)/* set voltage level */ if (tps65218_reg_write (TPS65218_PROT_LEVEL_2 , dc_cntrl_reg, volt_sel, -TPS65218_MASK_ALL_BITS )) +TPS65218_DCDC_VSEL_MASK ))return 1 ;/* set GO bit to initiate voltage transition */ include/power/tps65218.h +2
-0@@ -56,6 +56,8 @@ enum {#define TPS65218_MASK_ALL_BITS 0xFF +#define TPS65218_DCDC_VSEL_MASK 0x3F +#define TPS65218_DCDC_VOLT_SEL_0950MV 0x0a#define TPS65218_DCDC_VOLT_SEL_1100MV 0x19#define TPS65218_DCDC_VOLT_SEL_1200MV 0x23
PATCH 1/1 power: pmic: tps65218: Fix tps65218_voltage_update function
Quoted 7 lines · Jaehoon Chung
Quoted 6 lines · Keerthy
Currently while setting the vsel value for dcdc1 and dcdc2 the driver is wrongly masking the entire 8 bits in the process clearing PFM (bit7) field as well. Hence describe an appropriate mask for vsel field and modify only those bits in the vsel mask.
Quoted 8 lines
Quoted 4 lines
Source: http://www.ti.com/lit/ds/symlink/tps65218.pdf
Signed-off-by Keerthy <[email protected]>Fixes 86db550b38 ("power: Add support for the TPS65218 PMIC")If delegate to me..i will pick this.
Reviewed-by Jaehoon Chung <[email protected]>
Thanks Jaehoon Chung.
Quoted 34 lines
Quoted 33 lines
--- drivers/power/pmic/pmic_tps65218.c | 2 +- include/power/tps65218.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-)drivers/power/pmic/pmic_tps65218.c +1
-1@@ -101,7 +101,7 @@ int tps65218_voltage_update(uchar dc_cntrl_reg, uchar volt_sel)/* set voltage level */ if (tps65218_reg_write (TPS65218_PROT_LEVEL_2 , dc_cntrl_reg, volt_sel, -TPS65218_MASK_ALL_BITS )) +TPS65218_DCDC_VSEL_MASK ))return 1 ;/* set GO bit to initiate voltage transition */ include/power/tps65218.h +2
-0@@ -56,6 +56,8 @@ enum {#define TPS65218_MASK_ALL_BITS 0xFF +#define TPS65218_DCDC_VSEL_MASK 0x3F +#define TPS65218_DCDC_VOLT_SEL_0950MV 0x0a#define TPS65218_DCDC_VOLT_SEL_1100MV 0x19#define TPS65218_DCDC_VOLT_SEL_1200MV 0x23
PATCH 1/1 power: pmic: tps65218: Fix tps65218_voltage_update function
Quoted 12 lines · Keerthy
Quoted 9 lines · Jaehoon Chung
Quoted 8 lines · Keerthy
Currently while setting the vsel value for dcdc1 and dcdc2 the driver is wrongly masking the entire 8 bits in the process clearing PFM (bit7) field as well. Hence describe an appropriate mask for vsel field and modify only those bits in the vsel mask.
Quoted 8 lines
Quoted 6 lines
Quoted 2 lines
Signed-off-by Keerthy <[email protected]>Fixes 86db550b38 ("power: Add support for the TPS65218 PMIC")If delegate to me..i will pick this.
Reviewed-by Jaehoon Chung <[email protected]>Thanks Jaehoon Chung.
Applied to u-boot-mmc. Thanks
Jaehoon Chung
Quoted 38 lines
Quoted 35 lines
Quoted 34 lines
--- drivers/power/pmic/pmic_tps65218.c | 2 +- include/power/tps65218.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-)drivers/power/pmic/pmic_tps65218.c +1
-1@@ -101,7 +101,7 @@ int tps65218_voltage_update(uchar dc_cntrl_reg, uchar volt_sel)/* set voltage level */ if (tps65218_reg_write (TPS65218_PROT_LEVEL_2 , dc_cntrl_reg, volt_sel, -TPS65218_MASK_ALL_BITS )) +TPS65218_DCDC_VSEL_MASK ))return 1 ;/* set GO bit to initiate voltage transition */ include/power/tps65218.h +2
-0@@ -56,6 +56,8 @@ enum {#define TPS65218_MASK_ALL_BITS 0xFF +#define TPS65218_DCDC_VSEL_MASK 0x3F +#define TPS65218_DCDC_VOLT_SEL_0950MV 0x0a#define TPS65218_DCDC_VOLT_SEL_1100MV 0x19#define TPS65218_DCDC_VOLT_SEL_1200MV 0x23
PATCH 1/1 power: pmic: tps65218: Fix tps65218_voltage_update function
In reply to Jaehoon ChungQuoted 7 lines · Jaehoon Chung
Quoted 6 lines · Keerthy
Currently while setting the vsel value for dcdc1 and dcdc2 the driver is wrongly masking the entire 8 bits in the process clearing PFM (bit7) field as well. Hence describe an appropriate mask for vsel field and modify only those bits in the vsel mask.
Quoted 6 lines
Quoted 4 lines
Source: http://www.ti.com/lit/ds/symlink/tps65218.pdf
Signed-off-by Keerthy <[email protected]>Fixes 86db550b38 ("power: Add support for the TPS65218 PMIC")If delegate to me..i will pick this.
Feel free (always!) to grab things in patchwork that are in your areas, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20170525/9414a364/attachment.sig>
PATCH 1/1 power: pmic: tps65218: Fix tps65218_voltage_update function
Quoted 10 lines · Tom Rini
Quoted 9 lines · Jaehoon Chung
Quoted 8 lines · Keerthy
Currently while setting the vsel value for dcdc1 and dcdc2 the driver is wrongly masking the entire 8 bits in the process clearing PFM (bit7) field as well. Hence describe an appropriate mask for vsel field and modify only those bits in the vsel mask.
Quoted 7 lines
Quoted 4 lines
Quoted 2 lines
Signed-off-by Keerthy <[email protected]>Fixes 86db550b38 ("power: Add support for the TPS65218 PMIC")If delegate to me..i will pick this.
Feel free (always!) to grab things in patchwork that are in your areas, thanks!
Thanks!