Re: [libvirt] [PATCH] build: avoid non-portable cast of pthread_t

2013-05-03 Thread Guido Günther
Hi Eric, On Thu, May 02, 2013 at 03:58:23PM -0600, Eric Blake wrote: POSIX says pthread_t is opaque. We can't guarantee if it is scaler or a pointer, nor what size it is; and BSD differs from Linux. We've also had reports of gcc complaining on attempts to cast it, if we use a cast to the

[libvirt] [PATCH 1/2] Fixup rpcgen code on kFreeBSD too

2013-05-03 Thread Guido Günther
since it uses glibc's rpcgen. --- src/rpc/genprotocol.pl |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rpc/genprotocol.pl b/src/rpc/genprotocol.pl index c8c1570..f02ce13 100755 --- a/src/rpc/genprotocol.pl +++ b/src/rpc/genprotocol.pl @@ -31,7 +31,7 @@ open RPCGEN,

[libvirt] [PATCH 2/2] Make detect_scsi_host_caps a function on all architectures

2013-05-03 Thread Guido Günther
In the non linux case some callers like gather_scsi_host_caps needed the return code of -1 while others like update_caps needed an emtpy statement (to avoid a statement without effect warning). This is much simpler solved by using a function instead of a define. ---

[libvirt] [PATCH] docs: fix 'since' for socket path generation

2013-05-03 Thread Ján Tomko
Commit 297c99a says it works from 1.0.5 but it only got pushed after the 1.0.5 release. --- Pushed under the trivial rule. docs/formatdomain.html.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index 8d4edfb..3570bbc

Re: [libvirt] [PATCH 01/11] Fix possible undefined value in check-symsorting.pl

2013-05-03 Thread Ján Tomko
On 05/02/2013 02:03 PM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com It is possible for $line to be undefined at first used, if the symfile doesn't have a section prefix (which is the case for auto-generated symfiles). Signed-off-by: Daniel P. Berrange

Re: [libvirt] [PATCH 04/11] Separate virGetHostname() API contract from driver APIs

2013-05-03 Thread Ján Tomko
On 05/02/2013 02:03 PM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Currently the virGetHostname() API has a bogus virConnectPtr parameter. This is because virtualization drivers directly reference this API in their virDriverPtr tables, tieing its API design to

Re: [libvirt] [PATCH 11/11] Delete udevFreeIfaceDef function in udev interface driver

2013-05-03 Thread Ján Tomko
On 05/02/2013 02:03 PM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The udevFreeIfaceDef function in the udev interface driver just duplicates code from virInterfaceDefFree. Delete it and call the standard API instead. Signed-off-by: Daniel P. Berrange

Re: [libvirt] [libvirt-glib 2/3] gconfig: Add GVirConfigDomainSnapshotDisk getters/setters

2013-05-03 Thread Daniel P. Berrange
On Thu, May 02, 2013 at 11:17:49PM +0200, Christophe Fergeau wrote: On Thu, May 02, 2013 at 11:40:56PM +0300, Zeeshan Ali (Khattak) wrote: On Thu, May 2, 2013 at 6:36 PM, Christophe Fergeau cferg...@redhat.com wrote: On Thu, May 02, 2013 at 06:22:14PM +0300, Zeeshan Ali (Khattak) wrote:

Re: [libvirt] [PATCH 11/11] Delete udevFreeIfaceDef function in udev interface driver

2013-05-03 Thread Daniel P. Berrange
On Fri, May 03, 2013 at 10:44:24AM +0200, Ján Tomko wrote: On 05/02/2013 02:03 PM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The udevFreeIfaceDef function in the udev interface driver just duplicates code from virInterfaceDefFree. Delete it and call the

Re: [libvirt] [PATCH] build: avoid non-portable cast of pthread_t

2013-05-03 Thread Daniel P. Berrange
On Thu, May 02, 2013 at 03:58:23PM -0600, Eric Blake wrote: POSIX says pthread_t is opaque. We can't guarantee if it is scaler or a pointer, nor what size it is; and BSD differs from Linux. We've also had reports of gcc complaining on attempts to cast it, if we use a cast to the wrong type

[libvirt] [PATCH] Fix warning about unsupported cookie flags in QEMU driver

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The QEMU migration code unconditionally sets the 'persistent' cookie flag on the source host. The dest host, however, only allows it during parsing if VIR_MIGRATE_PERSIST_DEST was set. Make the source host only set it if this flag is present.

[libvirt] [PATCH] Fix F_DUPFD_CLOEXEC operation args

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The F_DUPFD_CLOEXEC operation with fcntl() expects a single int argument, specifying the minimum FD number for the newly dup'd file descriptor. We were not specifying that causing random stack data to be accessed as the FD number. Sometimes that

Re: [libvirt] [PATCH 06/11] Separate internal node suspend APIs from public API

2013-05-03 Thread Ján Tomko
On 05/02/2013 02:03 PM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The individual hypervisor drivers were directly referencing APIs in virnodesuspend.c in their virDriverPtr struct. Separate these methods, so there is always a wrapper in the hypervisor driver.

