summaryrefslogtreecommitdiffstats
path: root/hw/virtio/virtio-pci.h
diff options
context:
space:
mode:
authorMarcel Apfelbaum2017-02-20 21:43:13 +0100
committerMichael S. Tsirkin2017-03-16 00:46:41 +0100
commit27ce0f3afc9dd25d21b43bbce505157afd93d111 (patch)
tree765cac6b398ed0b05851097e4c958a6a03362a38 /hw/virtio/virtio-pci.h
parenthw/virtio: fix Link Control Register for PCI Express virtio devices (diff)
downloadqemu-27ce0f3afc9dd25d21b43bbce505157afd93d111.tar.gz
qemu-27ce0f3afc9dd25d21b43bbce505157afd93d111.tar.xz
qemu-27ce0f3afc9dd25d21b43bbce505157afd93d111.zip
hw/virtio: fix Power Management Control Register for PCI Express virtio devices
Make Power Management State flag writable to conform with the PCI Express spec. Signed-off-by: Marcel Apfelbaum <marcel@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/virtio/virtio-pci.h')
-rw-r--r--hw/virtio/virtio-pci.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/hw/virtio/virtio-pci.h b/hw/virtio/virtio-pci.h
index 9b5dd5a752..b095dfc6d9 100644
--- a/hw/virtio/virtio-pci.h
+++ b/hw/virtio/virtio-pci.h
@@ -75,6 +75,7 @@ enum {
VIRTIO_PCI_FLAG_ATS_BIT,
VIRTIO_PCI_FLAG_INIT_DEVERR_BIT,
VIRTIO_PCI_FLAG_INIT_LNKCTL_BIT,
+ VIRTIO_PCI_FLAG_INIT_PM_BIT,
};
/* Need to activate work-arounds for buggy guests at vmstate load. */
@@ -108,6 +109,9 @@ enum {
/* Init Link Control register */
#define VIRTIO_PCI_FLAG_INIT_LNKCTL (1 << VIRTIO_PCI_FLAG_INIT_LNKCTL_BIT)
+/* Init Power Management */
+#define VIRTIO_PCI_FLAG_INIT_PM (1 << VIRTIO_PCI_FLAG_INIT_PM_BIT)
+
typedef struct {
MSIMessage msg;
int virq;