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>
This commit is contained in:
Jason Glenesk 2020-09-11 12:36:15 -07:00 committed by Felix Held
parent 11c1b94d03
commit 201acca634
1 changed files with 4 additions and 4 deletions

View File

@ -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);