[PATCH 5/5] virtio-pci: switch to PM ops macro to initialise PM functions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Use the SET_SYSTEM_SLEEP_PM_OPS macro to initialise the suspend/resume
functions in the new PM API.

Signed-off-by: Amit Shah <amit.shah@xxxxxxxxxx>
---
 drivers/virtio/virtio_pci.c |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)

diff --git a/drivers/virtio/virtio_pci.c b/drivers/virtio/virtio_pci.c
index 0fa4f85..2e03d41 100644
--- a/drivers/virtio/virtio_pci.c
+++ b/drivers/virtio/virtio_pci.c
@@ -768,12 +768,7 @@ static int virtio_pci_restore(struct device *dev)
 }
 
 static const struct dev_pm_ops virtio_pci_pm_ops = {
-	.suspend	= virtio_pci_freeze,
-	.resume		= virtio_pci_restore,
-	.freeze		= virtio_pci_freeze,
-	.thaw		= virtio_pci_restore,
-	.restore	= virtio_pci_restore,
-	.poweroff	= virtio_pci_freeze,
+	SET_SYSTEM_SLEEP_PM_OPS(virtio_pci_freeze, virtio_pci_restore)
 };
 #endif
 
-- 
1.7.7.6

_______________________________________________
Virtualization mailing list
Virtualization@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linuxfoundation.org/mailman/listinfo/virtualization


[Index of Archives]     [KVM Development]     [Libvirt Development]     [Libvirt Users]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux