pinctrl: sh-pfc: remove unnecessary platform_set_drvdata()
PATCH 1/1 pinctrl: sh-pfc: remove unnecessary platform_set_drvdata()
The driver core clears the driver data to NULL after device_release or on probe failure. Thus, it is not needed to manually clear the device driver data to NULL.
Signed-off-by Jingoo Han <[email protected]>
--- drivers/pinctrl/sh-pfc/core.c | 2 -- 1 file changed, 2 deletions(-)
drivers/pinctrl/sh-pfc/core.c +0 -2
@@ -539,8 +539,6 @@ static int sh_pfc_remove(struct platform_device *pdev)if (pfc->info->ops && pfc->info->ops->exit) pfc->info->ops->exit (pfc); -platform_set_drvdata (pdev,NULL ); -return 0 ; }
Signature · 1 line
1.7.10.4
Hi Jingoo,
Thank you for the patch.
Quoted 5 lines · On Thursday 22 August 2013 11:00:55 Jingoo Han wrote:
The driver core clears the driver data to NULL after
device_releaseor on probe failure. Thus, it is not needed to manually clear the device driver data to NULL.Signed-off-by Jingoo Han <[email protected]>
Acked-by Laurent Pinchart <[email protected]>
Linus, can you take this for v3.12 ? If it's too late I'll take it in my tree and will include it in the v3.13 pull request.
Quoted 16 lines
--- drivers/pinctrl/sh-pfc/core.c | 2 -- 1 file changed, 2 deletions(-)drivers/pinctrl/sh-pfc/core.c +0
-2@@ -539,8 +539,6 @@ static int sh_pfc_remove(struct platform_device *pdev)if (pfc->info->ops && pfc->info->ops->exit) pfc->info->ops->exit (pfc); -platform_set_drvdata (pdev,NULL ); -return 0 ; }
Signature · 3 lines
Regards, Laurent Pinchart