Re: [libvirt] [PATCH 02/11] Rename security context to selinux context

2013-05-03 Thread Ján Tomko
On 05/02/2013 02:03 PM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The there various methods named virSecurityContext, which are specific to SELinux. Rename them all to virSELinuxContext. They will still raise errors at runtime if SELinux is not compiled

Re: [libvirt] [PATCH 05/11] Separate internal node device APIs from public API

2013-05-03 Thread Ján Tomko
On 05/02/2013 02:03 PM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The individual hypervisor drivers were directly referencing APIs in src/nodeinfo.c in their virDriverPtr struct. Separate these methods, so there is always a wrapper in the hypervisor driver. This

Re: [libvirt] [PATCH 07/11] Fix naming of some node device APIs

2013-05-03 Thread Ján Tomko
On 05/02/2013 02:03 PM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com In renaming driver API implementations to match the public API naming scheme, a few cases in the node device driver were missed. Signed-off-by: Daniel P. Berrange berra...@redhat.com ---

Re: [libvirt] [Qemu-devel] [PATCH qom-cpu 6/9] target-i386: Add feature-words property

2013-05-03 Thread Igor Mammedov
On Mon, 22 Apr 2013 16:00:17 -0300 Eduardo Habkost ehabk...@redhat.com wrote: This property will be useful for libvirt, as libvirt already has logic based on low-level feature bits (not feature names), so it will be really easy to convert the current libvirt logic to something using the

Re: [libvirt] [PATCH] Fix warning about unsupported cookie flags in QEMU driver

2013-05-03 Thread Michal Privoznik
On 03.05.2013 12:10, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The QEMU migration code unconditionally sets the 'persistent' cookie flag on the source host. The dest host, however, only allows it during parsing if VIR_MIGRATE_PERSIST_DEST was set. Make the

[libvirt] [PATCH] build: fix make rpm failure

