[libvirt] [libvirt-test-API][PATCH 1/2] Add coredump_with_format test case

2015-02-26 Thread jiahu
The coredump_with_format.py uses coreDumpWithFormat() to validate new API virDomainCoreDumpWithFormat of libvirt. --- repos/domain/coredump_with_format.py | 239 +++ 1 file changed, 239 insertions(+) create mode 100644 repos/domain/coredump_with_format.py diff

Re: [libvirt] [PATCH] Ignore listen attribute of graphics for type network listens

2015-02-26 Thread Ján Tomko
On Thu, Feb 26, 2015 at 12:40:43PM -0500, Laine Stump wrote: On 02/26/2015 11:39 AM, Ján Tomko wrote: On Thu, Feb 26, 2015 at 04:29:53PM +0100, Martin Kletzander wrote: On Thu, Feb 26, 2015 at 09:57:22AM -0500, Laine Stump wrote: On 02/26/2015 08:53 AM, Ján Tomko wrote: Commit 6992994

[libvirt] [libvirt-test-API][PATCH 2/2] Add coredump_with_format test case to linux_domain conf

2015-02-26 Thread jiahu
--- cases/linux_domain.conf | 44 1 file changed, 44 insertions(+) diff --git a/cases/linux_domain.conf b/cases/linux_domain.conf index a5ada35..490ee90 100644 --- a/cases/linux_domain.conf +++ b/cases/linux_domain.conf @@ -34,6 +34,50 @@ domain:start

[libvirt] [libvirt-test-API][PATCH 0/2] Add coredump_with_format test case

2015-02-26 Thread jiahu
The coredump_with_format.py uses coreDumpWithFormat() to validate new API virDomainCoreDumpWithFormat of libvirt. jiahu (2): Add coredump_with_format test case Add coredump_with_format test case to linux_domain conf cases/linux_domain.conf | 44 +++

Re: [libvirt] [PATCH] qemu: forbid large value wraparound in balloon period collection

2015-02-26 Thread Martin Kletzander
On Thu, Feb 26, 2015 at 05:42:10PM +0100, Erik Skultety wrote: On 02/25/2015 08:10 AM, Martin Kletzander wrote: On Tue, Feb 24, 2015 at 04:28:18PM +0100, Erik Skultety wrote: We do parse and represent period collection as unsigned int in our internal structures, however commit

[libvirt] [PATCH v1 10/31] bridge_driver: s/virNetworkObjList/virNetworkObjListPtr/

2015-02-26 Thread Michal Privoznik
In order to hide the object internals (and use just accessors everywhere), lets store a pointer to the object, instead of object itself. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/network/bridge_driver.c | 98 +++-

[libvirt] [PATCH v1 28/31] virNetworkObjFindBy*: Return an reference to found object

2015-02-26 Thread Michal Privoznik
This patch turns both virNetworkObjFindByUUID() and virNetworkObjFindByName() to return an referenced object so that even if caller unlocks it, it's for sure that object won't disappear meanwhile. Especially if the object (in general) is locked and unlocked during the caller run. Moreover, this

[libvirt] [PATCH v1 03/31] testNetworkUpdate: Unlock network at the end

2015-02-26 Thread Michal Privoznik
Silly this bug went unnoticed so long. At the beginning we try to find the passed network in the list of network objects. If found, it's locked and real work takes place. Then, in the end, the network object is never unlocked. Signed-off-by: Michal Privoznik mpriv...@redhat.com ---

[libvirt] Adding timestamps for all emulator output

2015-02-26 Thread Andrey Korolyov
Hello, I think it would be useful if libvirt will be able to prefix all messages from emulator pipes with the date stamping, for example I am trying to catch very rare and non-fatal race with virtio-serial-bus: Guest failure in adding device virtio-serial0.0 which is specific to the Windows

Re: [libvirt] [PATCH] Ignore listen attribute of graphics for type network listens

2015-02-26 Thread Francesco Romani
- Original Message - From: Laine Stump la...@laine.org To: libvir-list@redhat.com Cc: Francesco Romani from...@redhat.com, Ján Tomko jto...@redhat.com Sent: Thursday, February 26, 2015 4:28:13 PM Subject: Re: [libvirt] [PATCH] Ignore listen attribute of graphics for type network

Re: [libvirt] [PATCH] Ignore listen attribute of graphics for type network listens

2015-02-26 Thread Ján Tomko
On Thu, Feb 26, 2015 at 04:29:53PM +0100, Martin Kletzander wrote: On Thu, Feb 26, 2015 at 09:57:22AM -0500, Laine Stump wrote: On 02/26/2015 08:53 AM, Ján Tomko wrote: Commit 6992994 started filling the listen attribute of the parent graphics elements from type='network' listens. When

Re: [libvirt] [PATCH] qemu: forbid large value wraparound in balloon period collection

2015-02-26 Thread Erik Skultety
On 02/25/2015 08:10 AM, Martin Kletzander wrote: On Tue, Feb 24, 2015 at 04:28:18PM +0100, Erik Skultety wrote: We do parse and represent period collection as unsigned int in our internal structures, however commit d5c67e7f4523450023b89b69c16472582c85eeaf converts this to int, thus wrapping

