mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-12 19:04:59 +00:00
wheatley: Modified board level drivers for eSPI POC on wheatley.
Modified board level drivers for eSPI POC on wheatley. By adding CONFIG_ESPI definition, ec can support espi protocols for host interface on x86 based platform such as skylake and so on. CONFIG_VW_SIGNALS will be used in the future for saving GPIOs during power sequence. Modified sources: 1. wheatley/board.h: Enable/disable espi driver. 2, wheatley/board.c: Add VW signals in power signal list. 3. wheatley/gpio.inc: Save GPIOs if CONFIG_VW_SIGNALS is defined. BRANCH=none BUG=chrome-os-partner:34346 TEST=make BOARD=wheatley; test nuvoton IC specific drivers Change-Id: I0e8a951de6eacd4f8be65ffaac242f38079375d5 Signed-off-by: Mulin Chao <mlchao@nuvoton.com> Reviewed-on: https://chromium-review.googlesource.com/366520 Reviewed-by: Randall Spangler <rspangler@chromium.org>
This commit is contained in:
@@ -44,6 +44,7 @@
|
||||
#include "usb_pd.h"
|
||||
#include "usb_pd_tcpm.h"
|
||||
#include "util.h"
|
||||
#include "espi.h"
|
||||
|
||||
#define CPRINTS(format, args...) cprints(CC_USBCHARGE, format, ## args)
|
||||
#define CPRINTF(format, args...) cprintf(CC_USBCHARGE, format, ## args)
|
||||
@@ -101,8 +102,13 @@ void tablet_mode_interrupt(enum gpio_signal signal)
|
||||
const struct power_signal_info power_signal_list[] = {
|
||||
{GPIO_RSMRST_L_PGOOD, 1, "RSMRST_N_PWRGD"},
|
||||
{GPIO_PCH_SLP_S0_L, 1, "SLP_S0_DEASSERTED"},
|
||||
#ifdef CONFIG_VW_SIGNALS
|
||||
{VW_SLP_S3_L, 1, "SLP_S3_DEASSERTED"},
|
||||
{VW_SLP_S4_L, 1, "SLP_S4_DEASSERTED"},
|
||||
#else
|
||||
{GPIO_PCH_SLP_S3_L, 1, "SLP_S3_DEASSERTED"},
|
||||
{GPIO_PCH_SLP_S4_L, 1, "SLP_S4_DEASSERTED"},
|
||||
#endif
|
||||
{GPIO_PCH_SLP_SUS_L, 1, "SLP_SUS_DEASSERTED"},
|
||||
{GPIO_PMIC_DPWROK, 1, "PMIC_DPWROK"},
|
||||
};
|
||||
|
||||
@@ -148,6 +148,10 @@
|
||||
#undef CONFIG_CMD_TIMERINFO
|
||||
#undef CONFIG_CONSOLE_CMDHELP
|
||||
|
||||
/* Features of eSPI */
|
||||
#undef CONFIG_ESPI /* Use eSPI protocol for host interface of x86 CPU */
|
||||
#undef CONFIG_VW_SIGNALS /* Use VW signals instead of GPIOs */
|
||||
|
||||
#ifndef __ASSEMBLER__
|
||||
|
||||
#include "gpio_signal.h"
|
||||
|
||||
@@ -15,8 +15,11 @@ GPIO_INT(WP_L, PIN(7, 1), GPIO_INT_BOTH, switch
|
||||
GPIO_INT(POWER_BUTTON_L, PIN(9, 7), GPIO_INT_BOTH, power_button_interrupt) /* A48 - GPIO97 for ROP_EC_PWR_BTN_L_R */
|
||||
/* RSMRST from PMIC */
|
||||
GPIO_INT(RSMRST_L_PGOOD, PIN(7, 2), GPIO_INT_BOTH, power_signal_interrupt) /* A36 - PWRGD for ROP_EC_RSMRST_L */
|
||||
/* Use VW signals instead of GPIOs */
|
||||
#ifndef CONFIG_VW_SIGNALS
|
||||
GPIO_INT(PCH_SLP_S4_L, PIN(5, 0), GPIO_INT_BOTH, power_signal_interrupt) /* A25 - GPIO50 for SLP_S4_L */
|
||||
GPIO_INT(PCH_SLP_S3_L, PIN(4, 0), GPIO_INT_BOTH, power_signal_interrupt) /* B21 - TA1 for SLP_S3_L */
|
||||
#endif
|
||||
/*
|
||||
* This pulldown should be removed in future hardware followers. The signal
|
||||
* is pulled up in the SoC when the primary rails are on and/or ramping.
|
||||
|
||||
Reference in New Issue
Block a user