summaryrefslogtreecommitdiff
path: root/board/gingerbread/board.h
diff options
context:
space:
mode:
authorScott Collyer <scollyer@google.com>2021-03-25 19:47:14 -0700
committerCommit Bot <commit-bot@chromium.org>2021-04-10 21:48:43 +0000
commit62aa709f472b6a4021ccb3396701b2a2036caea7 (patch)
tree29b73d765523ef973c0015fcfa67d34abe661ff6 /board/gingerbread/board.h
parent8113e3d1f538039477ec4b1461031da770931055 (diff)
downloadchrome-ec-62aa709f472b6a4021ccb3396701b2a2036caea7.tar.gz
honeybuns: Add power button support
This CL adds support for the power button including a new task to allow for power sequencing delays. The power button is used for two purposes. First, to turn the dock on or off, and second, to allow for a user set preference of the MF for DP 2 or 4 lane selection. If the dock is off, the dock will be turned on as soon as the short press timer expires. If the dock is already on, then a short press action is only recognized on the release so a long press will only change the MF preference. BUG=b:164157329 BRANCH=quiche TEST=manaual short press -> turns dock on off as expected long press -> toggles MF preference and flashes LED Signed-off-by: Scott Collyer <scollyer@google.com> Change-Id: I8519c072a7f10657c369344ead6149fc7d31bb36 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2718268 Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Sam Hurst <shurst@google.com> Commit-Queue: Scott Collyer <scollyer@chromium.org>
Diffstat (limited to 'board/gingerbread/board.h')
-rw-r--r--board/gingerbread/board.h20
1 files changed, 19 insertions, 1 deletions
diff --git a/board/gingerbread/board.h b/board/gingerbread/board.h
index 21883367d0..d0b2994d31 100644
--- a/board/gingerbread/board.h
+++ b/board/gingerbread/board.h
@@ -68,7 +68,25 @@ enum debug_gpio {
TRIGGER_2,
};
-void board_debug_gpio(int trigger, int enable, int pulse_usec);
+/*
+ * Function used to control GPIO signals as a timing marker. This is intended to
+ * be used for development/debugging purposes.
+ *
+ * @param trigger GPIO debug signal selection
+ * @param level desired level of the debug gpio signal
+ * @param pulse_usec pulse width if non-zero
+ */
+void board_debug_gpio(enum debug_gpio trigger, int level, int pulse_usec);
+
+/*
+ * Function called in power on case to enable usbc related interrupts
+ */
+void board_enable_usbc_interrupts(void);
+
+/*
+ * Function called in power off case to disable usbc related interrupts
+ */
+void board_disable_usbc_interrupts(void);
#endif /* !__ASSEMBLER__ */