[libvirt] [PATCH] parallels: Cleanup partly opened drivers on connect open failure

2015-02-26 Thread Michal Privoznik
Well, the parallelsConnectOpen() joins several sub-driver openings into one big if condition. If any of sub-driver fails to open, the whole API finishes immediately. The problem is, sub-drivers may have left some memory allocated. Fortunately, we have a free function for that:

Re: [libvirt] [PATCH] Ignore listen attribute of graphics for type network listens

2015-02-26 Thread Ján Tomko
On Thu, Feb 26, 2015 at 11:10:06AM -0500, Francesco Romani wrote: - Original Message - From: Laine Stump la...@laine.org To: libvir-list@redhat.com Cc: Francesco Romani from...@redhat.com, Ján Tomko jto...@redhat.com Sent: Thursday, February 26, 2015 4:28:13 PM Subject: Re:

Re: [libvirt] [PATCH] Ignore listen attribute of graphics for type network listens

2015-02-26 Thread Laine Stump
On 02/26/2015 08:53 AM, Ján Tomko wrote: Commit 6992994 started filling the listen attribute of the parent graphics elements from type='network' listens. When this XML is passed to UpdateDevice, parsing fails: XML error: graphics listen attribute 10.20.30.40 must match address attribute of

Re: [libvirt] Adding timestamps for all emulator output

2015-02-26 Thread Andrey Korolyov
On Thu, Feb 26, 2015 at 5:36 PM, Daniel P. Berrange berra...@redhat.com wrote: On Thu, Feb 26, 2015 at 06:29:49PM +0400, Andrey Korolyov wrote: Hello, I think it would be useful if libvirt will be able to prefix all messages from emulator pipes with the date stamping, for example I am trying

Re: [libvirt] [PATCH v1 05/31] virNetworkObjIsDuplicate: s/@doms/@nets/

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:14 +0100, Michal Privoznik wrote: This is probably a copy-paste error from virDomainObj* counterpart. But when speaking of virNetworkObj we should use variable @nets for an array of networks, rather than @doms. It's just confusing. Signed-off-by: Michal

Re: [libvirt] [PATCH v1 07/31] virNetworkObjListExport: Pass virNetworkObjListPtr

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:16 +0100, Michal Privoznik wrote: Instead of copying the whole object onto stack when calling the function, just pass the pointer to the object and save up some space on the stack. Moreover, this prepares the code to hide the virNetworkObjList structure into

Re: [libvirt] [PATCH v1 03/31] testNetworkUpdate: Unlock network at the end

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:12 +0100, Michal Privoznik wrote: Silly this bug went unnoticed so long. At the beginning we try to find the passed network in the list of network objects. If found, it's locked and real work takes place. Then, in the end, the network object is never unlocked.

Re: [libvirt] [PATCH] Ignore listen attribute of graphics for type network listens

2015-02-26 Thread Francesco Romani
Hi, - Original Message - From: Laine Stump la...@laine.org To: libvir-list@redhat.com Cc: Ján Tomko jto...@redhat.com, from...@redhat.com Sent: Thursday, February 26, 2015 3:57:22 PM Subject: Re: [PATCH] Ignore listen attribute of graphics for type network listens On 02/26/2015

Re: [libvirt] [PATCH v1 02/31] bridge_driver: Don't check network active unlocked

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:11 +0100, Michal Privoznik wrote: Okay, this is mainly for educational purposes, since is called from single point only, with all the possible locks held. So Drop the last two commas in the sentence. there's no way for other thread to hop in and do something

Re: [libvirt] [PATCH] docs: add a note that spice channel is ignoret without spice graphics

2015-02-26 Thread Pavel Hrdina
On Thu, Feb 26, 2015 at 03:05:02PM +0100, Martin Kletzander wrote: On Thu, Feb 26, 2015 at 12:09:57PM +0100, Pavel Hrdina wrote: To prevent a confusion about missing chardev argument in qemu command line add a note about that behavior into documentation. Signed-off-by: Pavel Hrdina

Re: [libvirt] [PATCH v1 08/31] test_driver: s/virNetworkObjList/virNetworkObjListPtr/

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 16:46:26 +0100, Peter Krempa wrote: On Thu, Feb 26, 2015 at 15:17:17 +0100, Michal Privoznik wrote: In order to hide the object internals (and use just accessors everywhere), lets store a pointer to the object, instead of object itself. Signed-off-by: Michal

Re: [libvirt] [PATCH v1 04/31] networkGetNetworkAddress: Drop empty 'error' label

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:13 +0100, Michal Privoznik wrote: Moreover, there are two points within the function, where we're missing 'goto cleanup'. Fix this too. Control flow is okay even in that case, but this makes it more clear. Signed-off-by: Michal Privoznik mpriv...@redhat.com

Re: [libvirt] [PATCH] Ignore listen attribute of graphics for type network listens

