Re: [libvirt] [PATCH 03/13] Rewrite virAtomic APIs using GLib's atomic ops code

2012-07-20 Thread Hu Tao
On Thu, Jul 19, 2012 at 08:15:28AM -0600, Eric Blake wrote: On 07/18/2012 07:07 PM, Hu Tao wrote: ... + +# define virAtomicIntGet(atomic) \ +(__extension__ ({ \ +verify

[libvirt] [PATCH] don't make lxc_driver static

2012-07-20 Thread Gao feng
because it will be used in lxc_process.c below is the error information debug : virDriverLoadModule:66 : Module load lxc error : virDriverLoadModule:78 : failed to load module /usr/local/lib/libvirt/connection-driver/libvirt_driver_lxc.so

Re: [libvirt] [PATCH] Added timestamps to storage volumes

2012-07-20 Thread Hendrik Schwartke
On 19.07.2012 16:08, Eric Blake wrote: On 07/19/2012 01:13 AM, Hendrik Schwartke wrote: I reconsidered the way timestamps are represented. I think that an event at 100.91 happened before 100.200 is misleading. Yep, definite bug - you have to zero-pad the subsecond resolution, and also consider

[libvirt] [PATCHv2 0/2] *** SUBJECT HERE ***

2012-07-20 Thread Viktor Mihajlovski
Thanks for reviewing the patches. V2 of the series refactors the changes into the generic domain configuration/XML support for disk geometry and a qemu specific part with the testcases. Kind Regards, Viktor J.B. Joret (2): Support for Disk Geometry Override qemu: Disk Geometry Override

[libvirt] [PATCHv2 2/2] qemu: Disk Geometry Override Support

2012-07-20 Thread Viktor Mihajlovski
From: J.B. Joret j...@linux.vnet.ibm.com Qemu command line generation for geometry override and testcases. V2 Changes: squashed qemu code and testcases. Signed-off-by: J.B. Joret j...@linux.vnet.ibm.com Signed-off-by: Viktor Mihajlovski mihaj...@linux.vnet.ibm.com --- src/qemu/qemu_command.c

[libvirt] [PATCHv2 1/2] Support for Disk Geometry Override

2012-07-20 Thread Viktor Mihajlovski
From: J.B. Joret j...@linux.vnet.ibm.com A hypervisor may allow to override the disk geometry of drives. Qemu, as an example with cyls=,heads=,secs=[,trans=]. This patch extends the domain config to allow the specification of disk geometry with libvirt. V2 Changes: Split out qemu specific code,

[libvirt] Libvirt/LXC/SystemD/SELinux Hackfest at Linux Plumbers, San Diego

2012-07-20 Thread Daniel P. Berrange
Hi Folks, This years Linux Plumbers Conference (LPC)[1] is taking place in San Diego in the last week of August (co-located with LinuxCon). Since there is alot of integration between libvirt / LXC / SystemD and SELinux, and many of the key developers from those projects will be at LPC, Lennart

Re: [libvirt] [PATCH] don't make lxc_driver static

2012-07-20 Thread Daniel P. Berrange
On Fri, Jul 20, 2012 at 02:43:19PM +0800, Gao feng wrote: because it will be used in lxc_process.c below is the error information debug : virDriverLoadModule:66 : Module load lxc error : virDriverLoadModule:78 : failed to load module

Re: [libvirt] [PATCH libvirt-glib] gobject: add GVir.DomainShutdownFlags binding

2012-07-20 Thread Christophe Fergeau
On Thu, Jul 19, 2012 at 07:36:50PM +0200, Marc-André Lureau wrote: --- libvirt-gobject/libvirt-gobject-domain.c |2 +- libvirt-gobject/libvirt-gobject-domain.h | 13 + libvirt-gobject/libvirt-gobject.sym |1 + 3 files changed, 15 insertions(+), 1 deletion(-)

Re: [libvirt] [PATCH 06/23] Replace use of openvzError with virReportError

2012-07-20 Thread Peter Krempa
On 07/18/12 20:40, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the OpenVZ driver to use virReportError instead of the openvzError custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk |1 -

Re: [libvirt] [PATCH 09/23] Replace use of libxlError with virReportError

2012-07-20 Thread Jiri Denemark
On Wed, Jul 18, 2012 at 19:40:45 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the libxl driver to use virReportError instead of the libxlError custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk |1 -

Re: [libvirt] [PATCH 11/23] Replace use of virLockError with virReportError

2012-07-20 Thread Jiri Denemark
On Wed, Jul 18, 2012 at 19:40:47 +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the lock manager drivers to use virReportError instead of the virLockError custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com ---

Re: [libvirt] [PATCH 10/23] Replace use of remoteError with virReportError

2012-07-20 Thread Peter Krempa
On 07/18/12 20:40, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the remote driver to use virReportError instead of the remoteError custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk |1 -

