diff options
author | Pi-Hsun Shih <pihsun@chromium.org> | 2019-02-13 17:54:08 +0800 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2019-02-19 12:46:20 -0800 |
commit | 2f45ad6eadd33e9d872a6fa249c0b0517ef4fc15 (patch) | |
tree | 945b464389ef9ffdc2e2e180b857e1e1e9d10b97 /chip/mt_scp/system.c | |
parent | a66c36ee98fc109dc2abb4c1fcc8947dd267fcc0 (diff) | |
download | chrome-ec-2f45ad6eadd33e9d872a6fa249c0b0517ef4fc15.tar.gz |
kukui_scp: Always use watchdog reset on reboot.
BUG=b:120889996
TEST=`reboot` in SCP console, and see that it triggers a watchdog reset.
BRANCH=none
Change-Id: I4b629dc32dfd3bed8d802b211c1170ff72ee0943
Signed-off-by: Pi-Hsun Shih <pihsun@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1469853
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Reviewed-by: Nicolas Boichat <drinkcat@chromium.org>
Diffstat (limited to 'chip/mt_scp/system.c')
-rw-r--r-- | chip/mt_scp/system.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/chip/mt_scp/system.c b/chip/mt_scp/system.c index baa0ea59b6..9a68fac27b 100644 --- a/chip/mt_scp/system.c +++ b/chip/mt_scp/system.c @@ -232,9 +232,10 @@ void system_reset(int flags) } } - /* SCB AIRCR reset */ - CPU_NVIC_APINT = 0x05fa0004; - /* Spin wait for chip to reboot */ + /* Set watchdog timer to small value, and spin wait for watchdog reset */ + SCP_WDT_CFG = 0; + SCP_WDT_CFG = SCP_WDT_ENABLE | SCP_WDT_PERIOD(1); + watchdog_reload(); while (1) ; } |