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: <CACRpkdYi-y9zWAR71rQOtKVJOuGgE4n8Q47YXZW=Pt345UWDkw@mail.gmail.com>
Date: Sun, 28 Jan 2024 16:49:42 +0100
From: Linus Walleij <linus.walleij@...aro.org>
To: Jacky Huang <ychuang570808@...il.com>
Cc: robh+dt@...nel.org, krzysztof.kozlowski+dt@...aro.org, conor+dt@...nel.org, 
	p.zabel@...gutronix.de, j.neuschaefer@....net, 
	linux-arm-kernel@...ts.infradead.org, linux-gpio@...r.kernel.org, 
	devicetree@...r.kernel.org, linux-kernel@...r.kernel.org, 
	ychuang3@...oton.com, schung@...oton.com
Subject: Re: [PATCH v3 4/4] pinctrl: nuvoton: Add ma35d1 pinctrl and GPIO driver

Hi Jacky,

thanks for your patch!

this caught my eye:

On Tue, Jan 23, 2024 at 9:06 AM Jacky Huang <ychuang570808@...il.com> wrote:

> From: Jacky Huang <ychuang3@...oton.com>
>
> Add common pinctrl and GPIO driver for Nuvoton MA35 series SoC, and
> add support for ma35d1 pinctrl.
>
> Signed-off-by: Jacky Huang <ychuang3@...oton.com>
(...)

> +       if (ma35_pinconf_get_power_source(npctl, pin) == MVOLT_1800) {
> +               for (i = 0; i < sizeof(ds_1800mv_tbl) / sizeof(u32); i++) {

Isn't this equivalent to:

for (i = 0; i < ARRAY_SIZE(ds_1800mv_tbl; i++) {

> +                       if (ds_1800mv_tbl[i] == strength)
> +                               ds_val = i;
> +               }
> +       } else {
> +               for (i = 0; i < sizeof(ds_3300mv_tbl) / sizeof(u32); i++) {

Dito

Perhaps more cases, pls check!

Yours,
Linus Walleij

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