Re: [libvirt] [PATCH 13/23] Replace use of ESX_ERROR ESX_VI_ERROR with virReportError

2012-07-20 Thread Michal Privoznik
On 18.07.2012 20:40, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the ESX driver to use virReportError instead of the ESX_ERROR ESX_VI_ERROR custom macros Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk |2 -

Re: [libvirt] [PATCH 14/23] Replace use of HYPERV_ERROR with virReportError

2012-07-20 Thread Michal Privoznik
On 18.07.2012 20:40, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the Hyper-V driver to use virReportError instead of the HYPERV_ERROR custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk |1 -

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Jiri Denemark
On Fri, Jul 20, 2012 at 00:40:33 +0800, Osier Yang wrote: Mainly for later patches' use, to filter the pools by pool type. include/libvirt/libvirt.h.in: Add enum virStoragePoolType; Add pool type to virStoragePoolInfo. src/conf/storage_conf.h: Remove enum virStoragePoolType.

Re: [libvirt] [PATCH 16/23] Replace use of PHYP_ERROR with virReportError

2012-07-20 Thread Martin Kletzander
On 07/18/2012 08:40 PM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the Power-Hypervisor driver to use virReportError instead of the PHYP_ERROR custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk |1 -

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Daniel P. Berrange
On Fri, Jul 20, 2012 at 02:28:26PM +0200, Jiri Denemark wrote: On Fri, Jul 20, 2012 at 00:40:33 +0800, Osier Yang wrote: Mainly for later patches' use, to filter the pools by pool type. include/libvirt/libvirt.h.in: Add enum virStoragePoolType; Add pool type to virStoragePoolInfo.

Re: [libvirt] [PATCH 15/23] Replace use of virSecurityReportError with virReportError

2012-07-20 Thread Michal Privoznik
On 18.07.2012 20:40, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the security drivers to use virReportError instead of the virSecurityReportError custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk |

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Osier Yang
On 2012年07月20日 20:44, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 02:28:26PM +0200, Jiri Denemark wrote: On Fri, Jul 20, 2012 at 00:40:33 +0800, Osier Yang wrote: Mainly for later patches' use, to filter the pools by pool type. include/libvirt/libvirt.h.in: Add enum virStoragePoolType;

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Daniel P. Berrange
On Fri, Jul 20, 2012 at 09:00:21PM +0800, Osier Yang wrote: On 2012年07月20日 20:44, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 02:28:26PM +0200, Jiri Denemark wrote: On Fri, Jul 20, 2012 at 00:40:33 +0800, Osier Yang wrote: Mainly for later patches' use, to filter the pools by pool type.

Re: [libvirt] [PATCH 20/23] Replace use of nodeReportError with virReportError

2012-07-20 Thread Michal Privoznik
On 18.07.2012 20:40, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the nodeinfo helper code to use virReportError instead of the nodeReportError custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk |1 -

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Osier Yang
On 2012年07月20日 21:01, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 09:00:21PM +0800, Osier Yang wrote: On 2012年07月20日 20:44, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 02:28:26PM +0200, Jiri Denemark wrote: On Fri, Jul 20, 2012 at 00:40:33 +0800, Osier Yang wrote: Mainly for

Re: [libvirt] [PATCH 23/23] Replace use of virNetError with virReportError

2012-07-20 Thread Michal Privoznik
On 18.07.2012 20:40, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the libvirtd dispatch code to use virReportError instead of the virNetError custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com --- daemon/remote.c| 214

Re: [libvirt] [PATCH 12/23] Replace use of custom macros with virReportError in the Xen drivers

2012-07-20 Thread Peter Krempa
On 07/18/12 20:40, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the legacy Xen drivers to use virReportError instead of the statsError, virXenInotifyError, virXenStoreError, virXendError, xenUnifiedError, xenXMError custom macros Signed-off-by: Daniel P.

Re: [libvirt] [PATCH 22/23] Replace use of virConfError with virReportError

