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: <CAMRc=MfnN0sD=yb7NO6ixHC-mhv2Cg5qw_wb8cZGtg23chwmOg@mail.gmail.com>
Date: Wed, 17 Dec 2025 10:30:04 +0100
From: Bartosz Golaszewski <brgl@...nel.org>
To: Rosen Penev <rosenp@...il.com>
Cc: linux-gpio@...r.kernel.org, Linus Walleij <linusw@...nel.org>, 
	open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 3/3] gpio: realtek-otto: use of instead of device handlers

On Wed, Dec 17, 2025 at 7:32 AM Rosen Penev <rosenp@...il.com> wrote:
>
> This is an OF only driver. No point in using generic device handlers.
>
> Signed-off-by: Rosen Penev <rosenp@...il.com>
> ---
>  drivers/gpio/gpio-realtek-otto.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpio/gpio-realtek-otto.c b/drivers/gpio/gpio-realtek-otto.c
> index efcddbe01308..8bad43afc586 100644
> --- a/drivers/gpio/gpio-realtek-otto.c
> +++ b/drivers/gpio/gpio-realtek-otto.c
> @@ -372,10 +372,10 @@ static int realtek_gpio_probe(struct platform_device *pdev)
>         if (!ctrl)
>                 return -ENOMEM;
>
> -       dev_flags = (unsigned int)(kernel_ulong_t)device_get_match_data(dev);
> +       dev_flags = (unsigned int)(kernel_ulong_t)of_device_get_match_data(dev);
>
>         ngpios = REALTEK_GPIO_MAX;
> -       device_property_read_u32(dev, "ngpios", &ngpios);
> +       of_property_read_u32(dev->of_node, "ngpios", &ngpios);
>
>         if (ngpios > REALTEK_GPIO_MAX) {
>                 dev_err(&pdev->dev, "invalid ngpios (max. %d)\n",
> --
> 2.52.0
>

Yeah, no, there's almost *never* a point in using OF-specific accessors. NAK.

Bart

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