Re: [libvirt] [PATCHv2 0/2] doc: Improve snapshot/blockjob docs

2014-07-14 Thread Peter Krempa
On 07/11/14 18:27, Eric Blake wrote: On 07/11/2014 03:01 AM, Peter Krempa wrote: Peter Krempa (2): doc: Document that snapshot name of block-backed disk isnt autogenerated doc: Be more specific about semantics of _REUSE_EXT flag ACK series; you picked up on all my suggestions on

[libvirt] OVMF exposure in libvirt

2014-07-14 Thread Michal Privoznik
Dear list, there's been a lot of development in QEMU on this part. And I think it's settled down enough long so I can start looking at it. So I'd like to hear you opinion what's the best way to expose this in libvirt. OVMF can bee looked at as a UEFI enablement in guest. Standard UEFI

Re: [libvirt] [PATCH 3/3] virSecurityLabelDef: use enum type for @type

2014-07-14 Thread Michal Privoznik
On 11.07.2014 18:59, Eric Blake wrote: On 07/11/2014 03:32 AM, Michal Privoznik wrote: There's this trend in libvirt of using enum types wherever possible. Now that I'm at virSecurityLabelDef let's rework @type item of the structure so we don't have to typecast it elsewhere. Signed-off-by:

Re: [libvirt] OVMF exposure in libvirt

2014-07-14 Thread Daniel P. Berrange
On Mon, Jul 14, 2014 at 09:32:34AM +0200, Michal Privoznik wrote: Dear list, there's been a lot of development in QEMU on this part. And I think it's settled down enough long so I can start looking at it. So I'd like to hear you opinion what's the best way to expose this in libvirt. OVMF

Re: [libvirt] [libvirt-glib 1/3] Add gvir_config_capabilities_cpu_get_model()

2014-07-14 Thread Christophe Fergeau
On Tue, Jul 08, 2014 at 07:41:55PM +0100, Zeeshan Ali (Khattak) wrote: On Mon, Jul 7, 2014 at 12:09 PM, Christophe Fergeau cferg...@redhat.com wrote: This is returning a char * capabilities host cpu modelxxx/model /cpu /host /capabilities while the next patch

Re: [libvirt] OVMF exposure in libvirt

2014-07-14 Thread Peter Krempa
On 07/14/14 11:27, Daniel P. Berrange wrote: On Mon, Jul 14, 2014 at 09:32:34AM +0200, Michal Privoznik wrote: Dear list, there's been a lot of development in QEMU on this part. And I think it's settled down enough long so I can start looking at it. So I'd like to hear you opinion what's the

Re: [libvirt] OVMF exposure in libvirt

2014-07-14 Thread Daniel P. Berrange
On Mon, Jul 14, 2014 at 11:55:52AM +0200, Peter Krempa wrote: On 07/14/14 11:27, Daniel P. Berrange wrote: On Mon, Jul 14, 2014 at 09:32:34AM +0200, Michal Privoznik wrote: Dear list, there's been a lot of development in QEMU on this part. And I think it's settled down enough long so I

[libvirt] [PATCH] LXC: create a bind mount for sysfs when enable userns but disable netns

2014-07-14 Thread Chen Hanxiao
kernel commit 7dc5dbc879bd0779924b5132a48b731a0bc04a1e forbid us doing a fresh mount for sysfs when enable userns but disable netns. This patch will create a bind mount in this senario. Signed-off-by: Chen Hanxiao chenhanx...@cn.fujitsu.com --- src/lxc/lxc_container.c | 44

Re: [libvirt] [PATCHv2]util:openvswitch:Delete port if it is exist when add port

2014-07-14 Thread Michal Privoznik
On 12.07.2014 06:47, Lichunhe wrote: If the ovs service stop abnormal, or host cold reboot, vm is destroyed after ovs service stop. The ovs port which connect to interface of vm will not be clear. When the ovs service restart, recover configuration from db, but the interface is no exist, port

[libvirt] [PATCH V2 5/6] tests: Add test cases for secondary-vga

