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@xxxxxxxxxx> --- drivers/mmc/host/moxart-mmc.c | 2 -- 1 file changed, 2 deletions(-) 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)) -- 2.25.1