2015-02-26 Thread Laine Stump
On 02/26/2015 10:11 AM, Francesco Romani wrote: Hi, - Original Message - From: Laine Stump la...@laine.org To: libvir-list@redhat.com Cc: Ján Tomko jto...@redhat.com, from...@redhat.com Sent: Thursday, February 26, 2015 3:57:22 PM Subject: Re: [PATCH] Ignore listen attribute of

Re: [libvirt] [PATCH] Ignore listen attribute of graphics for type network listens

2015-02-26 Thread Martin Kletzander
On Thu, Feb 26, 2015 at 09:57:22AM -0500, Laine Stump wrote: On 02/26/2015 08:53 AM, Ján Tomko wrote: Commit 6992994 started filling the listen attribute of the parent graphics elements from type='network' listens. When this XML is passed to UpdateDevice, parsing fails: XML error: graphics

Re: [libvirt] [PATCH v1 08/31] test_driver: s/virNetworkObjList/virNetworkObjListPtr/

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:17 +0100, Michal Privoznik wrote: In order to hide the object internals (and use just accessors everywhere), lets store a pointer to the object, instead of object itself. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/test/test_driver.c | 106

Re: [libvirt] [PATCH v1 10/31] bridge_driver: s/virNetworkObjList/virNetworkObjListPtr/

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:19 +0100, Michal Privoznik wrote: In order to hide the object internals (and use just accessors everywhere), lets store a pointer to the object, instead of object itself. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/network/bridge_driver.c

Re: [libvirt] Adding timestamps for all emulator output

2015-02-26 Thread Daniel P. Berrange
On Thu, Feb 26, 2015 at 06:40:11PM +0400, Andrey Korolyov wrote: On Thu, Feb 26, 2015 at 5:36 PM, Daniel P. Berrange berra...@redhat.com wrote: On Thu, Feb 26, 2015 at 06:29:49PM +0400, Andrey Korolyov wrote: Hello, I think it would be useful if libvirt will be able to prefix all

Re: [libvirt] [PATCH v1 08/31] test_driver: s/virNetworkObjList/virNetworkObjListPtr/

2015-02-26 Thread Michal Privoznik
On 26.02.2015 16:46, Peter Krempa wrote: On Thu, Feb 26, 2015 at 15:17:17 +0100, Michal Privoznik wrote: In order to hide the object internals (and use just accessors everywhere), lets store a pointer to the object, instead of object itself. Signed-off-by: Michal Privoznik

Re: [libvirt] [PATCH v1 09/31] parallels: s/virNetworkObjList/virNetworkObjListPtr/

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:18 +0100, Michal Privoznik wrote: In order to hide the object internals (and use just accessors everywhere), lets store a pointer to the object, instead of object itself. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/parallels/parallels_driver.c

Re: [libvirt] [PATCH v3 0/9] qemu: Add quorum support to libvirt

2015-02-26 Thread Peter Krempa
On Mon, Feb 23, 2015 at 14:18:31 +0100, Matthias Gatto wrote: On Tue, Feb 10, 2015 at 4:43 PM, Matthias Gatto matthias.ga...@outscale.com wrote: The purpose of these patches is to introduce quorum for libvirt I've try to follow this proposal:

Re: [libvirt] [PATCHv2 5/7] qemu: command: Add helper to align memory sizes

2015-02-26 Thread Martin Kletzander
On Wed, Feb 25, 2015 at 11:22:04AM +0100, Peter Krempa wrote: The memory sizes in qemu are aligned up to 1 MiB boundaries. There are two places where this was done once for the total size and then for individual NUMA cell sizes. Add a function that will align the sizes in one place so that it's

[libvirt] [PATCH v1 23/31] network_conf: Introduce virNetworkObjEndAPI

2015-02-26 Thread Michal Privoznik
This is practically copy of qemuDomObjEndAPI. The reason why is it so widely available is to avoid code duplication, since the function is going to be called from our bridge driver, test driver and parallels driver too. Signed-off-by: Michal Privoznik mpriv...@redhat.com ---

[libvirt] [PATCH v1 18/31] parallels_network: Adapt to new virNetworkObjList accessors

2015-02-26 Thread Michal Privoznik
Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/parallels/parallels_network.c | 66 +++ 1 file changed, 12 insertions(+), 54 deletions(-) diff --git a/src/parallels/parallels_network.c b/src/parallels/parallels_network.c index 94e77cc..868e3f5

[libvirt] [PATCH v1 26/31] parallels_network: Use virNetworkObjEndAPI

2015-02-26 Thread Michal Privoznik
So far, this is pure code replacement. But once we introduce reference counting to virNetworkObj this will be more handy as there'll be only one function to change: virNetworkObjEndAPI(). Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/parallels/parallels_network.c | 18

[libvirt] [PATCH v1 12/31] conf: s/virNetworkFindByUUID/virNetworkObjFindByUUID/

2015-02-26 Thread Michal Privoznik
It's returning virNetworkObjPtr after all. And it matches the pattern laid out by domain_conf.h. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 8 src/conf/network_conf.h | 4 ++-- src/libvirt_private.syms | 2 +-

