summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2021-06-04 13:31:03 -0600
committerCommit Bot <commit-bot@chromium.org>2021-06-09 18:35:43 +0000
commit0a7d8b159229ace9d5b8131d6be61d69a71e6e69 (patch)
treee6d4265b66f059b5a606e72230b61fbf4ce847de
parent629f84562924610a6fc4dd726b1054fe3ecd6d79 (diff)
downloadchrome-ec-0a7d8b159229ace9d5b8131d6be61d69a71e6e69.tar.gz
Create a public header for it5205.c
Add a separate public header for this chip so we can include it from Zephyr. BUG=b:189855648 BRANCH=none TEST=make BOARD=hayato -j30 Signed-off-by: Simon Glass <sjg@chromium.org> Change-Id: Idf2cfbf31e32880ca8cb7d5e72ba0d844cda31b9 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2941808 Reviewed-by: Denis Brockus <dbrockus@chromium.org> Commit-Queue: Denis Brockus <dbrockus@chromium.org> Tested-by: Denis Brockus <dbrockus@chromium.org>
-rw-r--r--driver/usb_mux/it5205.h5
-rw-r--r--include/driver/usb_mux/it5205_public.h15
2 files changed, 16 insertions, 4 deletions
diff --git a/driver/usb_mux/it5205.h b/driver/usb_mux/it5205.h
index c4fdc6ce49..0fb9f009f6 100644
--- a/driver/usb_mux/it5205.h
+++ b/driver/usb_mux/it5205.h
@@ -10,10 +10,7 @@
#include "stdbool.h"
#include "usb_mux.h"
-
-/* I2C interface */
-#define IT5205_I2C_ADDR1_FLAGS 0x48
-#define IT5205_I2C_ADDR2_FLAGS 0x58
+#include "usb_mux/it5205_public.h"
/* Chip ID registers */
#define IT5205_REG_CHIP_ID3 0x4
diff --git a/include/driver/usb_mux/it5205_public.h b/include/driver/usb_mux/it5205_public.h
new file mode 100644
index 0000000000..81dc326049
--- /dev/null
+++ b/include/driver/usb_mux/it5205_public.h
@@ -0,0 +1,15 @@
+/* Copyright 2021 The Chromium OS Authors. All rights reserved.
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ *
+ * ITE IT5205 Type-C USB alternate mode mux public header
+ */
+
+#ifndef __CROS_EC_DRIVER_USB_MUX_IT5205_PUBLIC_H
+#define __CROS_EC_DRIVER_USB_MUX_IT5205_PUBLIC_H
+
+/* I2C interface */
+#define IT5205_I2C_ADDR1_FLAGS 0x48
+#define IT5205_I2C_ADDR2_FLAGS 0x58
+
+#endif /* __CROS_EC_DRIVER_USB_MUX_IT5205_PUBLIC_H */