Felix Held has submitted this change. ( https://review.coreboot.org/c/coreboot/+/80454?usp=email )
Change subject: drivers/crb: Disable device if CRB TPM not present ......................................................................
drivers/crb: Disable device if CRB TPM not present
If CRB TPM is not detected in the system it may mean it is inactive due to disabled or neutered ME. In such case, the chipset will route the TPM traffic to LPC/SPI on Intel systems.
If CRB TPM is not probed, disable the CRB TPM device driver, so that coreboot will not generate improper SMBIOS/SSDT ACPI tables.
Change-Id: Ie0928536d9042b1f680d585e1ca9ad2cadf0c8ef Signed-off-by: Michał Żygowski michal.zygowski@3mdeb.com Reviewed-on: https://review.coreboot.org/c/coreboot/+/80454 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Lean Sheng Tan sheng.tan@9elements.com Reviewed-by: Sergii Dmytruk sergii.dmytruk@3mdeb.com --- M src/drivers/crb/tis.c 1 file changed, 5 insertions(+), 0 deletions(-)
Approvals: build bot (Jenkins): Verified Lean Sheng Tan: Looks good to me, but someone else must approve Sergii Dmytruk: Looks good to me, approved
diff --git a/src/drivers/crb/tis.c b/src/drivers/crb/tis.c index 5e81935..df45125 100644 --- a/src/drivers/crb/tis.c +++ b/src/drivers/crb/tis.c @@ -207,6 +207,11 @@
static void enable_dev(struct device *dev) { + if (crb_tis_probe(NULL) == NULL) { + dev->enabled = 0; + return; + } + #if !DEVTREE_EARLY dev->ops = &crb_ops; #endif