Code Review
/
kvmfornfv.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Merge "These changes are the raw update to qemu-2.6."
[kvmfornfv.git]
/
qemu
/
xen-common.c
diff --git
a/qemu/xen-common.c
b/qemu/xen-common.c
index
0dcdbc3
..
e641ad1
100644
(file)
--- a/
qemu/xen-common.c
+++ b/
qemu/xen-common.c
@@
-8,6
+8,7
@@
* GNU GPL, version 2 or (at your option) any later version.
*/
* GNU GPL, version 2 or (at your option) any later version.
*/
+#include "qemu/osdep.h"
#include "hw/xen/xen_backend.h"
#include "qmp-commands.h"
#include "sysemu/char.h"
#include "hw/xen/xen_backend.h"
#include "qmp-commands.h"
#include "sysemu/char.h"
@@
-113,11
+114,17
@@
static void xen_change_state_handler(void *opaque, int running,
static int xen_init(MachineState *ms)
{
static int xen_init(MachineState *ms)
{
- xen_xc = x
en_x
c_interface_open(0, 0, 0);
- if (xen_xc ==
XC_HANDLER_INITIAL_VALUE
) {
+ xen_xc = xc_interface_open(0, 0, 0);
+ if (xen_xc ==
NULL
) {
xen_be_printf(NULL, 0, "can't open xen interface\n");
return -1;
}
xen_be_printf(NULL, 0, "can't open xen interface\n");
return -1;
}
+ xen_fmem = xenforeignmemory_open(0, 0);
+ if (xen_fmem == NULL) {
+ xen_be_printf(NULL, 0, "can't open xen fmem interface\n");
+ xc_interface_close(xen_xc);
+ return -1;
+ }
qemu_add_vm_change_state_handler(xen_change_state_handler, NULL);
global_state_set_optional();
qemu_add_vm_change_state_handler(xen_change_state_handler, NULL);
global_state_set_optional();