aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/virtio
diff options
context:
space:
mode:
authorLadi Prosek <lprosek@redhat.com>2016-02-01 13:36:31 -0500
committerMichael S. Tsirkin <mst@redhat.com>2016-03-02 10:01:49 -0500
commit4e94ebdd06d5dc72b7a40fc12fc496d601fb7bbc (patch)
tree113da9721a062241f4108c993d29bdb67740cd36 /drivers/virtio
parentfc77dbd34c5c99bce46d40a2491937c3bcbd10af (diff)
virtio-pci: read the right virtio_pci_notify_cap field
Looks like a copy-paste bug. The value is used as an optimization and a wrong value probably isn't causing any serious damage. Found when porting this code to Windows. Signed-off-by: Ladi Prosek <lprosek@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'drivers/virtio')
-rw-r--r--drivers/virtio/virtio_pci_modern.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/virtio/virtio_pci_modern.c b/drivers/virtio/virtio_pci_modern.c
index c0c11fad4611..7760fc1a2218 100644
--- a/drivers/virtio/virtio_pci_modern.c
+++ b/drivers/virtio/virtio_pci_modern.c
@@ -679,7 +679,7 @@ int virtio_pci_modern_probe(struct virtio_pci_device *vp_dev)
679 679
680 pci_read_config_dword(pci_dev, 680 pci_read_config_dword(pci_dev,
681 notify + offsetof(struct virtio_pci_notify_cap, 681 notify + offsetof(struct virtio_pci_notify_cap,
682 cap.length), 682 cap.offset),
683 &notify_offset); 683 &notify_offset);
684 684
685 /* We don't know how many VQs we'll map, ahead of the time. 685 /* We don't know how many VQs we'll map, ahead of the time.