[libvirt] [PATCH v1 21/31] network_conf: Make virNetworkObj actually virObject

2015-02-26 Thread Michal Privoznik
So far it's just a structure which happens to have 'Obj' in its name, but otherwise it not related to virObject at all. No reference counting, not virObjectLock(), nothing. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- cfg.mk| 2 - src/conf/network_conf.c

[libvirt] [PATCH v1 15/31] network_conf: Introduce virNetworkObjListNumOfNetworks

2015-02-26 Thread Michal Privoznik
An accessor following pattern laid out by virDomainObjList* APIs. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 26 ++ src/conf/network_conf.h | 5 + src/libvirt_private.syms | 1 + 3 files changed, 32 insertions(+) diff --git

[libvirt] [PATCH v1 25/31] test_driver: Use virNetworkObjEndAPI

2015-02-26 Thread Michal Privoznik
So far, this is pure code replacement. But once we introduce reference counting to virNetworkObj this will be more handy as there'll be only one function to change: virNetworkObjEndAPI(). Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/test/test_driver.c | 42

Re: [libvirt] [PATCH] docs: add a note that spice channel is ignoret without spice graphics

2015-02-26 Thread Martin Kletzander
On Thu, Feb 26, 2015 at 12:09:57PM +0100, Pavel Hrdina wrote: To prevent a confusion about missing chardev argument in qemu command line add a note about that behavior into documentation. Signed-off-by: Pavel Hrdina phrd...@redhat.com --- docs/formatdomain.html.in | 4 1 file changed, 4

Re: [libvirt] Adding timestamps for all emulator output

2015-02-26 Thread Daniel P. Berrange
On Thu, Feb 26, 2015 at 06:29:49PM +0400, Andrey Korolyov wrote: Hello, I think it would be useful if libvirt will be able to prefix all messages from emulator pipes with the date stamping, for example I am trying to catch very rare and non-fatal race with virtio-serial-bus: Guest failure

[libvirt] [PATCH v1 05/31] virNetworkObjIsDuplicate: s/@doms/@nets/

2015-02-26 Thread Michal Privoznik
This is probably a copy-paste error from virDomainObj* counterpart. But when speaking of virNetworkObj we should use variable @nets for an array of networks, rather than @doms. It's just confusing. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 34

[libvirt] [PATCH v1 00/31] Drop network driver lock

2015-02-26 Thread Michal Privoznik
The patchset starts slowly, with small patches, and small changes, accelerating towards the end, with big changes. I know that network driver is not used as intensely as domain drivers, but hey, if we remove 100 lines (and substitute some others) we get fine grained locking! And cleaner code, of

[libvirt] [PATCH v1 02/31] bridge_driver: Don't check network active unlocked

2015-02-26 Thread Michal Privoznik
Okay, this is mainly for educational purposes, since is called from single point only, with all the possible locks held. So there's no way for other thread to hop in and do something wrong. Nevertheless, we should not give bad example. Signed-off-by: Michal Privoznik mpriv...@redhat.com ---

[libvirt] [PATCH v1 11/31] conf: s/virNetworkFindByUUID/virNetworkObjFindByUUID/

2015-02-26 Thread Michal Privoznik
It's returning virNetworkObjPtr after all. And it matches the pattern laid out by domain_conf.h. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 6 +++--- src/conf/network_conf.h | 4 ++-- src/libvirt_private.syms | 2 +-

[libvirt] [PATCH] Ignore listen attribute of graphics for type network listens

2015-02-26 Thread Ján Tomko
Commit 6992994 started filling the listen attribute of the parent graphics elements from type='network' listens. When this XML is passed to UpdateDevice, parsing fails: XML error: graphics listen attribute 10.20.30.40 must match address attribute of first listen element (found none) Ignore the

[libvirt] [PATCH v1 09/31] parallels: s/virNetworkObjList/virNetworkObjListPtr/

2015-02-26 Thread Michal Privoznik
In order to hide the object internals (and use just accessors everywhere), lets store a pointer to the object, instead of object itself. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/parallels/parallels_driver.c | 5 +++- src/parallels/parallels_network.c | 60

[libvirt] [PATCH v1 13/31] network_conf: Introduce virNetworkObjListForEach

2015-02-26 Thread Michal Privoznik
This API will be used in the future to call passed callback over each network object in the list. It's slightly different to it virDomainObjListForEach counterpart, because virDomainObjList uses a hash table to store domain object, while virNetworkObjList uses an array. Therefore, iterating over

[libvirt] [PATCH v1 04/31] networkGetNetworkAddress: Drop empty 'error' label

2015-02-26 Thread Michal Privoznik
Moreover, there are two points within the function, where we're missing 'goto cleanup'. Fix this too. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/network/bridge_driver.c | 12 +--- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/network/bridge_driver.c

[libvirt] [PATCH v1 08/31] test_driver: s/virNetworkObjList/virNetworkObjListPtr/

