From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tom Rini Date: Thu, 14 Feb 2019 07:22:10 -0500 Subject: [U-Boot] [PATCH] lib/crc16: use non-C99 loop style In-Reply-To: <1AE354E8-4434-485A-9B67-719F3D414E2B@theobroma-systems.com> References: <20190213215728.21603-1-thomas.petazzoni@bootlin.com> <20190214003133.GC21737@bill-the-cat> <9A6E6FE9-1037-4D47-BB1C-21D775A8557C@theobroma-systems.com> <20190214085615.3bbcbd47@windsurf> <1AE354E8-4434-485A-9B67-719F3D414E2B@theobroma-systems.com> Message-ID: <20190214122210.GD21737@bill-the-cat> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit To: u-boot@lists.denx.de On Thu, Feb 14, 2019 at 12:35:12PM +0100, Philipp Tomsich wrote: > Tom & Thomas, > > > On 14.02.2019, at 08:56, Thomas Petazzoni wrote: > > > > However, generally speaking is U-Boot interested in allowing this kind > > of C99 variable declaration ? For example, the Linux kernel coding > > style doesn't allow this, but perhaps U-Boot has made a difference > > choice here. > > > I took the opportunity to see how widespread the use of this style already > is in U-Boot (as it will eventually creep in, now that we’ve moved to GCC6 > or newer) and there’s only a few occurences to date: > > board/synopsys/hsdk/env-lib.c: for (u32 i = 0; i < NR_CPUS; i++) { > board/synopsys/hsdk/env-lib.c: for (u32 i = 0; i < NR_CPUS; i++) { > board/synopsys/hsdk/env-lib.c: for (u32 i = 0; i < NR_CPUS; i++) { > board/synopsys/hsdk/env-lib.c: for (u32 i = 0; map[i].env_name; i++) > board/synopsys/hsdk/env-lib.c: for (u32 i = 0; map[i].env_name; i++) > board/synopsys/hsdk/env-lib.c: for (u32 i = 0; map[i].env_name; i++) { > board/synopsys/hsdk/env-lib.c: for (u32 i = 0; map[i].env_name; i++) { > board/synopsys/hsdk/env-lib.c: for (u32 i = 0; map[i].env_name; i++) { > board/synopsys/hsdk/env-lib.c: for (u32 i = 0; map[i].env_name; i++) { > board/synopsys/hsdk/hsdk.c: for (u32 i = 0; i < NR_CPUS; i++) { > board/synopsys/hsdk/hsdk.c: for (u32 i = 0; i < NR_CPUS; i++) { > board/synopsys/hsdk/hsdk.c: for (u32 i = 0; i < NR_CPUS; i++) { > board/synopsys/hsdk/hsdk.c: for (u32 i = 0; i < NR_CPUS; i++) > board/synopsys/hsdk/hsdk.c: for (u32 i = MASTER_CPU_ID + 1; i < NR_CPUS; i++) > board/synopsys/hsdk/hsdk.c: for (u32 i = 0; i < NR_CPUS; i++) { > lib/crc16.c: for (int i = 0; i < len; i++) Well, lets go with the C99 flag instead for v2, thanks again! -- Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: not available URL: