lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20231001170540.yiouho2lrzrioxns@pengutronix.de>
Date:   Sun, 1 Oct 2023 19:05:40 +0200
From:   Uwe Kleine-König <u.kleine-koenig@...gutronix.de>
To:     André Apitzsch <git@...tzsch.eu>
Cc:     Christophe JAILLET <christophe.jaillet@...adoo.fr>,
        conor+dt@...nel.org, devicetree@...r.kernel.org,
        krzysztof.kozlowski+dt@...aro.org, lee@...nel.org,
        linux-kernel@...r.kernel.org, linux-leds@...r.kernel.org,
        pavel@....cz, phone-devel@...r.kernel.org, robh+dt@...nel.org,
        ~postmarketos/upstreaming@...ts.sr.ht
Subject: Re: [PATCH v5 2/2] leds: add ktd202x driver

Hello André,

On Sun, Oct 01, 2023 at 06:56:20PM +0200, André Apitzsch wrote:
> Am Sonntag, dem 01.10.2023 um 17:15 +0200 schrieb Christophe JAILLET:
> > Le 01/10/2023 à 15:52, André Apitzsch a écrit :
> > > +       for_each_available_child_of_node(np, child) {
> > > +               u32 mono_color = 0;
> > 
> > Un-needed init.
> > And, why is it defined here, while reg is defined out-side the loop?
> 
> I'll move it out-side the loop (without initialization).

In my book a variable with a narrow scope is better. I didn't check, but
if you can restrict both variables to the for loop, that's nicer.

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | https://www.pengutronix.de/ |

Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