aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/of/unittest.c
diff options
context:
space:
mode:
authorUwe Kleine-König <[email protected]>2023-03-19 10:06:18 +0000
committerRob Herring <[email protected]>2023-03-20 19:59:08 +0000
commit5cdade2d77dd41a2ed98967c3887f5d66a4d23c4 (patch)
treea423f0a6dbea3ea26cb3f28d366030ca4a3b44e2 /drivers/of/unittest.c
parentdt-bindings: crypto: fsl,sec-v4.0: Convert to DT schema (diff)
downloadkernel-5cdade2d77dd41a2ed98967c3887f5d66a4d23c4.tar.gz
kernel-5cdade2d77dd41a2ed98967c3887f5d66a4d23c4.zip
of: unittest: Drop call to platform_set_drvdata(..., NULL)
The driver core already unsets driver data after .remove() completes. So there is no reason to do this explicitly in the driver itself. Signed-off-by: Uwe Kleine-König <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Rob Herring <[email protected]>
Diffstat (limited to 'drivers/of/unittest.c')
-rw-r--r--drivers/of/unittest.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/of/unittest.c b/drivers/of/unittest.c
index b5a7a31d8bd2..2504092e8302 100644
--- a/drivers/of/unittest.c
+++ b/drivers/of/unittest.c
@@ -1639,7 +1639,6 @@ static int unittest_gpio_remove(struct platform_device *pdev)
if (devptr->chip.base != -1)
gpiochip_remove(&devptr->chip);
- platform_set_drvdata(pdev, NULL);
kfree(devptr);
return 0;