summaryrefslogtreecommitdiffstats
path: root/xen-hvm.c
diff options
context:
space:
mode:
authorIan Campbell <ian.campbell@citrix.com>2016-02-10 11:07:03 +0000
committerTimothy Pearson <tpearson@raptorengineering.com>2019-11-29 19:41:57 -0600
commit42f5b7c450ba9a6a64fd8dae353ea54a41b2a8ed (patch)
treef6046f51dfce03c194d4360783d51af04014aa15 /xen-hvm.c
parent1410086b09a182e230c9a84e26946fde0702a8ed (diff)
downloadhqemu-42f5b7c450ba9a6a64fd8dae353ea54a41b2a8ed.zip
hqemu-42f5b7c450ba9a6a64fd8dae353ea54a41b2a8ed.tar.gz
xen: drop XenXC and associated interface wrappers
Now that 4.2 and earlier are no longer supported "xc_interface *" is always the right type for the xc interface handle. With this we can also simplify the handling of the xenforeignmemory compatibility wrapper by making xenforeignmemory_handle == xc_interface, instead of an xc_interface* and remove various uses of & and *h. Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Reviewed-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Diffstat (limited to 'xen-hvm.c')
-rw-r--r--xen-hvm.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/xen-hvm.c b/xen-hvm.c
index 918cabc..fbe0e3a 100644
--- a/xen-hvm.c
+++ b/xen-hvm.c
@@ -1224,7 +1224,7 @@ void xen_hvm_init(PCMachineState *pcms, MemoryRegion **ram_memory)
&ioreq_pfn, &bufioreq_pfn,
&bufioreq_evtchn);
if (rc < 0) {
- error_report("failed to get ioreq server info: error %d handle=" XC_INTERFACE_FMT,
+ error_report("failed to get ioreq server info: error %d handle=%p",
errno, xen_xc);
goto err;
}
@@ -1237,7 +1237,7 @@ void xen_hvm_init(PCMachineState *pcms, MemoryRegion **ram_memory)
PROT_READ|PROT_WRITE,
1, &ioreq_pfn, NULL);
if (state->shared_page == NULL) {
- error_report("map shared IO page returned error %d handle=" XC_INTERFACE_FMT,
+ error_report("map shared IO page returned error %d handle=%p",
errno, xen_xc);
goto err;
}
@@ -1249,8 +1249,8 @@ void xen_hvm_init(PCMachineState *pcms, MemoryRegion **ram_memory)
xenforeignmemory_map(xen_fmem, xen_domid, PROT_READ|PROT_WRITE,
1, &ioreq_pfn, NULL);
if (state->shared_vmport_page == NULL) {
- error_report("map shared vmport IO page returned error %d handle="
- XC_INTERFACE_FMT, errno, xen_xc);
+ error_report("map shared vmport IO page returned error %d handle=%p",
+ errno, xen_xc);
goto err;
}
} else if (rc != -ENOSYS) {
@@ -1272,7 +1272,7 @@ void xen_hvm_init(PCMachineState *pcms, MemoryRegion **ram_memory)
rc = xen_set_ioreq_server_state(xen_xc, xen_domid, state->ioservid, true);
if (rc < 0) {
- error_report("failed to enable ioreq server info: error %d handle=" XC_INTERFACE_FMT,
+ error_report("failed to enable ioreq server info: error %d handle=%p",
errno, xen_xc);
goto err;
}
@@ -1333,11 +1333,11 @@ err:
void destroy_hvm_domain(bool reboot)
{
- XenXC xc_handle;
+ xc_interface *xc_handle;
int sts;
- xc_handle = xen_xc_interface_open(0, 0, 0);
- if (xc_handle == XC_HANDLER_INITIAL_VALUE) {
+ xc_handle = xc_interface_open(0, 0, 0);
+ if (xc_handle == NULL) {
fprintf(stderr, "Cannot acquire xenctrl handle\n");
} else {
sts = xc_domain_shutdown(xc_handle, xen_domid,
OpenPOWER on IntegriCloud