From: Wei Yongjun Date: Thu, 15 Sep 2016 02:25:52 +0000 (+0000) Subject: net: emac: remove unnecessary dev_set_drvdata() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=7e5eded5c189abaea77556da41af1195af841b0a;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git net: emac: remove unnecessary dev_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 Signed-off-by: David S. Miller --- diff --git a/drivers/net/ethernet/qualcomm/emac/emac.c b/drivers/net/ethernet/qualcomm/emac/emac.c index 56e0a9f1c5ec..42d2d233b60f 100644 --- a/drivers/net/ethernet/qualcomm/emac/emac.c +++ b/drivers/net/ethernet/qualcomm/emac/emac.c @@ -722,7 +722,6 @@ static int emac_remove(struct platform_device *pdev) mdiobus_unregister(adpt->mii_bus); free_netdev(netdev); - dev_set_drvdata(&pdev->dev, NULL); return 0; }