ethernet: broadcom: remove unnecessary platform_set_drvdata()
authorJingoo Han <jg1.han@samsung.com>
Thu, 22 Aug 2013 01:57:20 +0000 (10:57 +0900)
committerDavid S. Miller <davem@davemloft.net>
Thu, 22 Aug 2013 22:12:21 +0000 (15:12 -0700)
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: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/bcm63xx_enet.c

index 89ff09ec7d288f9ec4a24fc42f6ba871868527b2..190219e0240062549973be2f8ea9191763625e47 100644 (file)
@@ -2836,7 +2836,6 @@ static int bcm_enetsw_remove(struct platform_device *pdev)
        res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
        release_mem_region(res->start, resource_size(res));
 
-       platform_set_drvdata(pdev, NULL);
        free_netdev(dev);
        return 0;
 }