libxenlight: use watch and select in libxl_wait_for_device_model
PATCH 1/1 libxenlight: use watch and select in libxl_wait_for_device_model
Hi all,
this patch reimplements libxl_wait_for_device_model using a xenstore watch and a select loop.
Signed-off-by Stefano Stabellini <[email protected]>
---
tools/libxl/libxl.c +1 -0
@@ -888,6 +888,7 @@ *starting_r =libxl_calloc (ctx,sizeof (libxl_device_model_starting),1 );if (!*starting_r) goto xit; p = *starting_r; + p->for_spawn =libxl_calloc (ctx,sizeof (struct libxl_spawn_starting ),1 ); }else { p = &buf_starting; p->for_spawn =NULL ;
tools/libxl/libxl_device.c +33 -17
64 lines not on this page · raw message
tools/libxl/libxl_internal.h +1 -0
@@ -28,6 +28,7 @@#include "libxl_utils.h" #define LIBXL_DESTROY_TIMEOUT 10 +#define LIBXL_DEVICE_MODEL_START_TIMEOUT 10#define LIBXL_XENCONSOLE_LIMIT 1048576#define LIBXL_XENCONSOLE_PROTOCOL "vt100"#define QEMU_SIGNATURE "QemuDeviceModelRecord"