From mboxrd@z Thu Jan 1 00:00:00 1970 From: Phil Sutter Date: Wed, 13 Jan 2016 10:42:45 +0100 Subject: [U-Boot] [PATCH v3 10/10] mvebu: ds414: Implement Synology specific command set In-Reply-To: <56960832.1030809@denx.de> References: <1451050886-20124-1-git-send-email-phil@nwl.cc> <20151225134013.C56016121B@mail.nwl.cc> <56960832.1030809@denx.de> Message-ID: <20160113094245.GA4253@orbyte.nwl.cc> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Stefan, On Wed, Jan 13, 2016 at 09:17:54AM +0100, Stefan Roese wrote: > I'm preparing a branch for Luka to pull from. With all the pending > mvebu patches included. And noticed a small issue with this patch. > See below... > > On 25.12.2015 14:41, Phil Sutter wrote: [...] > > +static int do_syno(cmd_tbl_t *cmdtp, int flag, > > + int argc, char * const argv[]) > > +{ > > + const char *cmd; > > + int ret; > > + > > + if (argc < 2) > > + goto usage; > > + > > + cmd = argv[1]; > > + --argc; > > + ++argv; > > + > > + if (!strcmp(cmd, "populate_env")) > > + ret = do_syno_populate(argc, argv); > > + else if (!strcmp(cmd, "clk_gate")) > > + ret = do_syno_clk_gate(argc, argv); > > + > > + if (ret != -1) > > + return ret; > > Here I get this warning: > > board/Synology/common/cmd_syno.c: In function 'do_syno': > board/Synology/common/cmd_syno.c:216:5: warning: 'ret' may be used uninitialized in this function [-Wmaybe-uninitialized] > if (ret != -1) > ^ > > I've changed this to init ret to 0 in my branch. Let me know if this > is okay with you. Yes, sure! I have to admit, I didn't spend much time on this file. It was always merely for fixing the "real" issues. Thanks, Phil