2014-07-14 Thread Wang Rui
From: Zeng Junliang zengjunli...@huawei.com While adding support for secondary-vga, we should add test cases for it and test its basic functions. Signed-off-by: Zeng Junliang zengjunli...@huawei.com Signed-off-by: Wang Rui moon.wang...@huawei.com --- qemuxml2argv-graphics-vnc-secondary-vga.xml

[libvirt] [PATCH V2 1/6] qemu: Remove vram attribute in some cases

2014-07-14 Thread Wang Rui
From: Zeng Junliang zengjunli...@huawei.com The vram attribute is invalid for cirrus and stdvga device, and default vram value would make us confused. It would be better to remove it. Signed-off-by: Zeng Junliang zengjunli...@huawei.com Signed-off-by: Wang Rui moon.wang...@huawei.com ---

[libvirt] [PATCH V2 0/6] Some improvements for video model.

2014-07-14 Thread Wang Rui
From: Zeng Junliang zengjunli...@huawei.com https://www.redhat.com/archives/libvir-list/2014-June/msg00569.html diff to v1: - Rmoving the confusing vram attribute for cirrus and stdvga. - leave out cirrus for the new vgamem attribute. - add secondary-vga supports and some other docs and tests.

[libvirt] [PATCH V2 3/6] qemu: Add support for secondary-vga

2014-07-14 Thread Wang Rui
From: Zeng Junliang zengjunli...@huawei.com Secondary-vga is supported by QEMU in currently master. Add it supported in libvirt as qemu commandline shows: '-device secondary-vga'. Signed-off-by: Zeng Junliang zengjunli...@huawei.com Signed-off-by: Wang Rui moon.wang...@huawei.com ---

[libvirt] [PATCH V2 4/6] tests: modify test case related to vgamem attribute

2014-07-14 Thread Wang Rui
From: Zeng Junliang zengjunli...@huawei.com While removing the useless vram attribute for cirrus and stdvga device, we should update the corresponding test cases. Adding test cases for the new vgamem attribute is also needed. Signed-off-by: Zeng Junliang zengjunli...@huawei.com Signed-off-by:

[libvirt] [PATCH V2 6/6] docs: add description for vgamem attribute and secondary-vga

2014-07-14 Thread Wang Rui
From: Zeng Junliang zengjunli...@huawei.com Enhance schema. Add description for vgamem attribute and secondary-vga. Signed-off-by: Zeng Junliang zengjunli...@huawei.com Signed-off-by: Wang Rui moon.wang...@huawei.com --- docs/formatdomain.html.in | 39 ++-

[libvirt] [PATCH V2 2/6] qemu: Introduce vgamem attribute for video model

2014-07-14 Thread Wang Rui
From: Zeng Junliang zengjunli...@huawei.com This patch introduces vgamem attribute for video model, and sets its default value as qemu used. Parse it in two ways accroding to qemu startup parameters supported: -device or -vga. Signed-off-by: Zeng Junliang zengjunli...@huawei.com Signed-off-by:

Re: [libvirt] [PATCH 0/2] Implement interface stats for BSD

2014-07-14 Thread Michal Privoznik
On 06.07.2014 18:28, Roman Bogorodskiy wrote: This series implements support for querying network interface stats on (Free)BSD. It's more of an RFC, because I'm uncertain about few things: - It feels a little strange to have a source file that implements only a single function like

Re: [libvirt] [PATCH 2/2] Rework lxc apparmor profile

2014-07-14 Thread Serge Hallyn
Quoting Cédric Bosdonnat (cbosdon...@suse.com): diff --git a/examples/apparmor/libvirt-lxc b/examples/apparmor/libvirt-lxc index d404328..4bfb503 100644 --- a/examples/apparmor/libvirt-lxc +++ b/examples/apparmor/libvirt-lxc @@ -2,16 +2,115 @@ Hi, this being a verbatim copy from lxc's

Re: [libvirt] [libvirt-glib 1/3] Add gvir_config_capabilities_cpu_get_model()

2014-07-14 Thread Zeeshan Ali (Khattak)
On Mon, Jul 14, 2014 at 10:44 AM, Christophe Fergeau cferg...@redhat.com wrote: On Tue, Jul 08, 2014 at 07:41:55PM +0100, Zeeshan Ali (Khattak) wrote: On Mon, Jul 7, 2014 at 12:09 PM, Christophe Fergeau cferg...@redhat.com wrote: This is returning a char * capabilities host cpu

