diff mbox series

[-next,3/4] mmc: moxart: remove unnecessary dev_set_drvdata()

Message ID 20230807141704.3486854-4-yangyingliang@huawei.com
State New
Headers show
Series mmc: remove unnecessary set_drvdata() function | expand

Commit Message

Yang Yingliang Aug. 7, 2023, 2:17 p.m. UTC
Remove unnecessary dev_set_drvdata(..., NULL) in ->remove(),
the driver_data will be set to NULL in device_unbind_cleanup()
after calling ->remove() in driver call code.

Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
---
 drivers/mmc/host/moxart-mmc.c | 2 --
 1 file changed, 2 deletions(-)
diff mbox series

Patch

diff --git a/drivers/mmc/host/moxart-mmc.c b/drivers/mmc/host/moxart-mmc.c
index d0d6ffcf78d4..43c2a95bc29a 100644
--- a/drivers/mmc/host/moxart-mmc.c
+++ b/drivers/mmc/host/moxart-mmc.c
@@ -692,8 +692,6 @@  static int moxart_remove(struct platform_device *pdev)
 	struct mmc_host *mmc = dev_get_drvdata(&pdev->dev);
 	struct moxart_host *host = mmc_priv(mmc);
 
-	dev_set_drvdata(&pdev->dev, NULL);
-
 	if (!IS_ERR_OR_NULL(host->dma_chan_tx))
 		dma_release_channel(host->dma_chan_tx);
 	if (!IS_ERR_OR_NULL(host->dma_chan_rx))