Skip to content

Commit 45d3393

Browse files
weiyjdavem330
authored andcommitted
net: mediatek: 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: Wei Yongjun <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 5288b6f commit 45d3393

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

drivers/net/ethernet/mediatek/mtk_eth_soc.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1892,7 +1892,6 @@ static int mtk_remove(struct platform_device *pdev)
18921892
netif_napi_del(&eth->tx_napi);
18931893
netif_napi_del(&eth->rx_napi);
18941894
mtk_cleanup(eth);
1895-
platform_set_drvdata(pdev, NULL);
18961895

18971896
return 0;
18981897
}

0 commit comments

Comments
 (0)