diff options
author | Jason Glenesk <jason.glenesk@amd.corp-partner.google.com> | 2020-09-11 12:36:15 -0700 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2020-09-15 13:41:58 +0000 |
commit | 201acca6340aef82e2b3c8cb15c61f7a7f13be92 (patch) | |
tree | b6ebac9a5780b6c0bbe77c47183b15b0b5a53ea1 /src/acpi/acpigen.c | |
parent | 11c1b94d033d1a9009c8a4270118b83abdf9cee8 (diff) |
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>
Diffstat (limited to 'src/acpi/acpigen.c')
-rw-r--r-- | src/acpi/acpigen.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/acpi/acpigen.c b/src/acpi/acpigen.c index 44f9106296..7910cbcbc1 100644 --- a/src/acpi/acpigen.c +++ b/src/acpi/acpigen.c @@ -850,8 +850,8 @@ void acpigen_write_CST_package_entry(acpi_cstate_t *cstate) { 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 @@ void acpigen_write_CST_package(acpi_cstate_t *cstate, int nentries) 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 @@ void acpigen_write_CSD_package(u32 domain, u32 numprocs, CSD_coord coordtype, 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); |