Nico Huber merged this change.
Fix one more -Wmissing-field-initializers warning
Fixes:
ichspi.c: In function ‘ich_init_spi’:
ichspi.c:1707:9: warning: missing initializer for field ‘component’
Change-Id: Iee5728167963fece24822ad2e3ab7bd9d444b42c
Signed-off-by: Richard Hughes <richard@hughsie.com>
Reviewed-on: https://review.coreboot.org/c/31224
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
---
M ichspi.c
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/ichspi.c b/ichspi.c
index 507d443..911f50a 100644
--- a/ichspi.c
+++ b/ichspi.c
@@ -1704,7 +1704,7 @@
char *arg;
int ich_spi_rw_restricted = 0;
int desc_valid = 0;
- struct ich_descriptors desc = { 0 };
+ struct ich_descriptors desc;
enum ich_spi_mode {
ich_auto,
ich_hwseq,
@@ -1715,6 +1715,8 @@
ich_generation = ich_gen;
ich_spibar = spibar;
+ memset(&desc, 0x00, sizeof(struct ich_descriptors));
+
/* Moving registers / bits */
if (ich_generation == CHIPSET_100_SERIES_SUNRISE_POINT) {
num_freg = 10;
To view, visit change 31224. To unsubscribe, or for help writing mail filters, visit settings.