mirror of
https://github.com/torvalds/linux.git
synced 2026-06-08 06:25:52 +02:00
tps65910:set dcdc time step 12.5mv/us
This commit is contained in:
parent
e609b8428a
commit
8283fc01e8
|
|
@ -92,7 +92,8 @@ int tps65910_pre_init(struct tps65910 *tps65910){
|
|||
}
|
||||
|
||||
val |= (1<<5); //when 1: 1.5 A
|
||||
val |= (0x07<<2); //TSTEP[2:0] = 111 : 2.5 mV/¦Ìs(sampling 3 Mhz/5)
|
||||
val &= (~(0x3 <<2));
|
||||
val |= (0x01<<2); //TSTEP[3:2] = 01 : 12.5 mV/us(sampling 3 Mhz)
|
||||
err = tps65910_reg_write(tps65910, TPS65910_VDD1, val);
|
||||
if (err) {
|
||||
printk(KERN_ERR "Unable to write TPS65910_VDD1 reg\n");
|
||||
|
|
@ -107,6 +108,8 @@ int tps65910_pre_init(struct tps65910 *tps65910){
|
|||
}
|
||||
|
||||
val |= (1<<5); //when 1: 1.5 A
|
||||
val &= (~(0x3 <<2));
|
||||
val |= (0x01<<2); //TSTEP[3:2] = 01 : 12.5 mV/us(sampling 3 Mhz)
|
||||
err = tps65910_reg_write(tps65910, TPS65910_VDD2, val);
|
||||
if (err) {
|
||||
printk(KERN_ERR "Unable to write TPS65910_VDD2 reg\n");
|
||||
|
|
|
|||
|
|
@ -936,7 +936,7 @@ static int tps65910_set_voltage_dcdc_time_sel(struct regulator_dev *dev,
|
|||
switch (id) {
|
||||
case TPS65910_REG_VDD1:
|
||||
case TPS65910_REG_VDD2:
|
||||
return DIV_ROUND_UP(abs(old_volt - new_volt), 12500);
|
||||
return DIV_ROUND_UP(abs(old_volt - new_volt)*2, 12500);
|
||||
case TPS65911_REG_VDDCTRL:
|
||||
return DIV_ROUND_UP(abs(old_volt - new_volt), 5000);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user