2015-02-26 Thread Michal Privoznik
In order to hide the object internals (and use just accessors everywhere), lets store a pointer to the object, instead of object itself. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/test/test_driver.c | 106 - 1 file changed, 51

[libvirt] [PATCH v1 17/31] test_driver: Adapt to new virNetworkObjList accessors

2015-02-26 Thread Michal Privoznik
Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/test/test_driver.c | 64 ++ 1 file changed, 12 insertions(+), 52 deletions(-) diff --git a/src/test/test_driver.c b/src/test/test_driver.c index ecb7bcd..0a68283 100644 ---

[libvirt] [RFC] Memory hotplug naming [Was: [PATCHv2 3/7] conf: Replace access to def-mem.max_balloon with accessor functions]

2015-02-26 Thread Martin Kletzander
On Wed, Feb 25, 2015 at 11:22:02AM +0100, Peter Krempa wrote: As there are two possible approaches to define a domain's memory size - one used with legacy, non-NUMA VMs configured in the memory element and per-node based approach on NUMA machines - the user needs to make sure that both are

Re: [libvirt] [PATCHv2 6/7] conf: numa: Add helper to count total memory size configured in NUMA

2015-02-26 Thread Martin Kletzander
On Wed, Feb 25, 2015 at 11:22:05AM +0100, Peter Krempa wrote: The total NUMA memory consists of the sum of individual NUMA node memory amounts. --- Notes: Version 2: - Already ACKed but didn't make sense to push. And ACK again... pgpZm3kZAUEBa.pgp Description: PGP signature --

[libvirt] [PATCH v1 22/31] virNetworkObjList: Derive from virObjectLockableClass

2015-02-26 Thread Michal Privoznik
Later we can turn APIs to lock the object if needed instead of relying on caller to mutually exclude itself (probably done by locking a big lock anyway). Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)

[libvirt] [PATCH v1 20/31] network_conf: Turn struct _virNetworkObjList private

2015-02-26 Thread Michal Privoznik
Now that all the code uses accessors, don't expose the structure anyway. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 7 +++ src/conf/network_conf.h | 6 -- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/conf/network_conf.c

[libvirt] [PATCH v1 27/31] virNetworkObjListPtr: Make APIs self-locking

2015-02-26 Thread Michal Privoznik
Every API that touches internal structure of the object must lock the object first. Not every API that has the object as an argument needs to do that though. Some APIs just pass the object to lower layers, which, however, must lock the object then. Look at the code, you'll get my meaning soon.

[libvirt] [PATCH v1 31/31] parallels_network: Drop parallelsDriverLock() from everywhere.

2015-02-26 Thread Michal Privoznik
While in previous commits there were some places that relied on the big lock, in this file there's no such place and the big driver lock can be dropped completely. Yay! Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/parallels/parallels_network.c | 33

[libvirt] [PATCH v1 16/31] bridge_driver: Adapt to new virNetworkObjList accessors

2015-02-26 Thread Michal Privoznik
Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/network/bridge_driver.c | 333 1 file changed, 148 insertions(+), 185 deletions(-) diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index 268af49..1c73342 100644 ---

[libvirt] [PATCH v1 30/31] test_driver: Drop testDriverLock() from almost everywhere

2015-02-26 Thread Michal Privoznik
Well, if 'everywhere' is defined as that part of the driver code that serves virNetwork* APIs. Again, we lower layers already have their locks, so there's no point doing big lock. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/test/test_driver.c | 56

Re: [libvirt] [PATCHv2 1/7] qemu: Forbid setting maximum memory size with the API with NUMA enabled

2015-02-26 Thread Martin Kletzander
On Thu, Feb 26, 2015 at 01:20:29PM +0100, Martin Kletzander wrote: On Wed, Feb 25, 2015 at 11:21:58AM +0100, Peter Krempa wrote: NUMA enabled guest configuration explicitly specifies memory sizes for individual nodes. Allowing the virDomainSetMemoryFlags API (and friends) to change the total

[libvirt] [PATCH v1 29/31] bridge_driver: Drop networkDriverLock() from almost everywhere

2015-02-26 Thread Michal Privoznik
Now that we have fine grained locks, there's no need to lock the whole driver. We can rely on self-locking APIs. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/network/bridge_driver.c | 45 +++-- 1 file changed, 3 insertions(+), 42

[libvirt] [PATCH v1 07/31] virNetworkObjListExport: Pass virNetworkObjListPtr

2015-02-26 Thread Michal Privoznik
Instead of copying the whole object onto stack when calling the function, just pass the pointer to the object and save up some space on the stack. Moreover, this prepares the code to hide the virNetworkObjList structure into network_conf.c and use accessors only. Signed-off-by: Michal Privoznik

[libvirt] [PATCH v1 01/31] networkLookupByUUID: Improve error message

2015-02-26 Thread Michal Privoznik
We have this function networkObjFromNetwork() which for given virNetworkPtr tries to find corresponding virNetworkObjPtr. If no object is found, a nice error message is printed out: no network with matching uuid '$uuid' ($name) Let's improve the error message produced by networkLookupByUUID to

