2023-07-17 12:23:32

by Andrei Coardos

[permalink] [raw]
Subject: [PATCH] gpio: eic-sprd: remove unneeded platform_set_drvdata() call

The platform_set_drvdata() call was never used, ever since the driver was
originally added.
It looks like this copy+paste left-over. Possibly the author copied from a
driver that had this line, but also had a remove hook.

Reviewed-by: Alexandru Ardelean <[email protected]>
Signed-off-by: Andrei Coardos <[email protected]>
---
drivers/gpio/gpio-eic-sprd.c | 1 -
1 file changed, 1 deletion(-)

diff --git a/drivers/gpio/gpio-eic-sprd.c b/drivers/gpio/gpio-eic-sprd.c
index 84352a6f4973..53db88ae2a20 100644
--- a/drivers/gpio/gpio-eic-sprd.c
+++ b/drivers/gpio/gpio-eic-sprd.c
@@ -653,7 +653,6 @@ static int sprd_eic_probe(struct platform_device *pdev)
return ret;
}

- platform_set_drvdata(pdev, sprd_eic);
return 0;
}

--
2.34.1



2023-07-17 14:43:16

by Andy Shevchenko

[permalink] [raw]
Subject: Re: [PATCH] gpio: eic-sprd: remove unneeded platform_set_drvdata() call

On Mon, Jul 17, 2023 at 03:10:04PM +0300, Andrei Coardos wrote:
> The platform_set_drvdata() call was never used, ever since the driver was
> originally added.
> It looks like this copy+paste left-over. Possibly the author copied from a
> driver that had this line, but also had a remove hook.

Reviewed-by: Andy Shevchenko <[email protected]>

--
With Best Regards,
Andy Shevchenko



2023-07-20 06:47:15

by Baolin Wang

[permalink] [raw]
Subject: Re: [PATCH] gpio: eic-sprd: remove unneeded platform_set_drvdata() call



On 7/17/2023 8:10 PM, Andrei Coardos wrote:
> The platform_set_drvdata() call was never used, ever since the driver was
> originally added.
> It looks like this copy+paste left-over. Possibly the author copied from a
> driver that had this line, but also had a remove hook.
>
> Reviewed-by: Alexandru Ardelean <[email protected]>
> Signed-off-by: Andrei Coardos <[email protected]>

LGTM. Thanks.
Reviewed-by: Baolin Wang <[email protected]>

> ---
> drivers/gpio/gpio-eic-sprd.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/drivers/gpio/gpio-eic-sprd.c b/drivers/gpio/gpio-eic-sprd.c
> index 84352a6f4973..53db88ae2a20 100644
> --- a/drivers/gpio/gpio-eic-sprd.c
> +++ b/drivers/gpio/gpio-eic-sprd.c
> @@ -653,7 +653,6 @@ static int sprd_eic_probe(struct platform_device *pdev)
> return ret;
> }
>
> - platform_set_drvdata(pdev, sprd_eic);
> return 0;
> }
>

2023-07-29 14:30:14

by Bartosz Golaszewski

[permalink] [raw]
Subject: Re: [PATCH] gpio: eic-sprd: remove unneeded platform_set_drvdata() call

On Mon, Jul 17, 2023 at 2:10 PM Andrei Coardos <[email protected]> wrote:
>
> The platform_set_drvdata() call was never used, ever since the driver was
> originally added.
> It looks like this copy+paste left-over. Possibly the author copied from a
> driver that had this line, but also had a remove hook.
>
> Reviewed-by: Alexandru Ardelean <[email protected]>
> Signed-off-by: Andrei Coardos <[email protected]>
> ---
> drivers/gpio/gpio-eic-sprd.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/drivers/gpio/gpio-eic-sprd.c b/drivers/gpio/gpio-eic-sprd.c
> index 84352a6f4973..53db88ae2a20 100644
> --- a/drivers/gpio/gpio-eic-sprd.c
> +++ b/drivers/gpio/gpio-eic-sprd.c
> @@ -653,7 +653,6 @@ static int sprd_eic_probe(struct platform_device *pdev)
> return ret;
> }
>
> - platform_set_drvdata(pdev, sprd_eic);
> return 0;
> }
>
> --
> 2.34.1
>

Applied, thanks!

Bart