summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAbe Levkoy <alevkoy@chromium.org>2019-10-08 13:18:53 -0600
committerCommit Bot <commit-bot@chromium.org>2019-10-17 20:11:11 +0000
commitf409af3d4ac946a93819fd323d348ae3bdc4141f (patch)
tree0a3da1be706105d27fede7873b45e6ebd480bfad
parent4cb90db539a065dc3cc375c7d24c45018d9ef98b (diff)
downloadchrome-ec-f409af3d4ac946a93819fd323d348ae3bdc4141f.tar.gz
volteer: Configure power sequencing signals
Configure power sequencing interrupts and power-enable lines. Leave SLP_S4_L, which will be virtual, unimplemented for now. BUG=b:139553375 TEST=make buildall BRANCH=none Change-Id: Idf11290c84deb9ea2a71f5498a4a0db5363d2a3b Signed-off-by: Abe Levkoy <alevkoy@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1865481 Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
-rw-r--r--board/volteer/board.c1
-rw-r--r--board/volteer/board.h7
-rw-r--r--board/volteer/ec.tasklist1
-rw-r--r--board/volteer/gpio.inc17
4 files changed, 26 insertions, 0 deletions
diff --git a/board/volteer/board.c b/board/volteer/board.c
index 54c7e52594..2e95163a94 100644
--- a/board/volteer/board.c
+++ b/board/volteer/board.c
@@ -10,6 +10,7 @@
#include "gpio.h"
#include "hooks.h"
#include "lid_switch.h"
+#include "power.h"
#include "power_button.h"
#include "switch.h"
#include "system.h"
diff --git a/board/volteer/board.h b/board/volteer/board.h
index 782c77036a..00cbd12451 100644
--- a/board/volteer/board.h
+++ b/board/volteer/board.h
@@ -50,14 +50,21 @@
*/
#define GPIO_AC_PRESENT GPIO_ACOK_OD
#define GPIO_EC_INT_L EC_PCH_INT_ODL
+#define GPIO_EN_PP5000 GPIO_EN_PP5000_A
#define GPIO_ENTERING_RW GPIO_EC_ENTERING_RW
#define GPIO_LID_OPEN GPIO_EC_LID_OPEN
#define GPIO_KBD_KSO2 GPIO_EC_KSO_02_INV
#define GPIO_PCH_WAKE_L GPIO_EC_PCH_WAKE_ODL
#define GPIO_PCH_PWRBTN_L GPIO_EC_PCH_PWR_BTN_ODL
+#define GPIO_PCH_RSMRST_L GPIO_EC_PCH_RSMRST_ODL
#define GPIO_PCH_RTCRST GPIO_EC_PCH_RTCRST
#define GPIO_PCH_SYS_PWROK GPIO_EC_PCH_SYS_PWROK
+#define GPIO_PCH_SLP_S0_L GPIO_SLP_S0_L
+#define GPIO_PCH_SLP_S3_L GPIO_SLP_S3_L
+#define GPIO_PCH_SLP_S4_L GPIO_SLP_S4_L
+#define GPIO_PG_EC_DSW_PWROK GPIO_DSW_PWROK
#define GPIO_POWER_BUTTON_L GPIO_H1_EC_PWR_BTN_ODL
+#define GPIO_RSMRST_L_PGOOD GPIO_PG_EC_RSMRST_ODL
#define GPIO_CPU_PROCHOT GPIO_EC_PROCHOT_ODL
#define GPIO_SYS_RESET_L GPIO_SYS_RST_ODL
#define GPIO_WP_L GPIO_EC_WP_L
diff --git a/board/volteer/ec.tasklist b/board/volteer/ec.tasklist
index aa43567270..ca22534cf4 100644
--- a/board/volteer/ec.tasklist
+++ b/board/volteer/ec.tasklist
@@ -10,6 +10,7 @@
#define CONFIG_TASK_LIST \
TASK_ALWAYS(HOOKS, hook_task, NULL, LARGER_TASK_STACK_SIZE) \
TASK_NOTEST(KEYPROTO, keyboard_protocol_task, NULL, TASK_STACK_SIZE) \
+ TASK_NOTEST(CHIPSET, chipset_task, NULL, LARGER_TASK_STACK_SIZE) \
TASK_ALWAYS(HOSTCMD, host_command_task, NULL, LARGER_TASK_STACK_SIZE) \
TASK_ALWAYS(CONSOLE, console_task, NULL, VENTI_TASK_STACK_SIZE) \
TASK_ALWAYS(POWERBTN, power_button_task, NULL, LARGER_TASK_STACK_SIZE) \
diff --git a/board/volteer/gpio.inc b/board/volteer/gpio.inc
index 74b484a8fb..2be8fd7bf3 100644
--- a/board/volteer/gpio.inc
+++ b/board/volteer/gpio.inc
@@ -15,6 +15,17 @@ GPIO_INT(H1_EC_PWR_BTN_ODL, PIN(0, 1), GPIO_INT_BOTH, power_button_interrupt)
GPIO_INT(ACOK_OD, PIN(0, 0), GPIO_INT_BOTH | GPIO_HIB_WAKE_HIGH, extpower_interrupt)
/* Power sequencing interrupts */
+GPIO_INT(SLP_S0_L, PIN(D, 5), GPIO_INT_BOTH, power_signal_interrupt)
+#ifndef CONFIG_HOSTCMD_ESPI_VW_SLP_SIGNALS
+GPIO_INT(SLP_S3_L, PIN(A, 5), GPIO_INT_BOTH, power_signal_interrupt)
+#endif
+GPIO_INT(SLP_SUS_L, PIN(D, 7), GPIO_INT_BOTH, power_signal_interrupt)
+/* TODO(b/139553375): Consider using intel_x86_rsmrst_signal_interrupt. */
+GPIO_INT(PG_EC_RSMRST_ODL, PIN(E, 2), GPIO_INT_BOTH, power_signal_interrupt)
+GPIO_INT(DSW_PWROK, PIN(C, 7), GPIO_INT_BOTH, power_signal_interrupt)
+/* TODO(b/139553375): This signal is virtual; need to change code to support
+ * virtual S4 with physical S3. */
+UNIMPLEMENTED(SLP_S4_L)
/* Sensor Interrupts */
@@ -24,6 +35,12 @@ GPIO_INT(ACOK_OD, PIN(0, 0), GPIO_INT_BOTH | GPIO_HIB_WAKE_HIGH, ex
/* Volume button interrupts */
+/* Power Sequencing Signals */
+GPIO(EN_PP3300_A, PIN(A, 3), GPIO_OUT_LOW)
+GPIO(EN_PP5000_A, PIN(A, 4), GPIO_OUT_LOW)
+/* The EC does not buffer this signal on Volteer. */
+UNIMPLEMENTED(PCH_DSW_PWROK)
+
/* Other wake sources */
/*
* GPIO_INT_BOTH is required for PSL wake from hibernate, but we don't need an