diff mbox series

[1/2] ACPI: APEI: Drop unsetting driver data on remove

Message ID 20221013064459.121933-1-u.kleine-koenig@pengutronix.de
State Accepted
Commit 36006ccb6bc7d8c7937277f985efddf658d7a1f9
Headers show
Series [1/2] ACPI: APEI: Drop unsetting driver data on remove | expand

Commit Message

Uwe Kleine-König Oct. 13, 2022, 6:44 a.m. UTC
Since commit 0998d0631001 ("device-core: Ensure drvdata = NULL when no
driver is bound") the driver core cares for cleaning driver data, so
don't do it in the driver, too.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
 drivers/acpi/apei/ghes.c | 2 --
 1 file changed, 2 deletions(-)


base-commit: 4fe89d07dcc2804c8b562f6c7896a45643d34b2f

Comments

Rafael J. Wysocki Oct. 28, 2022, 4:39 p.m. UTC | #1
On Thu, Oct 13, 2022 at 8:53 AM Uwe Kleine-König
<u.kleine-koenig@pengutronix.de> wrote:
>
> Since commit 0998d0631001 ("device-core: Ensure drvdata = NULL when no
> driver is bound") the driver core cares for cleaning driver data, so
> don't do it in the driver, too.
>
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
> ---
>  drivers/acpi/apei/ghes.c | 2 --
>  1 file changed, 2 deletions(-)
>
> diff --git a/drivers/acpi/apei/ghes.c b/drivers/acpi/apei/ghes.c
> index d91ad378c00d..307fbb97a116 100644
> --- a/drivers/acpi/apei/ghes.c
> +++ b/drivers/acpi/apei/ghes.c
> @@ -1444,8 +1444,6 @@ static int ghes_remove(struct platform_device *ghes_dev)
>
>         kfree(ghes);
>
> -       platform_set_drvdata(ghes_dev, NULL);
> -
>         return 0;
>  }
>
>
> base-commit: 4fe89d07dcc2804c8b562f6c7896a45643d34b2f
> --

Applied as 6.2 material, thanks!
diff mbox series

Patch

diff --git a/drivers/acpi/apei/ghes.c b/drivers/acpi/apei/ghes.c
index d91ad378c00d..307fbb97a116 100644
--- a/drivers/acpi/apei/ghes.c
+++ b/drivers/acpi/apei/ghes.c
@@ -1444,8 +1444,6 @@  static int ghes_remove(struct platform_device *ghes_dev)
 
 	kfree(ghes);
 
-	platform_set_drvdata(ghes_dev, NULL);
-
 	return 0;
 }