summaryrefslogtreecommitdiff
path: root/chip/ish/config_chip.h
diff options
context:
space:
mode:
authorJack Rosenthal <jrosenth@chromium.org>2019-03-14 13:14:15 -0600
committerchrome-bot <chrome-bot@chromium.org>2019-03-26 04:44:00 -0700
commit9a5a7225737051e9523a775ebf8bba63f144259b (patch)
tree4c604846f721c564c9dd966d7e5184230805c243 /chip/ish/config_chip.h
parent5555323902f965a6e489e797f0e156d460e62d67 (diff)
downloadchrome-ec-9a5a7225737051e9523a775ebf8bba63f144259b.tar.gz
ish: Add watchdog timer
This adds support for the watchdog timer (WDT) available on Intel Sensor Hub (ISH). The ISH will reset after T1 expires; see the comments at the top of watchdog.c for further information on this design decision. Originally, we had planned to implement a counter that would disable the WDT after N failures. This was abandoned, since the register used to store the counter was not able to maintain a value across reset on a reliable basis (see b:128679825). BUG=b:127980538,b:128679825 BRANCH=none TEST=Used waitms command on arcada to verify WDT triggered a warning IRQ after T1 and reset the system. Change-Id: I4bd16c253110d60c57eb24cda2abc0facee20748 Signed-off-by: Jack Rosenthal <jrosenth@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1526316 Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com> Reviewed-by: Jett Rink <jettrink@chromium.org>
Diffstat (limited to 'chip/ish/config_chip.h')
-rw-r--r--chip/ish/config_chip.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/chip/ish/config_chip.h b/chip/ish/config_chip.h
index c595e825b9..d10ee650d6 100644
--- a/chip/ish/config_chip.h
+++ b/chip/ish/config_chip.h
@@ -67,6 +67,17 @@
#include "config_flash_layout.h"
+/*****************************************************************************/
+/* Watchdog Timer Configuration */
+/*****************************************************************************/
+#if defined(CHIP_FAMILY_ISH3) || defined(CHIP_FAMILY_ISH5)
+#define WDT_CLOCK_HZ (120000000) /* 120 MHz */
+#elif defined(CHIP_FAMILY_ISH4)
+#define WDT_CLOCK_HZ (100000000) /* 100 MHz */
+#else
+#error "CHIP_FAMILY_ISH(3|4|5) must be defined"
+#endif
+
/****************************************************************************/
/* Customize the build */
/* Optional features present on this chip */