From c83bab62b3657d97299c8368b6c610e4cbf994b6 Mon Sep 17 00:00:00 2001 From: Patrick Rudolph Date: Fri, 13 Dec 2019 12:16:06 +0100 Subject: acpi: Be more ACPI compliant when generating _UID * Add function to generate unique _UID using CRC32 * Add function to write the _UID based on a device's ACPI path ACPI devices that have the same _HID must use different _UID. Linux doesn't care about _UID if it's not used. Windows 10 verifies the ACPI code on boot and BSODs if two devices with the same _HID share the same _UID. Fixes BSOD seen on Windows 10. Change-Id: I47cd5396060d325f9ce338afced6af021e7ff2b4 Signed-off-by: Patrick Rudolph Reviewed-on: https://review.coreboot.org/c/coreboot/+/37695 Tested-by: build bot (Jenkins) Reviewed-by: Philipp Deppenwiese --- src/drivers/crb/tis.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/drivers/crb') diff --git a/src/drivers/crb/tis.c b/src/drivers/crb/tis.c index f2aba48297..b1fbad01eb 100644 --- a/src/drivers/crb/tis.c +++ b/src/drivers/crb/tis.c @@ -117,7 +117,7 @@ static void crb_tpm_fill_ssdt(struct device *dev) acpigen_write_name_string("_HID", "MSFT0101"); acpigen_write_name_string("_CID", "MSFT0101"); - acpigen_write_name_integer("_UID", 1); + acpi_device_write_uid(dev); acpigen_write_STA(ACPI_STATUS_DEVICE_ALL_ON); -- cgit v1.2.3