summaryrefslogtreecommitdiff
path: root/src/mainboard/google/peach_pit/romstage.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainboard/google/peach_pit/romstage.c')
-rw-r--r--src/mainboard/google/peach_pit/romstage.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/mainboard/google/peach_pit/romstage.c b/src/mainboard/google/peach_pit/romstage.c
index 16dc997e75..248809d1a2 100644
--- a/src/mainboard/google/peach_pit/romstage.c
+++ b/src/mainboard/google/peach_pit/romstage.c
@@ -97,13 +97,10 @@ static int setup_power(int is_resume)
uint8_t reg = pmic_writes[i].reg;
if (pmic_writes[i].or_orig)
- error |= i2c_read(4, MAX77802_I2C_ADDR,
- reg, sizeof(reg),
- &data, sizeof(data));
+ error |= i2c_readb(4, MAX77802_I2C_ADDR, reg, &data);
+
data |= pmic_writes[i].val;
- error |= i2c_write(4, MAX77802_I2C_ADDR,
- reg, sizeof(reg),
- &data, sizeof(data));
+ error |= i2c_writeb(4, MAX77802_I2C_ADDR, reg, data);
}
return error;