[libvirt] [PATCH v1 24/31] bridge_driver: Use virNetworkObjEndAPI

2015-02-26 Thread Michal Privoznik
So far, this is pure code replacement. But once we introduce reference counting to virNetworkObj this will be more handy as there'll be only one function to change: virNetworkObjEndAPI(). Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/network/bridge_driver.c | 57

[libvirt] [PATCH v1 06/31] virNetworkObjListFree: Accept NULL

2015-02-26 Thread Michal Privoznik
All of our vir*Free() functions should accept NULL, even though that there's no way of actually passing NULL with current code. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/conf/network_conf.c

[libvirt] [PATCH v1 19/31] network_conf: Turn virNetworkObjList into virObject

2015-02-26 Thread Michal Privoznik
Well, one day this will be self-locking object, but not today. But lets prepare the code for that! Moreover, virNetworkObjListFree() is no longer needed, so turn it into virNetworkObjListDispose(). Signed-off-by: Michal Privoznik mpriv...@redhat.com --- cfg.mk| 1 -

[libvirt] [PATCH v1 14/31] network_conf: Introduce virNetworkObjListGetNames

2015-02-26 Thread Michal Privoznik
An accessor following pattern laid out by virDomainObjList* APIs. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 38 ++ src/conf/network_conf.h | 8 src/libvirt_private.syms | 1 + 3 files changed, 47

Re: [libvirt] [PATCHv2 7/7] conf: Automatically use NUMA memory size in case NUMA is enabled

2015-02-26 Thread Martin Kletzander
On Wed, Feb 25, 2015 at 11:22:06AM +0100, Peter Krempa wrote: Use the NUMA total instead of the configured size both in XML and for uses in the code once NUMA is enabled for a domain. One test case change is necessary as the rounding of the individual cell sizes was not matching the rounding of

[libvirt] [PATCH 1/2] PowerPC: Augment XML schema to include 'ppc64le' arch ; newer pseries-2.* machine types.

2015-02-26 Thread Prerna Saxena
From 7128e773058751e4d1024ef7d8e4ad286c93ba55 Mon Sep 17 00:00:00 2001 From: Prerna Saxena pre...@linux.vnet.ibm.com Date: Thu, 26 Feb 2015 08:10:58 -0600 Subject: [PATCH 1/2] PowerPC: Augment XML schema to include 'ppc64le' arch and newer pseries-2.* machine types. Acked-by: Ján Tomko

[libvirt] [PATCH 2/2] Tests : Add test for 'ppc64le' architecture.

2015-02-26 Thread Prerna Saxena
Tests : Add test for 'ppc64le' architecture. Signed-off-by: Prerna Saxena pre...@linux.vnet.ibm.com --- .../qemuxml2argv-pseries-cpu-le.args | 7 + .../qemuxml2argv-pseries-cpu-le.xml| 17 tests/qemuxml2argvtest.c | 2 ++

[libvirt] [PATCH 0/2] PowerPC : Miscellaneous fixes for 'ppc64le' architecture.

2015-02-26 Thread Prerna Saxena
From a28ef5a3e7b9cb023948cf97d9f472bb3a1e06d3 Mon Sep 17 00:00:00 2001 From: Prerna Saxena pre...@linux.vnet.ibm.com Date: Thu, 26 Feb 2015 22:31:05 +0530 This series adds few miscellaneous fixes for PowerPC 64-bit Little Endian Architecture. Changelog : == v1 of Patch 1/2 already

Re: [libvirt] [PATCH] Ignore listen attribute of graphics for type network listens

2015-02-26 Thread Laine Stump
On 02/26/2015 11:39 AM, Ján Tomko wrote: On Thu, Feb 26, 2015 at 04:29:53PM +0100, Martin Kletzander wrote: On Thu, Feb 26, 2015 at 09:57:22AM -0500, Laine Stump wrote: On 02/26/2015 08:53 AM, Ján Tomko wrote: Commit 6992994 started filling the listen attribute of the parent graphics elements

Re: [libvirt] [PATCH v1 12/31] conf: s/virNetworkFindByUUID/virNetworkObjFindByUUID/

2015-02-26 Thread Peter Krempa
s/ByUUID/ByName/g in subject On Thu, Feb 26, 2015 at 15:17:21 +0100, Michal Privoznik wrote: It's returning virNetworkObjPtr after all. And it matches the pattern laid out by domain_conf.h. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 8

Re: [libvirt] [PATCH v1 13/31] network_conf: Introduce virNetworkObjListForEach

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:22 +0100, Michal Privoznik wrote: This API will be used in the future to call passed callback over each network object in the list. It's slightly different to it s/to it/to it's/ virDomainObjListForEach counterpart, because virDomainObjList uses a hash table to

Re: [libvirt] [PATCH v1 14/31] network_conf: Introduce virNetworkObjListGetNames

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:23 +0100, Michal Privoznik wrote: An accessor following pattern laid out by virDomainObjList* APIs. The domain object accessors are quite different in this case, but ... Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 38