2012-07-20 Thread Peter Krempa
On 07/18/12 20:40, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the libvirtd config handling code to use virReportError instead of the virConfError custom macro Signed-off-by: Daniel P. Berrange berra...@redhat.com --- cfg.mk |1 -

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Jiri Denemark
On Fri, Jul 20, 2012 at 21:10:57 +0800, Osier Yang wrote: On 2012年07月20日 21:01, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 09:00:21PM +0800, Osier Yang wrote: On 2012年07月20日 20:44, Daniel P. Berrange wrote: Fortunately no other part of this patch series appears to rely on this

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Daniel P. Berrange
On Fri, Jul 20, 2012 at 03:21:20PM +0200, Jiri Denemark wrote: On Fri, Jul 20, 2012 at 21:10:57 +0800, Osier Yang wrote: On 2012年07月20日 21:01, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 09:00:21PM +0800, Osier Yang wrote: On 2012年07月20日 20:44, Daniel P. Berrange wrote:

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Osier Yang
On 2012年07月20日 21:23, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 03:21:20PM +0200, Jiri Denemark wrote: On Fri, Jul 20, 2012 at 21:10:57 +0800, Osier Yang wrote: On 2012年07月20日 21:01, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 09:00:21PM +0800, Osier Yang wrote: On 2012年07月20日

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Osier Yang
On 2012年07月20日 21:10, Osier Yang wrote: On 2012年07月20日 21:01, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 09:00:21PM +0800, Osier Yang wrote: On 2012年07月20日 20:44, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 02:28:26PM +0200, Jiri Denemark wrote: On Fri, Jul 20, 2012 at 00:40:33

[libvirt] [PATCH v3] storage: netfs and iscsi need option srcSpec for resource discovery

2012-07-20 Thread Guannan Ren
The option 'srcSpec' to virsh command find-storage-pool-sources is optional for logical type of storage pool, but mandatory for netfs and iscsi type. When missing the option for netfs and iscsi, libvirt reports XML parsing error due to null string option srcSpec. error: Failed to find any netfs

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Peter Krempa
On 07/20/12 15:26, Osier Yang wrote: On 2012年07月20日 21:23, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 03:21:20PM +0200, Jiri Denemark wrote: On Fri, Jul 20, 2012 at 21:10:57 +0800, Osier Yang wrote: On 2012年07月20日 21:01, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 09:00:21PM

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Daniel P. Berrange
On Fri, Jul 20, 2012 at 09:26:48PM +0800, Osier Yang wrote: On 2012年07月20日 21:23, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 03:21:20PM +0200, Jiri Denemark wrote: On Fri, Jul 20, 2012 at 21:10:57 +0800, Osier Yang wrote: On 2012年07月20日 21:01, Daniel P. Berrange wrote: On Fri, Jul 20,

[libvirt] [PATCH v2] doc: update the minimum value for nodesuspend time duration

2012-07-20 Thread Guannan Ren
libvirt asks the duration time is above 60 seconds in code src/util/virnodesuspend.c: define MIN_TIME_REQ_FOR_SUSPEND 60 /* in seconds */ if (alarmTime = MIN_TIME_REQ_FOR_SUSPEND) { virReportError(VIR_ERR_INVALID_ARG, %s, _(Suspend duration is too short));

Re: [libvirt] [PATCH] doc: update the minimum value for nodesuspend time duration

2012-07-20 Thread Guannan Ren
On 07/19/2012 09:24 PM, Eric Blake wrote: On 07/19/2012 03:05 AM, Guannan Ren wrote: libvirt asks the duration time is above 60 seconds in code src/util/virnodesuspend.c: define MIN_TIME_REQ_FOR_SUSPEND 60 /* in seconds */ We should update the information in virsh help and manpage. ---

Re: [libvirt] [PATCH 02/50] list: Expose pool type via virStoragePoolGetInfo

2012-07-20 Thread Osier Yang
On 2012年07月20日 21:35, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 09:26:48PM +0800, Osier Yang wrote: On 2012年07月20日 21:23, Daniel P. Berrange wrote: On Fri, Jul 20, 2012 at 03:21:20PM +0200, Jiri Denemark wrote: On Fri, Jul 20, 2012 at 21:10:57 +0800, Osier Yang wrote: On 2012年07月20日

[libvirt] [PATCH 0/3] Updates for Xen error reporting

2012-07-20 Thread Daniel P. Berrange
This is an update of the previous patch to make Xen use virReportError. Before that can be done, some cleanup in Xen was required -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] [PATCH 1/3] Ensure failure to talk to Xen hypervisor is fatal when privileged

2012-07-20 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com As per the comment, the Xen hypervisor driver is considered to be mandatory when running privileged. When it fails to open, we should thus return an error, not ignore it. --- src/xen/xen_driver.c |2 ++ 1 file changed, 2 insertions(+) diff --git

Re: [libvirt] [PATCH 1/5] Add public API to register a callback to be invoked on connection close

2012-07-20 Thread Daniel P. Berrange
On Thu, Jul 19, 2012 at 11:46:28AM -0600, Eric Blake wrote: On 07/19/2012 09:04 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Define a new virConnectSetCloseCallback() public API which allows registering a callback to be invoked when the connection to a

[libvirt] [PATCH 2/3] Make sure xenHypervisorInit correctly reports errors

2012-07-20 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The xenHypervisorInit method was called from two different locations, during initial driver registration and also while opening a Xen connection. The former can't report any useful errors to the end user/app, so remove it. To ensure thread safety use a