[libvirt] [PATCH 1/2] docs: mention more about older capability feature bits

2014-07-14 Thread Eric Blake
Our documentation for features was rather sparse; this fleshes out more of the details for other existing capabilities (and cost me some time trawling git history). * docs/formatcaps.html.in: Document it feature bits. Signed-off-by: Eric Blake ebl...@redhat.com --- docs/formatcaps.html.in | 42

[libvirt] [PATCH 0/2] capabilities cleanups

2014-07-14 Thread Eric Blake
I'm still trying to figure out how best to expose capabilities in the new virConnectGetDomainCapabilities for things such as active commit - we may want to tweak that XML before it becomes baked in as part of the 1.2.7 release. But meanwhile, these two patches should be fairly non-controversial.

[libvirt] [PATCH 2/2] capabilities: use bool instead of int

2014-07-14 Thread Eric Blake
While preparing to add a capability for active commit, I noticed that the existing code was abusing int for boolean values. * src/conf/capabilities.h (_virCapsGuestFeature, _virCapsHost) (virCapabilitiesNew, virCapabilitiesAddGuestFeature): Improve types. * src/conf/capabilities.c

Re: [libvirt] OVMF exposure in libvirt

2014-07-14 Thread Paolo Bonzini
Il 14/07/2014 11:27, Daniel P. Berrange ha scritto: -drive file=img_1,if=pflash,format=raw,readonly \ -drive file=img_2,if=pflash,format=raw It's safer to add ,unit=0 and ,unit=1 too. We already use loader/ for specifying alternative BIOS blobs for the QEMU -bios arg. Since you

Re: [libvirt] OVMF exposure in libvirt

2014-07-14 Thread Daniel P. Berrange
On Mon, Jul 14, 2014 at 04:12:14PM +0200, Paolo Bonzini wrote: Il 14/07/2014 11:27, Daniel P. Berrange ha scritto: -drive file=img_1,if=pflash,format=raw,readonly \ -drive file=img_2,if=pflash,format=raw It's safer to add ,unit=0 and ,unit=1 too. Is there any compelling reason

[libvirt] [PATCH 0/2] Tri-state bool enum cleanups

2014-07-14 Thread Ján Tomko
We have been using a few different enum types with the same values: DEFAULT ENABLED = on / yes DISABLED = off / no Replace these with just two enums with rather unimaginative names: virDomainYesNo and virDomainOnOff Ján Tomko (2): Introduce virDomainYesNo enum type Introduce virDomainOnOff

[libvirt] [PATCH 2/2] Introduce virDomainOnOff enum

2014-07-14 Thread Ján Tomko
Replace virDomainFeatureState virDomainIoEventFd virDomainVirtioEventIdx virDomainDiskCopyOnRead virDomainMemDump virDomainPCIRombarMode virDomainGraphicsSpicePlaybackCompression --- src/conf/domain_conf.c | 140 ++- src/conf/domain_conf.h | 82

Re: [libvirt] [PATCH 1/2] Introduce virDomainYesNo enum type

2014-07-14 Thread Daniel P. Berrange
On Mon, Jul 14, 2014 at 04:47:16PM +0200, Ján Tomko wrote: @@ -10901,9 +10884,9 @@ virDomainDefParseBootXML(xmlXPathContextPtr ctxt, for useserial)); goto cleanup; } -def-os.bios.useserial =

Re: [libvirt] [PATCH 0/2] capabilities cleanups

2014-07-14 Thread John Ferlan
On 07/14/2014 10:08 AM, Eric Blake wrote: I'm still trying to figure out how best to expose capabilities in the new virConnectGetDomainCapabilities for things such as active commit - we may want to tweak that XML before it becomes baked in as part of the 1.2.7 release. But meanwhile, these

[libvirt] [PATCH 1/2] Introduce virDomainYesNo enum type

