Felix Held has submitted this change. ( https://review.coreboot.org/c/coreboot/+/45339 )
Change subject: acpi: Correct sizes for ACPI data fields ......................................................................
acpi: Correct sizes for ACPI data fields
Correct sizes of Count, Type, and Latency data field in _CST object to integer, byte, word, respectively. Correct size of NumEntries data field in _CSD object to integer.
BUG=b:155307433 TEST=Boot Morphius and dump SSDT _CST and _CSD objects. Confirm that sizes written conform to ACPI_6_3_May16.pdf ACPI specification. BRANCH=Zork
Change-Id: I356b46f2fa787e18442a66280b6545a3b525a08b Signed-off-by: Jason Glenesk jason.glenesk@amd.corp-partner.google.com Reviewed-on: https://review.coreboot.org/c/coreboot/+/45339 Reviewed-by: Furquan Shaikh furquan@google.com Reviewed-by: Marshall Dawson marshalldawson3rd@gmail.com Reviewed-by: Raul Rangel rrangel@chromium.org Tested-by: build bot (Jenkins) no-reply@coreboot.org --- M src/acpi/acpigen.c 1 file changed, 4 insertions(+), 4 deletions(-)
Approvals: build bot (Jenkins): Verified Furquan Shaikh: Looks good to me, approved Marshall Dawson: Looks good to me, approved Raul Rangel: Looks good to me, approved
diff --git a/src/acpi/acpigen.c b/src/acpi/acpigen.c index 44f9106..7910cbc 100644 --- a/src/acpi/acpigen.c +++ b/src/acpi/acpigen.c @@ -850,8 +850,8 @@ { acpigen_write_package(4); acpigen_write_register_resource(&cstate->resource); - acpigen_write_dword(cstate->ctype); - acpigen_write_dword(cstate->latency); + acpigen_write_byte(cstate->ctype); + acpigen_write_word(cstate->latency); acpigen_write_dword(cstate->power); acpigen_pop_len(); } @@ -861,7 +861,7 @@ int i; acpigen_write_name("_CST"); acpigen_write_package(nentries+1); - acpigen_write_dword(nentries); + acpigen_write_integer(nentries);
for (i = 0; i < nentries; i++) acpigen_write_CST_package_entry(cstate + i); @@ -875,7 +875,7 @@ acpigen_write_name("_CSD"); acpigen_write_package(1); acpigen_write_package(6); - acpigen_write_byte(6); // 6 values + acpigen_write_integer(6); // 6 values acpigen_write_byte(0); // revision 0 acpigen_write_dword(domain); acpigen_write_dword(coordtype);