Re: [libvirt] [PATCH 3/5] Add callback to virNetClient to be invoked on connection close

2012-07-20 Thread Daniel P. Berrange
On Thu, Jul 19, 2012 at 11:57:17AM -0600, Eric Blake wrote: On 07/19/2012 09:04 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Allow detection of socket close in virNetClient via an callback function, triggered on any condition that causes the socket to be

Re: [libvirt] [PATCH 5/5] Extend events demo to show close callbacks in use

2012-07-20 Thread Daniel P. Berrange
On Thu, Jul 19, 2012 at 01:12:33PM -0600, Eric Blake wrote: On 07/19/2012 09:04 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Use a driver close callback to trigger shutdown of the events demo program Signed-off-by: Daniel P. Berrange berra...@redhat.com

[libvirt] [PATCH 1/5 v2] Add public API to register a callback to be invoked on connection close

2012-07-20 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Define a new virConnectSetCloseCallback() public API which allows registering a callback to be invoked when the connection to a hypervisor is closed. The callback is provided with the reason for the close, which may be 'error', 'eof' or 'keepalive'.

[libvirt] [PATCH] Disable NWFilter driver completely when unprivileged

2012-07-20 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Running libvirtd unprivileged results in a warning message from the NWFilter driver virNWFilterSnoopLeaseFileRefresh:1882 : open(/var/run/libvirt/network/nwfilter.ltmp): No such file or directory Since it requires privileged network access, this

[libvirt] [PATCH 06/49] list: Implement listAllStoragePools for storage driver

2012-07-20 Thread Osier Yang
src/storage/storage_driver.c: Implement listAllStoragePools. --- src/storage/storage_driver.c | 19 +++ 1 files changed, 19 insertions(+), 0 deletions(-) diff --git a/src/storage/storage_driver.c b/src/storage/storage_driver.c index c9b8021..0974879 100644 ---

[libvirt] [PATCH 01/49] Fix indentions

2012-07-20 Thread Osier Yang
Some of the macros use tab, while the left use spaces, this patch change it to always use the spaces. And a few aligning fixes. --- src/datatypes.h | 86 +++--- 1 files changed, 43 insertions(+), 43 deletions(-) diff --git a/src/datatypes.h

[libvirt] [PATCH 03/49] list: Define new API virStorageListALlStoragePools

2012-07-20 Thread Osier Yang
This introduces a new API to list the storage pool objects, 4 groups of flags are provided to filter the returned pools: * Active or not * Autostarting or not * Persistent or not * And the pool type. include/libvirt/libvirt.h.in: New enum virConnectListAllStoragePoolFlags;

[libvirt] [PATCH 05/49] list: Implement the RPC calls for virConnectListAllStoragePools

2012-07-20 Thread Osier Yang
The RPC generator doesn't support returning list of object, this patch do the work manually. * daemon/remote.c: Implement the server side handler remoteDispatchConnectListAllStoragePools * src/remote/remote_driver.c: Add remote driver handler remoteConnectListAllStoragePools. *

[libvirt] [PATCH 09/49] virsh: Fix the wrong doc for pool-list

2012-07-20 Thread Osier Yang
The storage pool's management doesn't relate with a domain, it probably was a intention, but not achieved yet. And the fact is only active pools are listed by default. --- tools/virsh.pod |9 - 1 files changed, 4 insertions(+), 5 deletions(-) diff --git a/tools/virsh.pod

[libvirt] [PATCH 04/49] list: Add helpers for listing storage pool objects

2012-07-20 Thread Osier Yang
src/conf/virobjectlist.c: Add virStoragePoolMatch to filter the pools; Add virStoragePoolList to iterate over the pool objects with filter. src/conf/virobjectlist.h: Declare virStoragePoolMatch, virStoragePoolList, and the macros for filters. src/libvirt_private.syms: Export helper

[libvirt] [PATCH 15/49] list: Implemente RPC calls for virStoragePoolListAllVolumes

2012-07-20 Thread Osier Yang
The RPC generator doesn't returning support list of object, this patch do the work manually. * daemon/remote.c: Implemente the server side handler remoteDispatchStoragePoolListAllVolumes * src/remote/remote_driver.c: Add remote driver handler remoteStoragePoolListAllVolumes *

[libvirt] [PATCH 02/49] list: Rename virdomainlist.[ch] for common use

2012-07-20 Thread Osier Yang
Except objects of domains, domain snapshots, we will also add APIs to list objects like storage pools, storage vols, network, interface, etc. And it's deserved to have the small helper functions in a common file instead of in separate files. This patch renames virdomainlist.[ch] to

[libvirt] [PATCH 11/49] list: Use virConnectListAllStoragePools in virsh

