summaryrefslogtreecommitdiffstats
path: root/src/mainboard/google
diff options
context:
space:
mode:
authorPhilipp Deppenwiese <zaolin@das-labor.org>2018-02-27 19:40:52 +0100
committerMartin Roth <martinroth@google.com>2018-06-04 20:33:07 +0000
commitc07f8fbe6fd13e4245da71574b52b47e9733db84 (patch)
tree12db8b3c40552eab81045c6165538e2d3ba36ce8 /src/mainboard/google
parent961d31bdb3c97e177156ed335d6f2c726d08ab51 (diff)
downloadcoreboot-c07f8fbe6fd13e4245da71574b52b47e9733db84.tar.gz
coreboot-c07f8fbe6fd13e4245da71574b52b47e9733db84.tar.bz2
coreboot-c07f8fbe6fd13e4245da71574b52b47e9733db84.zip
security/tpm: Unify the coreboot TPM software stack
* Remove 2nd software stack in pc80 drivers directory. * Create TSPI interface for common usage. * Refactor TSS / TIS code base. * Add vendor tss (Cr50) directory. * Change kconfig options for TPM to TPM1. * Add user / board configuration with: * MAINBOARD_HAS_*_TPM # * BUS driver * MAINBOARD_HAS_TPM1 or MAINBOARD_HAS_TPM2 * Add kconfig TPM user selection (e.g. pluggable TPMs) * Fix existing headers and function calls. * Fix vboot for interface usage and antirollback mode. Change-Id: I7ec277e82a3c20c62a0548a1a2b013e6ce8f5b3f Signed-off-by: Philipp Deppenwiese <zaolin@das-labor.org> Reviewed-on: https://review.coreboot.org/24903 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Diffstat (limited to 'src/mainboard/google')
-rw-r--r--src/mainboard/google/auron/Kconfig1
-rw-r--r--src/mainboard/google/beltino/Kconfig1
-rw-r--r--src/mainboard/google/butterfly/Kconfig1
-rw-r--r--src/mainboard/google/chell/Kconfig1
-rw-r--r--src/mainboard/google/cheza/Kconfig2
-rw-r--r--src/mainboard/google/cyan/Kconfig1
-rw-r--r--src/mainboard/google/daisy/Kconfig2
-rw-r--r--src/mainboard/google/eve/Kconfig3
-rw-r--r--src/mainboard/google/fizz/Kconfig3
-rw-r--r--src/mainboard/google/foster/Kconfig2
-rw-r--r--src/mainboard/google/gale/Kconfig2
-rw-r--r--src/mainboard/google/glados/Kconfig1
-rw-r--r--src/mainboard/google/gru/Kconfig6
-rw-r--r--src/mainboard/google/jecht/Kconfig1
-rw-r--r--src/mainboard/google/kahlee/Kconfig25
-rw-r--r--src/mainboard/google/lars/Kconfig1
-rw-r--r--src/mainboard/google/link/Kconfig1
-rw-r--r--src/mainboard/google/link/romstage.c2
-rw-r--r--src/mainboard/google/nyan_big/Kconfig2
-rw-r--r--src/mainboard/google/nyan_blaze/Kconfig2
-rw-r--r--src/mainboard/google/oak/Kconfig7
-rw-r--r--src/mainboard/google/octopus/Kconfig11
-rw-r--r--src/mainboard/google/parrot/Kconfig1
-rw-r--r--src/mainboard/google/parrot/romstage.c2
-rw-r--r--src/mainboard/google/peach_pit/Kconfig2
-rw-r--r--src/mainboard/google/poppy/Kconfig30
-rw-r--r--src/mainboard/google/purin/Kconfig2
-rw-r--r--src/mainboard/google/rambi/Kconfig1
-rw-r--r--src/mainboard/google/reef/Kconfig3
-rw-r--r--src/mainboard/google/rotor/Kconfig2
-rw-r--r--src/mainboard/google/slippy/Kconfig1
-rw-r--r--src/mainboard/google/smaug/Kconfig2
-rw-r--r--src/mainboard/google/storm/Kconfig2
-rw-r--r--src/mainboard/google/stout/Kconfig1
-rw-r--r--src/mainboard/google/stout/romstage.c2
-rw-r--r--src/mainboard/google/urara/Kconfig2
-rw-r--r--src/mainboard/google/veyron/Kconfig2
-rw-r--r--src/mainboard/google/veyron_mickey/Kconfig2
-rw-r--r--src/mainboard/google/veyron_rialto/Kconfig2
-rw-r--r--src/mainboard/google/zoombini/Kconfig6
40 files changed, 83 insertions, 60 deletions
diff --git a/src/mainboard/google/auron/Kconfig b/src/mainboard/google/auron/Kconfig
index 791dcba5ef41..92dd9e45fa31 100644
--- a/src/mainboard/google/auron/Kconfig
+++ b/src/mainboard/google/auron/Kconfig
@@ -10,6 +10,7 @@ config BOARD_GOOGLE_BASEBOARD_AURON
select HAVE_SMI_HANDLER
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
select INTEL_INT15
select SYSTEM_TYPE_LAPTOP
diff --git a/src/mainboard/google/beltino/Kconfig b/src/mainboard/google/beltino/Kconfig
index a029fecab20f..428db7346c31 100644
--- a/src/mainboard/google/beltino/Kconfig
+++ b/src/mainboard/google/beltino/Kconfig
@@ -12,6 +12,7 @@ config BOARD_GOOGLE_BASEBOARD_BELTINO
select HAVE_SMI_HANDLER
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
if BOARD_GOOGLE_BASEBOARD_BELTINO
diff --git a/src/mainboard/google/butterfly/Kconfig b/src/mainboard/google/butterfly/Kconfig
index 884d80079ddc..8323d7fcb71c 100644
--- a/src/mainboard/google/butterfly/Kconfig
+++ b/src/mainboard/google/butterfly/Kconfig
@@ -14,6 +14,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select HAVE_ACPI_RESUME
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
select INTEL_INT15
select SERIRQ_CONTINUOUS_MODE # Workaround for EC/KBC IRQ1.
diff --git a/src/mainboard/google/chell/Kconfig b/src/mainboard/google/chell/Kconfig
index f958d9166a7d..9257b5a7b17f 100644
--- a/src/mainboard/google/chell/Kconfig
+++ b/src/mainboard/google/chell/Kconfig
@@ -17,6 +17,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select HAVE_SMI_HANDLER
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
select SOC_INTEL_SKYLAKE
select SYSTEM_TYPE_LAPTOP
diff --git a/src/mainboard/google/cheza/Kconfig b/src/mainboard/google/cheza/Kconfig
index b60c1b0c86ce..13868b49b11d 100644
--- a/src/mainboard/google/cheza/Kconfig
+++ b/src/mainboard/google/cheza/Kconfig
@@ -11,6 +11,8 @@ config BOARD_SPECIFIC_OPTIONS
select SOC_QUALCOMM_SDM845
select SPI_FLASH
select MAINBOARD_HAS_CHROMEOS
+ select MAINBOARD_HAS_SPI_TPM_CR50
+ select MAINBOARD_HAS_TPM2
config VBOOT
select VBOOT_VBNV_FLASH
diff --git a/src/mainboard/google/cyan/Kconfig b/src/mainboard/google/cyan/Kconfig
index 7b8fd44aa0d6..fdd6316a1768 100644
--- a/src/mainboard/google/cyan/Kconfig
+++ b/src/mainboard/google/cyan/Kconfig
@@ -10,6 +10,7 @@ config BOARD_GOOGLE_BASEBOARD_CYAN
select HAVE_OPTION_TABLE
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
select SOC_INTEL_BRASWELL
select HAVE_ACPI_RESUME
select PCIEXP_L1_SUB_STATE if !BOARD_GOOGLE_CYAN
diff --git a/src/mainboard/google/daisy/Kconfig b/src/mainboard/google/daisy/Kconfig
index 7a939057b286..5184578a914e 100644
--- a/src/mainboard/google/daisy/Kconfig
+++ b/src/mainboard/google/daisy/Kconfig
@@ -28,6 +28,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select MAINBOARD_HAS_NATIVE_VGA_INIT
select MAINBOARD_FORCE_NATIVE_VGA_INIT
select HAVE_LINEAR_FRAMEBUFFER
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select VBOOT_VBNV_EC
diff --git a/src/mainboard/google/eve/Kconfig b/src/mainboard/google/eve/Kconfig
index 93d6f70581c7..9205651ba067 100644
--- a/src/mainboard/google/eve/Kconfig
+++ b/src/mainboard/google/eve/Kconfig
@@ -15,12 +15,11 @@ config BOARD_SPECIFIC_OPTIONS
select EC_GOOGLE_CHROMEEC_LPC
select HAVE_ACPI_RESUME
select HAVE_ACPI_TABLES
- select I2C_TPM
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_I2C_TPM_CR50
+ select MAINBOARD_HAS_TPM2
select MAINBOARD_USES_FSP2_0
select SOC_INTEL_KABYLAKE
- select TPM2
config VBOOT
select EC_GOOGLE_CHROMEEC_SWITCHES
diff --git a/src/mainboard/google/fizz/Kconfig b/src/mainboard/google/fizz/Kconfig
index 19385fff8166..7b3ba45f1bce 100644
--- a/src/mainboard/google/fizz/Kconfig
+++ b/src/mainboard/google/fizz/Kconfig
@@ -17,8 +17,7 @@ config BOARD_SPECIFIC_OPTIONS
select NO_FADT_8042
select SOC_INTEL_KABYLAKE
select MAINBOARD_HAS_SPI_TPM_CR50
- select SPI_TPM
- select TPM2
+ select MAINBOARD_HAS_TPM2
select GENERIC_SPD_BIN
select RT8168_GET_MAC_FROM_VPD
select RT8168_SET_LED_MODE
diff --git a/src/mainboard/google/foster/Kconfig b/src/mainboard/google/foster/Kconfig
index c8076d761341..22d274731970 100644
--- a/src/mainboard/google/foster/Kconfig
+++ b/src/mainboard/google/foster/Kconfig
@@ -24,6 +24,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select BOOTROM_SDRAM_INIT # use BootRom to config sdram
select COMMON_CBFS_SPI_WRAPPER
select SPI_FLASH_WINBOND
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select VBOOT_VBNV_FLASH
diff --git a/src/mainboard/google/gale/Kconfig b/src/mainboard/google/gale/Kconfig
index d3470ca94f44..883c9feb3b3d 100644
--- a/src/mainboard/google/gale/Kconfig
+++ b/src/mainboard/google/gale/Kconfig
@@ -29,6 +29,8 @@ config BOARD_SPECIFIC_OPTIONS
select SPI_FLASH_STMICRO
select SPI_FLASH_WINBOND
select DRIVERS_UART
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select VBOOT_DISABLE_DEV_ON_RECOVERY
diff --git a/src/mainboard/google/glados/Kconfig b/src/mainboard/google/glados/Kconfig
index de78aae0e65c..9a2e4ccf3c96 100644
--- a/src/mainboard/google/glados/Kconfig
+++ b/src/mainboard/google/glados/Kconfig
@@ -17,6 +17,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select HAVE_SMI_HANDLER
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
select SOC_INTEL_SKYLAKE
select SYSTEM_TYPE_LAPTOP
diff --git a/src/mainboard/google/gru/Kconfig b/src/mainboard/google/gru/Kconfig
index e97dce4982b7..11bf18cf1224 100644
--- a/src/mainboard/google/gru/Kconfig
+++ b/src/mainboard/google/gru/Kconfig
@@ -57,11 +57,13 @@ config BOARD_SPECIFIC_OPTIONS
select SPI_FLASH
select SPI_FLASH_GIGADEVICE
select SPI_FLASH_WINBOND
+ select MAINBOARD_HAS_SPI_TPM_CR50 if GRU_HAS_TPM2
+ select MAINBOARD_HAS_I2C_TPM_GENERIC if !GRU_HAS_TPM2
+ select MAINBOARD_HAS_TPM1 if !GRU_HAS_TPM2
+ select MAINBOARD_HAS_TPM2 if GRU_HAS_TPM2
config VBOOT
select EC_GOOGLE_CHROMEEC_SWITCHES
- select MAINBOARD_HAS_SPI_TPM_CR50 if GRU_HAS_TPM2
- select SPI_TPM if GRU_HAS_TPM2
select VBOOT_VBNV_FLASH
config MAINBOARD_DIR
diff --git a/src/mainboard/google/jecht/Kconfig b/src/mainboard/google/jecht/Kconfig
index fdb5ee01fffe..e9802053b7bc 100644
--- a/src/mainboard/google/jecht/Kconfig
+++ b/src/mainboard/google/jecht/Kconfig
@@ -9,6 +9,7 @@ config BOARD_GOOGLE_BASEBOARD_JECHT
select HAVE_SMI_HANDLER
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
if BOARD_GOOGLE_BASEBOARD_JECHT
diff --git a/src/mainboard/google/kahlee/Kconfig b/src/mainboard/google/kahlee/Kconfig
index b44e3bd75729..d1e4877cc872 100644
--- a/src/mainboard/google/kahlee/Kconfig
+++ b/src/mainboard/google/kahlee/Kconfig
@@ -30,7 +30,6 @@ config BOARD_GOOGLE_BASEBOARD_KAHLEE
select GFXUMA
select GOOGLE_SMBIOS_MAINBOARD_VERSION
select MAINBOARD_HAS_CHROMEOS
- select MAINBOARD_HAS_LPC_TPM if BOARD_GOOGLE_KAHLEE
select SERIRQ_CONTINUOUS_MODE
select STONEYRIDGE_UART
select SOC_AMD_PSP_SELECTABLE_SMU_FW
@@ -108,22 +107,14 @@ config AMD_FWM_POSITION_INDEX
int
default 1
-# Select this option to enable use of cr50 I2C TPM on kahlee
-config KAHLEE_USE_I2C_TPM
- bool
- default y if !BOARD_GOOGLE_KAHLEE
- select I2C_TPM
- select MAINBOARD_HAS_I2C_TPM_CR50
- select TPM2
-
config DRIVER_TPM_I2C_BUS
hex
- depends on KAHLEE_USE_I2C_TPM
+ depends on I2C_TPM
default 0x01
config DRIVER_TPM_I2C_ADDR
hex
- depends on KAHLEE_USE_I2C_TPM
+ depends on I2C_TPM
default 0x50
config GRUNT_AUDIO
@@ -133,4 +124,16 @@ config GRUNT_AUDIO
select DRIVERS_GENERIC_MAX98357A
select DRIVERS_I2C_DA7219
+config GRUNT_TPM
+ bool
+ default y if BOARD_GOOGLE_GRUNT
+ select MAINBOARD_HAS_I2C_TPM_CR50
+ select MAINBOARD_HAS_TPM2
+
+config KAHLEE_TPM
+ bool
+ default y if BOARD_GOOGLE_KAHLEE
+ select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
+
endif # BOARD_GOOGLE_BASEBOARD_KAHLEE
diff --git a/src/mainboard/google/lars/Kconfig b/src/mainboard/google/lars/Kconfig
index fdcc7ab5ebc2..e9c27be48f03 100644
--- a/src/mainboard/google/lars/Kconfig
+++ b/src/mainboard/google/lars/Kconfig
@@ -19,6 +19,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select HAVE_SMI_HANDLER
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
select SOC_INTEL_SKYLAKE
select SYSTEM_TYPE_LAPTOP
diff --git a/src/mainboard/google/link/Kconfig b/src/mainboard/google/link/Kconfig
index 32f9fb618335..b7f0c777966a 100644
--- a/src/mainboard/google/link/Kconfig
+++ b/src/mainboard/google/link/Kconfig
@@ -13,6 +13,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select HAVE_ACPI_RESUME
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
select SERIRQ_CONTINUOUS_MODE
select MAINBOARD_HAS_NATIVE_VGA_INIT
select HAVE_LINEAR_FRAMEBUFFER if MAINBOARD_DO_NATIVE_VGA_INIT
diff --git a/src/mainboard/google/link/romstage.c b/src/mainboard/google/link/romstage.c
index a1bbe34a4b69..cc2ef22ab620 100644
--- a/src/mainboard/google/link/romstage.c
+++ b/src/mainboard/google/link/romstage.c
@@ -36,7 +36,7 @@
#include <arch/cpu.h>
#include <cpu/x86/msr.h>
#include <halt.h>
-#include <security/tpm/tis.h>
+#include <security/tpm/tspi.h>
#include <cbfs.h>
#include <southbridge/intel/bd82x6x/chip.h>
diff --git a/src/mainboard/google/nyan_big/Kconfig b/src/mainboard/google/nyan_big/Kconfig
index cdc5d226e2e1..87edabac4765 100644
--- a/src/mainboard/google/nyan_big/Kconfig
+++ b/src/mainboard/google/nyan_big/Kconfig
@@ -28,6 +28,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select SPI_FLASH_GIGADEVICE
select SPI_FLASH_WINBOND
select SPI_FLASH_FAST_READ_DUAL_OUTPUT_3B
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select EC_GOOGLE_CHROMEEC_SWITCHES
diff --git a/src/mainboard/google/nyan_blaze/Kconfig b/src/mainboard/google/nyan_blaze/Kconfig
index 912022718fdc..be6a186f35b0 100644
--- a/src/mainboard/google/nyan_blaze/Kconfig
+++ b/src/mainboard/google/nyan_blaze/Kconfig
@@ -29,6 +29,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select SPI_FLASH_GIGADEVICE
select SPI_FLASH_WINBOND
select SPI_FLASH_FAST_READ_DUAL_OUTPUT_3B
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select EC_GOOGLE_CHROMEEC_SWITCHES
diff --git a/src/mainboard/google/oak/Kconfig b/src/mainboard/google/oak/Kconfig
index bab142bdd298..9d6fa0e2fb3c 100644
--- a/src/mainboard/google/oak/Kconfig
+++ b/src/mainboard/google/oak/Kconfig
@@ -18,11 +18,18 @@ config BOARD_GOOGLE_OAK_COMMON
if BOARD_GOOGLE_OAK_COMMON
+config OTHERS_HAVE_TPM1
+ bool
+ default y if !BOARD_GOOGLE_ROWAN
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
+
config OAK_HAS_TPM2
bool
default y if BOARD_GOOGLE_ROWAN
default n
select MAINBOARD_HAS_I2C_TPM_CR50
+ select MAINBOARD_HAS_TPM2
config BOARD_SPECIFIC_OPTIONS
def_bool y
diff --git a/src/mainboard/google/octopus/Kconfig b/src/mainboard/google/octopus/Kconfig
index b0957b8e4247..94333c5c6b36 100644
--- a/src/mainboard/google/octopus/Kconfig
+++ b/src/mainboard/google/octopus/Kconfig
@@ -12,11 +12,12 @@ config BOARD_GOOGLE_BASEBOARD_OCTOPUS
select EC_GOOGLE_CHROMEEC
select EC_GOOGLE_CHROMEEC_BOARDID
select EC_GOOGLE_CHROMEEC_LPC
- select HAS_TPM if !VBOOT_MOCK_SECDATA
select HAVE_ACPI_RESUME
select HAVE_ACPI_TABLES
select MAINBOARD_HAS_CHROMEOS
select SOC_ESPI
+ select MAINBOARD_HAS_SPI_TPM_CR50
+ select MAINBOARD_HAS_TPM2
if BOARD_GOOGLE_BASEBOARD_OCTOPUS
@@ -68,14 +69,6 @@ config GBB_HWID
default "PHASER TEST 7167" if BOARD_GOOGLE_PHASER
default "OCTOPUS TEST 6859" if BOARD_GOOGLE_OCTOPUS
-config HAS_TPM
- bool
- default n
- select MAINBOARD_HAS_SPI_TPM_CR50
- select MAINBOARD_HAS_TPM2
- select SPI_TPM
- select TPM2
-
config MAX_CPUS
int
default 4
diff --git a/src/mainboard/google/parrot/Kconfig b/src/mainboard/google/parrot/Kconfig
index fa45e4a4b45c..50f28e79e1d6 100644
--- a/src/mainboard/google/parrot/Kconfig
+++ b/src/mainboard/google/parrot/Kconfig
@@ -13,6 +13,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select HAVE_ACPI_RESUME
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
select INTEL_INT15
# Workaround for EC/KBC IRQ1.
select SERIRQ_CONTINUOUS_MODE
diff --git a/src/mainboard/google/parrot/romstage.c b/src/mainboard/google/parrot/romstage.c
index 12c11141c2e5..30fa7c22b8b6 100644
--- a/src/mainboard/google/parrot/romstage.c
+++ b/src/mainboard/google/parrot/romstage.c
@@ -36,7 +36,7 @@
#include <cpu/x86/msr.h>
#include <halt.h>
#include <cbfs.h>
-#include <security/tpm/tis.h>
+#include <security/tpm/tspi.h>
#include "ec/compal/ene932/ec.h"
void pch_enable_lpc(void)
diff --git a/src/mainboard/google/peach_pit/Kconfig b/src/mainboard/google/peach_pit/Kconfig
index 542176a25c28..84b4804af37f 100644
--- a/src/mainboard/google/peach_pit/Kconfig
+++ b/src/mainboard/google/peach_pit/Kconfig
@@ -25,6 +25,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select MAINBOARD_FORCE_NATIVE_VGA_INIT
select HAVE_LINEAR_FRAMEBUFFER
select DRIVER_PARADE_PS8625
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select VBOOT_VBNV_EC
diff --git a/src/mainboard/google/poppy/Kconfig b/src/mainboard/google/poppy/Kconfig
index 14ea3a5482ba..ad08dd464d84 100644
--- a/src/mainboard/google/poppy/Kconfig
+++ b/src/mainboard/google/poppy/Kconfig
@@ -13,6 +13,8 @@ config BOARD_GOOGLE_BASEBOARD_POPPY
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_USES_FSP2_0
select SOC_INTEL_KABYLAKE
+ select MAINBOARD_HAS_SPI_TPM_CR50
+ select MAINBOARD_HAS_TPM2
if BOARD_GOOGLE_BASEBOARD_POPPY
@@ -33,15 +35,15 @@ config DEVICETREE
default "variants/baseboard/devicetree.cb"
config DRIVER_TPM_I2C_BUS
- depends on VARIANT_HAS_I2C_TPM
+ depends on MAINBOARD_HAS_I2C_TPM_CR50
default 0x1
config DRIVER_TPM_I2C_ADDR
- depends on VARIANT_HAS_I2C_TPM
+ depends on MAINBOARD_HAS_I2C_TPM_CR50
default 0x50
config DRIVER_TPM_SPI_BUS
- depends on VARIANT_HAS_SPI_TPM
+ depends on MAINBOARD_HAS_SPI_TPM_CR50
default 0x1
config GBB_HWID
@@ -127,27 +129,11 @@ config VARIANT_DIR
default "nocturne" if BOARD_GOOGLE_NOCTURNE
default "soraka" if BOARD_GOOGLE_SORAKA
-# Select this option to enable use of cr50 I2C TPM on the variant.
-config VARIANT_HAS_I2C_TPM
- bool
- default n
- select I2C_TPM
- select MAINBOARD_HAS_I2C_TPM_CR50
- select TPM2
-
# Select this option to enable camera ACPI support on the variant.
config VARIANT_HAS_CAMERA_ACPI
bool
default n
-# Select this option to enable use of cr50 SPI TPM on the variant.
-config VARIANT_HAS_SPI_TPM
- bool
- default n
- select MAINBOARD_HAS_SPI_TPM_CR50
- select SPI_TPM
- select TPM2
-
config VARIANT_SPECIFIC_OPTIONS_ATLAS
def_bool n
select CHROMEOS_WIFI_SAR if CHROMEOS
@@ -156,14 +142,12 @@ config VARIANT_SPECIFIC_OPTIONS_ATLAS
select DRIVERS_PS2_KEYBOARD
select DRIVERS_SPI_ACPI
select EXCLUDE_NATIVE_SD_INTERFACE
- select VARIANT_HAS_SPI_TPM if !VBOOT_MOCK_SECDATA
config VARIANT_SPECIFIC_OPTIONS_POPPY
def_bool n
select DRIVERS_I2C_MAX98927
select NO_FADT_8042
select VARIANT_HAS_CAMERA_ACPI
- select VARIANT_HAS_I2C_TPM if !VBOOT_MOCK_SECDATA
config VARIANT_SPECIFIC_OPTIONS_NAMI
def_bool n
@@ -173,7 +157,6 @@ config VARIANT_SPECIFIC_OPTIONS_NAMI
select DRIVERS_PS2_KEYBOARD
select DRIVERS_SPI_ACPI
select EXCLUDE_NATIVE_SD_INTERFACE
- select VARIANT_HAS_SPI_TPM if !VBOOT_MOCK_SECDATA
config VARIANT_SPECIFIC_OPTIONS_NAUTILUS
def_bool n
@@ -182,7 +165,6 @@ config VARIANT_SPECIFIC_OPTIONS_NAUTILUS
select DRIVERS_I2C_DA7219
select DRIVERS_PS2_KEYBOARD
select VARIANT_HAS_CAMERA_ACPI
- select VARIANT_HAS_I2C_TPM if !VBOOT_MOCK_SECDATA
config VARIANT_SPECIFIC_OPTIONS_NOCTURNE
def_bool n
@@ -191,14 +173,12 @@ config VARIANT_SPECIFIC_OPTIONS_NOCTURNE
select DRIVERS_I2C_DA7219
select DRIVERS_SPI_ACPI
select EXCLUDE_NATIVE_SD_INTERFACE
- select VARIANT_HAS_SPI_TPM if !VBOOT_MOCK_SECDATA
config VARIANT_SPECIFIC_OPTIONS_SORAKA
def_bool n
select DRIVERS_I2C_MAX98927
select NO_FADT_8042
select VARIANT_HAS_CAMERA_ACPI
- select VARIANT_HAS_I2C_TPM if !VBOOT_MOCK_SECDATA
config VBOOT
select EC_GOOGLE_CHROMEEC_SWITCHES
diff --git a/src/mainboard/google/purin/Kconfig b/src/mainboard/google/purin/Kconfig
index ebe6fe19f691..f48c33c98cd5 100644
--- a/src/mainboard/google/purin/Kconfig
+++ b/src/mainboard/google/purin/Kconfig
@@ -25,6 +25,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select SPI_FLASH
select SPI_FLASH_SPANSION
select SPI_FLASH_STMICRO # required for the reference board BCM958305K
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select VBOOT_VBNV_FLASH
diff --git a/src/mainboard/google/rambi/Kconfig b/src/mainboard/google/rambi/Kconfig
index 3db8ac6c8dbe..440276dd1278 100644
--- a/src/mainboard/google/rambi/Kconfig
+++ b/src/mainboard/google/rambi/Kconfig
@@ -10,6 +10,7 @@ config BOARD_GOOGLE_BASEBOARD_RAMBI
select HAVE_ACPI_RESUME
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
select SYSTEM_TYPE_LAPTOP if !BOARD_GOOGLE_NINJA && !BOARD_GOOGLE_SUMO
if BOARD_GOOGLE_BASEBOARD_RAMBI
diff --git a/src/mainboard/google/reef/Kconfig b/src/mainboard/google/reef/Kconfig
index bea7fd02844e..9214421a29ac 100644
--- a/src/mainboard/google/reef/Kconfig
+++ b/src/mainboard/google/reef/Kconfig
@@ -13,10 +13,9 @@ config BOARD_GOOGLE_BASEBOARD_REEF
select EC_GOOGLE_CHROMEEC_LPC
select HAVE_ACPI_RESUME
select HAVE_ACPI_TABLES
- select I2C_TPM
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_I2C_TPM_CR50
- select TPM2
+ select MAINBOARD_HAS_TPM2
select GOOGLE_SMBIOS_MAINBOARD_VERSION
select DRIVERS_INTEL_WIFI
select USE_SAR
diff --git a/src/mainboard/google/rotor/Kconfig b/src/mainboard/google/rotor/Kconfig
index 437fa02c1838..7a864937d53a 100644
--- a/src/mainboard/google/rotor/Kconfig
+++ b/src/mainboard/google/rotor/Kconfig
@@ -20,6 +20,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select SOC_MARVELL_MVMAP2315
select MAINBOARD_HAS_CHROMEOS
select BOARD_ROMSIZE_KB_4096
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select VBOOT_MOCK_SECDATA
diff --git a/src/mainboard/google/slippy/Kconfig b/src/mainboard/google/slippy/Kconfig
index 392333a32887..c43b713ec0cd 100644
--- a/src/mainboard/google/slippy/Kconfig
+++ b/src/mainboard/google/slippy/Kconfig
@@ -13,6 +13,7 @@ config BOARD_GOOGLE_BASEBOARD_SLIPPY
select HAVE_SMI_HANDLER
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
select INTEL_INT15
select MAINBOARD_HAS_LIBGFXINIT
diff --git a/src/mainboard/google/smaug/Kconfig b/src/mainboard/google/smaug/Kconfig
index 86c187d3b3a1..a8c69851c129 100644
--- a/src/mainboard/google/smaug/Kconfig
+++ b/src/mainboard/google/smaug/Kconfig
@@ -29,6 +29,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select SOC_NVIDIA_TEGRA210
select MAINBOARD_DO_DSI_INIT
select MAINBOARD_HAS_CHROMEOS
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select EC_GOOGLE_CHROMEEC_SWITCHES
diff --git a/src/mainboard/google/storm/Kconfig b/src/mainboard/google/storm/Kconfig
index cd66a92198ac..b8fc326db899 100644
--- a/src/mainboard/google/storm/Kconfig
+++ b/src/mainboard/google/storm/Kconfig
@@ -27,6 +27,8 @@ config BOARD_SPECIFIC_OPTIONS
select SPI_FLASH_SPANSION
select SPI_FLASH_STMICRO
select DRIVERS_UART
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select VBOOT_DISABLE_DEV_ON_RECOVERY
diff --git a/src/mainboard/google/stout/Kconfig b/src/mainboard/google/stout/Kconfig
index eca4eaeada10..ebec5a516789 100644
--- a/src/mainboard/google/stout/Kconfig
+++ b/src/mainboard/google/stout/Kconfig
@@ -14,6 +14,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select HAVE_ACPI_RESUME
select MAINBOARD_HAS_CHROMEOS
select MAINBOARD_HAS_LPC_TPM
+ select MAINBOARD_HAS_TPM1
select INTEL_INT15
select SANDYBRIDGE_IVYBRIDGE_LVDS
diff --git a/src/mainboard/google/stout/romstage.c b/src/mainboard/google/stout/romstage.c
index 4f7f869a9cfd..9ad03f736660 100644
--- a/src/mainboard/google/stout/romstage.c
+++ b/src/mainboard/google/stout/romstage.c
@@ -36,7 +36,7 @@
#include <cpu/x86/msr.h>
#include <halt.h>
#include <bootmode.h>
-#include <security/tpm/tis.h>
+#include <security/tpm/tspi.h>
#include <cbfs.h>
#include <ec/quanta/it8518/ec.h>
#include "ec.h"
diff --git a/src/mainboard/google/urara/Kconfig b/src/mainboard/google/urara/Kconfig
index 3d415c4a3e5e..2c4431c829ea 100644
--- a/src/mainboard/google/urara/Kconfig
+++ b/src/mainboard/google/urara/Kconfig
@@ -24,6 +24,8 @@ config BOARD_SPECIFIC_OPTIONS
select CPU_IMGTEC_PISTACHIO
select COMMON_CBFS_SPI_WRAPPER
select SPI_FLASH
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config MAINBOARD_DIR
string
diff --git a/src/mainboard/google/veyron/Kconfig b/src/mainboard/google/veyron/Kconfig
index f051b3d84165..6aef4ce9152b 100644
--- a/src/mainboard/google/veyron/Kconfig
+++ b/src/mainboard/google/veyron/Kconfig
@@ -40,6 +40,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select SPI_FLASH
select SPI_FLASH_GIGADEVICE
select SPI_FLASH_WINBOND
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select VBOOT_VBNV_EC
diff --git a/src/mainboard/google/veyron_mickey/Kconfig b/src/mainboard/google/veyron_mickey/Kconfig
index 6b7b4334af9e..c283f0e906cb 100644
--- a/src/mainboard/google/veyron_mickey/Kconfig
+++ b/src/mainboard/google/veyron_mickey/Kconfig
@@ -25,6 +25,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select SPI_FLASH
select SPI_FLASH_GIGADEVICE
select SPI_FLASH_WINBOND
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select VBOOT_PHYSICAL_REC_SWITCH
diff --git a/src/mainboard/google/veyron_rialto/Kconfig b/src/mainboard/google/veyron_rialto/Kconfig
index 6cea9f05acfa..a8971d8fcbe8 100644
--- a/src/mainboard/google/veyron_rialto/Kconfig
+++ b/src/mainboard/google/veyron_rialto/Kconfig
@@ -25,6 +25,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select SPI_FLASH
select SPI_FLASH_GIGADEVICE
select SPI_FLASH_WINBOND
+ select MAINBOARD_HAS_I2C_TPM_GENERIC
+ select MAINBOARD_HAS_TPM1
config VBOOT
select VBOOT_PHYSICAL_REC_SWITCH
diff --git a/src/mainboard/google/zoombini/Kconfig b/src/mainboard/google/zoombini/Kconfig
index 78ef386aa1c9..d28f6621a399 100644
--- a/src/mainboard/google/zoombini/Kconfig
+++ b/src/mainboard/google/zoombini/Kconfig
@@ -97,17 +97,15 @@ config VBOOT
config ZOOMBINI_USE_I2C_TPM
bool
default n
- select I2C_TPM
select MAINBOARD_HAS_I2C_TPM_CR50
- select TPM2
+ select MAINBOARD_HAS_TPM2
# Select this option to enable use of cr50 SPI TPM on zoombini.
config ZOOMBINI_USE_SPI_TPM
bool
default y
select MAINBOARD_HAS_SPI_TPM_CR50
- select SPI_TPM
- select TPM2
+ select MAINBOARD_HAS_TPM2
config TPM_TIS_ACPI_INTERRUPT
int