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] [day] [month] [year] [list]
Message-ID: <CAMRc=Mettq0xOPx7cgzk=-szp=FrzyWkCiW8NxC9WWyDnAM4dg@mail.gmail.com>
Date:   Tue, 1 Aug 2023 21:21:42 +0200
From:   Bartosz Golaszewski <brgl@...ev.pl>
To:     Andrei Coardos <aboutphysycs@...il.com>
Cc:     linux-kernel@...r.kernel.org, linux-gpio@...r.kernel.org,
        andy@...nel.org, linus.walleij@...aro.org,
        Alexandru Ardelean <alex@...uggie.ro>
Subject: Re: [PATCH v2] gpio: max77620: remove unneeded platform_set_drvdata() call

On Tue, Jul 25, 2023 at 2:36 PM Andrei Coardos <aboutphysycs@...il.com> wrote:
>
> This function call is not required because no counterpart
> platform_get_drvdata() call is present to leverage the private data of
> the driver.
> Since the private data is confined to this driver file, external access
> is not feasible.
> The use of this function appears redundant in the current context of the
> driver's implementation.
>
> Reviewed-by: Alexandru Ardelean <alex@...uggie.ro>
> Signed-off-by: Andrei Coardos <aboutphysycs@...il.com>
> ---
>
> Changelog V1->V2:
>
> * https://lore.kernel.org/linux-gpio/20230720132535.23413-1-aboutphysycs@gmail.com/
> * fixed subject line: adjusted colons where needed
>
>  drivers/gpio/gpio-max77620.c | 2 --
>  1 file changed, 2 deletions(-)
>
> diff --git a/drivers/gpio/gpio-max77620.c b/drivers/gpio/gpio-max77620.c
> index c18b60e39a94..8c2a5609161f 100644
> --- a/drivers/gpio/gpio-max77620.c
> +++ b/drivers/gpio/gpio-max77620.c
> @@ -331,8 +331,6 @@ static int max77620_gpio_probe(struct platform_device *pdev)
>         girq->init_hw = max77620_gpio_irq_init_hw;
>         girq->threaded = true;
>
> -       platform_set_drvdata(pdev, mgpio);
> -
>         ret = devm_gpiochip_add_data(&pdev->dev, &mgpio->gpio_chip, mgpio);
>         if (ret < 0) {
>                 dev_err(&pdev->dev, "gpio_init: Failed to add max77620_gpio\n");
> --
> 2.34.1
>

Applied, thanks!

Bartosz

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