summaryrefslogtreecommitdiff
path: root/src/soc/intel/alderlake
diff options
context:
space:
mode:
authorElyes Haouas <ehaouas@noos.fr>2023-07-28 06:15:03 +0200
committerFelix Singer <service+coreboot-gerrit@felixsinger.de>2023-07-31 04:29:12 +0000
commitb39abc7bab854c0cd923db778c80f9e67b85f51f (patch)
tree6320a1a1018c706ded4af11bccceb06f917d12fb /src/soc/intel/alderlake
parentf7926461da1b080d78860dd5c9fba6cb8452dbd6 (diff)
soc/intel/alderlake/hsphy.c: Use C99 flexible arrays
Use C99 flexible arrays instead of older style of one-element or zero-length arrays. It allows the compiler to generate errors when the flexible array does not occur at the end in the structure. Change-Id: Id0baf970dbe94a8ebf75f8dbabc6abe345d1c454 Signed-off-by: Elyes Haouas <ehaouas@noos.fr> Reviewed-on: https://review.coreboot.org/c/coreboot/+/76783 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Arthur Heymans <arthur@aheymans.xyz> Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de>
Diffstat (limited to 'src/soc/intel/alderlake')
-rw-r--r--src/soc/intel/alderlake/hsphy.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/soc/intel/alderlake/hsphy.c b/src/soc/intel/alderlake/hsphy.c
index 5333a8bf2f..005d85149f 100644
--- a/src/soc/intel/alderlake/hsphy.c
+++ b/src/soc/intel/alderlake/hsphy.c
@@ -34,13 +34,13 @@ struct hsphy_cache {
uint32_t hsphy_size;
uint8_t hash_algo;
uint8_t digest[MAX_HASH_SIZE];
- uint8_t hsphy_fw[0];
+ uint8_t hsphy_fw[];
} __packed;
struct ip_push_model {
uint16_t count;
uint16_t address;
- uint32_t data[0];
+ uint32_t data[];
} __packed;
static int heci_get_hsphy_payload(void *buf, uint32_t *buf_size, uint8_t *hash_buf,