2014-07-14 Thread Ján Tomko
Replace all three-state (default/yes/no) enums with it: virDomainBootMenu virDomainPMState virDomainGraphicsSpiceClipboardCopypaste virDomainGraphicsSpiceAgentFileTransfer --- src/conf/domain_conf.c | 54 ++-- src/conf/domain_conf.h | 45

Re: [libvirt] OVMF exposure in libvirt

2014-07-14 Thread Paolo Bonzini
Il 14/07/2014 16:43, Daniel P. Berrange ha scritto: -drive file=img_1,if=pflash,format=raw,readonly \ -drive file=img_2,if=pflash,format=raw It's safer to add ,unit=0 and ,unit=1 too. Is there any compelling reason to make the unit numbers user configurable. Are they guest ABI

[libvirt] [PATCH] blockjob: wait for pivot to complete

2014-07-14 Thread Eric Blake
https://bugzilla.redhat.com/show_bug.cgi?id=1119173 documents that commit eaba79d was flawed in the implementation of the VIR_DOMAIN_BLOCK_JOB_ABORT_ASYNC flag when it comes to completing a blockcopy. Basically, the qemu pivot action is async (the QMP command returns immediately, but the user

[libvirt] [PATCH] GetBlockInfo: Use the correct path to qemuOpenFile

2014-07-14 Thread John Ferlan
Commit id '3ea661de' refactored the code to use the 'disk-src-path' instead of getting the path from virDomainDiskGetSource(). The one call to qemuOpenFile() didn't use the disk source path, rather it used the path as passed from the caller (in this case 'vda') - this caused a failure with the

Re: [libvirt] [PATCH 0/2] capabilities cleanups

2014-07-14 Thread Eric Blake
On 07/14/2014 08:58 AM, John Ferlan wrote: On 07/14/2014 10:08 AM, Eric Blake wrote: I'm still trying to figure out how best to expose capabilities in the new virConnectGetDomainCapabilities for things such as active commit - we may want to tweak that XML before it becomes baked in as

Re: [libvirt] [PATCH 1/2] Introduce virDomainYesNo enum type

2014-07-14 Thread Eric Blake
On 07/14/2014 08:56 AM, Daniel P. Berrange wrote: On Mon, Jul 14, 2014 at 04:47:16PM +0200, Ján Tomko wrote: @@ -10901,9 +10884,9 @@ virDomainDefParseBootXML(xmlXPathContextPtr ctxt, for useserial)); goto cleanup; } -

Re: [libvirt] [PATCH 1/2] Introduce virDomainYesNo enum type

