[PATCH 1/3] of: unittest: Drop call to platform_set_drvdata(..., NULL)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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 <u.kleine-koenig@xxxxxxxxxxxxxx>
---
 drivers/of/unittest.c | 1 -
 1 file changed, 1 deletion(-)

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;
-- 
2.39.2




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux