summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKeith Short <keithshort@chromium.org>2021-09-16 14:49:11 -0600
committerCommit Bot <commit-bot@chromium.org>2021-09-17 19:03:14 +0000
commitc6be277af16926c2f780f84e1a307f2751814570 (patch)
tree7a0b82fc116a3961c8bd99c61fc0bd58e803360c
parentabc448dfbb68b8b94fbfaf1e8193d44b44cf1107 (diff)
downloadchrome-ec-c6be277af16926c2f780f84e1a307f2751814570.tar.gz
zephyr: herobrine_npcx9: Set TCPC I2C speed to 400 kHz
The PS8805 supports 1 MHz operation normally, but only 400 kHz operation during flash updates. The I2C passthru interface used by depthcharge doesn't support changing the I2C frequency or informing the EC that a firmware update is going to start, so the lower frequency must be used. BUG=b:199550987 BRANCH=none TEST=Verify PS8805-A3 firmware updates Signed-off-by: Keith Short <keithshort@chromium.org> Change-Id: I9be242ce03cc29c74559c6012b5cc83680b7b288 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3166998 Reviewed-by: Wai-Hong Tam <waihong@google.com>
-rw-r--r--zephyr/projects/herobrine/herobrine_npcx9/i2c.dts14
1 files changed, 12 insertions, 2 deletions
diff --git a/zephyr/projects/herobrine/herobrine_npcx9/i2c.dts b/zephyr/projects/herobrine/herobrine_npcx9/i2c.dts
index 97b6f0661d..8e26fae393 100644
--- a/zephyr/projects/herobrine/herobrine_npcx9/i2c.dts
+++ b/zephyr/projects/herobrine/herobrine_npcx9/i2c.dts
@@ -86,12 +86,22 @@
&i2c1_0 {
status = "okay";
- clock-frequency = <I2C_BITRATE_FAST_PLUS>;
+ /*
+ * TODO(b/200280341): PS8805 SPI ROM access
+ *
+ * The PS8805 supports 1 MHz during normal operation, but only
+ * 400 Khz during firmware updates. The I2C passthru commands don't
+ * currently support changing the I2C frequency or notifying the EC
+ * that a programming operation is going to start. Lower the clock
+ * rate to 400 kHz for all accesses.
+ */
+ clock-frequency = <I2C_BITRATE_FAST>;
};
&i2c2_0 {
status = "okay";
- clock-frequency = <I2C_BITRATE_FAST_PLUS>;
+ /* TODO(b/200280341): PS8805 SPI ROM access */
+ clock-frequency = <I2C_BITRATE_FAST>;
};
&i2c3_0 {