From 7a8305f1bd452a74a1679e75383f888b48e67f4d Mon Sep 17 00:00:00 2001 From: David Hendricks Date: Fri, 1 Sep 2017 20:16:58 -0700 Subject: [PATCH] ich_descriptors: Use MAX_NUM_FLREGS for entries[] 5 regions made sense in 2013 when this bit of code was originally written. MAX_NUM_FLREGS is now used to keep track of the max number of flash regions and is >5 since Sunrise Point. Change-Id: Idb559e618369fecf930724a7c1c84765247f3e38 Signed-off-by: David Hendricks Reviewed-on: https://review.coreboot.org/21338 Tested-by: build bot (Jenkins) Reviewed-by: Nico Huber --- ich_descriptors.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ich_descriptors.h b/ich_descriptors.h index 9a16031ef..db4d28f01 100644 --- a/ich_descriptors.h +++ b/ich_descriptors.h @@ -568,7 +568,7 @@ struct ich_descriptors { struct ich_layout { struct flashrom_layout base; - struct romentry entries[5]; + struct romentry entries[MAX_NUM_FLREGS]; }; ssize_t ich_number_of_regions(enum ich_chipset cs, const struct ich_desc_content *content);