2014-07-14 Thread Daniel P. Berrange
On Mon, Jul 14, 2014 at 10:38:01AM -0600, Eric Blake wrote: On 07/14/2014 08:56 AM, Daniel P. Berrange wrote: On Mon, Jul 14, 2014 at 04:47:16PM +0200, Ján Tomko wrote: @@ -10901,9 +10884,9 @@ virDomainDefParseBootXML(xmlXPathContextPtr ctxt, for

Re: [libvirt] [PATCH 3/3] virSecurityLabelDef: use enum type for @type

2014-07-14 Thread Eric Blake
On 07/14/2014 03:09 AM, Michal Privoznik wrote: On 11.07.2014 18:59, Eric Blake wrote: On 07/11/2014 03:32 AM, Michal Privoznik wrote: There's this trend in libvirt of using enum types wherever possible. Now that I'm at virSecurityLabelDef let's rework @type item of the structure so we don't

Re: [libvirt] [PATCH] GetBlockInfo: Use the correct path to qemuOpenFile

2014-07-14 Thread Eric Blake
On 07/14/2014 10:30 AM, John Ferlan wrote: Commit id '3ea661de' refactored the code to use the 'disk-src-path' instead of getting the path from virDomainDiskGetSource(). The one call to qemuOpenFile() didn't use the disk source path, rather it used the path as passed from the caller (in this

Re: [libvirt] [PATCH 1/2] Introduce virDomainYesNo enum type

2014-07-14 Thread Eric Blake
On 07/14/2014 10:40 AM, Daniel P. Berrange wrote: } -def-os.bios.useserial = VIR_DOMAIN_BIOS_USESERIAL_YES; +def-os.bios.useserial = VIR_DOMAIN_YES_NO_ENABLED; } else { -def-os.bios.useserial = VIR_DOMAIN_BIOS_USESERIAL_NO; +

[libvirt] LVM Volume Creation

2014-07-14 Thread Ravi Samji
Hi All, I'm having issue with creating LVM volume via libvirt. XML of LVM StoragePool is:     VG01             /dev/VG01       (existing vg) XML of create volume in lvm pool is:     ub_test01.img     0     1                 When I create the volume with above XML defn, lvs command

Re: [libvirt] [libvirt-glib 1/3] Add gvir_config_capabilities_cpu_get_model()

2014-07-14 Thread Christophe Fergeau
On Mon, Jul 14, 2014 at 02:56:18PM +0100, Zeeshan Ali (Khattak) wrote: Ah so you mean that I use the same object to represent both? I'm not sure that makes sense since they are part of different XMLs and therefore different entities. I'm not sure here. We already have GVirConfigDomainCpu which

Re: [libvirt] [libvirt-glib 1/3] Add gvir_config_capabilities_cpu_get_model()

2014-07-14 Thread Zeeshan Ali (Khattak)
On Mon, Jul 14, 2014 at 6:31 PM, Christophe Fergeau cferg...@redhat.com wrote: On Mon, Jul 14, 2014 at 02:56:18PM +0100, Zeeshan Ali (Khattak) wrote: Ah so you mean that I use the same object to represent both? I'm not sure that makes sense since they are part of different XMLs and therefore

[libvirt] python bindings links?

2014-07-14 Thread Eric Blake
According to http://libvirt.org/bindings.html, python bindings are still listed as part of libvirt.git. But now that they are a separate git repository, we probably ought to have a more official page for these bindings, including an easy-to-find link to the repository viewer. Right now,

Re: [libvirt] [libvirt-users] LVM Volume Creation

2014-07-14 Thread Eric Blake
On 07/14/2014 07:26 AM, Ravi Samji wrote: Hi All, I'm having issue with creating LVM volume via libvirt. XML of LVM StoragePool is: VG01 /dev/VG01 (existing vg) XML of create volume in lvm pool is: ub_test01.img 0 1 Umm,

Re: [libvirt] python bindings links?

2014-07-14 Thread Nehal J Wani
On Tue, Jul 15, 2014 at 1:25 AM, Eric Blake ebl...@redhat.com wrote: According to http://libvirt.org/bindings.html, python bindings are still listed as part of libvirt.git. But now that they are a separate git repository, we probably ought to have a more official page for these bindings,

Re: [libvirt] [PREPOST 08/17] src/xenxs:Refactor graphics config parsing code

2014-07-14 Thread Jim Fehlig
David Kiarie wrote: From: Kiarie Kahurani davidkiar...@gmail.com introduce function xenParseXMVfb(.); which parses the graphics config signed-off-by: David Kiariedavidkiar...@gmail.com --- src/xenxs/xen_xm.c | 247 - 1 file

Re: [libvirt] [PREPOST 09/17] src/xenxs:Refactor OS and Miscellaneous deivices config

2014-07-14 Thread Jim Fehlig
David Kiarie wrote: From: Kiarie Kahurani davidkiar...@gmail.com Introduce functions xenParseXMOS(.) and xenParseXMMisc(.) to parse the OS and Miscellaneous devices configs signed-off-by: David Kiariedavidkiar...@gmail.com --- src/xenxs/xen_xm.c | 146

Re: [libvirt] [PREPOST 10/17] src/xenxs:Refactor xenParseXM( )

2014-07-14 Thread Jim Fehlig
David Kiarie wrote: From: Kiarie Kahurani davidkiar...@gmail.com A couple of miscellaneous fixed and wrap code common code into xenParseConfigCommon(...).I will drop some of the functions later though signed-off-by: David Kiariedavidkiar...@gmail.com --- src/xenxs/xen_xm.c | 134

Re: [libvirt] [PREPOST 11/17] src/xenxs:Refactor code formating general information

2014-07-14 Thread Jim Fehlig
David Kiarie wrote: From: Kiarie Kahurani davidkiar...@gmail.com refactor code parsing uuid, memory and name options signed-off-by:David Kiariedavidkiar...@gmail.com --- src/xenxs/xen_xm.c | 40 +++- 1 file changed, 27 insertions(+), 13 deletions(-)

Re: [libvirt] [PREPOST 12/17] src/xenxs:Refactor virtual time config options formating code

2014-07-14 Thread Jim Fehlig
David Kiarie wrote: From: Kiarie Kahurani davidkiar...@gmail.com Introduce function xenFormatXMTimeOffset(..) which formats virtual time config Ah, on the format side you split TimeOffset and EventActions as I requested on the parse side. Looks good with the exception of the usual

Re: [libvirt] [PREPOST 13/17] src/xenxs:Refactor code formating event actions config

2014-07-14 Thread Jim Fehlig
David Kiarie wrote: From: Kiarie Kahurani davidkiar...@gmail.com Introduce function xenFormatXMEventActions(.) which formats actions following certain events Looks good with exception of my tiring whitespace comments :-). Regards, Jim signed-off-by:David

