Last batch of important fixups intertwined with various cleanups and stability fixes: Lots of more values checking, and abort as soon as there are errors. Contains a critical usability fix regarding waitpid (typo in option) and without this batch it''s very easy to trigger a SIGBUS in xenstored. The library is now robust to: - missing xenstored - missing xenctrl privcmd - not enough memory to build a domain - missing vif devices - and some usually unexpected situation not addressed yet: fixup stubdomains building to have the same robustness. Vincent Hanquez (6): tests a lots more of xl return value inside the library and in xl. do not try to set memory target with a number we haven''t verified in set-mem. misc cleanup typo in old patch, lead to waitpid forever instead of waitpid with WNOHANG remove ctx argument to exec remove ctx dangerously passed to children. tools/libxl/libxl.c | 54 +++++++++++++++++++++++++---------------- tools/libxl/libxl_exec.c | 22 +++++++--------- tools/libxl/libxl_internal.h | 7 +---- tools/libxl/xl.c | 39 +++++++++++++++++++++++++---- 4 files changed, 78 insertions(+), 44 deletions(-) _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Vincent Hanquez
2010-Jan-11 21:48 UTC
[Xen-devel] [PATCH 1/6] tests a lots more of xl return value inside the library and in xl.
introducing a domain where the xenguest build function has fail, lead to having xenstored receiving SIGBUS, since it''s trying to access some of the domain''s memory, which haven''t been properly allocated. (it doesn''t seems to be a way to make xenstored more robust to this though since xc_map_foreign_range just succeed). make xl a lot more robust regarding all those random errors possible. Signed-off-by: Vincent Hanquez <vincent.hanquez@eu.citrix.com> --- tools/libxl/libxl.c | 37 +++++++++++++++++++++++++------------ tools/libxl/xl.c | 29 ++++++++++++++++++++++++----- 2 files changed, 49 insertions(+), 17 deletions(-) _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Vincent Hanquez
2010-Jan-11 21:48 UTC
[Xen-devel] [PATCH 2/6] do not try to set memory target with a number we haven''t verified in set-mem.
checking that memory string conversion what done properly instead of sending a request to balloon a domain to 0 memory. Signed-off-by: Vincent Hanquez <vincent.hanquez@eu.citrix.com> --- tools/libxl/xl.c | 10 +++++++++- 1 files changed, 9 insertions(+), 1 deletions(-) _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
wait_for_device_model expect two pointer as the end not 2 integers. remove debugging message in libxl_list Signed-off-by: Vincent Hanquez <vincent.hanquez@eu.citrix.com> --- tools/libxl/libxl.c | 9 ++++----- 1 files changed, 4 insertions(+), 5 deletions(-) _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Vincent Hanquez
2010-Jan-11 21:48 UTC
[Xen-devel] [PATCH 4/6] typo in old patch, lead to waitpid forever instead of waitpid with WNOHANG
fix qemu starting problem Signed-off-by: Vincent Hanquez <vincent.hanquez@eu.citrix.com> --- tools/libxl/libxl_exec.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Signed-off-by: Vincent Hanquez <vincent.hanquez@eu.citrix.com> --- tools/libxl/libxl.c | 4 ++-- tools/libxl/libxl_exec.c | 4 +--- tools/libxl/libxl_internal.h | 3 +-- 3 files changed, 4 insertions(+), 7 deletions(-) _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Vincent Hanquez
2010-Jan-11 21:48 UTC
[Xen-devel] [PATCH 6/6] remove ctx dangerously passed to children.
apart from ctx->waitpid, it''s potentially harmful to call into logging. Signed-off-by: Vincent Hanquez <vincent.hanquez@eu.citrix.com> --- tools/libxl/libxl.c | 4 ++-- tools/libxl/libxl_exec.c | 14 +++++++------- tools/libxl/libxl_internal.h | 4 +--- 3 files changed, 10 insertions(+), 12 deletions(-) _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel