search for: libxl_ctx

Displaying 20 results from an estimated 77 matches for "libxl_ctx".

2009 Nov 18
6
[PATCH 1/3] libxenlight: Clean up logging arrangements
...al.h | 11 ++++- tools/libxl/libxl_xshelp.c | 5 ++ 7 files changed, 124 insertions(+), 62 deletions(-) diff --git a/tools/libxl/libxl.c b/tools/libxl/libxl.c index 69690e4..5e2f23b 100644 --- a/tools/libxl/libxl.c +++ b/tools/libxl/libxl.c @@ -106,14 +106,17 @@ int libxl_domain_make(struct libxl_ctx *ctx, libxl_domain_create_info *info, ret = xc_domain_create(ctx->xch, info->ssidref, handle, flags, domid); if (ret < 0) { - XL_LOG(ctx, XL_LOG_ERROR, "domain creation fail: %d", ret); + XL_LOG_ERRNOVAL(ctx, XL_LOG_ERROR, ret, "domain creation fail...
2010 Aug 12
0
[PATCH, v2]: xl: Implement per-API-call garbage-collection lifetime
...work in this area should sew up all these loose ends. Signed-off-by: Gianni Tedesco <gianni.tedesco@citrix.com> diff -r 7b144fe8c528 tools/libxl/libxl.c --- a/tools/libxl/libxl.c Wed Aug 11 14:39:44 2010 +0100 +++ b/tools/libxl/libxl.c Thu Aug 12 15:22:56 2010 +0100 @@ -45,17 +45,12 @@ int libxl_ctx_init(libxl_ctx *ctx, int v return ERROR_VERSION; memset(ctx, 0, sizeof(libxl_ctx)); ctx->lg = lg; - ctx->alloc_maxsize = 256; - ctx->alloc_ptrs = calloc(ctx->alloc_maxsize, sizeof(void *)); - if (!ctx->alloc_ptrs) - return ERROR_NOMEM; memset(&...
2011 Jan 11
0
[PATCH, v2]: xl: move domain struct init functions to libxl
...; + nic_info->bridge = strdup("xenbr0"); + if ( asprintf(&nic_info->script, "%s/vif-bridge", + libxl_xen_script_dir_path()) < 0 ) + return ERROR_FAIL; + nic_info->nictype = NICTYPE_IOEMU; + return 0; +} + int libxl_device_nic_add(libxl_ctx *ctx, uint32_t domid, libxl_device_nic *nic) { libxl__gc gc = LIBXL_INIT_GC(ctx); @@ -1182,6 +1211,34 @@ err: } /******************************************************************************/ +void libxl_device_net2_init(libxl_device_net2 *net2_info, int devnum) +{ + const uint8_t *r;...
2010 May 19
6
[PATCH 0/6]xl: Add ''xl tmem-*'' commands
Add tmem-* commands, did some simple tests. [PATCH 1/6]xl: Add ''xl tmem-list'' command [PATCH 2/6]xl: Add ''xl tmem-freeze'' command [PATCH 3/6]xl: Add ''xl tmem-destroy'' command [PATCH 4/6]xl: Add ''xl tmem-thaw'' command [PATCH 5/6]xl: Add ''xl tmem-set'' command [PATCH 6/6]xl: Add ''xl
2012 Aug 15
2
[PATCH] libxl: make domain resume API asynchronous
...LOG* helper macros. Signed-off-by: Ian Campbell <ian.campbell@citrix.com> diff -r 30bf79cc14d9 -r 7cec0543f67c tools/libxl/libxl.c --- a/tools/libxl/libxl.c Wed Aug 15 14:45:21 2012 +0100 +++ b/tools/libxl/libxl.c Wed Aug 15 16:58:21 2012 +0100 @@ -396,15 +396,12 @@ int libxl_domain_rename(libxl_ctx *ctx, return rc; } -int libxl_domain_resume(libxl_ctx *ctx, uint32_t domid, int suspend_cancel) +int libxl__domain_resume(libxl__gc *gc, uint32_t domid, int suspend_cancel) { - GC_INIT(ctx); int rc = 0; - if (xc_domain_resume(ctx->xch, domid, suspend_cancel)) { - LI...
2011 Oct 14
21
xl create PV guest with qcow/qcow2 disk images fail
Hi, List, I''m trying xl create a pv guest with qcow/qcow2 image, it always fails at libxl_device_disk_local_attach. #xl create pv_config_file libxl: error: libxl.c:1119:libxl_device_disk_local_attach: cannot locally attach a qdisk image if the format is not raw libxl: error: libxl_create.c:467:do_domain_create: failed to run bootloader: -3 disk configuration is: disk=[
2010 Aug 13
3
[PATCH] xl: make libxl_uuid2string internal to libxenlight
...ce the per-api-call-gc-lifetime patch. Signed-off-by: Gianni Tedesco <gianni.tedesco@citrix.com> diff -r dc335ebde3b5 tools/libxl/libxl.c --- a/tools/libxl/libxl.c Thu Aug 12 18:03:23 2010 +0100 +++ b/tools/libxl/libxl.c Fri Aug 13 15:32:31 2010 +0100 @@ -90,7 +90,7 @@ int libxl_domain_make(libxl_ctx *ctx, li xs_transaction_t t; xen_domain_handle_t handle; - uuid_string = libxl_uuid2string(ctx, info->uuid); + uuid_string = libxl_uuid2string(&gc, info->uuid); if (!uuid_string) { libxl_free_all(&gc); return ERROR_NOMEM; @@ -453,7 +453,7 @@ in...
2012 Feb 20
18
[PATCH] libxl: fix compile error of libvirt
a, libxl_event.h is included in libxl.h. So, the former one also need to be installed. b, define __XEN_TOOLS__ in libxl.h: the head file "xen/sysctl.h" need check this macro. It is the same way used by the xen libxc public headers(tools/libxc/xenctrl.h and tools/libxc/xenctrlosdep.h). Signed-off-by: Bamvor Jian Zhang <bjzhang@suse.com> diff -r 87218bd367be
2012 May 15
5
[PATCH 0 of 4 v3] Add commands to automatically prep devices for pass-through
Add commands to automatically prep devices for pass-through The current method for passing through devices requires users to either modify cryptic Linux boot parameters and reboot, or do a lot of manual reads and writes into sysfs nodes. This set of patches introduces commands to make this easier. It expands on the concept of "assignable" (from the list_assignable_devices command).
2012 Jan 26
1
[PATCH v2] libxl: fix mutex initialization
...ges since v1: * Fix leak of mutex attr. Signed-off-by: Roger Pau Monne <roger.pau@entel.upc.edu> diff -r f581bb82fecd -r 259112aee618 tools/libxl/libxl.c --- a/tools/libxl/libxl.c Sat Jan 14 19:04:48 2012 +0100 +++ b/tools/libxl/libxl.c Sat Jan 14 19:04:48 2012 +0100 @@ -26,7 +26,6 @@ int libxl_ctx_alloc(libxl_ctx **pctx, in { libxl_ctx *ctx = NULL; struct stat stat_buf; - const pthread_mutex_t mutex_value = PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP; int rc; if (version != LIBXL_VERSION) { rc = ERROR_VERSION; goto out; } @@ -40,10 +39,10 @@ int libxl_ctx_alloc(libxl_ctx...
2013 Sep 09
1
[PATCH V3] xl: HVM domain S3 bugfix
...| 2 ++ tools/libxl/libxl_qmp.c | 5 +++++ 3 files changed, 36 insertions(+), 2 deletions(-) diff --git a/tools/libxl/libxl.c b/tools/libxl/libxl.c index 81785df..267bc25 100644 --- a/tools/libxl/libxl.c +++ b/tools/libxl/libxl.c @@ -4641,10 +4641,37 @@ int libxl_domain_sched_params_get(libxl_ctx *ctx, uint32_t domid, return ret; } +static int libxl__domain_s3_resume(libxl__gc *gc, int domid) +{ + int rc = 0; + + switch (libxl__domain_type(gc, domid)) { + case LIBXL_DOMAIN_TYPE_HVM: + switch (libxl__device_model_version_running(gc, domid)) { + case LIBXL_DEVIC...
2012 Feb 09
7
[PATCH V2 0/3] Set VNC password to QEMU upstream
Anthony PERARD (3): libxl_qmp: Use GC instead of CTX as parameter for _initialize. Provide dm_vnc() as a in libxl helper. libxl: Set VNC password through QMP tools/libxl/libxl_create.c | 2 +- tools/libxl/libxl_dm.c | 32 ++++++++++++++---------- tools/libxl/libxl_internal.h | 7 ++++- tools/libxl/libxl_qmp.c | 55 ++++++++++++++++++++++++++++++----------- 4 files
2010 Aug 18
16
[PATCH 00 of 16] libxl: autogenerate type definitions and destructor functions
The series introduces auto-generation of the type definitions used in the libxl interface followed by auto-generation of a destructor function for each type. In the future it may be possible to use the related data structures for other purposes, for example auto-generation of the functions to marshal between C and language binding data types. tools/_libxl_types.h should be identical both before
2012 Jul 04
53
[PATCH 00 of 10 v3] Automatic NUMA placement for xl
Hello, Third version of the NUMA placement series Xen 4.2. All the comments received during v2''s review have been addressed (more details in single changelogs). The most notable changes are the following: - the libxl_cpumap --> libxl_bitmap renaming has been rebased on top of the recent patches that allows us to allocate bitmaps of different sizes; - the heuristics for deciding
2010 Jun 28
8
[PATCH] add xl ocaml bindings
...<caml/alloc.h> +#include <caml/memory.h> +#include <caml/signals.h> +#include <caml/fail.h> +#include <caml/callback.h> + +#include <sys/mman.h> +#include <stdint.h> +#include <string.h> + +#include "libxl.h" + +#define INIT_CTX() \ + ret = libxl_ctx_init(&ctx, LIBXL_VERSION, NULL); \ + if (ret != 0) \ + failwith_xl("cannot init context"); + +#define FREE_CTX() \ + libxl_ctx_free(&ctx) + +void log_callback(void *userdata, int loglevel, const char *file, + int line, const char *func, char *s) +{ +} + +void failwith_xl(char *...
2013 Nov 25
22
[PATCH 0/4] Coverity fixes for tools/libxl
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com> -- 1.7.10.4
2010 Aug 13
4
[PATCH] xl: Make blktap support optional
Make blktap support optional. Enable it by default on Linux, disable it on non-Linux. Signed-off-by: Christoph Egger <Christoph.Egger@amd.com> -- ---to satisfy European Law for business letters: Advanced Micro Devices GmbH Einsteinring 24, 85609 Dornach b. Muenchen Geschaeftsfuehrer: Alberto Bozzo, Andrew Bowd Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen Registergericht Muenchen,
2013 Dec 01
70
[PATCH 00/13] Coverity fixes for libxl
Matthew Daley (13): libxl: fix unsigned less-than-0 comparison in e820_sanitize libxl: check for xc_domain_setmaxmem failure in libxl__build_pre libxl: correct file open success check in libxl__device_pci_reset libxl: don''t leak p in libxl__wait_for_backend libxl: remove unsigned less-than-0 comparison libxl: actually abort if initializing a ctx''s lock fails libxl:
2012 Apr 04
10
[PATCH 0 of 2] libxl: add libxl_domain_config_init
The following series implements libxl_domain_config_init as per the libxl API requirement that each type has an init function. The first function does this in an open coded manner and is proposed for Xen 4.2. The second function is RFC only since it moves the definition of this type into the IDL and makes the required infrastructure updates to enable this. I think this is more 4.3 material at
2013 Apr 12
11
[PATCH v4 1/2] libxl: postpone backend name resolution
...eld, allowing either a domid or a domain name to be specified in the configuration structures. The domain name is resolved into a domain ID in the _setdefault function when adding the device. This change allows the backend of the block devices to be specified (which previously required passing the libxl_ctx down into the block device parser), and will simplify specification of backend domains in other users of libxl. Signed-off-by: Daniel De Graaf <dgdegra@tycho.nsa.gov> Cc: Ian Jackson <ian.jackson@eu.citrix.com> Cc: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Cc: Ian Cam...