diff options
author | Wei Yongjun <weiyj.lk@gmail.com> | 2016-08-16 01:50:34 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-08-16 02:16:10 +0300 |
commit | 557bc7d44d52d52374bc72e9cc3b0beb41026886 (patch) | |
tree | 78fcd46b1523fc2bef2c74dfe282bd1ccb5165f4 /drivers | |
parent | 64721094b9a966c8e02d2b03729e5093471f9d1c (diff) | |
download | linux-557bc7d44d52d52374bc72e9cc3b0beb41026886.tar.xz |
net: ena: Remove unnecessary pci_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 <weiyj.lk@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ethernet/amazon/ena/ena_netdev.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/net/ethernet/amazon/ena/ena_netdev.c b/drivers/net/ethernet/amazon/ena/ena_netdev.c index 94790df2d559..499a22b165f1 100644 --- a/drivers/net/ethernet/amazon/ena/ena_netdev.c +++ b/drivers/net/ethernet/amazon/ena/ena_netdev.c @@ -3060,7 +3060,6 @@ err_device_destroy: err_free_region: ena_release_bars(ena_dev, pdev); err_free_ena_dev: - pci_set_drvdata(pdev, NULL); vfree(ena_dev); err_disable_device: pci_disable_device(pdev); @@ -3156,8 +3155,6 @@ static void ena_remove(struct pci_dev *pdev) ena_release_bars(ena_dev, pdev); - pci_set_drvdata(pdev, NULL); - pci_disable_device(pdev); ena_com_destroy_interrupt_moderation(ena_dev); |