Re: [PATCH v2 3/5] sh: mach-rsk: rsk7203: use static device properties for LEDs and GPIO buttons
Andy Shevchenko <[email protected]> Wed, 3 Jun 2026 02:52:20 +0300
| Newsgroups | org.kernel.vger.linux-sh,org.kernel.vger.linux-gpio,org.kernel.vger.linux-kernel,org.kernel.vger.linux-renesas-soc |
|---|---|
| Organization | Intel Finland Oy - BIC 0357606-4 - c/o Alberga Business Park, 6 krs, Bertel Jungin Aukio 5, 02600 Espoo |
| Message-ID | <[email protected]> |
On Wed, Jun 03, 2026 at 02:45:39AM +0300, Andy Shevchenko wrote:
> On Tue, Jun 02, 2026 at 03:06:14PM -0700, Dmitry Torokhov wrote:
> > On Wed, Jun 03, 2026 at 01:02:56AM +0300, Andy Shevchenko wrote:
> > > On Wed, May 20, 2026 at 10:13:19PM -0700, Dmitry Torokhov wrote:
...
> > > > + for (i = 0; i < ARRAY_SIZE(rsk7203_devices); i++) {
> > >
> > > for (unsigned int i = 0; i < ARRAY_SIZE(rsk7203_devices); i++) {
> > >
> > > ...and drop the above definition of i.
> >
> > Why? I do not see coding style suggesting this.
>
> Linus Torvalds.
https://lore.kernel.org/lkml/CAHk-=wgy8p4is8ApEQCT5NS7XFb+NXeo-TKz7jRRZVksLLBSrQ@mail.gmail.com/
And IIRC it was another discussion (more recent than that) where he again
mentioned nice of use for-loops with local iterators.
--
With Best Regards,
Andy Shevchenko