Skip to content
Snippets Groups Projects
Commit 52c7265f authored by Konrad Rzeszutek Wilk's avatar Konrad Rzeszutek Wilk Committed by Stefano Stabellini
Browse files

xen/pt: xen_host_pci_config_read returns -errno, not -1 on failure


However the init routines assume that on errors the return
code is -1 (as the libxc API is) - while those xen_host_* routines follow
another paradigm - negative errno on return, 0 on success.

Reviewed-by: default avatarStefano Stabellini <stefano.stabellini@eu.citrix.com>
Signed-off-by: default avatarKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Signed-off-by: default avatarStefano Stabellini <stefano.stabellini@eu.citrix.com>
parent cf8124f0
No related branches found
No related tags found
No related merge requests found
......@@ -729,7 +729,7 @@ static int xen_pt_initfn(PCIDevice *d)
/* Initialize virtualized PCI configuration (Extended 256 Bytes) */
if (xen_host_pci_get_block(&s->real_device, 0, d->config,
PCI_CONFIG_SPACE_SIZE) == -1) {
PCI_CONFIG_SPACE_SIZE) < 0) {
xen_host_pci_device_put(&s->real_device);
return -1;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment