Jon Murphy has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/63704 )
Change subject: mb/google/skyrim: Unmask espi, debug keyboard ......................................................................
mb/google/skyrim: Unmask espi, debug keyboard
Unmask espi interrupts, add keyboard init and debug
BUG=b:227282870 TEST=Build and boot to OS in Skyrim.
Signed-off-by: Jon Murphy jpmurphy@google.com Change-Id: I7e9816d67500365ed1d2ee39ef184a1f60321ca1 --- M src/mainboard/google/skyrim/bootblock.c M src/mainboard/google/skyrim/ec.c M src/mainboard/google/skyrim/mainboard.c M src/mainboard/google/skyrim/variants/baseboard/devicetree.cb 4 files changed, 12 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/04/63704/1
diff --git a/src/mainboard/google/skyrim/bootblock.c b/src/mainboard/google/skyrim/bootblock.c index 4128090..ddf1a63 100644 --- a/src/mainboard/google/skyrim/bootblock.c +++ b/src/mainboard/google/skyrim/bootblock.c @@ -10,6 +10,8 @@ size_t num_gpios; const struct soc_amd_gpio *gpios;
+ espi_disable_lpc_ldrq(); + variant_espi_gpio_table(&gpios, &num_gpios); gpio_configure_pads(gpios, num_gpios);
diff --git a/src/mainboard/google/skyrim/ec.c b/src/mainboard/google/skyrim/ec.c index bc29833..ab40e2b 100644 --- a/src/mainboard/google/skyrim/ec.c +++ b/src/mainboard/google/skyrim/ec.c @@ -11,7 +11,7 @@ static const struct sci_source espi_sci_sources[] = { { .scimap = SMITYPE_ESPI_SYS, - .gpe = GEVENT_3, + .gpe = EC_SCI_GPI, .direction = SMI_SCI_LVL_HIGH, /* enum smi_sci_lvl */ .level = SMI_SCI_EDG, /* enum smi_sci_dir */ } diff --git a/src/mainboard/google/skyrim/mainboard.c b/src/mainboard/google/skyrim/mainboard.c index 7c89f49..103a833 100644 --- a/src/mainboard/google/skyrim/mainboard.c +++ b/src/mainboard/google/skyrim/mainboard.c @@ -1,5 +1,6 @@ /* SPDX-License-Identifier: GPL-2.0-or-later */
+#include <amdblocks/acpimmio.h> #include <amdblocks/amd_pci_util.h> #include <baseboard/variants.h> #include <console/console.h> @@ -111,6 +112,13 @@ init_tables(); /* Initialize the PIRQ data structures for consumption */ pirq_setup(); + + /* Write SLAVE0_RXVW_MISC_CNTL to disable IRQ grouping */ + write32((void *)0xfec200a8, 0); + + /* TODO: b/184678786 - Move into espi_config */ + /* Unmask eSPI IRQ 1 (Keyboard) */ + pm_write32(PM_ESPI_INTR_CTRL, PM_ESPI_DEV_INTR_MASK & ~(BIT(1))); }
struct chip_operations mainboard_ops = { diff --git a/src/mainboard/google/skyrim/variants/baseboard/devicetree.cb b/src/mainboard/google/skyrim/variants/baseboard/devicetree.cb index a6894ee..f0d1039 100644 --- a/src/mainboard/google/skyrim/variants/baseboard/devicetree.cb +++ b/src/mainboard/google/skyrim/variants/baseboard/devicetree.cb @@ -35,7 +35,7 @@ .oob_ch_en = 0, .flash_ch_en = 0,
- .vw_irq_polarity = ESPI_VW_IRQ_LEVEL_HIGH(1) | ESPI_VW_IRQ_LEVEL_HIGH(12), + .vw_irq_polarity = ESPI_VW_IRQ_LEVEL_HIGH(1), }"
register "i2c_scl_reset" = "GPIO_I2C0_SCL | GPIO_I2C1_SCL |