Re: [libvirt] [PATCH v2] admin: Fix memory leak in remoteAdminConnectClose

2016-02-18 Thread Erik Skultety
On 18/02/16 17:24, Pavel Hrdina wrote: > On Thu, Feb 18, 2016 at 05:18:13PM +0100, Erik Skultety wrote: >> When virt-admin is run with valgrind, this kind of output can be obtained: >> >> HEAP SUMMARY: >> in use at exit: 134,589 bytes in 1,031 blocks >> total heap usage: 2,667 allocs, 1,636 fre

Re: [libvirt] [PATCH 1/3] domain: reuse update flags checking functions

2016-02-18 Thread Nikolay Shirokovskiy
On 19.02.2016 01:43, John Ferlan wrote: > > > On 02/02/2016 08:04 AM, Nikolay Shirokovskiy wrote: >> >> >> On 02.02.2016 01:48, John Ferlan wrote: >>> >>> >>> On 01/15/2016 09:05 AM, Nikolay Shirokovskiy wrote: Uses virDomainLiveConfigHelperMethod or virDomainObjUpdateModificationImpa

Re: [libvirt] [PATCH 1/3] domain: add implicit controllers from post parse

2016-02-18 Thread Jim Fehlig
On 02/17/2016 10:17 AM, Cole Robinson wrote: > Seems like the natural fit, since we are already adding other XML bits > in the PostParse routine. > > Previously AddImplicitControllers was only called at the end of XML > parsing, meaning code that builds a DomainDef by hand had to manually > call it

Re: [libvirt] [Qemu-devel] [RFC PATCH 0/2] ARM: add QMP command to query GIC version

2016-02-18 Thread Peter Xu
On Thu, Feb 18, 2016 at 06:10:21PM +0100, Andrea Bolognani wrote: > On Thu, 2016-02-18 at 17:52 +0100, Andrew Jones wrote: > > > Is this work on any of our todo list (or anyone has started the > > > prototyping)? > > >  > > > It seems reasonable to provide such a generic interface, rather than > >

Re: [libvirt] [PATCH 3/3] common-impl: make virDomainObjGetPersistentDef return only persistent config

2016-02-18 Thread John Ferlan
On 02/02/2016 08:18 AM, Nikolay Shirokovskiy wrote: > > > On 02.02.2016 15:13, John Ferlan wrote: >> >> >> On 01/15/2016 09:05 AM, Nikolay Shirokovskiy wrote: >>> It's rather unexpected that function with such a name could return >>> transient definition. This is possible if we call it for >>>

Re: [libvirt] [PATCH 1/3] domain: reuse update flags checking functions

2016-02-18 Thread John Ferlan
On 02/02/2016 08:04 AM, Nikolay Shirokovskiy wrote: > > > On 02.02.2016 01:48, John Ferlan wrote: >> >> >> On 01/15/2016 09:05 AM, Nikolay Shirokovskiy wrote: >>> Uses virDomainLiveConfigHelperMethod or >>> virDomainObjUpdateModificationImpact appropriately. >>> >>> Signed-off-by: Nikolay Shiro

[libvirt] [PATCH] Fix bug of attaching redirdev device

2016-02-18 Thread Osier Yang
RHBZ: https://bugzilla.redhat.com/show_bug.cgi?id=1298070 The corresponding chardev must be attached first, otherwise the the qemu command line won't be complete (missing the host part), --- src/qemu/qemu_hotplug.c | 27 ++- 1 file changed, 22 insertions(+), 5 deletions(-)

Re: [libvirt] VMware driver: SessionIsActive API / Sessions.ValidateSession permission

2016-02-18 Thread Matthias Bolte
2016-02-16 16:13 GMT+01:00 Richard W.M. Jones : > On Mon, Feb 15, 2016 at 11:22:27PM +0100, Matthias Bolte wrote: >> 2016-02-11 12:59 GMT+01:00 Richard W.M. Jones : >> > Is calling SessionIsActive necessary? From my (very limited) >> > understanding, it seems as if we might use 'SessionManager. >>

[libvirt] [PATCH] qemu_process: mark auto-generated spice ports as reserved

2016-02-18 Thread Pavel Hrdina
In case you will specify graphics like this: or libvirt will automatically add autoport='no'. This leads to an issue that in qemuProcessStop() we don't release that port because we are releasing both port if autoport=yes or only port marked as reserved. If autoport=no but we request to gene

