Angel Pons has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/46909 )
Change subject: soc/intel/broadwell/cpu/acpi.c: Clean up C-state generation ......................................................................
soc/intel/broadwell/cpu/acpi.c: Clean up C-state generation
Do not use `memcpy()` to initialize a single array element, and use the ARRAY_SIZE macro to specify the for-loop max instead of a magic number.
Change-Id: Ifdf3d6969eaa23c0aab058bbcc6e607bcf3c5736 Signed-off-by: Angel Pons th3fanbus@gmail.com --- M src/soc/intel/broadwell/cpu/acpi.c 1 file changed, 2 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/09/46909/1
diff --git a/src/soc/intel/broadwell/cpu/acpi.c b/src/soc/intel/broadwell/cpu/acpi.c index 56a4e99..a12fd0e 100644 --- a/src/soc/intel/broadwell/cpu/acpi.c +++ b/src/soc/intel/broadwell/cpu/acpi.c @@ -210,8 +210,8 @@ else set = cstate_set_non_s0ix;
- for (i = 0; i < 3; i++) { - memcpy(&map[i], &cstate_map[set[i]], sizeof(acpi_cstate_t)); + for (i = 0; i < ARRAY_SIZE(map); i++) { + map[i] = cstate_map[set[i]]; map[i].ctype = i + 1; }
Angel Pons has abandoned this change. ( https://review.coreboot.org/c/coreboot/+/46909 )
Change subject: soc/intel/broadwell/cpu/acpi.c: Clean up C-state generation ......................................................................
Abandoned
Scrapped