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: <CAH3L5QpuoDYU6qvWH7_z5Yx0cW2qPMbCA8AFEYAPsiEkSzCiwQ@mail.gmail.com>
Date:   Wed, 2 Aug 2023 15:37:02 +0300
From:   Alexandru Ardelean <alex@...uggie.ro>
To:     Andrei Coardos <aboutphysycs@...il.com>
Cc:     linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
        linux-stm32@...md-mailman.stormreply.com,
        linux-iio@...r.kernel.org, alexandre.torgue@...s.st.com,
        mcoquelin.stm32@...il.com, lars@...afoo.de, jic23@...nel.org
Subject: Re: [PATCH] iio: trigger: stm32-lptimer-trigger: remove unneeded platform_set_drvdata()

On Wed, Aug 2, 2023 at 3:09 PM Andrei Coardos <aboutphysycs@...il.com> wrote:
>
> This function call was found to be unnecessary as there is no equivalent
> platform_get_drvdata() call to access the private data of the driver. Also,
> the private data is defined in this driver, so there is no risk of it being
> accessed outside of this driver file.
>
> Reviewed-by: Alexandru Ardelean <alex@...uggie.ro>
> Signed-off-by: Andrei Coardos <aboutphysycs@...il.com>
> ---
>  drivers/iio/trigger/stm32-lptimer-trigger.c | 2 --
>  1 file changed, 2 deletions(-)
>
> diff --git a/drivers/iio/trigger/stm32-lptimer-trigger.c b/drivers/iio/trigger/stm32-lptimer-trigger.c
> index 2e447a3f047d..df2416e33375 100644
> --- a/drivers/iio/trigger/stm32-lptimer-trigger.c
> +++ b/drivers/iio/trigger/stm32-lptimer-trigger.c
> @@ -92,8 +92,6 @@ static int stm32_lptim_trigger_probe(struct platform_device *pdev)
>         if (ret)
>                 return ret;

this can become now:

            return stm32_lptim_setup_trig(priv);


>
> -       platform_set_drvdata(pdev, priv);
> -
>         return 0;
>  }
>
> --
> 2.34.1
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