2012-07-20 Thread Osier Yang
tools/virsh.c: * vshStoragePoolSorter to sort the pool list by pool name. * struct vshStoragePoolList to present the pool list, pool info is collected by list-poolinfo if 'details' is specified by user. * vshStoragePoolListFree to free the pool list * vshStoragePoolListCollect

[libvirt] [PATCH 07/49] list: Implement listAllStoragePools for test driver

2012-07-20 Thread Osier Yang
src/test/test_driver.c: Implement listAllStoragePools --- src/test/test_driver.c | 17 + 1 files changed, 17 insertions(+), 0 deletions(-) diff --git a/src/test/test_driver.c b/src/test/test_driver.c index bf2c1c2..21164ca 100644 --- a/src/test/test_driver.c +++

[libvirt] [PATCH 17/49] list: Implement virStoragePoolListAllVolumes for test driver

2012-07-20 Thread Osier Yang
src/test/test_driver.c: Implement poolListAllVolumes. --- src/test/test_driver.c | 67 1 files changed, 67 insertions(+), 0 deletions(-) diff --git a/src/test/test_driver.c b/src/test/test_driver.c index 21164ca..9b528f2 100644 ---

[libvirt] [PATCH 00/49 v2] Atomic APIs to list objects

2012-07-20 Thread Osier Yang
v1 - v2: * Fix the stupid mistake - changing the public struct, error out if the new option '--type' for pool-list is specified, and the libvirt is old enough without listAllStoragePools supported. Except the already supported APIs for domain and domain snapshot, this series add the

[libvirt] [PATCH 19/49] list: Expose virStoragePoolListAllVolumes to Python binding

2012-07-20 Thread Osier Yang
The implementation is done manually as the generator does not support wrapping lists of C pointers into Python objects. python/libvirt-override-api.xml: Document python/libvirt-override-virStoragePool.py: * New file, includes implementation of listAllVolumes. python/libvirt-override.c:

[libvirt] [PATCH 14/49] list: Define new API virStoragePoolListAllVolumes

2012-07-20 Thread Osier Yang
Simply returns the storage volume objects. No supported filter flags. include/libvirt/libvirt.h.in: Declare the API python/generator.py: Skip the function for generating. virStoragePool.py will be added in later patch. src/driver.h: virDrvStoragePoolListVolumesFlags

[libvirt] [PATCH 30/49] list: Implement listAllInterfaces

2012-07-20 Thread Osier Yang
This is not that ideal as API for other objects, as it's still O(n). Because interface driver uses netcf APIs to manage the stuffs, instead of by itself. And netcf APIs don't return a object. It provides APIs like old libvirt APIs: ncf_number_of_interfaces ncf_list_interfaces

[libvirt] [PATCH 18/49] list: Use virStoragePoolListAllVolumes in virsh

2012-07-20 Thread Osier Yang
tools/virsh.c: * vshStorageVolSorter to sort storage vols by name * vshStorageVolumeListFree to free the volume objects list * vshStorageVolumeListCollect to collect the volume objects, trying to use new API first, fall back to older APIs if it's not supported. --- tools/virsh.c |

[libvirt] [PATCH 35/49] list: Add helpers for listing node devices

2012-07-20 Thread Osier Yang
src/conf/virobjectlist.h: * New macro VIR_CONNECT_LIST_NODE_DEVICES_FILTERS_CAP * Declare virNodeDeviceList src/conf/virobjectlist.c: * New helpers virNodeDeviceCapMatch, virNodeDeviceMatch. virNodeDeviceCapMatch looks up the list of all the caps the device support, to see if the

[libvirt] [PATCH 12/49] virsh: Use vshPrint instead of printf

2012-07-20 Thread Osier Yang
--- tools/virsh.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/tools/virsh.c b/tools/virsh.c index ab64918..7d7c9ca 100644 --- a/tools/virsh.c +++ b/tools/virsh.c @@ -18344,7 +18344,7 @@ cmdQemuMonitorCommand(vshControl *ctl, const vshCmd *cmd) if

[libvirt] [PATCH 13/49] python: Expose virStorageListAllStoragePools to python binding

2012-07-20 Thread Osier Yang
The implementation is done manually as the generator does not support wrapping lists of C pointers into Python objects. python/libvirt-override-api.xml: Document python/libvirt-override-virConnect.py: Add listAllStoragePools python/libvirt-override.c: Implementation for the wrapper. ---

[libvirt] [PATCH 21/49] list: Implement RPC calls for virConnectListAllNetworks

2012-07-20 Thread Osier Yang
The RPC generator doesn't support returning list of object, this patch do the work manually. * daemon/remote.c: Implemente the server side handler remoteDispatchConnectListAllNetworks. * src/remote/remote_driver.c: Add remote driver handler remoteConnectListAllNetworks. *

[libvirt] [PATCH 10/49] list: Change MATCH for common use in virsh

