From: Konrad Rzeszutek Wilk Date: Wed, 8 Jul 2015 19:58:41 +0000 (-0400) Subject: xen/pt: Don't slurp wholesale the PCI configuration registers X-Git-Tag: qemu-xen-4.7.0-rc1~24 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=f6787aedc9043bffc5ee5b64c6d46b8fc7298a96;p=qemu-xen.git xen/pt: Don't slurp wholesale the PCI configuration registers Instead we have the emulation registers ->init functions which consult the host values to see what the initial value should be and they are responsible for populating the dev.config. Reviewed-by: Stefano Stabellini Signed-off-by: Konrad Rzeszutek Wilk Signed-off-by: Stefano Stabellini --- diff --git a/hw/xen/xen_pt.c b/hw/xen/xen_pt.c index da9015c191..aa96288236 100644 --- a/hw/xen/xen_pt.c +++ b/hw/xen/xen_pt.c @@ -790,12 +790,7 @@ static int xen_pt_initfn(PCIDevice *d) } /* Initialize virtualized PCI configuration (Extended 256 Bytes) */ - rc = xen_host_pci_get_block(&s->real_device, 0, d->config, - PCI_CONFIG_SPACE_SIZE); - if (rc < 0) { - XEN_PT_ERR(d,"Could not read PCI_CONFIG space! (rc:%d)\n", rc); - goto err_out; - } + memset(d->config, 0, PCI_CONFIG_SPACE_SIZE); s->memory_listener = xen_pt_memory_listener; s->io_listener = xen_pt_io_listener;