Re: [libvirt] [PATCH v1 15/31] network_conf: Introduce virNetworkObjListNumOfNetworks

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:24 +0100, Michal Privoznik wrote: An accessor following pattern laid out by virDomainObjList* APIs. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 26 ++ src/conf/network_conf.h | 5 +

Re: [libvirt] [PATCH v1 11/31] conf: s/virNetworkFindByUUID/virNetworkObjFindByUUID/

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 15:17:20 +0100, Michal Privoznik wrote: It's returning virNetworkObjPtr after all. And it matches the pattern laid out by domain_conf.h. Signed-off-by: Michal Privoznik mpriv...@redhat.com --- src/conf/network_conf.c | 6 +++--- src/conf/network_conf.h

[libvirt] [PATCH 2/2] virsh.pod: Update find-storage-pool-sources[-as] man page

2015-02-26 Thread John Ferlan
https://bugzilla.redhat.com/show_bug.cgi?id=921426 Add to the man page a more complete description of what exactly the command expects on input and will return on output based on what is currently supported. Perhaps missing findPoolSources implementations are backends for sheepdog and rbd. Also

[libvirt] [PATCH 1/2] iscsi: Adjust error message for findStorageSources backend

2015-02-26 Thread John Ferlan
The virStorageBackendISCSIFindPoolSources API only needs the 'host' name in order to discover iSCSI pools, it returns the various device paths. On input, it's also possible to further restrict a search by providing the port attribute for the host element and the (undocumented) initiator element.

[libvirt] [PATCH 0/2] Update find-storage-pool-source[-as] man page

2015-02-26 Thread John Ferlan
https://bugzilla.redhat.com/show_bug.cgi?id=921426 The first patch is just a change to the error message. As it turns out only the host is necessary to find iSCSI targets. I have to assume over time adjustments to the code made the need to provide the name obsolete, but I did not research exactly

Re: [libvirt] [PATCH] conf: fix not jump to cleanup when parse a host id is invalid

2015-02-26 Thread lhuang
On 02/26/2015 03:56 PM, Ján Tomko wrote: On Thu, Feb 26, 2015 at 02:14:20PM +0800, Luyao Huang wrote: https://bugzilla.redhat.com/show_bug.cgi?id=1196503 We already check whether the host id is valid or not, add a jump to forbid invalid host id. Signed-off-by: Luyao Huang lhu...@redhat.com

Re: [libvirt] [PATCH] util: do not take it as wrong if no PortData is found while getting migrateData

2015-02-26 Thread Martin Kletzander
On Thu, Feb 12, 2015 at 12:08:54PM +0800, Zhang Bo wrote: The function virNetDevOpenvswitchGetMigrateData() uses the cmd ovs-vsctl to get portdata. If no portdata is available, rather than failure in running the cmd, we think we should just print a warning message here, rather than taking it as

Re: [libvirt] [PATCH] util: do not take it as wrong if no PortData is found while getting migrateData

2015-02-26 Thread Martin Kletzander
On Thu, Feb 26, 2015 at 10:25:45AM +0100, Martin Kletzander wrote: On Thu, Feb 12, 2015 at 12:08:54PM +0800, Zhang Bo wrote: The function virNetDevOpenvswitchGetMigrateData() uses the cmd ovs-vsctl to get portdata. If no portdata is available, rather than failure in running the cmd, we think we

Re: [libvirt] [PATCHv2 07/10] qemu: add support for memory devices

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 17:58:36 +0800, Zhu Guihua wrote: On 02/25/2015 10:44 PM, Peter Krempa wrote: Add support to start qemu instance with 'pc-dimm' device. Thanks to the refactors we are able to reuse the existing function to determine the parameters. --- Notes: Version

[libvirt] [PATCH 0/2] For 1.2.13 - Fix crash with gluster URIs

2015-02-26 Thread Peter Krempa
Peter Krempa (2): util: storagefile: Don't crash on gluster URIs without path util: storage: Fix error type in virStorageSourceParseBackingURI src/util/virstoragefile.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) -- 2.2.2 -- libvir-list mailing list

Re: [libvirt] [PATCHv2 07/10] qemu: add support for memory devices

2015-02-26 Thread Zhu Guihua
On 02/25/2015 10:44 PM, Peter Krempa wrote: Add support to start qemu instance with 'pc-dimm' device. Thanks to the refactors we are able to reuse the existing function to determine the parameters. --- Notes: Version 2: - dropped the ACPI naming src/qemu/qemu_command.c

Re: [libvirt] [PATCH 0/2] For 1.2.13 - Fix crash with gluster URIs

2015-02-26 Thread Martin Kletzander
On Thu, Feb 26, 2015 at 10:50:56AM +0100, Peter Krempa wrote: Peter Krempa (2): util: storagefile: Don't crash on gluster URIs without path util: storage: Fix error type in virStorageSourceParseBackingURI src/util/virstoragefile.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-)

[libvirt] [PATCH 1/2] util: storagefile: Don't crash on gluster URIs without path