[libvirt] [PATCH 20/25] qemu: Introduce qemuBuildRedirdevCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the redirdev device options to the command line removing that task from the mainline qemuBuildCommandLine. Also move the qemuBuildRedirdevDevStr closer to the new function and modify to use the const virDomainDef instead of virDomainDefPtr Signed-off-by: John Fer

[libvirt] [PATCH 24/25] qemu: Introduce qemuBuildNVRAMCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the NVRAM device options to the command line removing that task from the mainline qemuBuildCommandLine. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 61 ++--- 1 file changed, 38 insertions(+), 23 deletions(

[libvirt] [PATCH 18/25] qemu: Introduce qemuBuildSoundCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the sound device options to the command line removing that task from the mainline qemuBuildCommandLine. Also since qemuBuildSoundDevStr was only local here, make it static as well as modifying the const virDomainDef. Signed-off-by: John Ferlan --- src/qemu/qemu

[libvirt] [PATCH 23/25] qemu: Introduce qemuBuildRNGCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the RNG device options to the command line removing that task from the mainline qemuBuildCommandLine. Also modify the qemuBuildRNGDevStr to use const virDomainDef instead of virDomainDefPtr. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 80 ++

[libvirt] [PATCH 19/25] qemu: Introduce qemuBuildWatchdogCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the watchdog device options to the command line removing that task from the mainline qemuBuildCommandLine. Also since qemuBuildWatchdogDevStr was only local here, make it static as well as modifying the const virDomainDef. Signed-off-by: John Ferlan --- src/qem

[libvirt] [PATCH 07/25] qemu: Introduce qemuBuildDiskDriveCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the disk -drive options to the command line removing that task from the mainline qemuBuildCommandLine. Also since using const virDomainDef in new function, that means other functions called needed to change their usage. Signed-off-by: John Ferlan --- src/conf/d

[libvirt] [PATCH 25/25] qemu: Introduce qemuBuildPanicCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the panic device options to the command line removing that task from the mainline qemuBuildCommandLine. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 158 ++-- 1 file changed, 87 insertions(+), 71 deletions(

[libvirt] [PATCH 01/25] qemu: Introduce qemuBuildClockCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the '-clock' options to the command line removing that task from the mainline qemuBuildCommandLine. Also includes some minor formatting cleanups. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 300 ++-- 1 fi

[libvirt] [PATCH 21/25] qemu: Introduce qemuBuildHostdevCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the host device options to the command line removing that task from the mainline qemuBuildCommandLine. Also modify qemuBuildPCIHostdevDevStr, qemuBuildUSBHostdevDevStr, and qemuBuildSCSIHostdevDevStr to use const virDomainDef instead of virDomainDefPtr. Make qemu

[libvirt] [PATCH 11/25] qemu: Introduce qemuBuildSerialCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the serial device options to the command line removing that task from the mainline qemuBuildCommandLine. Using const virDomainDef causes collateral damage in other called APIs which need to make the similar adjustment Signed-off-by: John Ferlan --- src/qemu/qem

[libvirt] [PATCH 08/25] qemu: Introduce qemuBuildFSDevCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the -fsdev options to the command line removing that task from the mainline qemuBuildCommandLine. Since both qemuBuildFSStr and qemuBuildFSDevStr are local, make them static and fix their prototypes to use the const virDomainDef as well. Make some minor formatting

[libvirt] [PATCH 02/25] qemu: Introduce qemuBuildPMCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the power management options to the command line removing that task from the mainline qemuBuildCommandLine. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 136 ++-- 1 file changed, 75 insertions(+), 61 deleti

[libvirt] [PATCH 15/25] qemu: Modify qemuBuildTPMCommandLine

2016-02-18 Thread John Ferlan
Modify the argument order and types to match other similar helpers. Also modify called functions to use the def->emulator instead of passing def->emulator and def. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 28 +--- 1 file changed, 13 insertions(+), 15 dele

[libvirt] [PATCH 17/25] qemu: Introduce qemuBuildVideoCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the video device options to the command line removing that task from the mainline qemuBuildCommandLine. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 316 +--- 1 file changed, 166 insertions(+), 150 deletion

[libvirt] [PATCH 12/25] qemu: Introduce qemuBuildParallelsCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the parallels device options to the command line removing that task from the mainline qemuBuildCommandLine. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 77 + 1 file changed, 46 insertions(+), 31 deleti

[libvirt] [PATCH 03/25] qemu: Introduce qemuBuildBootCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the -boot options to the command line removing that task from the mainline qemuBuildCommandLine. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 282 +--- 1 file changed, 150 insertions(+), 132 deletions(-) d

[libvirt] [PATCH 14/25] qemu: Introduce qemuBuildConsoleCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the console device options to the command line removing that task from the mainline qemuBuildCommandLine. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 134 ++-- 1 file changed, 74 insertions(+), 60 deletion

[libvirt] [PATCH 04/25] qemu: Introduce qemuBuildGlobalControllerCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the -global controller options to the command line removing that task from the mainline qemuBuildCommandLine. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 106 +++- 1 file changed, 60 insertions(+), 46 dele

[libvirt] [PATCH 13/25] qemu: Introduce qemuBuildChannelsCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the channel device options to the command line removing that task from the mainline qemuBuildCommandLine. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 159 ++-- 1 file changed, 87 insertions(+), 72 deletion

[libvirt] [PATCH 16/25] qemu: Introduce qemuBuildInputCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the input device options to the command line removing that task from the mainline qemuBuildCommandLine. Make qemuBuildUSBInputDevStr static since only this module calls it. Also the change to use const virDomainDef forces other changes. Signed-off-by: John Ferla

[libvirt] [PATCH 10/25] qemu: Introduce qemuBuildSmartcardCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the smartcard device options to the command line removing that task from the mainline qemuBuildCommandLine. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 219 ++-- 1 file changed, 117 insertions(+), 102 dele

[libvirt] [PATCH 09/25] qemu: Introduce qemuBuildNetCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the network device options to the command line removing that task from the mainline qemuBuildCommandLine. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 133 +--- 1 file changed, 82 insertions(+), 51 deletion

[libvirt] [PATCH 00/25] Final pile of qemu_command.c changes

2016-02-18 Thread John Ferlan
Finishing the adventure - certainly qemuBuildCommandLine looks much cleaner now and is much shorter (~2100 lines down to ~250 lines). The downside is plowing though the changes and the reviews. John Ferlan (25): qemu: Introduce qemuBuildClockCommandLine qemu: Introduce qemuBuildPMCommandLine

[libvirt] [PATCH 05/25] qemu: Introduce qemuBuildControllerDevCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the controller -device options to the command line removing that task from the mainline qemuBuildCommandLine. Also adjust to using const virDomainDef instead of virDomainDefPtr. This causes collateral damage in order to modify called APIs to use the const virDomai

[libvirt] [PATCH 22/25] qemu: Introduce qemuBuildMemballoonCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the memballoon device options to the command line removing that task from the mainline qemuBuildCommandLine. Also modify the qemuBuildMemballoonDevStr to use const virDomainDef instead of virDomainDefPtr. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c |

[libvirt] [PATCH 06/25] qemu: Introduce qemuBuildHubCommandLine

2016-02-18 Thread John Ferlan
Add new function to manage adding the hub -device options to the command line removing that task from the mainline qemuBuildCommandLine. Also make qemuBuildHubDevStr static to the module since it's only used here. Signed-off-by: John Ferlan --- src/qemu/qemu_command.c | 38 +

Re: [libvirt] [Qemu-devel] [RFC PATCH 0/2] ARM: add QMP command to query GIC version

2016-02-18 Thread Andrea Bolognani
On Thu, 2016-02-18 at 17:52 +0100, Andrew Jones wrote: > > Is this work on any of our todo list (or anyone has started the > > prototyping)? > >  > > It seems reasonable to provide such a generic interface, rather than > > adding a "query-gic-capability" for GIC versions only. The problem > > is th

Re: [libvirt] [PATCH 6/6] storage:dir: adapts .refreshVol .refreshPool for ploop volumes

2016-02-18 Thread Olga Krishtal
​ On 18/02/16 18:17, Ján Tomko wrote: On Thu, Feb 18, 2016 at 05:04:16PM +0300, Maxim Nestratov wrote: 18.02.2016 16:46, Ján Tomko пишет: On Wed, Feb 17, 2016 at 02:40:05PM +0300, Olga Krishtal wrote: To update information about ploop volumes inside the a single pool we need to be sure that

Re: [libvirt] [Qemu-devel] [RFC PATCH 0/2] ARM: add QMP command to query GIC version

2016-02-18 Thread Andrew Jones
On Thu, Feb 18, 2016 at 12:40:56PM +0800, Peter Xu wrote: > On Mon, Feb 15, 2016 at 03:22:05PM +, Daniel P. Berrange wrote: > > On Mon, Feb 15, 2016 at 04:08:33PM +0100, Markus Armbruster wrote: > > > Peter Xu writes: > > > > > > > On Mon, Feb 15, 2016 at 10:52:01AM +0100, Markus Armbruster w

Re: [libvirt] [PATCH 6/6] storage:dir: adapts .refreshVol .refreshPool for ploop volumes

2016-02-18 Thread Olga Krishtal
On 18/02/16 18:17, Ján Tomko wrote: On Thu, Feb 18, 2016 at 05:04:16PM +0300, Maxim Nestratov wrote: 18.02.2016 16:46, Ján Tomko пишет: On Wed, Feb 17, 2016 at 02:40:05PM +0300, Olga Krishtal wrote: To update information about ploop volumes inside the a single pool we need to be sure that it i

[libvirt] [PATCH] qemu: add spice opengl support

2016-02-18 Thread Marc-André Lureau
Add Spice graphics gl attribute. qemu 2.6 should have -spice gl=on argument to enable opengl rendering context (patches on the ML). This is necessary to actually enable virgl rendering. Add a qemuxml2argv test for virtio-gpu + spice with virgl. Signed-off-by: Marc-André Lureau --- docs/formatdo

Re: [libvirt] [PATCH v2] admin: Fix memory leak in remoteAdminConnectClose

2016-02-18 Thread Pavel Hrdina
On Thu, Feb 18, 2016 at 05:18:13PM +0100, Erik Skultety wrote: > When virt-admin is run with valgrind, this kind of output can be obtained: > > HEAP SUMMARY: > in use at exit: 134,589 bytes in 1,031 blocks > total heap usage: 2,667 allocs, 1,636 frees, 496,755 bytes allocated > > 88 bytes in

[libvirt] [PATCH v2] admin: Fix memory leak in remoteAdminConnectClose

2016-02-18 Thread Erik Skultety
When virt-admin is run with valgrind, this kind of output can be obtained: HEAP SUMMARY: in use at exit: 134,589 bytes in 1,031 blocks total heap usage: 2,667 allocs, 1,636 frees, 496,755 bytes allocated 88 bytes in 1 blocks are definitely lost in loss record 82 of 128 at 0x4C2A9C7: calloc (

Re: [libvirt] [PATCH v2 5/5] RFC qemu: add spice opengl support

2016-02-18 Thread Marc-André Lureau
Hi On Fri, Nov 27, 2015 at 2:10 PM, Michal Privoznik wrote: > On 25.11.2015 09:42, Marc-André Lureau wrote: >> Add Spice graphics gl attribute. qemu 2.6 should have -spice gl=on >> argument to enable opengl rendering context. This is necessary >> to actually enable virgl rendering. >> >> Add a qe

Re: [libvirt] [PATCH] admin: Fix memory leak in remoteAdminConnectClose

2016-02-18 Thread Erik Skultety
On 18/02/16 15:06, Erik Skultety wrote: > When virt-admin is run with valgrind, this kind of output can be obtained: > > HEAP SUMMARY: > in use at exit: 134,589 bytes in 1,031 blocks > total heap usage: 2,667 allocs, 1,636 frees, 496,755 bytes allocated > > 88 bytes in 1 blocks are definitely

Re: [libvirt] [PATCH 6/6] storage:dir: adapts .refreshVol .refreshPool for ploop volumes

2016-02-18 Thread Olga Krishtal
On 18/02/16 17:04, Maxim Nestratov wrote: 18.02.2016 16:46, Ján Tomko пишет: On Wed, Feb 17, 2016 at 02:40:05PM +0300, Olga Krishtal wrote: To update information about ploop volumes inside the a single pool we need to be sure that it is the ploop directory and not some other directory. Ploop v

Re: [libvirt] Libvirtd and OSX... with QEMU

2016-02-18 Thread Justin Clift
On 2016-02-18 10:43, Martin Kletzander wrote: On Mon, Jan 18, 2016 at 05:04:44PM +, Justin Clift wrote: But last night I had the realisation that libvirtd itself might work too since it functions on the other BSD's. So, took a few minutes to try it out. Without QEMU installed, libvirtd

Re: [libvirt] [PATCH] gic: Introduce VIR_GIC_VERSION_DEFAULT alias

2016-02-18 Thread Andrea Bolognani
This was of course not meant to be a reply to the other patch, but to be a separate thread... Sigh. -- Andrea Bolognani Software Engineer - Virtualization Team -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] [PATCH] gic: Introduce VIR_GIC_VERSION_DEFAULT alias

2016-02-18 Thread Andrea Bolognani
GIC v2 is the default, but checking against that specific version when we want to know whether the default has been selected is potentially error prone; using an alias instead makes it safer. --- src/qemu/qemu_command.c | 7 +++ src/qemu/qemu_domain.c | 4 ++-- src/util/virgic.h | 3 +++

[libvirt] [PATCH] docs: List possible GIC versions

2016-02-18 Thread Andrea Bolognani
Recent changes to the handling of GIC version, specifically commit 2a7b11eafb67, have clearly defined what values are acceptable for the version attribute of the element. Update the documentation accordingly. --- docs/formatdomain.html.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) d

Re: [libvirt] [PATCH 6/6] storage:dir: adapts .refreshVol .refreshPool for ploop volumes

2016-02-18 Thread Ján Tomko
On Thu, Feb 18, 2016 at 05:04:16PM +0300, Maxim Nestratov wrote: > 18.02.2016 16:46, Ján Tomko пишет: > > On Wed, Feb 17, 2016 at 02:40:05PM +0300, Olga Krishtal wrote: > >> To update information about ploop volumes inside the a single pool we need > >> to be sure that it is the ploop directory and

Re: [libvirt] [PATCH 3/6] storage:dir: adapts .uploadVol .dowloadVol for ploop volume

2016-02-18 Thread Olga Krishtal
On 18/02/16 16:57, Ján Tomko wrote: On Wed, Feb 17, 2016 at 02:40:02PM +0300, Olga Krishtal wrote: In case of ploop volume, target path of the volume is the path to the directory that contains image file named root.hds and DiskDescriptor.xml. While using uploadVol and downloadVol callbacks we ne

[libvirt] [PATCH v2 0/7] NSS module for libvirt

2016-02-18 Thread Michal Privoznik
v2 of: https://www.redhat.com/archives/libvir-list/2016-February/msg00693.html diff to v1: - Rework to return multiple IPs instead of the first one found - Move the module into libvirt-nss rpm package - Fix linking (drop libvirt_util.la from LDADD) Michal Privoznik (7): Export virLease* functi

[libvirt] [PATCH v2 5/7] nss: Implement _nss_libvirt_gethostbyname3_r

2016-02-18 Thread Michal Privoznik
The implementation is pretty straightforward. Moreover, because of the nature of things, gethostbyname_r and gethostbyname2_r can be implemented at the same time too. Signed-off-by: Michal Privoznik --- tools/Makefile.am | 7 +- tools/nss/libvirt_nss.c| 354 +++

[libvirt] [PATCH v2 1/7] Export virLease* functions for leases file handling

2016-02-18 Thread Michal Privoznik
These functions are going to be reused very shortly. So instead of duplicating the code, lets move them into utils module. Signed-off-by: Michal Privoznik --- po/POTFILES.in | 1 + src/Makefile.am| 1 + src/libvirt_private.syms | 6 + src/network/leaseshelper.c |

[libvirt] [PATCH v2 7/7] nss: Introduce a test

2016-02-18 Thread Michal Privoznik
A small test to see how is the nss module working. Signed-off-by: Michal Privoznik --- cfg.mk | 2 +- tests/Makefile.am | 18 + tests/nssdata/virbr0.status | 14 tests/nssmock.c | 140 + tests/nsstest.c

[libvirt] [PATCH v2 6/7] Implement _nss_libvirt_gethostbyname4_r

2016-02-18 Thread Michal Privoznik
This function is a different beast compared to previous ones. But yet again, nothing surprising is happening here. Signed-off-by: Michal Privoznik --- tools/nss/libvirt_nss.c| 92 ++ tools/nss/libvirt_nss.h| 4 ++ tools/nss/libvirt_nss.syms |

[libvirt] [PATCH v2 3/7] Initial support for NSS plugin skeleton

2016-02-18 Thread Michal Privoznik
Name Service Switch is a glibc feature responsible for many things. Translating domain names into IP addresses and vice versa is just one of them. However, currently it's the only functionality that this commit is tickling. Well, in this commit the plugin skeleton is introduced. Implementation to c

[libvirt] [PATCH v2 4/7] libvirt.spec.in: Introduce libvirt-nss package

2016-02-18 Thread Michal Privoznik
Lets put the NSS module into its own package. Signed-off-by: Michal Privoznik --- libvirt.spec.in | 21 + 1 file changed, 21 insertions(+) diff --git a/libvirt.spec.in b/libvirt.spec.in index fc2e2cf..3490142 100644 --- a/libvirt.spec.in +++ b/libvirt.spec.in @@ -155,6 +155,

[libvirt] [PATCH v2 2/7] virjson: Resolve const correctness

2016-02-18 Thread Michal Privoznik
Plenty of our virJSON*() APIs don't modify passed object. They merely get a value stored in it. Note this fact in their definition and enforce const correctness. Signed-off-by: Michal Privoznik --- src/util/virjson.c | 58 +++--- src/util/virjson.h

[libvirt] [PATCH] admin: Fix memory leak in remoteAdminConnectClose

2016-02-18 Thread Erik Skultety
When virt-admin is run with valgrind, this kind of output can be obtained: HEAP SUMMARY: in use at exit: 134,589 bytes in 1,031 blocks total heap usage: 2,667 allocs, 1,636 frees, 496,755 bytes allocated 88 bytes in 1 blocks are definitely lost in loss record 82 of 128 at 0x4C2A9C7: calloc (

Re: [libvirt] [PATCH 6/6] storage:dir: adapts .refreshVol .refreshPool for ploop volumes

2016-02-18 Thread Maxim Nestratov
18.02.2016 16:46, Ján Tomko пишет: On Wed, Feb 17, 2016 at 02:40:05PM +0300, Olga Krishtal wrote: To update information about ploop volumes inside the a single pool we need to be sure that it is the ploop directory and not some other directory. Ploop volume directory obligatory contains root.hds

Re: [libvirt] [PATCH 3/6] storage:dir: adapts .uploadVol .dowloadVol for ploop volume

2016-02-18 Thread Ján Tomko
On Wed, Feb 17, 2016 at 02:40:02PM +0300, Olga Krishtal wrote: > In case of ploop volume, target path of the volume is the path to the > directory that contains image file named root.hds and DiskDescriptor.xml. > While using uploadVol and downloadVol callbacks we need to open root.hds > itself. To

Re: [libvirt] [PATCH 6/6] storage:dir: adapts .refreshVol .refreshPool for ploop volumes

2016-02-18 Thread Ján Tomko
On Wed, Feb 17, 2016 at 02:40:05PM +0300, Olga Krishtal wrote: > To update information about ploop volumes inside the a single pool we need > to be sure that it is the ploop directory and not some other directory. > Ploop volume directory obligatory contains root.hds - image file and disk > descrip

Re: [libvirt] [PATCH] Error out on missing machine type in machine configs

2016-02-18 Thread John Ferlan
On 02/11/2016 07:07 AM, Ján Tomko wrote: > Commit f1a89a8 allowed parsing configs from /etc/libvirt > without validating the emulator capabilities. > > Check for the presence of os->type.machine even if the > VIR_DOMAIN_DEF_PARSE_SKIP_OSTYPE_CHECKS flag is set, > otherwise the daemon can crash o

Re: [libvirt] [PATCH 1/2] vsh: use virBufferTrim in vshOutputLogFile

2016-02-18 Thread John Ferlan
On 02/12/2016 08:59 AM, Ján Tomko wrote: > Use virBufferTrim to strip the extra newline at the end > of the message instead of open-coding it after the buffer's > string is formatted. > --- > tools/vsh.c | 5 + > 1 file changed, 1 insertion(+), 4 deletions(-) > ACK John -- libvir-list ma

Re: [libvirt] [PATCH 2/2] Introduce safewrite_str

2016-02-18 Thread John Ferlan
On 02/12/2016 08:59 AM, Ján Tomko wrote: > Just like safewrite, but calls strlen first to figure out > the length of the string. > --- > src/conf/virchrdev.c | 2 +- > src/libvirt_private.syms | 1 + > src/lxc/lxc_process.c | 4 ++-- > src/network/leaseshelper.c | 2 +- > src/op

Re: [libvirt] [PATCH v2 00/10] Reorganizing qemu_command.c continued

2016-02-18 Thread John Ferlan
On 02/17/2016 09:25 PM, John Ferlan wrote: > v1: http://www.redhat.com/archives/libvir-list/2016-February/msg00804.html > > v2 changes: > > Patch 1 makes changes as requested from review. > > Patches 2-7 are v1's 4-10 take a different approach by creating > qemuBuildCommandLine helper rout

Re: [libvirt] [PATCH 4/6] storage:dir: .resizeVol callback for ploop volume

2016-02-18 Thread Olga Krishtal
On 18/02/16 11:15, Nikolay Shirokovskiy wrote: On 17.02.2016 14:40, Olga Krishtal wrote: To change the size of ploop image file we use ploop resize cmd that takes 2 args: new size and path/to/DiskDescriptor.xml Signed-off-by: Olga Krishtal --- src/storage/storage_backend.c| 33 +

Re: [libvirt] [Xen-devel] [PATCH V2 0/4] libxl: support qemu's network-based block backends

2016-02-18 Thread Ian Campbell
On Wed, 2016-02-17 at 17:33 -0700, Jim Fehlig wrote: > xl/libxl already supports qemu's network-based block backends > such as nbd and rbd. libvirt has supported configuring network > disks for long time too. This series marries the two in the > libxl driver and in the xl<->xml converter. Only rbd

Re: [libvirt] Libvirtd and OSX... with QEMU

2016-02-18 Thread Martin Kletzander
On Mon, Jan 18, 2016 at 05:04:44PM +, Justin Clift wrote: On 18 Jan 2016, at 14:00, Martin Kletzander wrote: On Sun, Jan 17, 2016 at 10:16:54PM +, Justin Clift wrote: With debug level logging, although more verbose there's nothing that seems smoking-gun like. Except maybe this? 201

[libvirt] [PATCH v4 0/2] notify about reverting to a snapshot

2016-02-18 Thread Dmitry Andreev
Reverting to a snapshot may change domain configuration but there will be no events about that in some cases. Lack of the event become a problem for virt-manager https://bugzilla.redhat.com/show_bug.cgi?id=1081148 This patch-set introduces new event and emits it in qemuDomainRevertToSnapshot. v

[libvirt] [PATCH v4 1/2] Introduce new VIR_DOMAIN_EVENT_DEFINED_FROM_SNAPSHOT sub-event

2016-02-18 Thread Dmitry Andreev
When domain is reverted to a snapshot and domain state is changed libvirt emits _FROM_SNAPSHOT event. This new introduced event could be emitted if there was no changes in state but domain configuration was changed by a snapshot. --- examples/object-events/event-test.c | 2 ++ include/libvirt/libv

Re: [libvirt] [PATCHv3 0/2] notify about reverting to a snapshot

2016-02-18 Thread Dmitry Andreev
On 06.01.2016 01:19, John Ferlan wrote: On 12/23/2015 09:25 AM, Dmitry Andreev wrote: Reverting to snapshot may change domain configuration but there will be no events about that. Lack of the event become a problem for virt-manager https://bugzilla.redhat.com/show_bug.cgi?id=1081148 This p

[libvirt] [PATCH v4 2/2] qemu: emit 'defined' event after reverted to snapshot without state changes

2016-02-18 Thread Dmitry Andreev
When domain is reverted to a snapshot it's configuration and state may be changed. If the domain state was changed libvirt emits one or more _FROM_SNAPSHOT events. In case when domain and target states both are offline there will be no state changes and no events. Lack of the event become a proble

Re: [libvirt] [PATCH 3/3] common-impl: make virDomainObjGetPersistentDef return only persistent config

2016-02-18 Thread Nikolay Shirokovskiy
ping On 02.02.2016 16:18, Nikolay Shirokovskiy wrote: > > > On 02.02.2016 15:13, John Ferlan wrote: >> >> >> On 01/15/2016 09:05 AM, Nikolay Shirokovskiy wrote: >>> It's rather unexpected that function with such a name could return >>> transient definition. This is possible if we call it for >>>

Re: [libvirt] [PATCH] qemu: cgroup: fix cgroup permission logic

2016-02-18 Thread Peter Krempa
On Thu, Feb 18, 2016 at 10:19:51 +0100, Bjoern Walk wrote: > Fix logic error introduced in commit d6c91b3c which essentially broke > starting any domain. Oops!, thanks for catching this. ACK I'll push this in a while. > > Signed-off-by: Bjoern Walk > --- > src/qemu/qemu_cgroup.c | 2 +- > 1

Re: [libvirt] [PATCH 6/6] storage:dir: adapts .refreshVol .refreshPool for ploop volumes

2016-02-18 Thread Nikolay Shirokovskiy
On 17.02.2016 14:40, Olga Krishtal wrote: > To update information about ploop volumes inside the a single pool we need > to be sure that it is the ploop directory and not some other directory. > Ploop volume directory obligatory contains root.hds - image file and disk > descriptor - DiskDescripto

[libvirt] [PATCH] qemu: cgroup: fix cgroup permission logic

2016-02-18 Thread Bjoern Walk
Fix logic error introduced in commit d6c91b3c which essentially broke starting any domain. Signed-off-by: Bjoern Walk --- src/qemu/qemu_cgroup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qemu/qemu_cgroup.c b/src/qemu/qemu_cgroup.c index 53642a1..f3c5fbb 100644 --- a

Re: [libvirt] [PATCH v2] virsh: Remove when changing cdrom media source

2016-02-18 Thread Ján Tomko
On Wed, Feb 10, 2016 at 09:17:45AM +0100, Peter Krempa wrote: > Since the code is changing the source image path by modifying the > existing XML snippet the stays in place. > > As is relevant to the part of the image, the > update of that part makes the element invalid. > > CD/floppy images us

Re: [libvirt] [PATCH v2 08/10] qemu: Introduce qemuBuildSmbiosCommandLine

2016-02-18 Thread Peter Krempa
On Wed, Feb 17, 2016 at 21:25:41 -0500, John Ferlan wrote: > Add new function to manage adding the '-smbios' options to the command > line removing that task from the mainline qemuBuildCommandLine > > Also while I was looking at it, move the uuid processing closer to usage. > > Signed-off-by: Joh

Re: [libvirt] [PATCH v2 10/10] qemu: Introduce qemuBuildMonitorCommandLine

2016-02-18 Thread Peter Krempa
On Wed, Feb 17, 2016 at 21:25:43 -0500, John Ferlan wrote: > Add new function to manage adding the '-mon' or '-monitor' options to > the command line removing that task from the mainline qemuBuildCommandLine + two stylistic/alignment changes > > Signed-off-by: John Ferlan > --- > src/qemu/qemu

Re: [libvirt] [PATCH v2 09/10] qemu: Introduce qemuBuildSgaCommandLine

2016-02-18 Thread Peter Krempa
On Wed, Feb 17, 2016 at 21:25:42 -0500, John Ferlan wrote: > Add new function to manage adding the '-device sga' to the command > line removing that task from the mainline qemuBuildCommandLine > > Signed-off-by: John Ferlan > --- > src/qemu/qemu_command.c | 50 > ++--

Re: [libvirt] [PATCH 4/6] storage:dir: .resizeVol callback for ploop volume

2016-02-18 Thread Nikolay Shirokovskiy
On 17.02.2016 14:40, Olga Krishtal wrote: > To change the size of ploop image file we use ploop resize cmd that takes > 2 args: new size and path/to/DiskDescriptor.xml > > Signed-off-by: Olga Krishtal > --- > src/storage/storage_backend.c| 33 + > src/storag

Re: [libvirt] [PATCH 3/6] storage:dir: adapts .uploadVol .dowloadVol for ploop volume

2016-02-18 Thread Nikolay Shirokovskiy
On 17.02.2016 14:40, Olga Krishtal wrote: > In case of ploop volume, target path of the volume is the path to the > directory that contains image file named root.hds and DiskDescriptor.xml. > While using uploadVol and downloadVol callbacks we need to open root.hds > itself. To accomplish this goa

Re: [libvirt] [PATCH v2 02/10] qemu: Rename qemuBuildMachineArgStr

2016-02-18 Thread Pavel Hrdina
On Wed, Feb 17, 2016 at 09:25:35PM -0500, John Ferlan wrote: > Renane to qemuBuildMachineCommandLine to fit current (and future) s/Renane/Rename/ > helper naming conventions. -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list