2012-07-20 Thread Osier Yang
tools/virsh.c: Change MATCH for common use. It's safe, only the new helpers to collect objects use it. --- tools/virsh.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/virsh.c b/tools/virsh.c index 9c3b565..2d4567d 100644 --- a/tools/virsh.c +++ b/tools/virsh.c

[libvirt] [PATCH 20/49] list: Define new API virConnectListAllNetworks

2012-07-20 Thread Osier Yang
This is to list the network objects, supported filtering flags are: active|inactive, persistent|transient, autostart|no-autostart. include/libvirt/libvirt.h.in: Declare enum virConnectListAllNetworkFlags and virConnectListAllNetworks. python/generator.py: Skip

[libvirt] [PATCH 16/49] list: Implement virStoragePoolListAllVolumes for storage driver

2012-07-20 Thread Osier Yang
src/storage/storage_driver.c: Implement poolListAllVolumes. --- src/storage/storage_driver.c | 67 ++ 1 files changed, 67 insertions(+), 0 deletions(-) diff --git a/src/storage/storage_driver.c b/src/storage/storage_driver.c index 0974879..c630c2e 100644

[libvirt] [PATCH 38/49] virsh: Fix a bug of nodedev-list

2012-07-20 Thread Osier Yang
Output of commands like '%virsh nodedev-list --tree --cap pci' could be empty. Remove the useless checking. --- tools/virsh.c |5 ++--- 1 files changed, 2 insertions(+), 3 deletions(-) diff --git a/tools/virsh.c b/tools/virsh.c index 8e191f4..8b85a7a 100644 --- a/tools/virsh.c +++

[libvirt] [PATCH 08/49] list: Add helper to convert strings separated by ', ' to array

2012-07-20 Thread Osier Yang
tools/virsh.c: New helper function vshStringToArray, use the helper in cmdUndefine. --- tools/virsh.c | 107 +++-- 1 files changed, 66 insertions(+), 41 deletions(-) diff --git a/tools/virsh.c b/tools/virsh.c index 40f3be3..9c3b565 100644 ---

[libvirt] [PATCH 39/49] list: Use virConnectListAllNodeDevices in virsh

2012-07-20 Thread Osier Yang
tools/virsh.c: * vshNodeDeviceSorter to sort node devices by name * vshNodeDeviceListFree to free the node device objects list. * vshNodeDeviceListCollect to collect the node device objects, trying to use new API first, fall back to older APIs if it's not supported. * Change option

[libvirt] [PATCH 23/49] list: Implement listAllNetworks for network driver

2012-07-20 Thread Osier Yang
src/network/bridge_driver.c: Implement listAllNetworks. --- src/network/bridge_driver.c | 18 ++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index bb2a765..6a3ed3f 100644 ---

[libvirt] [PATCH 42/49] list: Implement listAllNWFilters

2012-07-20 Thread Osier Yang
Simply returns the object list. No filtering. src/nwfilter/nwfilter_driver.c: Implement listAllNWFilters --- src/nwfilter/nwfilter_driver.c | 57 1 files changed, 57 insertions(+), 0 deletions(-) diff --git a/src/nwfilter/nwfilter_driver.c

[libvirt] [PATCH 22/49] list: Add helpers to list network objects

2012-07-20 Thread Osier Yang
src/conf/virobjectlist.c: Add virNetworkMatch to filter the networks; and virNetworkList to iterate over all the networks with the filter. src/conf/virobjectlist.h: Declare virNetworkList and define the macros for filters. src/libvirt_private.syms: Export virNetworkList. ---

[libvirt] [PATCH 48/49] list: Use virConnectListAllSecrets in virsh

2012-07-20 Thread Osier Yang
tools/virsh.c: * vshSecretSorter to sort secret object by name * vshSecretListFree to free the secret objects list. * vshSecretListCollect to collect the secret objects, trying to use new API first, fall back to older APIs if it's not supported. --- tools/virsh.c | 192

[libvirt] [PATCH 27/49] daemon: Fix the wrong macro name

2012-07-20 Thread Osier Yang
WITH_INTERFACE is not defined, it should be WITH_NETCF there to load the interface driver. Eric posted patch weeks ago to resolve the problems in the whole build system, but it's not finalised yet: https://www.redhat.com/archives/libvir-list/2012-June/msg01299.html I'm going to simply fix the

[libvirt] [PATCH 31/49] list: Use virConnectListAllInterfaces in virsh

2012-07-20 Thread Osier Yang
tools/virsh.c: * vshInterfaceSorter to sort interfaces by name * vshInterfaceListFree to free the interface objects list. * vshInterfaceListCollect to collect the interface objects, trying to use new API first, fall back to older APIs if it's not supported. --- tools/virsh.c | 258

[libvirt] [PATCH 28/49] list: Define new API virConnectListAllInterfaces

