diff options
author | Wei Yongjun <weiyongjun1@huawei.com> | 2016-10-17 11:04:44 -0400 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2016-11-11 16:51:35 -0500 |
commit | 5b23e8fa46ca037e0f61df919e8a08659c0e7640 (patch) | |
tree | 721e19406486600a9fb98a5a76481133153a7e4b | |
parent | 1001354ca34179f3db924eb66672442a173147dc (diff) |
PCI: vmd: 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 <weiyongjun1@huawei.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Keith Busch <keith.busch@intel.com>
-rw-r--r-- | drivers/pci/host/vmd.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/pci/host/vmd.c b/drivers/pci/host/vmd.c index 37e29b580be3..6614b3552b9c 100644 --- a/drivers/pci/host/vmd.c +++ b/drivers/pci/host/vmd.c | |||
@@ -719,7 +719,6 @@ static void vmd_remove(struct pci_dev *dev) | |||
719 | struct vmd_dev *vmd = pci_get_drvdata(dev); | 719 | struct vmd_dev *vmd = pci_get_drvdata(dev); |
720 | 720 | ||
721 | vmd_detach_resources(vmd); | 721 | vmd_detach_resources(vmd); |
722 | pci_set_drvdata(dev, NULL); | ||
723 | sysfs_remove_link(&vmd->dev->dev.kobj, "domain"); | 722 | sysfs_remove_link(&vmd->dev->dev.kobj, "domain"); |
724 | pci_stop_root_bus(vmd->bus); | 723 | pci_stop_root_bus(vmd->bus); |
725 | pci_remove_root_bus(vmd->bus); | 724 | pci_remove_root_bus(vmd->bus); |