aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/virtio/virtio_pci.c
diff options
context:
space:
mode:
authorAmit Shah <amit.shah@redhat.com>2012-03-29 12:50:20 +0530
committerAmit Shah <amit.shah@redhat.com>2012-03-31 08:09:50 +0530
commitf38f8387cbdc4138a492ce9f2a5f04fd3cd3cf33 (patch)
tree037dfe639de15cbf6be59182872531a23cc20398 /drivers/virtio/virtio_pci.c
parentvirtio: balloon: Allow stats update after restore from S4 (diff)
downloadlinux-dev-f38f8387cbdc4138a492ce9f2a5f04fd3cd3cf33.tar.xz
linux-dev-f38f8387cbdc4138a492ce9f2a5f04fd3cd3cf33.zip
virtio: drop thaw PM operation
The thaw operation was used by the balloon driver, but after the last commit there's no reason to have separate thaw and restore callbacks. Signed-off-by: Amit Shah <amit.shah@redhat.com>
Diffstat (limited to 'drivers/virtio/virtio_pci.c')
-rw-r--r--drivers/virtio/virtio_pci.c28
1 files changed, 1 insertions, 27 deletions
diff --git a/drivers/virtio/virtio_pci.c b/drivers/virtio/virtio_pci.c
index 635e1efb3792..a35a402dfd78 100644
--- a/drivers/virtio/virtio_pci.c
+++ b/drivers/virtio/virtio_pci.c
@@ -773,32 +773,6 @@ static int restore_common(struct device *dev)
return ret;
}
-static int virtio_pci_thaw(struct device *dev)
-{
- struct pci_dev *pci_dev = to_pci_dev(dev);
- struct virtio_pci_device *vp_dev = pci_get_drvdata(pci_dev);
- struct virtio_driver *drv;
- int ret;
-
- ret = restore_common(dev);
- if (ret)
- return ret;
-
- drv = container_of(vp_dev->vdev.dev.driver,
- struct virtio_driver, driver);
-
- if (drv && drv->thaw)
- ret = drv->thaw(&vp_dev->vdev);
- else if (drv && drv->restore)
- ret = drv->restore(&vp_dev->vdev);
-
- /* Finally, tell the device we're all set */
- if (!ret)
- vp_set_status(&vp_dev->vdev, vp_dev->saved_status);
-
- return ret;
-}
-
static int virtio_pci_restore(struct device *dev)
{
struct pci_dev *pci_dev = to_pci_dev(dev);
@@ -824,7 +798,7 @@ static const struct dev_pm_ops virtio_pci_pm_ops = {
.suspend = virtio_pci_suspend,
.resume = virtio_pci_resume,
.freeze = virtio_pci_freeze,
- .thaw = virtio_pci_thaw,
+ .thaw = virtio_pci_restore,
.restore = virtio_pci_restore,
.poweroff = virtio_pci_suspend,
};