summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKapil Porwal <kapilporwal@google.com>2022-07-20 14:22:41 +0000
committerMartin Roth <martin.roth@amd.corp-partner.google.com>2022-07-22 17:07:01 +0000
commit381c21910aea3aaedc5a1cb1513bf29a06983545 (patch)
treee7510ca5b05aa2dd957f2e100977a5a4e6164783
parent3132a5fb89f3149bec7ee00e2121ee16a3436567 (diff)
mb/google/rex: Add TPM device to Kconfig and devicetree
Add TPM device for Rex. Device details: I2C Controller/Bus = 4 I2C Slave Address = 0x50 GPE = GPE0_DW1_03/GPP_E03 BUG=b:224325352 TEST=Verified in emulator that there is no regression Signed-off-by: Kapil Porwal <kapilporwal@google.com> Change-Id: Ifa3a5b503a203e3900049f27a54025156e22a285 Reviewed-on: https://review.coreboot.org/c/coreboot/+/66014 Reviewed-by: Subrata Banik <subratabanik@google.com> Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
-rw-r--r--src/mainboard/google/rex/Kconfig16
-rw-r--r--src/mainboard/google/rex/chromeos.fmd1
-rw-r--r--src/mainboard/google/rex/variants/rex0/overridetree.cb8
3 files changed, 24 insertions, 1 deletions
diff --git a/src/mainboard/google/rex/Kconfig b/src/mainboard/google/rex/Kconfig
index c10f3f3e14..1d7652c0b3 100644
--- a/src/mainboard/google/rex/Kconfig
+++ b/src/mainboard/google/rex/Kconfig
@@ -4,7 +4,9 @@ config BOARD_GOOGLE_REX_COMMON
select EC_GOOGLE_CHROMEEC_BOARDID
select HAVE_ACPI_RESUME
select HAVE_ACPI_TABLES
+ select I2C_TPM
select INTEL_LPSS_UART_FOR_CONSOLE
+ select MAINBOARD_HAS_TPM2
config BOARD_GOOGLE_BASEBOARD_REX
def_bool n
@@ -15,6 +17,8 @@ config BOARD_GOOGLE_BASEBOARD_REX
select MEMORY_SOLDERDOWN
select SOC_INTEL_METEORLAKE
select SYSTEM_TYPE_LAPTOP
+ select TI50_FIRMWARE_VERSION_NOT_SUPPORTED
+ select TPM_GOOGLE_TI50
config BOARD_GOOGLE_REX0
select BOARD_GOOGLE_BASEBOARD_REX
@@ -62,4 +66,16 @@ config UART_FOR_CONSOLE
config OVERRIDE_DEVICETREE
default "variants/\$(CONFIG_VARIANT_DIR)/overridetree.cb"
+config DRIVER_TPM_I2C_BUS
+ hex
+ default 0x4 if BOARD_GOOGLE_REX0
+
+config DRIVER_TPM_I2C_ADDR
+ hex
+ default 0x50
+
+config TPM_TIS_ACPI_INTERRUPT
+ int
+ default 35 # GPE0_DW1_03 (GPP_E03)
+
endif # BOARD_GOOGLE_REX_COMMON
diff --git a/src/mainboard/google/rex/chromeos.fmd b/src/mainboard/google/rex/chromeos.fmd
index 334cddaf7b..1714e80578 100644
--- a/src/mainboard/google/rex/chromeos.fmd
+++ b/src/mainboard/google/rex/chromeos.fmd
@@ -43,6 +43,7 @@ FLASH 32M {
# memory protected range specification.
WP_RO 8M {
RO_VPD(PRESERVE) 16K
+ RO_GSCVD 8K
RO_SECTION {
FMAP 2K
RO_FRID 64
diff --git a/src/mainboard/google/rex/variants/rex0/overridetree.cb b/src/mainboard/google/rex/variants/rex0/overridetree.cb
index 65c1c81671..f5d9430b22 100644
--- a/src/mainboard/google/rex/variants/rex0/overridetree.cb
+++ b/src/mainboard/google/rex/variants/rex0/overridetree.cb
@@ -110,7 +110,13 @@ chip soc/intel/meteorlake
device ref i2c2 on end
device ref i2c3 on end
device ref sata on end
- device ref i2c4 on end
+ device ref i2c4 on
+ chip drivers/i2c/tpm
+ register "hid" = ""GOOG0005""
+ register "irq" = "ACPI_IRQ_EDGE_LOW(GPP_E03_IRQ)"
+ device i2c 50 on end
+ end
+ end
device ref i2c5 on end
device ref pcie_rp5 on
# Enable WLAN Card PCIE 5 using clk 5