From 6bb709e552adf1a4549404d6eeccc89d22e06993 Mon Sep 17 00:00:00 2001 From: Furquan Shaikh Date: Wed, 7 Dec 2016 07:35:01 -0800 Subject: [PATCH] UPSTREAM: soc/mediatek/mt8173: Do not initialize static variables to 0 CQ-DEPEND=CL:417080,CL:417081,CL:417087 BUG=None BRANCH=None TEST=None Signed-off-by: Furquan Shaikh Reviewed-on: https://review.coreboot.org/17765 Tested-by: build bot (Jenkins) Reviewed-by: Aaron Durbin Change-Id: Ibf0bd772bfdb3bbf6482a0ec9ff90a5c0a8945d2 Reviewed-on: https://chromium-review.googlesource.com/417958 Commit-Ready: Furquan Shaikh Tested-by: Furquan Shaikh Reviewed-by: Aaron Durbin --- src/soc/mediatek/mt8173/flash_controller.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/soc/mediatek/mt8173/flash_controller.c b/src/soc/mediatek/mt8173/flash_controller.c index 2aee66834f..f6f6e2a6c7 100644 --- a/src/soc/mediatek/mt8173/flash_controller.c +++ b/src/soc/mediatek/mt8173/flash_controller.c @@ -235,8 +235,8 @@ static int nor_erase(const struct spi_flash *flash, u32 offset, size_t len) struct spi_flash *spi_flash_programmer_probe(struct spi_slave *spi, int force) { - static struct spi_flash flash = {0}; - static int done = 0; + static struct spi_flash flash; + static int done; if (done) return &flash;