summaryrefslogtreecommitdiff
path: root/include/usb_pd_tcpm.h
diff options
context:
space:
mode:
authorDiana Z <dzigterman@chromium.org>2020-10-16 15:24:54 -0600
committerCommit Bot <commit-bot@chromium.org>2020-10-19 23:20:56 +0000
commitdc5a1a0294ac6933205866a41e0f6ae1c4e4c615 (patch)
treedf19f43dc15730b9158b5d6c8c5cad7129f1ba03 /include/usb_pd_tcpm.h
parente1d70859fa3543c5ae5b4bed820aca2ca277ea17 (diff)
downloadchrome-ec-dc5a1a0294ac6933205866a41e0f6ae1c4e4c615.tar.gz
TCPMv2: Add debug detach interface
Some TCPCs may require special commands to be run after a debug accessory leaves the Attached.SNK/SRC states. Add an interface to support this, and call it from the TC when needed. BRANCH=None BUG=b:159495742,b:170259606 TEST=make -j buildall Signed-off-by: Diana Z <dzigterman@chromium.org> Change-Id: I79c7ebc308958c598cfa228598362c97b9b00e86 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2481941
Diffstat (limited to 'include/usb_pd_tcpm.h')
-rw-r--r--include/usb_pd_tcpm.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/usb_pd_tcpm.h b/include/usb_pd_tcpm.h
index b4cd7654a7..91837a55c3 100644
--- a/include/usb_pd_tcpm.h
+++ b/include/usb_pd_tcpm.h
@@ -326,6 +326,14 @@ struct tcpm_drv {
*/
int (*debug_accessory)(int port, bool enable);
+ /**
+ * Break debug connection, if TCPC requires specific commands to be run
+ * in order to correctly exit a debug connection.
+ *
+ * @param port Type-C port number
+ */
+ int (*debug_detach)(int port);
+
#ifdef CONFIG_USB_PD_DUAL_ROLE_AUTO_TOGGLE
/**
* Enable TCPC auto DRP toggling.