summaryrefslogtreecommitdiff
path: root/baseboard/grunt
diff options
context:
space:
mode:
authorAndrew McRae <amcrae@google.com>2020-06-20 11:48:59 +1000
committerCommit Bot <commit-bot@chromium.org>2020-06-23 03:17:54 +0000
commit131f7dc96e1c794befabdd8b182c7d5a190b58cc (patch)
treecdab2380508491fe000509b8544f3b41677d87af /baseboard/grunt
parentbaceadc0e81945b1ca0e58ae09d3d4724a991d40 (diff)
downloadchrome-ec-131f7dc96e1c794befabdd8b182c7d5a190b58cc.tar.gz
npcx: Add a new flag to check for initial power-on
The CR50 will reset the EC on some platforms after power-on. Add a reset flag to detect this and treat the second restart as a power-on restart rather than reset. Subsume the CONFIG_GPIO_INIT_POWER_ON_DELAY_MS config to make it clear what the behaviour will be. BUG=b:151329011 TEST=Confirm on dalboz, puff & variants that second reset is treated correctly. BRANCH=none Change-Id: Ib66de920403f08099b87d1eff797270606b44f8f Signed-off-by: Andrew McRae <amcrae@google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2255830 Reviewed-by: Peter Marheine <pmarheine@chromium.org> Commit-Queue: Andrew McRae <amcrae@chromium.org> Tested-by: Andrew McRae <amcrae@chromium.org>
Diffstat (limited to 'baseboard/grunt')
-rw-r--r--baseboard/grunt/baseboard.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/baseboard/grunt/baseboard.h b/baseboard/grunt/baseboard.h
index 466c5b05f9..589c2454ed 100644
--- a/baseboard/grunt/baseboard.h
+++ b/baseboard/grunt/baseboard.h
@@ -97,11 +97,10 @@
/*
* On power-on, H1 releases the EC from reset but then quickly asserts and
* releases the reset a second time. This means the EC sees 2 resets:
- * (1) power-on reset, (2) reset-pin reset. If we add a delay between reset (1)
- * and configuring GPIO output levels, then reset (2) will happen before the
- * end of the delay so we avoid extra output toggles.
+ * (1) power-on reset, (2) reset-pin reset. This config will
+ * allow the second reset to be treated as a power-on.
*/
-#define CONFIG_GPIO_INIT_POWER_ON_DELAY_MS 100
+#define CONFIG_BOARD_RESET_AFTER_POWER_ON
#define CONFIG_KEYBOARD_BOARD_CONFIG
#define CONFIG_KEYBOARD_COL2_INVERTED