Nico Huber merged this change.

View Change

Approvals: build bot (Jenkins): Verified Nico Huber: Looks good to me, approved
Fix several -Wno-missing-field-initializers warnings

Change-Id: Ib4487d4c1a38fa8471fa1f9034604412e9d14cf7
Signed-off-by: Richard Hughes <richard@hughsie.com>
Reviewed-on: https://review.coreboot.org/c/30405
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
---
M ichspi.c
M spi25.c
M util/ich_descriptors_tool/ich_descriptors_tool.c
3 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/ichspi.c b/ichspi.c
index 2144208..507d443 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 = { 0 };
enum ich_spi_mode {
ich_auto,
ich_hwseq,
diff --git a/spi25.c b/spi25.c
index f3a35a1..8b6c462 100644
--- a/spi25.c
+++ b/spi25.c
@@ -321,9 +321,11 @@
{
struct spi_command cmds[] = {
{
+ .readarr = 0,
.writecnt = 1,
.writearr = (const unsigned char[]){ JEDEC_WREN },
}, {
+ .readarr = 0,
.writecnt = 1,
.writearr = (const unsigned char[]){ op },
},
@@ -344,9 +346,11 @@
const uint8_t op = flash->chip->wrea_override ? : JEDEC_WRITE_EXT_ADDR_REG;
struct spi_command cmds[] = {
{
+ .readarr = 0,
.writecnt = 1,
.writearr = (const unsigned char[]){ JEDEC_WREN },
}, {
+ .readarr = 0,
.writecnt = 2,
.writearr = (const unsigned char[]){ op, regdata },
},
@@ -419,9 +423,11 @@
uint8_t cmd[1 + JEDEC_MAX_ADDR_LEN + 256];
struct spi_command cmds[] = {
{
+ .readarr = 0,
.writecnt = 1,
.writearr = (const unsigned char[]){ JEDEC_WREN },
}, {
+ .readarr = 0,
.writearr = cmd,
},
NULL_SPI_CMD,
diff --git a/util/ich_descriptors_tool/ich_descriptors_tool.c b/util/ich_descriptors_tool/ich_descriptors_tool.c
index aec97d0..aa857c8 100644
--- a/util/ich_descriptors_tool/ich_descriptors_tool.c
+++ b/util/ich_descriptors_tool/ich_descriptors_tool.c
@@ -150,7 +150,7 @@
const char *fn = NULL;
const char *csn = NULL;
enum ich_chipset cs = CHIPSET_ICH_UNKNOWN;
- struct ich_descriptors desc = {{ 0 }};
+ struct ich_descriptors desc = { 0 };

while ((opt = getopt(argc, argv, "df:c:")) != -1) {
switch (opt) {

To view, visit change 30405. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Ib4487d4c1a38fa8471fa1f9034604412e9d14cf7
Gerrit-Change-Number: 30405
Gerrit-PatchSet: 3
Gerrit-Owner: Nico Huber <nico.h@gmx.de>
Gerrit-Reviewer: Nico Huber <nico.h@gmx.de>
Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org>
Gerrit-MessageType: merged