summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWai-Hong Tam <waihong@google.com>2021-07-19 20:20:52 -0700
committerCommit Bot <commit-bot@chromium.org>2021-07-20 22:21:37 +0000
commit18bcc95366a2b415b4a9bd74cda56bce109f9bb7 (patch)
treecc9e918527ec4e58e5da273774e2f6a3bb83a834
parent4b2bc28799c4641a0ac302fd37171e3fb9080210 (diff)
downloadchrome-ec-18bcc95366a2b415b4a9bd74cda56bce109f9bb7.tar.gz
zephyr: herobrine_npcx9: Update I2C buses
This CL is a Zephyr-equivalent of CL:2993218. Add the I2C bus for the RTC chip. The chip runs at 400KHz. BRANCH=None BUG=b:192253134 TEST=Built the herobrine_npcx9 image successfully. Change-Id: I399485706c66070464fcd9fe53bec35b4c0454a6 Signed-off-by: Wai-Hong Tam <waihong@google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3039388 Reviewed-by: Yuval Peress <peress@chromium.org>
-rw-r--r--zephyr/dts/bindings/i2c/cros-ec-i2c-port-base.yaml1
-rw-r--r--zephyr/projects/herobrine/herobrine_npcx9/i2c.dts11
2 files changed, 12 insertions, 0 deletions
diff --git a/zephyr/dts/bindings/i2c/cros-ec-i2c-port-base.yaml b/zephyr/dts/bindings/i2c/cros-ec-i2c-port-base.yaml
index caffdfacfa..3838ca6fc9 100644
--- a/zephyr/dts/bindings/i2c/cros-ec-i2c-port-base.yaml
+++ b/zephyr/dts/bindings/i2c/cros-ec-i2c-port-base.yaml
@@ -29,6 +29,7 @@ properties:
- I2C_PORT_POWER
- I2C_PORT_PPC0
- I2C_PORT_PPC1
+ - I2C_PORT_RTC
- I2C_PORT_SENSOR
- I2C_PORT_TCPC0
- I2C_PORT_TCPC1
diff --git a/zephyr/projects/herobrine/herobrine_npcx9/i2c.dts b/zephyr/projects/herobrine/herobrine_npcx9/i2c.dts
index 1caba088c9..983f5af1f8 100644
--- a/zephyr/projects/herobrine/herobrine_npcx9/i2c.dts
+++ b/zephyr/projects/herobrine/herobrine_npcx9/i2c.dts
@@ -9,6 +9,7 @@
i2c-1 = &i2c1_0;
i2c-2 = &i2c2_0;
i2c-3 = &i2c3_0;
+ i2c-4 = &i2c4_1;
i2c-5 = &i2c5_0;
i2c-7 = &i2c7_0;
};
@@ -47,6 +48,11 @@
enum-name = "I2C_PORT_TCPC1";
label = "TCPC1";
};
+ rtc {
+ i2c-port = <&i2c4_1>;
+ enum-name = "I2C_PORT_RTC";
+ label = "RTC";
+ };
eeprom {
i2c-port = <&i2c5_0>;
enum-name = "I2C_PORT_EEPROM";
@@ -93,6 +99,11 @@
clock-frequency = <I2C_BITRATE_FAST>;
};
+&i2c4_1 {
+ status = "okay";
+ clock-frequency = <I2C_BITRATE_FAST>;
+};
+
&i2c5_0 {
status = "okay";
clock-frequency = <I2C_BITRATE_FAST>;