summaryrefslogtreecommitdiffstats
path: root/src/security/tpm/Makefile.inc
diff options
context:
space:
mode:
Diffstat (limited to 'src/security/tpm/Makefile.inc')
-rw-r--r--src/security/tpm/Makefile.inc51
1 files changed, 41 insertions, 10 deletions
diff --git a/src/security/tpm/Makefile.inc b/src/security/tpm/Makefile.inc
index 2385635f3251..9157fec386e8 100644
--- a/src/security/tpm/Makefile.inc
+++ b/src/security/tpm/Makefile.inc
@@ -1,14 +1,45 @@
+subdirs-$(CONFIG_TPM_CR50) += tss/vendor/cr50
+
## TSS
-verstage-$(CONFIG_TPM) += tss/tcg-1.2/tss.c
-verstage-$(CONFIG_TPM2) += tss/tcg-2.0/tss_marshaling.c
-verstage-$(CONFIG_TPM2) += tss/tcg-2.0/tss.c
+ifeq ($(CONFIG_TPM1),y)
+
+ramstage-y += tss/tcg-1.2/tss.c
+romstage-y += tss/tcg-1.2/tss.c
+
+verstage-$(CONFIG_VBOOT) += tss/tcg-1.2/tss.c
+postcar-$(CONFIG_VBOOT) += tss/tcg-1.2/tss.c
+
+## TSPI
+
+ramstage-y += tspi/tspi.c
+romstage-y += tspi/tspi.c
+
+verstage-$(CONFIG_VBOOT) += tspi/tspi.c
+postcar-$(CONFIG_VBOOT) += tspi/tspi.c
+
+endif # CONFIG_TPM1
+
+ifeq ($(CONFIG_TPM2),y)
+
+ramstage-y += tss/tcg-2.0/tss_marshaling.c
+ramstage-y += tss/tcg-2.0/tss.c
+
+romstage-y += tss/tcg-2.0/tss_marshaling.c
+romstage-y += tss/tcg-2.0/tss.c
+
+verstage-$(CONFIG_VBOOT) += tss/tcg-2.0/tss_marshaling.c
+verstage-$(CONFIG_VBOOT) += tss/tcg-2.0/tss.c
+
+postcar-$(CONFIG_VBOOT) += tss/tcg-2.0/tss_marshaling.c
+postcar-$(CONFIG_VBOOT) += tss/tcg-2.0/tss.c
+
+## TSPI
+
+ramstage-y += tspi/tspi.c
+romstage-y += tspi/tspi.c
-ifeq ($(CONFIG_VBOOT_SEPARATE_VERSTAGE),y)
-romstage-$(CONFIG_TPM) += tss/tcg-1.2/tss.c
-romstage-$(CONFIG_TPM2) += tss/tcg-2.0/tss_marshaling.c
-romstage-$(CONFIG_TPM2) += tss/tcg-2.0/tss.c
-endif # CONFIG_VBOOT_SEPARATE_VERSTAGE
+verstage-$(CONFIG_VBOOT) += tspi/tspi.c
+postcar-$(CONFIG_VBOOT) += tspi/tspi.c
-ramstage-$(CONFIG_TPM2) += tss/tcg-2.0/tss_marshaling.c
-ramstage-$(CONFIG_TPM2) += tss/tcg-2.0/tss.c
+endif # CONFIG_TPM2