Tyler Wang has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/78336?usp=email )
Change subject: [Test] mb/google/rex/var/karis: Use 2 gpio for stylus ......................................................................
[Test] mb/google/rex/var/karis: Use 2 gpio for stylus
Use 2 gpio for stylus detect and wake function. GPP_E04 is the IRQ source, and GPP_E09 is the wake source.
Change-Id: I7a83326f76932c8e501e6369bb845fc7236291b4 Signed-off-by: Tyler Wang tyler.wang@quanta.corp-partner.google.com --- M src/mainboard/google/rex/variants/karis/gpio.c M src/mainboard/google/rex/variants/karis/overridetree.cb 2 files changed, 8 insertions(+), 3 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/36/78336/1
diff --git a/src/mainboard/google/rex/variants/karis/gpio.c b/src/mainboard/google/rex/variants/karis/gpio.c index 2a94cae..00d2bf8 100644 --- a/src/mainboard/google/rex/variants/karis/gpio.c +++ b/src/mainboard/google/rex/variants/karis/gpio.c @@ -196,7 +196,8 @@ /* GPP_E03 : [] ==> GSC_SOC_INT_ODL */ PAD_CFG_GPI_APIC_LOCK(GPP_E03, NONE, LEVEL, INVERT, LOCK_CONFIG), /* GPP_E04 : [] ==> SOC_PEN_DETECT */ - PAD_CFG_GPI_IRQ_WAKE(GPP_E04, NONE, PLTRST, LEVEL, INVERT), + /* Copy gpio config from kano */ + PAD_CFG_GPI_GPIO_DRIVER(GPP_E04, NONE, PLTRST), /* GPP_E05 : [] ==> USB_A0_RT_RST_ODL */ PAD_CFG_GPO(GPP_E05, 1, DEEP), /* GPP_E06 : GPP_E06_STRAP ==> Component NC */ @@ -206,7 +207,8 @@ /* GPP_E08 : NC net. */ PAD_NC(GPP_E08, NONE), /* GPP_E09 : Not Connected */ - PAD_NC(GPP_E09, NONE), + /* Copy gpio config from kano */ + PAD_CFG_GPI_SCI_LOCK(GPP_E09, NONE, EDGE_SINGLE, NONE, LOCK_CONFIG), /* GPP_E10 : [] ==> SOC_FPMCU_INT_L */ PAD_CFG_GPI_IRQ_WAKE_LOCK(GPP_E10, NONE, LEVEL, INVERT, LOCK_CONFIG), /* GPP_E11 : [] ==> MEM_STRAP_0 */ diff --git a/src/mainboard/google/rex/variants/karis/overridetree.cb b/src/mainboard/google/rex/variants/karis/overridetree.cb index 24dec6f..f89a4f7 100644 --- a/src/mainboard/google/rex/variants/karis/overridetree.cb +++ b/src/mainboard/google/rex/variants/karis/overridetree.cb @@ -384,8 +384,11 @@ end chip drivers/generic/gpio_keys register "name" = ""PENH"" - # GPP_E04 is the IRQ source + # GPP_E04 is the IRQ source, and GPP_E09 is the wake source register "gpio" = "ACPI_GPIO_INPUT_ACTIVE_LOW(GPP_E04)" + register "key.wake_gpe" = "GPE0_DW1_09" + register "key.wakeup_route" = "WAKEUP_ROUTE_SCI" + register "key.wakeup_event_action" = "EV_ACT_DEASSERTED" register "key.dev_name" = ""EJCT"" register "key.linux_code" = "SW_PEN_INSERTED" register "key.linux_input_type" = "EV_SW"