Commit 515adc14 authored by Jingoo Han's avatar Jingoo Han Committed by John W. Linville

wireless: rt2x00: 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: default avatarJingoo Han <jg1.han@samsung.com>
Acked-by: default avatarGertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent c44354d2
...@@ -156,8 +156,6 @@ int rt2x00pci_probe(struct pci_dev *pci_dev, const struct rt2x00_ops *ops) ...@@ -156,8 +156,6 @@ int rt2x00pci_probe(struct pci_dev *pci_dev, const struct rt2x00_ops *ops)
exit_disable_device: exit_disable_device:
pci_disable_device(pci_dev); pci_disable_device(pci_dev);
pci_set_drvdata(pci_dev, NULL);
return retval; return retval;
} }
EXPORT_SYMBOL_GPL(rt2x00pci_probe); EXPORT_SYMBOL_GPL(rt2x00pci_probe);
...@@ -177,7 +175,6 @@ void rt2x00pci_remove(struct pci_dev *pci_dev) ...@@ -177,7 +175,6 @@ void rt2x00pci_remove(struct pci_dev *pci_dev)
/* /*
* Free the PCI device data. * Free the PCI device data.
*/ */
pci_set_drvdata(pci_dev, NULL);
pci_disable_device(pci_dev); pci_disable_device(pci_dev);
pci_release_regions(pci_dev); pci_release_regions(pci_dev);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment