diff --git a/hw/pass-through.c b/hw/pass-through.c
-index 6a53137..3420e95 100644
+index 51a39db..10904c9 100644
--- a/hw/pass-through.c
+++ b/hw/pass-through.c
@@ -90,6 +90,8 @@
}
static uint8_t find_cap_offset(struct pci_dev *pci_dev, uint8_t cap)
-@@ -4084,3 +4130,41 @@ err:
+@@ -4113,3 +4159,41 @@ err:
return status;
}
#endif /* __PASSTHROUGH_H__ */
diff --git a/hw/pci.c b/hw/pci.c
-index d7c516e..b2f4d43 100644
+index d7c516e..ec8b0c4 100644
--- a/hw/pci.c
+++ b/hw/pci.c
@@ -28,11 +28,14 @@
struct PCIBus {
int bus_num;
int devfn_min;
-@@ -611,7 +614,30 @@ uint32_t pci_data_read(void *opaque, uint32_t addr, int len)
+@@ -611,7 +614,32 @@ uint32_t pci_data_read(void *opaque, uint32_t addr, int len)
goto the_end;
}
config_addr = addr & 0xff;
+ else if (len == 4)
+ val = pt_pci_host_read_long(0, 0, 0, 0x00);
+ }
++ if (config_addr == 0xa0 && len == 2)
++ val = pt_pci_host_read_word(0, 0, 0, 0xa0);
+ }
+ else if (vga_passthrough && pci_dev->devfn == 0x10 && // intel graphic card
+ config_addr == 0xfc) // OpRegion address
printf("pci_config_read: %s: addr=%02x val=%08x len=%d\n",
pci_dev->name, config_addr, val, len);
diff --git a/vl.c b/vl.c
-index b273c75..e519705 100644
+index cdbe2a3..6d79072 100644
--- a/vl.c
+++ b/vl.c
@@ -233,6 +233,7 @@ CharDriverState *virtcon_hds[MAX_VIRTIO_CONSOLES];
#endif
int usb_enabled = 0;
int smp_cpus = 1;
-@@ -4275,6 +4276,7 @@ enum {
+@@ -4287,6 +4288,7 @@ enum {
QEMU_OPTION_domainname,
QEMU_OPTION_acpi,
QEMU_OPTION_vcpus,
/* Debug/Expert options: */
QEMU_OPTION_serial,
-@@ -4448,6 +4450,7 @@ static const QEMUOption qemu_options[] = {
+@@ -4460,6 +4462,7 @@ static const QEMUOption qemu_options[] = {
{ "pciemulation", HAS_ARG, QEMU_OPTION_pci_emulation },
{ "vncunused", 0, QEMU_OPTION_vncunused },
{ "vcpus", HAS_ARG, QEMU_OPTION_vcpus },
#if defined(CONFIG_XEN) && !defined(CONFIG_DM)
{ "xen-domid", HAS_ARG, QEMU_OPTION_xen_domid },
{ "xen-create", 0, QEMU_OPTION_xen_create },
-@@ -5281,6 +5284,9 @@ int main(int argc, char **argv, char **envp)
+@@ -5293,6 +5296,9 @@ int main(int argc, char **argv, char **envp)
case QEMU_OPTION_disable_opengl:
opengl_enabled = 0;
break;