From: Anton Vorontsov Date: Tue, 1 Sep 2009 22:17:24 +0000 (+0400) Subject: fsl: sys_eeprom: Fix 'may be used uninitialized' warning X-Git-Tag: v2009.11-rc1~180 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=9c671e7062720074f894ee329eaa6995b0823727;p=oweals%2Fu-boot.git fsl: sys_eeprom: Fix 'may be used uninitialized' warning The warning is bogus, so silence it by initializing the 'ret' variable. Signed-off-by: Anton Vorontsov Acked-by: Timur Tabi Signed-off-by: Kumar Gala --- diff --git a/board/freescale/common/sys_eeprom.c b/board/freescale/common/sys_eeprom.c index c0fff686b1..661015e000 100644 --- a/board/freescale/common/sys_eeprom.c +++ b/board/freescale/common/sys_eeprom.c @@ -204,7 +204,8 @@ static void update_crc(void) */ static int prog_eeprom(void) { - int ret, i; + int ret = 0; /* shut up gcc */ + int i; void *p; #ifdef CONFIG_SYS_EEPROM_BUS_NUM unsigned int bus;