2013-05-03 Thread Laine Stump
Commit 297c99a accidentally put a { where a ( belonged, causing make rpm to fail. --- Pushed under the build breaker rule. libvirt.spec.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libvirt.spec.in b/libvirt.spec.in index 6f25031..0ecd38d 100644 --- a/libvirt.spec.in

Re: [libvirt] [PATCH] Fix F_DUPFD_CLOEXEC operation args

2013-05-03 Thread Eric Blake
On 05/03/2013 04:12 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The F_DUPFD_CLOEXEC operation with fcntl() expects a single int argument, specifying the minimum FD number for the newly dup'd file descriptor. We were not specifying that causing random stack

Re: [libvirt] [PATCH] build: avoid non-portable cast of pthread_t

2013-05-03 Thread Eric Blake
On 05/03/2013 02:58 AM, Daniel P. Berrange wrote: On Thu, May 02, 2013 at 03:58:23PM -0600, Eric Blake wrote: POSIX says pthread_t is opaque. We can't guarantee if it is scaler or a pointer, nor what size it is; and BSD differs from Linux. We've also had reports of gcc complaining on attempts

Re: [libvirt] [PATCH 2/2] Make detect_scsi_host_caps a function on all architectures

2013-05-03 Thread Eric Blake
On 05/03/2013 12:22 AM, Guido Günther wrote: In the non linux case some callers like gather_scsi_host_caps needed the return code of -1 while others like update_caps needed an emtpy s/emtpy/empty/ statement (to avoid a statement without effect warning). This is much simpler solved by using a

Re: [libvirt] [PATCH 02/11] Rename security context to selinux context

2013-05-03 Thread Eric Blake
On 05/02/2013 06:03 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The there various methods named virSecurityContext, s/The there/There are/ which are specific to SELinux. Rename them all to virSELinuxContext. They will still raise errors at runtime if

Re: [libvirt] [PATCH] Fix F_DUPFD_CLOEXEC operation args

2013-05-03 Thread Eric Blake
On 05/03/2013 06:06 AM, Eric Blake wrote: On 05/03/2013 04:12 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The F_DUPFD_CLOEXEC operation with fcntl() expects a single int argument, specifying the minimum FD number for the newly dup'd file descriptor. We were not

[libvirt] [PATCH] Fix release of resources with lockd plugin

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The lockd plugin for the lock manager was not correctly handling the release of resource locks. This meant that during migration, or when pausing a VM, the locks would not get released. This in turn made it impossible to resume the domain, or finish

Re: [libvirt] [PATCH 1/2] Fixup rpcgen code on kFreeBSD too

2013-05-03 Thread Eric Blake
On 05/03/2013 12:21 AM, Guido Günther wrote: since it uses glibc's rpcgen. --- src/rpc/genprotocol.pl |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ACK. I suspect we could probably even remove the line completely, and instead focus on making the script work for all common flavors

Re: [libvirt] libvirt 'xdr_u_int64_t' undeclared error

2013-05-03 Thread Eric Blake
On 05/03/2013 01:51 AM, appzer0 wrote: Hello list, I don't know if I should file a bug so I'm asking here: I got problems building libvirt with obsolete headers from glibc + libtirpc headers. Which versions of glibc and libtirpc? I met the 'xdr_u_int64_t' undeclared error as it seems

[libvirt] [PATCHv2] network: fix network driver startup for qemu:///session

2013-05-03 Thread Laine Stump
This should resolve https://bugzilla.redhat.com/show_bug.cgi?id=958907 Recent new addition of code to read/write active network state to the NETWORK_STATE_DIR in the network driver broke startup for qemu:///session. The network driver had several state file paths hardcoded to /var, which could

Re: [libvirt] [Qemu-devel] [PATCH 3/3] gtk: add devices menu to allow changing removable block devices

2013-05-03 Thread Daniel P. Berrange
On Thu, May 02, 2013 at 10:40:06AM -0500, Anthony Liguori wrote: Kevin Wolf kw...@redhat.com writes: + +if (strcmp(type, ide-cd) == 0) { +disk_type = DT_CDROM; +} else if (strcmp(type, isa-fdc) == 0) { +disk_type = DT_FLOPPY; +}

Re: [libvirt] [PATCH] Fix release of resources with lockd plugin

2013-05-03 Thread Eric Blake
On 05/03/2013 06:15 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The lockd plugin for the lock manager was not correctly handling the release of resource locks. This meant that during migration, or when pausing a VM, the locks would not get released. This in

Re: [libvirt] [PATCH] Fix release of resources with lockd plugin

2013-05-03 Thread Daniel P. Berrange
On Fri, May 03, 2013 at 06:34:38AM -0600, Eric Blake wrote: On 05/03/2013 06:15 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The lockd plugin for the lock manager was not correctly handling the release of resource locks. This meant that during migration,

Re: [libvirt] [PATCHv2] network: fix network driver startup for qemu:///session

2013-05-03 Thread Eric Blake
On 05/03/2013 06:24 AM, Laine Stump wrote: This should resolve https://bugzilla.redhat.com/show_bug.cgi?id=958907 Recent new addition of code to read/write active network state to the NETWORK_STATE_DIR in the network driver broke startup for qemu:///session. The network driver had several

Re: [libvirt] [PATCHv2] network: fix network driver startup for qemu:///session

2013-05-03 Thread Daniel P. Berrange
On Fri, May 03, 2013 at 08:24:14AM -0400, Laine Stump wrote: Changes since V1: * change user directory names as outlined by danpb. * eliminate the base string which caused so much bad code, and otherwise simplify the logic * get rid of logDir, since it's never used. * eliminage the

[libvirt] [PATCH] Ignore 'uri' parameter in lockd driver

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com A 'uri' parameter was added for the benefit of sanlock. This causes a warning in the lockd driver though 2013-05-03 13:20:35.347+: 28403: error : virLockManagerLockDaemonNew:482 : internal error Unexpected parameter uri for object Ignore this

Re: [libvirt] [Qemu-devel] [PATCH qom-cpu 6/9] target-i386: Add feature-words property

2013-05-03 Thread Eduardo Habkost
On Fri, May 03, 2013 at 01:34:23PM +0200, Igor Mammedov wrote: On Mon, 22 Apr 2013 16:00:17 -0300 Eduardo Habkost ehabk...@redhat.com wrote: This property will be useful for libvirt, as libvirt already has logic based on low-level feature bits (not feature names), so it will be really

[libvirt] [PATCH] portability: fix virNetDevSetMAC and virNetDevExists on BSD

2013-05-03 Thread Roman Bogorodskiy
- provide virNetDevSetMAC() implementation based on SIOCSIFLLADDR ioctl. - adjust virNetDevExists() to check for ENXIO error because FreeBSD throws it when device doesn't exist --- configure.ac | 8 src/util/virnetdev.c | 41 - 2 files

[libvirt] [PATCH 1/6] Add support for storage format in FS driver

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Extend the driver element in filesystem devices to allow a storage format to be set. The new attribute uses 'format' to reflect the storage format. This is different from the driver element in disk devices which use 'type' to reflect the storage

[libvirt] [PATCH 5/6] Add 'nbd' as a valid filesystem driver type

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The filesystem element can now accept a driver type='nbd'/ as an alternative to 'loop'. The benefit of NBD is support for non-raw disk image formats. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- docs/formatdomain.html.in

[libvirt] [PATCH 0/6 v3] Support NBD volumes with LXC containers

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com A third version of: https://www.redhat.com/archives/libvir-list/2013-April/msg01539.html In v3 - Split patch 3 into 2 pieces - Added XML formatting tests - Fixed XML formatting - Remove !! from vars that are now bools Daniel P. Berrange (6):

[libvirt] [PATCH 2/6] Re-arrange code setting up ifs/disk loop devices for LXC

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The current code for setting up loop devices to LXC disks first does a switch() based on the disk format, then looks at the disk driver name. Reverse this so it first looks at the driver name, and then the disk format. This is more useful since the

[libvirt] [PATCH 6/6] Support NBD backed disks/filesystems in LXC driver

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The LXC driver can already configure disk or filesystem devices to use the loop device. This extends it to also allow for use of the NBD device, to support non-raw formats. Signed-off-by: Daniel P. Berrange berra...@redhat.com ---

[libvirt] [PATCH 3/6] Fix error handling of readdir() in virFileLoopDeviceOpen

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com To correctly handle errors from readdir() you must set 'errno' to zero before invoking it check its value afterwards to distinguish error from EOF. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/util/virfile.c | 10 -- 1 file

Re: [libvirt] [Qemu-devel] [PATCH 3/3] gtk: add devices menu to allow changing removable block devices

2013-05-03 Thread Anthony Liguori
Daniel P. Berrange berra...@redhat.com writes: On Thu, May 02, 2013 at 10:40:06AM -0500, Anthony Liguori wrote: Kevin Wolf kw...@redhat.com writes: + +if (strcmp(type, ide-cd) == 0) { +disk_type = DT_CDROM; +} else if (strcmp(type, isa-fdc) == 0) { +

[libvirt] [PATCH 4/6] Add a helper API for setting up a NBD device with qemu-nbd

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Add a virFileNBDDeviceAssociate method, which given a filename will setup a NBD device, using qemu-nbd as the server. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/libvirt_private.syms | 1 + src/util/virfile.c | 143

Re: [libvirt] [Qemu-devel] [PATCH 3/3] gtk: add devices menu to allow changing removable block devices

2013-05-03 Thread Daniel P. Berrange
On Fri, May 03, 2013 at 08:52:59AM -0500, Anthony Liguori wrote: Daniel P. Berrange berra...@redhat.com writes: On Thu, May 02, 2013 at 10:40:06AM -0500, Anthony Liguori wrote: Kevin Wolf kw...@redhat.com writes: + +if (strcmp(type, ide-cd) == 0) { +disk_type

Re: [libvirt] [PATCHv2] network: fix network driver startup for qemu:///session

2013-05-03 Thread Richard W.M. Jones
On Fri, May 03, 2013 at 08:24:14AM -0400, Laine Stump wrote: This should resolve https://bugzilla.redhat.com/show_bug.cgi?id=958907 Recent new addition of code to read/write active network state to the NETWORK_STATE_DIR in the network driver broke startup for qemu:///session. The network

[libvirt] [PATCH] Fix multiple formatting problems in HTML docs

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The rule generating the HTML docs passing the --html flag to xsltproc. This makes it use the legacy HTML parser, which either ignores or tries to fix all sorts of broken XML tags. There's no reason why we should be writing broken XML in the first

Re: [libvirt] [Qemu-devel] [PATCH qom-cpu 6/9] target-i386: Add feature-words property

2013-05-03 Thread Eric Blake
On 05/03/2013 07:17 AM, Eduardo Habkost wrote: We could, but maybe it would make the interface harder to use and not easier? Even when two feature words are returned in the same CPUID leaf, they are independent and separate feature-words that must be checked individually by libvirt, so I

[libvirt] [sandbox PATCH] allow to use a templated unit in virt-sandbox

2013-05-03 Thread Michael Scherer
This permit to create a templated unit inside the sandbox, using the sandbox name as a variable and so running the same unit with a different configuration without too much hassle. For example, someone could have several different configuration of website in /etc/nginx/websites.d/ and have each

Re: [libvirt] [PATCH] Fix multiple formatting problems in HTML docs

2013-05-03 Thread Eric Blake
On 05/03/2013 08:27 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The rule generating the HTML docs passing the --html flag to xsltproc. This makes it use the legacy HTML parser, which either ignores or tries to fix all sorts of broken XML tags. There's no

Re: [libvirt] [PATCH] Ignore 'uri' parameter in lockd driver

2013-05-03 Thread Eric Blake
On 05/03/2013 07:24 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com A 'uri' parameter was added for the benefit of sanlock. This causes a warning in the lockd driver though 2013-05-03 13:20:35.347+: 28403: error : virLockManagerLockDaemonNew:482 : internal

Re: [libvirt] [sandbox PATCH] allow to use a templated unit in virt-sandbox

2013-05-03 Thread Daniel P. Berrange
On Fri, May 03, 2013 at 04:32:45PM +0200, Michael Scherer wrote: This permit to create a templated unit inside the sandbox, using the sandbox name as a variable and so running the same unit with a different configuration without too much hassle. For example, someone could have several

Re: [libvirt] [PATCH 2/2] Make detect_scsi_host_caps a function on all architectures

2013-05-03 Thread Guido Günther
On Fri, May 03, 2013 at 06:04:11AM -0600, Eric Blake wrote: On 05/03/2013 12:22 AM, Guido Günther wrote: In the non linux case some callers like gather_scsi_host_caps needed the return code of -1 while others like update_caps needed an emtpy s/emtpy/empty/ Both pushed with the above

Re: [libvirt] libvirt 'xdr_u_int64_t' undeclared error

2013-05-03 Thread appzer0
Le 03/05/2013 14:26, Eric Blake a écrit : On 05/03/2013 01:51 AM, appzer0 wrote: Hello list, I don't know if I should file a bug so I'm asking here: I got problems building libvirt with obsolete headers from glibc + libtirpc headers. Which versions of glibc and libtirpc? Thanks for taking a

[libvirt] [PATCH v3 07/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/libxl/*

2013-05-03 Thread Michal Privoznik
--- src/libxl/libxl_conf.c | 86 ++-- src/libxl/libxl_driver.c | 14 +++- 2 files changed, 29 insertions(+), 71 deletions(-) diff --git a/src/libxl/libxl_conf.c b/src/libxl/libxl_conf.c index 3de642b..be7ccaa 100644 --- a/src/libxl/libxl_conf.c

[libvirt] [PATCH v3 21/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/security/*

2013-05-03 Thread Michal Privoznik
--- src/security/security_apparmor.c | 20 ++ src/security/security_dac.c | 23 src/security/security_nop.c | 7 +--- src/security/security_selinux.c | 79 +++- src/security/virt-aa-helper.c| 4 +- 5 files changed, 37

[libvirt] [PATCH v3 03/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/conf/*

2013-05-03 Thread Michal Privoznik
--- src/conf/capabilities.c | 30 + src/conf/cpu_conf.c | 19 src/conf/domain_conf.c | 105 ++-- src/conf/domain_event.c | 39 src/conf/node_device_conf.c | 29 ++--

[libvirt] [PATCH v3 24/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/uml/*

2013-05-03 Thread Michal Privoznik
--- src/uml/uml_conf.c | 10 -- src/uml/uml_driver.c | 8 +++- 2 files changed, 7 insertions(+), 11 deletions(-) diff --git a/src/uml/uml_conf.c b/src/uml/uml_conf.c index a55b5b1..52b705c 100644 --- a/src/uml/uml_conf.c +++ b/src/uml/uml_conf.c @@ -114,8 +114,8 @@

[libvirt] [PATCH v3 11/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/node_device/*

2013-05-03 Thread Michal Privoznik
--- src/node_device/node_device_driver.c | 33 src/node_device/node_device_hal.c| 13 ++--- src/node_device/node_device_udev.c | 99 ++-- 3 files changed, 46 insertions(+), 99 deletions(-) diff --git a/src/node_device/node_device_driver.c

[libvirt] [PATCH v3 04/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/cpu/*

2013-05-03 Thread Michal Privoznik
--- src/cpu/cpu_generic.c | 8 src/cpu/cpu_map.c | 3 ++- src/cpu/cpu_powerpc.c | 13 ++--- src/cpu/cpu_x86.c | 10 +- 4 files changed, 17 insertions(+), 17 deletions(-) diff --git a/src/cpu/cpu_generic.c b/src/cpu/cpu_generic.c index 9d5117f..7e3eda2 100644

[libvirt] [PATCH v3 31/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/xenxs/*

2013-05-03 Thread Michal Privoznik
--- src/xenxs/xen_sxpr.c | 192 +++ src/xenxs/xen_xm.c | 94 +++-- 2 files changed, 125 insertions(+), 161 deletions(-) diff --git a/src/xenxs/xen_sxpr.c b/src/xenxs/xen_sxpr.c index 9a76d04..4b486b2 100644 ---

[libvirt] [PATCH v3 08/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/locking/*

2013-05-03 Thread Michal Privoznik
--- src/locking/lock_daemon.c | 30 +++- src/locking/lock_daemon_config.c | 12 +-- src/locking/lock_daemon_dispatch.c | 6 ++ src/locking/lock_driver_lockd.c| 41 -- src/locking/lock_driver_sanlock.c | 12

[libvirt] [PATCH v3 09/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/lxc/*

2013-05-03 Thread Michal Privoznik
--- src/lxc/lxc_cgroup.c | 3 +-- src/lxc/lxc_conf.c | 36 +--- src/lxc/lxc_container.c | 18 -- src/lxc/lxc_controller.c | 20 src/lxc/lxc_driver.c | 9 ++--- src/lxc/lxc_process.c| 7 --- 6 files

[libvirt] [PATCH v3 10/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/network/*

2013-05-03 Thread Michal Privoznik
--- src/network/bridge_driver.c | 34 +++--- 1 file changed, 11 insertions(+), 23 deletions(-) diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index e828997..fb01ebf 100644 --- a/src/network/bridge_driver.c +++ b/src/network/bridge_driver.c @@

[libvirt] [PATCH v3 32/34] Adapt to VIR_STRDUP and VIR_STRNDUP in tests/*

2013-05-03 Thread Michal Privoznik
--- tests/commandhelper.c | 10 -- tests/commandtest.c| 2 +- tests/openvzutilstest.c| 6 -- tests/qemumonitortestutils.c | 15 +++ tests/qemuxml2argvtest.c | 23 --- tests/qemuxmlnstest.c

[libvirt] [PATCH v3 34/34] Introduce syntax-check rule to prefer VIR_STRDUP over strdup

2013-05-03 Thread Michal Privoznik
--- cfg.mk | 8 1 file changed, 8 insertions(+) diff --git a/cfg.mk b/cfg.mk index 1d63bbd..4ed2c3a 100644 --- a/cfg.mk +++ b/cfg.mk @@ -387,6 +387,11 @@ sc_prohibit_asprintf: halt='use strdup instead of virAsprintf with %s' \ $(_sc_search_regexp)

[libvirt] [PATCH v3 14/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/openvz/*

2013-05-03 Thread Michal Privoznik
--- src/openvz/openvz_conf.c | 45 ++--- src/openvz/openvz_driver.c | 39 +++ 2 files changed, 37 insertions(+), 47 deletions(-) diff --git a/src/openvz/openvz_conf.c b/src/openvz/openvz_conf.c index 49fae28..1d401fc

[libvirt] [PATCH v3 01/34] virstring: Introduce VIR_STRDUP and VIR_STRNDUP

2013-05-03 Thread Michal Privoznik
The code adaptation is not done right now, but in subsequent patches. Hence I am not implementing syntax-check rule as it would break compilation. Developers are strongly advised to use these new macros. They are similar to VIR_ALLOC() logic: VIR_STRDUP(dst, src) returns zero on success, -1

[libvirt] [PATCH v3 29/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/xen/*

2013-05-03 Thread Michal Privoznik
--- src/xen/block_stats.c| 16 +- src/xen/xen_driver.c | 9 +++--- src/xen/xen_hypervisor.c | 19 src/xen/xen_inotify.c| 15 +++--- src/xen/xend_internal.c | 78 src/xen/xm_internal.c| 9 ++

[libvirt] [PATCH v3 28/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/vmx/*

2013-05-03 Thread Michal Privoznik
--- src/vmx/vmx.c | 36 ++-- 1 file changed, 6 insertions(+), 30 deletions(-) diff --git a/src/vmx/vmx.c b/src/vmx/vmx.c index 9ec0269..a75cced 100644 --- a/src/vmx/vmx.c +++ b/src/vmx/vmx.c @@ -682,14 +682,7 @@ virVMXGetConfigString(virConfPtr conf, const char

[libvirt] [PATCH v3 15/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/parallels/*

2013-05-03 Thread Michal Privoznik
--- src/parallels/parallels_driver.c | 71 +-- src/parallels/parallels_network.c | 23 + src/parallels/parallels_storage.c | 62 +++--- 3 files changed, 58 insertions(+), 98 deletions(-) diff --git

[libvirt] [PATCH v3 19/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/rpc/*

2013-05-03 Thread Michal Privoznik
--- src/rpc/gendispatch.pl | 21 src/rpc/virnetclient.c | 16 -- src/rpc/virnetmessage.c | 12 --- src/rpc/virnetsaslcontext.c | 6 ++-- src/rpc/virnetserver.c | 6 ++-- src/rpc/virnetserverclient.c | 10 ++ src/rpc/virnetservermdns.c | 6

[libvirt] [PATCH v3 33/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/*

2013-05-03 Thread Michal Privoznik
--- src/datatypes.c | 76 +++-- src/libvirt.c | 14 +++ src/nodeinfo.c | 5 +--- 3 files changed, 41 insertions(+), 54 deletions(-) diff --git a/src/datatypes.c b/src/datatypes.c index d3cf5f2..41e9c57 100644 --- a/src/datatypes.c

[libvirt] [PATCH v3 20/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/secret/*

2013-05-03 Thread Michal Privoznik
--- src/secret/secret_driver.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/secret/secret_driver.c b/src/secret/secret_driver.c index 377b9f4..5d1739f 100644 --- a/src/secret/secret_driver.c +++ b/src/secret/secret_driver.c @@ -1097,9 +1097,8 @@

[libvirt] [PATCH v3 16/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/phyp/*

2013-05-03 Thread Michal Privoznik
--- src/phyp/phyp_driver.c | 50 ++ 1 file changed, 10 insertions(+), 40 deletions(-) diff --git a/src/phyp/phyp_driver.c b/src/phyp/phyp_driver.c index 85eb650..7079974 100644 --- a/src/phyp/phyp_driver.c +++ b/src/phyp/phyp_driver.c @@ -954,12

[libvirt] [PATCH v3 00/34] Introduce VIR_STRDUP

2013-05-03 Thread Michal Privoznik
Previously this aimed on dropping OOM report from almost everywhere (v1), then just prepare the ground (v2). Now, it just aims on introducing VIR_STRDUP and VIR_STRNDUP which do report OOM error. This will cause rebase conflicts, for sure. Sorry. Patches available at:

[libvirt] [PATCH v3 13/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/nwfilter/*

2013-05-03 Thread Michal Privoznik
--- src/nwfilter/nwfilter_dhcpsnoop.c | 22 +++--- src/nwfilter/nwfilter_driver.c| 7 +++ src/nwfilter/nwfilter_ebiptables_driver.c | 2 +- src/nwfilter/nwfilter_gentech_driver.c| 5 ++--- src/nwfilter/nwfilter_learnipaddr.c | 5 + 5 files

[libvirt] [PATCH v3 30/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/xenapi/*

2013-05-03 Thread Michal Privoznik
--- src/xenapi/xenapi_driver.c | 59 -- src/xenapi/xenapi_utils.c | 39 +++--- 2 files changed, 46 insertions(+), 52 deletions(-) diff --git a/src/xenapi/xenapi_driver.c b/src/xenapi/xenapi_driver.c index 7e64df6..2dcd024

[libvirt] [PATCH v3 22/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/storage/*

2013-05-03 Thread Michal Privoznik
--- src/storage/parthelper.c | 5 ++--- src/storage/storage_backend.c | 22 ++ src/storage/storage_backend_disk.c | 26 +++--- src/storage/storage_backend_fs.c | 34 ++

[libvirt] [PATCH v3 23/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/test/*

2013-05-03 Thread Michal Privoznik
--- src/test/test_driver.c | 144 ++--- 1 file changed, 52 insertions(+), 92 deletions(-) diff --git a/src/test/test_driver.c b/src/test/test_driver.c index f60f106..32b200c 100644 --- a/src/test/test_driver.c +++ b/src/test/test_driver.c @@ -219,18

[libvirt] [PATCH v3 05/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/esx/*

2013-05-03 Thread Michal Privoznik
--- src/esx/esx_driver.c| 43 ++-- src/esx/esx_interface_driver.c | 7 +--- src/esx/esx_network_driver.c| 28 - src/esx/esx_storage_backend_iscsi.c | 21 +++--- src/esx/esx_storage_backend_vmfs.c | 16 ++-- src/esx/esx_util.c

Re: [libvirt] [Qemu-devel] [PATCH qom-cpu 6/9] target-i386: Add feature-words property

2013-05-03 Thread Eric Blake
On 04/22/2013 01:00 PM, Eduardo Habkost wrote: This property will be useful for libvirt, as libvirt already has logic based on low-level feature bits (not feature names), so it will be really easy to convert the current libvirt logic to something using the feature-words property. The

[libvirt] [PATCH v3 02/34] Adapt to VIR_STRDUP and VIR_STRNDUP in daemon/*

2013-05-03 Thread Michal Privoznik
--- daemon/libvirtd-config.c | 50 +-- daemon/libvirtd.c| 29 + daemon/remote.c | 161 ++- 3 files changed, 92 insertions(+), 148 deletions(-) diff --git a/daemon/libvirtd-config.c b/daemon/libvirtd-config.c index

[libvirt] [PATCH v3 12/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/interface/*

2013-05-03 Thread Michal Privoznik
--- src/interface/interface_backend_udev.c | 36 +- 1 file changed, 9 insertions(+), 27 deletions(-) diff --git a/src/interface/interface_backend_udev.c b/src/interface/interface_backend_udev.c index 7daad16..7f01fce 100644 ---

[libvirt] [PATCH v3 06/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/hyperv/*

2013-05-03 Thread Michal Privoznik
--- src/hyperv/hyperv_driver.c | 50 ++ src/hyperv/hyperv_util.c | 18 + 2 files changed, 15 insertions(+), 53 deletions(-) diff --git a/src/hyperv/hyperv_driver.c b/src/hyperv/hyperv_driver.c index 7031fdb..2c18cb8 100644 ---

[libvirt] [PATCH v3 26/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/vbox/*

2013-05-03 Thread Michal Privoznik
--- src/vbox/vbox_XPCOMCGlue.c | 6 +- src/vbox/vbox_tmpl.c | 278 +++-- 2 files changed, 117 insertions(+), 167 deletions(-) diff --git a/src/vbox/vbox_XPCOMCGlue.c b/src/vbox/vbox_XPCOMCGlue.c index e0b606f..016d925 100644 ---

[libvirt] [PATCH v3 18/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/remote/*

2013-05-03 Thread Michal Privoznik
--- src/remote/remote_driver.c | 114 + 1 file changed, 44 insertions(+), 70 deletions(-) diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c index 97be2a0..ed3467f 100644 --- a/src/remote/remote_driver.c +++

[libvirt] [PATCH v3 27/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/vmware/*

2013-05-03 Thread Michal Privoznik
--- src/vmware/vmware_conf.c | 28 ++-- src/vmware/vmware_driver.c | 11 +-- 2 files changed, 15 insertions(+), 24 deletions(-) diff --git a/src/vmware/vmware_conf.c b/src/vmware/vmware_conf.c index 4fb61a8..4b61a9c 100644 --- a/src/vmware/vmware_conf.c +++

Re: [libvirt] [sandbox PATCH] allow to use a templated unit in virt-sandbox

2013-05-03 Thread Michael Scherer
Le vendredi 03 mai 2013 à 15:38 +0100, Daniel P. Berrange a écrit : On Fri, May 03, 2013 at 04:32:45PM +0200, Michael Scherer wrote: This permit to create a templated unit inside the sandbox, using the sandbox name as a variable and so running the same unit with a different configuration

Re: [libvirt] [Qemu-devel] [PATCH qom-cpu 7/9] target-i386: Use FeatureWord loop on filter_features_for_kvm()

2013-05-03 Thread Eric Blake
On 04/22/2013 01:00 PM, Eduardo Habkost wrote: Instead of open-coding the filtering code for each feature word, change the existing code to use the feature_word_info array, that have exactly the same CPUID eax/ecx/register values for each feature word. Signed-off-by: Eduardo Habkost

Re: [libvirt] [Qemu-devel] [PATCH qom-cpu 0/9] x86: feature words array (v11) + feature-words property

2013-05-03 Thread Andreas Färber
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Am 02.05.2013 21:48, schrieb Eric Blake: On 05/02/2013 01:43 PM, Eduardo Habkost wrote: As mentioned earlier I'd prefer to defer the property design rather than putting it lightly reviewed into 1.5 and living with some ABI. If libvirt urgently

Re: [libvirt] [sandbox PATCH] allow to use a templated unit in virt-sandbox

2013-05-03 Thread Daniel P. Berrange
On Fri, May 03, 2013 at 04:59:58PM +0200, Michael Scherer wrote: Le vendredi 03 mai 2013 à 15:38 +0100, Daniel P. Berrange a écrit : On Fri, May 03, 2013 at 04:32:45PM +0200, Michael Scherer wrote: This permit to create a templated unit inside the sandbox, using the sandbox name as a

Re: [libvirt] [Qemu-devel] [PATCH qom-cpu 9/9] target-i386: Add filtered-features property to X86CPU

2013-05-03 Thread Eric Blake
On 04/22/2013 01:00 PM, Eduardo Habkost wrote: This property will contain all the features that were removed from the CPU because they are not supported by the host. This way, libvirt or other management tools can emulate the check/enforce behavior by checking if filtered-properties is all

Re: [libvirt] [Qemu-devel] [PATCH qom-cpu 8/9] target-i386: Introduce X86CPU.filtered_features field

2013-05-03 Thread Eric Blake
On 04/22/2013 01:00 PM, Eduardo Habkost wrote: This field will contain the feature bits that were filtered out because of missing host support. Yes, libvirt would definitely like to know that. Signed-off-by: Eduardo Habkost ehabk...@redhat.com --- target-i386/cpu-qom.h | 3 +++

Re: [libvirt] [Qemu-devel] [PATCH qom-cpu 5/9] target-i386: Add ECX information to FeatureWordInfo

2013-05-03 Thread Andreas Färber
Am 22.04.2013 21:00, schrieb Eduardo Habkost: FEAT_7_0_EBX uses ECX as input, so we have to take that into account when reporting feature word values. Signed-off-by: Eduardo Habkost ehabk...@redhat.com --- target-i386/cpu.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-)

Re: [libvirt] [Qemu-devel] [PATCH qom-cpu 0/9] x86: feature words array (v11) + feature-words property

2013-05-03 Thread Igor Mammedov
On Fri, 03 May 2013 16:58:44 +0200 Andreas Färber afaer...@suse.de wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Am 02.05.2013 21:48, schrieb Eric Blake: On 05/02/2013 01:43 PM, Eduardo Habkost wrote: As mentioned earlier I'd prefer to defer the property design rather than

Re: [libvirt] [sandbox PATCH] allow to use a templated unit in virt-sandbox

2013-05-03 Thread Michael Scherer
Le vendredi 03 mai 2013 à 16:10 +0100, Daniel P. Berrange a écrit : On Fri, May 03, 2013 at 04:32:45PM +0200, Michael Scherer wrote: This permit to create a templated unit inside the sandbox, using the sandbox name as a variable and so running the same unit with a different configuration

Re: [libvirt] [sandbox PATCH] allow to use a templated unit in virt-sandbox

2013-05-03 Thread Daniel P. Berrange
On Fri, May 03, 2013 at 05:25:06PM +0200, Michael Scherer wrote: Le vendredi 03 mai 2013 à 16:10 +0100, Daniel P. Berrange a écrit : On Fri, May 03, 2013 at 04:32:45PM +0200, Michael Scherer wrote: This permit to create a templated unit inside the sandbox, using the sandbox name as a

Re: [libvirt] [Qemu-devel] [PATCH qom-cpu 0/9] x86: feature words array (v11) + feature-words property

2013-05-03 Thread Eric Blake
On 05/03/2013 08:58 AM, Andreas Färber wrote: I agree that libvirt would very much like to have this in 1.5. How can I help in reviewing things? Apart from the usual QMP considerations that you will know much better than me, I have two concerns here: 1) Polluting the QOM namespace with

[libvirt] [PATCH] Fix docs generator regression in previous commit

2013-05-03 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The previous commit failed to update the XSL to take account of fact that in XHTML mode the elements need namespace prefixes. This caused every web page to be blank! Pushed as a website breaker fix --- docs/drvqemu.html.in | 2 +- docs/page.xsl

  1   2   >