Re: [libvirt] [PREPOST 14/17] src/xenxs:Refactor code formating char devices config

2014-07-14 Thread Jim Fehlig
David Kiarie wrote: From: Kiarie Kahurani davidkiar...@gmail.com Introduce function xenFormatXMCharDev(); which formats char devices config signed-off-by:David Kiariedavidkiar...@gmail.com --- src/xenxs/xen_xm.c | 155 - 1 file

Re: [libvirt] [PREPOST 15/17] src/xenxs:Refactor Vif formating code

2014-07-14 Thread Jim Fehlig
David Kiarie wrote: From: Kiarie Kahurani davidkiar...@gmail.com Introduce the function xenFormatXMDomainNet(..) On the parsing side, you called this xenParseXMVif. To be consistent, this should be xenFormatXMVif. I think this could be done in a cleaner way signed-of-by: David

Re: [libvirt] [PATCHv3 1/2] virsh: Reject negative numbers in vshCommandOptUInt

2014-07-14 Thread John Ferlan
Bumping again - I found a related bz in my backlog... On 05/29/2014 01:15 PM, Eric Blake wrote: On 05/29/2014 05:54 AM, Peter Krempa wrote: Use virStrToLong_uip instead of virStrToLong_ui to reject negative numbers in the helper. None of the callers expects the wraparound feature for

[libvirt] [PATCH 0/3] libxl: support hotplug of interface device

2014-07-14 Thread Chunyan Liu
This patch series is to add support for attach/detaching an interface device. At the same time, add two fixes (1/3 and 3/3) Chunyan Liu (3): libxl: add HOSTDEV type in libxlDomainDetachDeviceConfig libxl: support hotplug of interface libxl: fix return value error Attach|DetachDeviceFlags

[libvirt] [PATCH 1/3] libxl: add HOSTDEV type in libxlDomainDetachDeviceConfig

2014-07-14 Thread Chunyan Liu
Missing HOSTDEV type in libxlDomainDetachDeviceConfig. Add it. Signed-off-by: Chunyan Liu cy...@suse.com --- src/libxl/libxl_driver.c | 23 ++- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/src/libxl/libxl_driver.c b/src/libxl/libxl_driver.c index

[libvirt] [PATCH 2/3] libxl: support hotplug of interface

2014-07-14 Thread Chunyan Liu
Add code to support attach/detaching a network device. Signed-off-by: Chunyan Liu cy...@suse.com --- src/libxl/libxl_domain.c | 12 +++- src/libxl/libxl_driver.c | 146 --- 2 files changed, 149 insertions(+), 9 deletions(-) diff --git

[libvirt] [PATCH 3/3] libxl: fix return value error Attach|DetachDeviceFlags

2014-07-14 Thread Chunyan Liu
Code logic in libxlDomainAttachDeviceFlags and libxlDomainDetachDeviceFlags is wrong with return value in error cases. 'ret' was being set to 0 if 'flags VIR_DOMAIN_DEVICE_MODIFY_CONFIG' was false. Then if something like virDomainDeviceDefParse() failed in the VIR_DOMAIN_DEVICE_MODIFY_LIVE