2012-07-20 Thread Osier Yang
This is to list the interface objects, supported filtering flags are: active|inactive. include/libvirt/libvirt.h.in: Declare enum virConnectListAllInterfaceFlags and virConnectListAllInterfaces. python/generator.py: Skip auto-generating src/driver.h:

[libvirt] [PATCH 24/49] list: Implement listAllNetworks for test driver

2012-07-20 Thread Osier Yang
src/test/test_driver.c: Implement listAllNetworks. --- src/test/test_driver.c | 17 + 1 files changed, 17 insertions(+), 0 deletions(-) diff --git a/src/test/test_driver.c b/src/test/test_driver.c index 9b528f2..ed8cd47 100644 --- a/src/test/test_driver.c +++

[libvirt] [PATCH 29/49] list: Implemente RPC calls for virConnectListAllInterfaces

2012-07-20 Thread Osier Yang
The RPC generator doesn't support returning list of object yet, this patch do the work manually. * daemon/remote.c: Implemente the server side handler remoteDispatchConnectListAllInterfaces. * src/remote/remote_driver.c: Add remote driver handler remoteConnectListAllInterfaces. *

[libvirt] [PATCHv3 2/2] qemu: Disk Geometry Override Support

2012-07-20 Thread Viktor Mihajlovski
From: J.B. Joret j...@linux.vnet.ibm.com Qemu command line generation for geometry override and testcases. V2 Changes: squashed qemu code and testcases. V3 Changes: use virReportError. Signed-off-by: J.B. Joret j...@linux.vnet.ibm.com Signed-off-by: Viktor Mihajlovski

[libvirt] [PATCH 25/49] list: Use virConnectListAllNetworks in virsh

2012-07-20 Thread Osier Yang
tools/virsh.c: * vshNetworkSorter to sort networks by name * vshNetworkListFree to free the network objects list. * vshNetworkListCollect to collect the network objects, trying to use new API first, fall back to older APIs if it's not supported. * New options --persistent,

[libvirt] [PATCH 26/49] list: Expose virConnectListAllNetworks to Python binding

2012-07-20 Thread Osier Yang
The implementation is done manually as the generator does not support wrapping lists of C pointers into Python objects. python/libvirt-override-api.xml: Document python/libvirt-override-virConnect.py: Implement listAllNetworks. python/libvirt-override.c: Implementation for the wrapper. ---

[libvirt] [PATCH 32/49] list: Expose virConnectListAllInterfaces to Python binding

2012-07-20 Thread Osier Yang
The implementation is done manually as the generator does not support wrapping lists of C pointers into Python objects. python/libvirt-override-api.xml: Document python/libvirt-override-virConnect.py: * New file, includes implementation of listAllInterfaces. python/libvirt-override.c:

[libvirt] [PATCH 34/49] list: Implemente RPC calls for virConnectListAllNodeDevices

2012-07-20 Thread Osier Yang
The RPC generator doesn't support returning list of object yet, this patch do the work manually. * daemon/remote.c: Implemente the server side handler remoteDispatchConnectListAllNodeDevices. * src/remote/remote_driver.c: Add remote driver handler remoteConnectListAllNodeDevices.

[libvirt] [PATCH 37/49] list: Expose virConnectListAllNodeDevices to Python binding

2012-07-20 Thread Osier Yang
The implementation is done manually as the generator does not support wrapping lists of C pointers into Python objects. python/libvirt-override-api.xml: Document python/libvirt-override-virConnect.py: * Implementation for listAllNodeDevices. python/libvirt-override.c: Implementation for the

[libvirt] [PATCH 40/49] list: Define new API virConnectListAllNWFilters

2012-07-20 Thread Osier Yang
This is to list the network fitler objects. No flags are supported include/libvirt/libvirt.h.in: Declare enum virConnectListAllNWFilterFlags and virConnectListAllNWFilters. python/generator.py: Skip auto-generating src/driver.h: (virDrvConnectListAllNWFilters)

[libvirt] [PATCH 33/49] list: Define new API virConnectListAllNodeDevices

2012-07-20 Thread Osier Yang
This is to list the node device objects, supports to filter the results by capability types. include/libvirt/libvirt.h.in: Declare enum virConnectListAllNodeDeviceFlags and virConnectListAllNodeDevices. python/generator.py: Skip auto-generating src/driver.h:

[libvirt] [PATCH 36/49] list: Implement listAllNodeDevices

2012-07-20 Thread Osier Yang
This simply implements listAllNodeDevices using helper virNodeDeviceList src/node_device/node_device_driver.h: * Declare nodeListAllNodeDevices. src/node_device/node_device_driver.c: * Implement nodeListAllNodeDevices. src/node_device/node_device_hal.c: * Hook listAllNodeDevices to

