diff options
author | Jon Mason <jon.mason@exar.com> | 2010-11-30 18:43:26 -0500 |
---|---|---|
committer | Jesse Barnes <jbarnes@virtuousgeek.org> | 2010-12-23 15:53:09 -0500 |
commit | 1d3c16a818e992c199844954d95c17fd7ce6cbba (patch) | |
tree | 6f54b4153b8f7e54bdb5a8abc3ceffa7b4eec0e2 /drivers/net/wireless/rt2x00 | |
parent | 2f671e2dbff6eb5ef4e2600adbec550c13b8fe72 (diff) |
PCI: make pci_restore_state return void
pci_restore_state only ever returns 0, thus there is no benefit in
having it return any value. Also, a large majority of the callers do
not check the return code of pci_restore_state. Make the
pci_restore_state a void return and avoid the overhead.
Acked-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Jon Mason <jon.mason@exar.com>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Diffstat (limited to 'drivers/net/wireless/rt2x00')
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2x00pci.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00pci.c b/drivers/net/wireless/rt2x00/rt2x00pci.c index 2449d785cf8d..4fd4c33de6ae 100644 --- a/drivers/net/wireless/rt2x00/rt2x00pci.c +++ b/drivers/net/wireless/rt2x00/rt2x00pci.c | |||
@@ -356,12 +356,12 @@ int rt2x00pci_resume(struct pci_dev *pci_dev) | |||
356 | struct rt2x00_dev *rt2x00dev = hw->priv; | 356 | struct rt2x00_dev *rt2x00dev = hw->priv; |
357 | 357 | ||
358 | if (pci_set_power_state(pci_dev, PCI_D0) || | 358 | if (pci_set_power_state(pci_dev, PCI_D0) || |
359 | pci_enable_device(pci_dev) || | 359 | pci_enable_device(pci_dev)) { |
360 | pci_restore_state(pci_dev)) { | ||
361 | ERROR(rt2x00dev, "Failed to resume device.\n"); | 360 | ERROR(rt2x00dev, "Failed to resume device.\n"); |
362 | return -EIO; | 361 | return -EIO; |
363 | } | 362 | } |
364 | 363 | ||
364 | pci_restore_state(pci_dev); | ||
365 | return rt2x00lib_resume(rt2x00dev); | 365 | return rt2x00lib_resume(rt2x00dev); |
366 | } | 366 | } |
367 | EXPORT_SYMBOL_GPL(rt2x00pci_resume); | 367 | EXPORT_SYMBOL_GPL(rt2x00pci_resume); |