diff options
author | Diana Z <dzigterman@chromium.org> | 2021-11-04 12:09:09 -0600 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2021-11-11 21:41:22 +0000 |
commit | 99a6013a9a7b31b4698d2ecd5a68d5a1e61fc036 (patch) | |
tree | 46bab0ee940f210cb1bd9be82be29275c6e4ec40 /include/usb_pd_tcpm.h | |
parent | 65ec8708608955683f04e7bbfdf2cef39b5214f9 (diff) | |
download | chrome-ec-99a6013a9a7b31b4698d2ecd5a68d5a1e61fc036.tar.gz |
TCPCI: Add an interface for I2C wake
When we wake a TCPC from I2C idle, there is a procedure in the TCPCI
specificaiton to follow. Implementing the full procedure will take some
refactoring, but for now at least send the i2c wake to the chip when we
plan to wake it. Otherwise, we don't actually wake the chip until the
LPM exit debounce finishes, which isn't in the intended use of the LPM
exit debounce.
BRANCH=None
BUG=b:195393479
TEST=make -j buildall
Signed-off-by: Diana Z <dzigterman@chromium.org>
Change-Id: I6d5a6d27cce653ab02b59ab0e09d06657f640c39
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3262585
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Diffstat (limited to 'include/usb_pd_tcpm.h')
-rw-r--r-- | include/usb_pd_tcpm.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/usb_pd_tcpm.h b/include/usb_pd_tcpm.h index 13d1fbbcb5..d17dab6aab 100644 --- a/include/usb_pd_tcpm.h +++ b/include/usb_pd_tcpm.h @@ -430,6 +430,16 @@ struct tcpm_drv { * @return EC_SUCCESS or error */ int (*enter_low_power_mode)(int port); + + /** + * Starts I2C wake sequence for TCPC + * + * NOTE: Do no use tcpc_(read|write) style helper methods in this + * function. You must use i2c_(read|write) directly. + * + * @param port Type-C port number + */ + void (*wake_low_power_mode)(int port); #endif #ifdef CONFIG_USB_PD_FRS_TCPC |