[libvirt] [PATCH 45/49] list: Define new API virConnectListAllSecrets

2012-07-20 Thread Osier Yang
This is to list the secret objects. No flags are supported include/libvirt/libvirt.h.in: Declare enum virConnectListAllSecretFlags and virConnectListAllSecrets. python/generator.py: Skip auto-generating src/driver.h: (virDrvConnectListAllSecrets) src/libvirt.c:

[libvirt] [PATCH 43/49] list: Use virConnectListAllNWFilters in virsh

2012-07-20 Thread Osier Yang
tools/virsh.c: * vshNWFilterSorter to sort network filters by name * vshNWFilterListFree to free the network filter objects list. * vshNWFilterListCollect to collect the network filter objects, trying to use new API first, fall back to older APIs if it's not supported. ---

[libvirt] [PATCH 47/49] list: Implement listAllSecrets

2012-07-20 Thread Osier Yang
Simply returns the object list. No filtering. src/secret/secret_driver.c: Implement listAllSecrets --- src/secret/secret_driver.c | 58 +++- 1 files changed, 57 insertions(+), 1 deletions(-) diff --git a/src/secret/secret_driver.c

[libvirt] [PATCH 46/49] list: Implement RPC calls for virConnectListAllSecrets

2012-07-20 Thread Osier Yang
The RPC generator doesn't support returning list of object yet, this patch do the work manually. * daemon/remote.c: Implemente the server side handler remoteDispatchConnectListAllSecrets. * src/remote/remote_driver.c: Add remote driver handler remoteConnectListAllSecrets. *

[libvirt] [PATCH 44/49] list: Expose virConnectListAllNWFilters to Python binding

2012-07-20 Thread Osier Yang
The implementation is done manually as the generator does not support wrapping lists of C pointers into Python objects. python/libvirt-override-api.xml: Document python/libvirt-override-virConnect.py: * Implementation for listAllNWFilters. python/libvirt-override.c: Implementation for the

[libvirt] [PATCHv3 1/2] Support for Disk Geometry Override

2012-07-20 Thread Viktor Mihajlovski
From: J.B. Joret j...@linux.vnet.ibm.com A hypervisor may allow to override the disk geometry of drives. Qemu, as an example with cyls=,heads=,secs=[,trans=]. This patch extends the domain config to allow the specification of disk geometry with libvirt. V2 Changes: Split out qemu specific code,

[libvirt] [PATCH 49/49] list: Expose virConnectListAllSecrets to Python binding

2012-07-20 Thread Osier Yang
The implementation is done manually as the generator does not support wrapping lists of C pointers into Python objects. python/libvirt-override-api.xml: Document python/libvirt-override-virConnect.py: Implementation for listAllSecrets. python/libvirt-override.c: Implementation for the wrapper.

[libvirt] [PATCH 41/49] list: Implement RPC calls for virConnectListAllNWFilters

2012-07-20 Thread Osier Yang
The RPC generator doesn't support returning list of object yet, this patch do the work manually. * daemon/remote.c: Implemente the server side handler remoteDispatchConnectListAllNWFilters. * src/remote/remote_driver.c: Add remote driver handler remoteConnectListAllNWFilters. *

[libvirt] [PATCHv3 0/2] Rework of Disk Geometry Support

2012-07-20 Thread Viktor Mihajlovski
Two more changes: 1. Use virReportError instead of custom xxxReportError. 2. Moved the geometry element to diskspec, so it applies to all kind of disks. Please disregard the preceding patches. J.B. Joret (2): Support for Disk Geometry Override qemu: Disk Geometry Override Support

Re: [libvirt] [PATCH] Disable NWFilter driver completely when unprivileged

2012-07-20 Thread Michal Privoznik
On 20.07.2012 16:22, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Running libvirtd unprivileged results in a warning message from the NWFilter driver virNWFilterSnoopLeaseFileRefresh:1882 : open(/var/run/libvirt/network/nwfilter.ltmp): No such file or

Re: [libvirt] [PATCH 03/13] Rewrite virAtomic APIs using GLib's atomic ops code

2012-07-20 Thread Eric Blake
On 07/20/2012 12:36 AM, Hu Tao wrote: The `verify' lines cause building warnings: cc1: warnings being treated as errors util/virobject.c: In function 'virClassNew': util/virobject.c:74:99: error: nested extern declaration of '_gl_verify_function2' [-Wnested-externs] Which version of gcc?

Re: [libvirt] [PATCH v8 7/8] parallels: add storage driver

2012-07-20 Thread Peter Krempa
On 07/04/12 19:42, Dmitry Guryanov wrote: PARALLELS has one serious discrepancy with libvirt: libvirt stores domain configuration files in one place, and storage files in other places (with the API of storage pools and storage volumes). PARALLELS stores all domain data in a single directory, for

  1   2   >