2015-02-26 Thread Peter Krempa
Similar to commit fdb80ed4f6563928b9942a0d1450e0c725aa6c06 libvirtd would crash if a gluster URI without path would be used in the backing chain of a volume. The crash happens in the gluster specific part of the parser that extracts the gluster volume name from the path. Fix the crash by checking

[libvirt] [PATCH 2/2] util: storage: Fix error type in virStorageSourceParseBackingURI

2015-02-26 Thread Peter Krempa
The gluster volume name extraction code was copied from the XML parser without changing the VIR_ERR_XML_ERROR error code. Use VIR_ERR_CONFIG_UNSUPPORTED instead. --- src/util/virstoragefile.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/virstoragefile.c

Re: [libvirt] [PATCH 1/4] util: introduce a new helper for get interface IPv6 address

2015-02-26 Thread lhuang
On 02/25/2015 11:55 PM, Laine Stump wrote: On 02/25/2015 04:50 AM, lhuang wrote: And i also thought about another issue after your reminding: An interface can have more than one IPv6 address. But i still couldn't find a good way until now to chose which IPv6 address if we find more than one

Re: [libvirt] [PATCH 0/2] For 1.2.13 - Fix crash with gluster URIs

2015-02-26 Thread Peter Krempa
On Thu, Feb 26, 2015 at 11:35:08 +0100, Martin Kletzander wrote: On Thu, Feb 26, 2015 at 10:50:56AM +0100, Peter Krempa wrote: Peter Krempa (2): util: storagefile: Don't crash on gluster URIs without path util: storage: Fix error type in virStorageSourceParseBackingURI

[libvirt] [PATCH] docs: add a note that spice channel is ignoret without spice graphics

2015-02-26 Thread Pavel Hrdina
To prevent a confusion about missing chardev argument in qemu command line add a note about that behavior into documentation. Signed-off-by: Pavel Hrdina phrd...@redhat.com --- docs/formatdomain.html.in | 4 1 file changed, 4 insertions(+) diff --git a/docs/formatdomain.html.in

Re: [libvirt] [PATCH] conf: fix not jump to cleanup when parse a host id is invalid

2015-02-26 Thread Ján Tomko
On Thu, Feb 26, 2015 at 02:14:20PM +0800, Luyao Huang wrote: https://bugzilla.redhat.com/show_bug.cgi?id=1196503 We already check whether the host id is valid or not, add a jump to forbid invalid host id. Signed-off-by: Luyao Huang lhu...@redhat.com --- src/conf/network_conf.c | 1 + 1

[libvirt] [PATCH] conf: error out on missing dhcp host attributes

2015-02-26 Thread Ján Tomko
In virNetworkDHCPHostDefParseXML an error is reported when partialOkay == true, and none of ip, mac, name were supplied. Add the missing goto and error out in this case. --- src/conf/network_conf.c | 1 + 1 file changed, 1 insertion(+) Pushed as trivial. diff --git a/src/conf/network_conf.c

Re: [libvirt] [PATCHv2 1/7] qemu: Forbid setting maximum memory size with the API with NUMA enabled

2015-02-26 Thread Martin Kletzander
On Wed, Feb 25, 2015 at 11:21:58AM +0100, Peter Krempa wrote: NUMA enabled guest configuration explicitly specifies memory sizes for individual nodes. Allowing the virDomainSetMemoryFlags API (and friends) to change the total doesn't make sense as the individual node configs are not updated in

Re: [libvirt] [PATCHv2 2/7] qemu: lxc: Clarify error message when setting current memory

2015-02-26 Thread Martin Kletzander
On Wed, Feb 25, 2015 at 11:22:00AM +0100, Peter Krempa wrote: Commit 60f7303c151cccdbe214b9f9ac59ecaf95cbf24b introduced the error message but it's unclear whether the persistent config or the live config tripped the message. Later the LXC driver copied the same code. Separate the message which

Re: [libvirt] [PATCHv2 4/7] phyp: Fix error messages mentioning memory

2015-02-26 Thread Martin Kletzander
On Wed, Feb 25, 2015 at 11:22:03AM +0100, Peter Krempa wrote: The messages for currentMemory and memory were swapped. --- Notes: Version 2: - new in series src/phyp/phyp_driver.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/phyp/phyp_driver.c

[libvirt] [PATCH] virsh.pod: Add information regarding LXC for setmem, memtune, and dominfo

2015-02-26 Thread John Ferlan
https://bugzilla.redhat.com/show_bug.cgi?id=1070695 Modify the virsh man page to more accurately describe which values are set by the virsh setmem and displayed by the virsh memtune or dominfo based on the setmem command results. Signed-off-by: John Ferlan jfer...@redhat.com --- tools/virsh.pod

[libvirt] [PATCH 1/2] virsh: Adjust domblklist to understand disk volume syntax

2015-02-26 Thread John Ferlan
A disk using a source pool is listed as having a source '-' in domblklist because it doesn't check the right XML syntax to find the source. Add a check for ./source/volume which is where the path (of sorts) to the volume name is described. Signed-off-by: John Ferlan jfer...@redhat.com ---

  1   2   >