Re: [libvirt] new libvirt pci controller type and pcie/q35 (was Re: [PATCH 4/7] add pci-bridge controller type)

2013-04-09 Thread Daniel P. Berrange
On Mon, Apr 08, 2013 at 03:32:07PM -0400, Laine Stump wrote: On 04/08/2013 12:48 PM, Daniel P. Berrange wrote: On Mon, Apr 08, 2013 at 12:37:49PM -0400, Laine Stump wrote: I think we're starting to get closer to the concrete problem that's bothering me. As I understand it (and again - what

Re: [libvirt] new libvirt pci controller type and pcie/q35 (was Re: [PATCH 4/7] add pci-bridge controller type)

2013-04-09 Thread Daniel P. Berrange
On Mon, Apr 08, 2013 at 10:37:45PM +0300, Michael S. Tsirkin wrote: On Mon, Apr 08, 2013 at 03:32:07PM -0400, Laine Stump wrote: On 04/08/2013 12:48 PM, Daniel P. Berrange wrote: On Mon, Apr 08, 2013 at 12:37:49PM -0400, Laine Stump wrote: I think we're starting to get closer to the

Re: [libvirt] [PATCH] Release VM lock before acquiring virDomainObjListPtr lock

2013-04-09 Thread Daniel P. Berrange
On Mon, Apr 08, 2013 at 09:15:28PM -0600, Eric Blake wrote: On 02/11/2013 09:46 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com When removing a VM from the virDomainObjListPtr, we must not be holding the VM lock while acquiring the list lock. Re-order code to

Re: [libvirt] new libvirt pci controller type and pcie/q35 (was Re: [PATCH 4/7] add pci-bridge controller type)

2013-04-09 Thread Daniel P. Berrange
On Mon, Apr 08, 2013 at 04:26:19PM -0600, Alex Williamson wrote: On Mon, 2013-04-08 at 12:37 -0400, Laine Stump wrote: On 04/05/2013 03:26 PM, Alex Williamson wrote: Sure. I just mean pci bus 0 (hmm, but actually this does point out a problem with my logic - the same namespace (well,

Re: [libvirt] [PATCH] Release VM lock before acquiring virDomainObjListPtr lock

2013-04-09 Thread Peter Krempa
On 04/09/13 11:08, Daniel P. Berrange wrote: On Mon, Apr 08, 2013 at 09:15:28PM -0600, Eric Blake wrote: On 02/11/2013 09:46 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com When removing a VM from the virDomainObjListPtr, we must not be holding the VM lock while

Re: [libvirt] [PATCH] Release VM lock before acquiring virDomainObjListPtr lock

2013-04-09 Thread Daniel P. Berrange
On Tue, Apr 09, 2013 at 10:08:31AM +0100, Daniel P. Berrange wrote: On Mon, Apr 08, 2013 at 09:15:28PM -0600, Eric Blake wrote: On 02/11/2013 09:46 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com When removing a VM from the virDomainObjListPtr, we must not

Re: [libvirt] [PATCH] Release VM lock before acquiring virDomainObjListPtr lock

2013-04-09 Thread Daniel P. Berrange
On Tue, Apr 09, 2013 at 12:22:38PM +0200, Peter Krempa wrote: On 04/09/13 11:08, Daniel P. Berrange wrote: On Mon, Apr 08, 2013 at 09:15:28PM -0600, Eric Blake wrote: On 02/11/2013 09:46 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com When removing a VM from the

Re: [libvirt] [PATCH] Release VM lock before acquiring virDomainObjListPtr lock

2013-04-09 Thread Peter Krempa
On 04/09/13 12:26, Daniel P. Berrange wrote: On Tue, Apr 09, 2013 at 10:08:31AM +0100, Daniel P. Berrange wrote: On Mon, Apr 08, 2013 at 09:15:28PM -0600, Eric Blake wrote: On 02/11/2013 09:46 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com When removing a VM from

Re: [libvirt] [PATCH] Release VM lock before acquiring virDomainObjListPtr lock

2013-04-09 Thread Daniel P. Berrange
On Tue, Apr 09, 2013 at 01:19:05PM +0200, Peter Krempa wrote: On 04/09/13 12:26, Daniel P. Berrange wrote: On Tue, Apr 09, 2013 at 10:08:31AM +0100, Daniel P. Berrange wrote: On Mon, Apr 08, 2013 at 09:15:28PM -0600, Eric Blake wrote: On 02/11/2013 09:46 AM, Daniel P. Berrange wrote: From:

Re: [libvirt] [PATCH] Release VM lock before acquiring virDomainObjListPtr lock

2013-04-09 Thread Peter Krempa
On 04/09/13 13:22, Daniel P. Berrange wrote: On Tue, Apr 09, 2013 at 01:19:05PM +0200, Peter Krempa wrote: On 04/09/13 12:26, Daniel P. Berrange wrote: On Tue, Apr 09, 2013 at 10:08:31AM +0100, Daniel P. Berrange wrote: On Mon, Apr 08, 2013 at 09:15:28PM -0600, Eric Blake wrote: On

[libvirt] [PATCH] Tweak EOF handling of streams

2013-04-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Typically when you get EOF on a stream, poll will return POLLIN|POLLHUP at the same time. Thus when we deal with stream reads, if we see EOF during the read, we can then clear the VIR_STREAM_EVENT_HANGUP VIR_STREAM_EVENT_ERROR event bits.

[libvirt] virsh list hangs

2013-04-09 Thread wangxiaojun
please help me, i just installed libvirt-git and qemu-git to my gentoo os. when i start libvirtd, then type virsh list , it has no response. hangs forever. following is my typed cmd: $LIBVIRT_DEBUG=1 libvirtd .. 2013-04-09 08:39:03.649+: 17021: debug : virFileClose:72 :

[libvirt] [PATCH 0/2] Fix domain list race crash

2013-04-09 Thread Peter Krempa
This series fixes the race between freeing and accessing of domain objects and provides a reproducer case to test it. Peter Krempa (2): conf: Fix race between looking up a domain object and freeing it DO NOT APPLY UPSTREAM: Reproducer of domain free crash src/conf/domain_conf.c | 8

[libvirt] [PATCH 1/2] conf: Fix race between looking up a domain object and freeing it

2013-04-09 Thread Peter Krempa
This patch fixes crash of the daemon that happens due to the following race condition: Let's have two threads in the libvirtd daemon's qemu driver: A - thread executing a API call to get information about a domain B - thread executing undefine on the same domain Assume following serialization of

[libvirt] [PATCH 2/2] DO NOT APPLY UPSTREAM: Reproducer of domain free crash

2013-04-09 Thread Peter Krempa
The issue is triggered using the following shell oneliner with this patch applied: virsh undefine domain sleep .1; virsh dominfo domain --- src/conf/domain_conf.c | 4 src/qemu/qemu_driver.c | 6 ++ 2 files changed, 10 insertions(+) diff --git a/src/conf/domain_conf.c

Re: [libvirt] [PATCH] Release VM lock before acquiring virDomainObjListPtr lock

2013-04-09 Thread Eric Blake
On 04/09/2013 03:08 AM, Daniel P. Berrange wrote: I'm trying to understand what the behavior was before this patch went in. Well this was just fixing a deadlock introduced in a previous patch. You need to look further back than just this patch. Originally the global QEMU driver lock would

Re: [libvirt] [PATCH 1/2] conf: Fix race between looking up a domain object and freeing it

2013-04-09 Thread Viktor Mihajlovski
On 04/09/2013 03:02 PM, Peter Krempa wrote: 1 file changed, 4 insertions(+) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 03e5740..cafef0c 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -2238,10 +2238,14 @@ void

Re: [libvirt] [PATCH 0/3] Un-break s390 default network model and clean up obsolete

2013-04-09 Thread Ján Tomko
On 04/05/2013 12:12 PM, Peter Krempa wrote: This series fixes the default network model for s390 that was broken by the recent addition of post parse close callbacks and cleans up code obsoleted by that addition. Peter Krempa (2): qemu: Clean up network device CLI generator qemu:

Re: [libvirt] [PATCH] Tweak EOF handling of streams

2013-04-09 Thread Daniel P. Berrange
On Tue, Apr 09, 2013 at 07:57:11AM -0600, Eric Blake wrote: On 04/09/2013 06:25 AM, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Typically when you get EOF on a stream, poll will return POLLIN|POLLHUP at the same time. Thus when we deal with stream reads, if

Re: [libvirt] [PATCH 0/3] Un-break s390 default network model and clean up obsolete

2013-04-09 Thread Peter Krempa
On 04/09/13 15:41, Ján Tomko wrote: On 04/05/2013 12:12 PM, Peter Krempa wrote: This series fixes the default network model for s390 that was broken by the recent addition of post parse close callbacks and cleans up code obsoleted by that addition. Peter Krempa (2): qemu: Clean up network

Re: [libvirt] [PATCH v2.5 01/10] conf: Change help function

2013-04-09 Thread Osier Yang
On 09/04/13 10:32, Han Cheng wrote: The helper function to look up disk controller model may be used by scsi hostdev. But it should be changed to use device info. Signed-off-by: Han Cheng hanc.f...@cn.fujitsu.com --- src/conf/domain_conf.c |8 src/conf/domain_conf.h |6

[libvirt] [PATCH] docs: use MiB/s instead of Mbps for migration speed

2013-04-09 Thread Ján Tomko
https://bugzilla.redhat.com/show_bug.cgi?id=948821 --- src/libvirt.c | 24 tools/virsh.pod | 4 ++-- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/src/libvirt.c b/src/libvirt.c index cef9f1f..c5221f5 100644 --- a/src/libvirt.c +++ b/src/libvirt.c @@

Re: [libvirt] [PATCH v2.5 02/10] docs/schemas: Move PortNumber and sourceinfoadapter to basictypes.rng

2013-04-09 Thread Osier Yang
On 09/04/13 10:32, Han Cheng wrote: The definiton of scsi adapter in storagespool.rng (sourceinfoadapter) can be used by scsi hostdev. Move it to basictypes.rng. PortNumber is defined in both domaincommon.rng and storagespool.rng, simplify it by moving it to basictypes.rng. Signed-off-by: Han

Re: [libvirt] [PATCH] docs: use MiB/s instead of Mbps for migration speed

2013-04-09 Thread Eric Blake
On 04/09/2013 08:29 AM, Ján Tomko wrote: https://bugzilla.redhat.com/show_bug.cgi?id=948821 --- src/libvirt.c | 24 tools/virsh.pod | 4 ++-- 2 files changed, 14 insertions(+), 14 deletions(-) ACK. -- Eric Blake eblake redhat com+1-919-301-3266 Libvirt

Re: [libvirt] [PATCH] docs: use MiB/s instead of Mbps for migration speed

2013-04-09 Thread Ján Tomko
On 04/09/2013 04:44 PM, Eric Blake wrote: On 04/09/2013 08:29 AM, Ján Tomko wrote: https://bugzilla.redhat.com/show_bug.cgi?id=948821 --- src/libvirt.c | 24 tools/virsh.pod | 4 ++-- 2 files changed, 14 insertions(+), 14 deletions(-) ACK. Thank you, pushed

[libvirt] [PATCH] qemu: Generate agent socket path if missing

2013-04-09 Thread Michal Privoznik
It's not desired to force users imagine path for a socket they are not even supposed to connect to. On the other hand, we already have a release where the qemu agent socket path is exposed to XML, so we cannot silently drop it from there. The new path is generated in form:

[libvirt] [PATCH] Fix crash in virNetDevGetVirtualFunctions

2013-04-09 Thread Laine Stump
Commit 9a3ff01d7f16cc280ce3176620c0714f55511a65 (which was ACKed at the end of January, but for some reason didn't get pushed until during the 1.0.4 freeze) fixed the logic in virPCIGetVirtualFunctions(). Unfortunately, a typo in the fix (replacing VIR_REALLOC_N with VIR_ALLOC_N during code

Re: [libvirt] [PATCH] Fix crash in virNetDevGetVirtualFunctions

2013-04-09 Thread Eric Blake
On 04/09/2013 12:15 PM, Laine Stump wrote: Commit 9a3ff01d7f16cc280ce3176620c0714f55511a65 (which was ACKed at the end of January, but for some reason didn't get pushed until during the 1.0.4 freeze) fixed the logic in virPCIGetVirtualFunctions(). Unfortunately, a typo in the fix (replacing

[libvirt] [PATCH 0/2] Add version comparison method for virsh_version output

2013-04-09 Thread John Ferlan
I believe this set of patches should be applied instead of those from https://www.redhat.com/archives/libvirt-cim/2013-April/msg6.html I suppose we could consider combining the two functions; however, there are a couple place where the return version string is compared more than once, so I

[libvirt] [PATCH 1/2] vxml: Add which volume could not be found to error message

2013-04-09 Thread John Ferlan
--- suites/libvirt-cim/lib/XenKvmLib/vxml.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/suites/libvirt-cim/lib/XenKvmLib/vxml.py b/suites/libvirt-cim/lib/XenKvmLib/vxml.py index 51a4166..82ab501 100644 --- a/suites/libvirt-cim/lib/XenKvmLib/vxml.py +++

[libvirt] [PATCH 2/2] Add and utilize virsh_version_cmp

2013-04-09 Thread John Ferlan
The string version comparisons failed when determining if 0.10.2 was a greater version than 0.4.1 (and other similar checks). Needed to create a version comparison method that did the right thing. Also, not change to 12_create_netfs_storagevolume_errs.py to use or logic rather than and logic on

Re: [libvirt] [PATCH] Fix crash in virNetDevGetVirtualFunctions

2013-04-09 Thread Laine Stump
On 04/09/2013 02:21 PM, Eric Blake wrote: On 04/09/2013 12:15 PM, Laine Stump wrote: Commit 9a3ff01d7f16cc280ce3176620c0714f55511a65 (which was ACKed at the end of January, but for some reason didn't get pushed until during the 1.0.4 freeze) fixed the logic in virPCIGetVirtualFunctions().

Re: [libvirt] new libvirt pci controller type and pcie/q35 (was Re: [PATCH 4/7] add pci-bridge controller type)

2013-04-09 Thread Laine Stump
On 04/09/2013 04:58 AM, Daniel P. Berrange wrote: On Mon, Apr 08, 2013 at 03:32:07PM -0400, Laine Stump wrote: On 04/08/2013 12:48 PM, Daniel P. Berrange wrote: On Mon, Apr 08, 2013 at 12:37:49PM -0400, Laine Stump wrote: I think we're starting to get closer to the concrete problem that's

Re: [libvirt] [PATCH] Fix crash in virNetDevGetVirtualFunctions

2013-04-09 Thread Eric Blake
On 04/09/2013 12:41 PM, Laine Stump wrote: (I noticed there is a v1.0.4-maint branch so (although nothing else had been pushed there since the release of 1.0.4) I pushed this patch to that branch as well.) I pushed a few more patches into that branch. I don't know if Fedora 19 will end up on

Re: [libvirt] [PATCH] v2:Support for adding a static route to a bridge

2013-04-09 Thread Gene Czarcinski
On 04/04/2013 12:08 PM, Laine Stump wrote: On 04/03/2013 04:02 PM, Gene Czarcinski wrote: On 04/02/2013 03:31 PM, Laine Stump wrote: On 03/15/2013 02:10 PM, Gene Czarcinski wrote: This patch adds support for adding a static route for a network. The via specifies the gateway's IP address.

Re: [libvirt] [PATCH] Fix crash in virNetDevGetVirtualFunctions

2013-04-09 Thread Laine Stump
On 04/09/2013 04:08 PM, Eric Blake wrote: When pushing to a maint branch, remember to use 'cherry-pick -x', so that it is obvious which mainline patch you are backporting. Yeah, I always seem to remember that just *after* I push instead of just before :-( -- libvir-list mailing list

Re: [libvirt] [PATCH] maint: update to latest gnulib

2013-04-09 Thread Eric Blake
On 04/05/2013 02:34 AM, Daniel P. Berrange wrote: On Thu, Apr 04, 2013 at 08:33:16PM -0600, Eric Blake wrote: On 04/01/2013 12:55 PM, Eric Blake wrote: While this update doesn't address any reported problems in libvirt, doing a post-release update to latest gnulib makes it easier to stay in

[libvirt] (no subject)

2013-04-09 Thread arvind viswanathan
I wanted to check if event loop integration was supported even for remote applications using libvirt. My application would like to make non-blocking calls and also recv asynchronous notification remotely. Can some one point out if its supported. thanks -- libvir-list mailing list

Re: [libvirt] [PATCH] Reusing the result of virArchFromHost instead of calling it multiple times

2013-04-09 Thread Eric Blake
On 04/09/2013 12:38 AM, Tal Kain wrote: On Mon, Apr 8, 2013 at 4:32 PM, Daniel P. Berrange berra...@redhat.comwrote: On Mon, Apr 08, 2013 at 03:33:07PM +0300, Tal Kain wrote: Signed-off-by: Tal Kain tal.k...@ravellosystems.com --- src/qemu/qemu_capabilities.c | 13 +++-- 1 file

Re: [libvirt] [PATCH] Release VM lock before acquiring virDomainObjListPtr lock

2013-04-09 Thread Eric Blake
On 04/09/2013 07:13 AM, Eric Blake wrote: On 04/09/2013 03:08 AM, Daniel P. Berrange wrote: I'm trying to understand what the behavior was before this patch went in. Well this was just fixing a deadlock introduced in a previous patch. You need to look further back than just this patch.

Re: [libvirt] [PATCH 0/2] Add version comparison method for virsh_version output

2013-04-09 Thread Peter Krempa
On 04/09/13 20:33, John Ferlan wrote: I believe this set of patches should be applied instead of those from https://www.redhat.com/archives/libvirt-cim/2013-April/msg6.html I suppose we could consider combining the two functions; however, there are a couple place where the return version

[libvirt] [PATCH] docs: fix typo when using Kerberos principals

2013-04-09 Thread Eric Blake
Kerberos uses 'primary' or 'key' files (principals), not 'abstract ideal' (principles). Reported by Jason Meinzer. Reflow a paragraph to fit in 80 columns in the process. * docs/auth.html.in: Fix spelling. --- Pushing under the trivial rule. docs/auth.html.in | 18 ++ 1 file

Re: [libvirt] [PATCH 0/2] Add version comparison method for virsh_version output

2013-04-09 Thread Eric Blake
On 04/09/2013 04:35 PM, Peter Krempa wrote: On 04/09/13 20:33, John Ferlan wrote: I believe this set of patches should be applied instead of those from https://www.redhat.com/archives/libvirt-cim/2013-April/msg6.html I suppose we could consider combining the two functions; however, there

[libvirt] [PATCH 04/12] libxl: populate xenstore memory entries at startup

2013-04-09 Thread Marek Marczykowski
libxl uses some xenstore entries for hints in memory management (especially when starting new domain). This includes dom0 memory limit and Xen free memory margin, based on current system state. Entries are created at first usage, so force such usage at daemon startup, which most likely will be

[libvirt] [PATCH 03/12] libxl: nodeDevice* support for PCI devices

2013-04-09 Thread Marek Marczykowski
For now only for PCI devices. Mostly copy-paste from old xen driver. --- src/libxl/libxl_driver.c | 193 +++ 1 file changed, 193 insertions(+) diff --git a/src/libxl/libxl_driver.c b/src/libxl/libxl_driver.c index 40a7a6b..011edf8 100644 ---

[libvirt] [PATCH 00/12] A bunch of extensions to libxl driver

2013-04-09 Thread Marek Marczykowski
This are some additional features to libxl driver. Some of them require change in domain config structures/syntax. Details described with each patch. The last two patches are bugfix for deadlock during daemon startup. PS Please keep me in To/Cc - I'm not subscribed to the list. Marek

[libvirt] [PATCH 01/12] libxl: allow script for any network interface, not only bridge

2013-04-09 Thread Marek Marczykowski
This can be useful for route or NAT networks, or any other custom network setup. Especially configuration example in documentation uses script/ tag with type 'ethernet'. --- src/libxl/libxl_conf.c | 17 + 1 file changed, 5 insertions(+), 12 deletions(-) diff --git

[libvirt] [PATCH 08/12] libxl: support backend domain setting for disk and net devices

2013-04-09 Thread Marek Marczykowski
This implement handling of domain name=''/ parameter introduced in previous patch. Lookup on domain name (to get domain ID) requires libxlDriverPrivate object, so it must be passed down to libxlMakeDisk and libxlMakeNet from top level callers. --- src/libxl/libxl_conf.c | 62

[libvirt] [PATCH 11/12] conf: virDomainObjListRemoveLocked function

2013-04-09 Thread Marek Marczykowski
While iterating with virDomainObjListForEach it is safe to remove current element. But while iterating, 'doms' lock is already taken, so can't use standard virDomainObjListRemove. So introduce virDomainObjListRemoveLocked for this purpose. This is required to fix deadlock in libxl driver. ---

[libvirt] [PATCH 12/12] libxl: fix deadlock in libxlReconnectDomain

2013-04-09 Thread Marek Marczykowski
Use virDomainObjListRemoveLocked instead of virDomainObjListRemove, as driver-domains is already taken by virDomainObjListForEach. Above deadlock can be triggered when libvirtd is started after some domain have been started by hand (in which case driver will not find libvirt-xml domain config).

[libvirt] [PATCH 07/12] conf: support backend domain name in disk and network devices

2013-04-09 Thread Marek Marczykowski
At least Xen supports backend drivers in another domain (aka driver domain). This patch introduces XML config option for such setting as 'domain' element with 'name' attribute. Verification its content is left for the driver. In the future some option will be needed for USB devices (hostdev

[libvirt] [PATCH 10/12] RFC: libxl: special 'stubdom-dm' emulator to use qemu in stub domain

2013-04-09 Thread Marek Marczykowski
Xen have feature of having device model in separate domain (called stub domain). It used to be enabled by special 'stubdom-dm' device model path. Recent xl have separate config option for this feature (device_model_stubdomain_override), but I'm not sure if it worth introducing another xen-specific

[libvirt] [PATCH 05/12] conf: add 'script' attribute to disk specification

2013-04-09 Thread Marek Marczykowski
Script to be called to prepare custom device for domain. Done with Xen in mind, it maps to libxl_device_disk.script. XML configuration would be: disk type='block' device='disk' source dev='/dev/mapper/custom-device'/ script path='/script/to/setup/custom-device'/ target dev='xvdc'/

[libvirt] [PATCH 06/12] libxl: use disk 'script' attribute

2013-04-09 Thread Marek Marczykowski
Implement handling of previously introduced script/ element for disk config. This can be used for custom backend configuration like non-standard device-mapper nodes, or to prepare device in other domain (see the next patch). --- src/libxl/libxl_conf.c | 5 + 1 file changed, 5 insertions(+)

[libvirt] [PATCH 09/12] libxl: fill HVM SDL and VNC settings based on graphics/ entries

2013-04-09 Thread Marek Marczykowski
Vfb entries in domain config are used only by PV drivers. Qemu parameters are build based on b_info struct. So fill it with the same data as vfb entries (actually the first one). This will additionally allow graphic-less domain, when no graphics/ entries are present in domain XML (previously VNC

Re: [libvirt] [PATCH 00/12] A bunch of extensions to libxl driver

2013-04-09 Thread Eric Blake
On 04/09/2013 07:53 PM, Marek Marczykowski wrote: This are some additional features to libxl driver. Some of them require change in domain config structures/syntax. Details described with each patch. The last two patches are bugfix for deadlock during daemon startup. PS Please keep me in

[libvirt] [PATCH RESENT 01/12] libxl: allow script for any network interface, not only bridge

2013-04-09 Thread Marek Marczykowski
This can be useful for route or NAT networks, or any other custom network setup. Especially configuration example in documentation uses script/ tag with type 'ethernet'. --- src/libxl/libxl_conf.c | 17 + 1 file changed, 5 insertions(+), 12 deletions(-) diff --git

[libvirt] [PATCH RESENT 02/12] libxl: PCI passthrough support

2013-04-09 Thread Marek Marczykowski
--- src/libxl/libxl_conf.c | 72 ++ src/libxl/libxl_conf.h | 2 ++ 2 files changed, 74 insertions(+) diff --git a/src/libxl/libxl_conf.c b/src/libxl/libxl_conf.c index ffc7bbb..7668305 100644 --- a/src/libxl/libxl_conf.c +++

[libvirt] [PATCH RESENT 05/12] conf: add 'script' attribute to disk specification

2013-04-09 Thread Marek Marczykowski
Script to be called to prepare custom device for domain. Done with Xen in mind, it maps to libxl_device_disk.script. XML configuration would be: disk type='block' device='disk' source dev='/dev/mapper/custom-device'/ script path='/script/to/setup/custom-device'/ target dev='xvdc'/

[libvirt] [PATCH RESENT 06/12] libxl: use disk 'script' attribute

2013-04-09 Thread Marek Marczykowski
Implement handling of previously introduced script/ element for disk config. This can be used for custom backend configuration like non-standard device-mapper nodes, or to prepare device in other domain (see the next patch). --- src/libxl/libxl_conf.c | 5 + 1 file changed, 5 insertions(+)

[libvirt] [PATCH RESENT 07/12] conf: support backend domain name in disk and network devices

2013-04-09 Thread Marek Marczykowski
At least Xen supports backend drivers in another domain (aka driver domain). This patch introduces XML config option for such setting as 'domain' element with 'name' attribute. Verification its content is left for the driver. In the future some option will be needed for USB devices (hostdev

[libvirt] [PATCH RESENT 09/12] libxl: fill HVM SDL and VNC settings based on graphics/ entries

2013-04-09 Thread Marek Marczykowski
Vfb entries in domain config are used only by PV drivers. Qemu parameters are build based on b_info struct. So fill it with the same data as vfb entries (actually the first one). This will additionally allow graphic-less domain, when no graphics/ entries are present in domain XML (previously VNC

[libvirt] [PATCH RESENT 10/12] RFC: libxl: special 'stubdom-dm' emulator to use qemu in stub domain

2013-04-09 Thread Marek Marczykowski
Xen have feature of having device model in separate domain (called stub domain). It used to be enabled by special 'stubdom-dm' device model path. Recent xl have separate config option for this feature (device_model_stubdomain_override), but I'm not sure if it worth introducing another

[libvirt] [PATCH RESENT 11/12] conf: virDomainObjListRemoveLocked function

2013-04-09 Thread Marek Marczykowski
While iterating with virDomainObjListForEach it is safe to remove current element. But while iterating, 'doms' lock is already taken, so can't use standard virDomainObjListRemove. So introduce virDomainObjListRemoveLocked for this purpose. --- src/conf/domain_conf.c | 17 +

[libvirt] [PATCH 00/12] A bunch of extensions to libxl driver

2013-04-09 Thread Marek Marczykowski
This are some additional features to libxl driver. Some of them require change in domain config structures/syntax. Details described with each patch. The last two patches are bugfix for deadlock during daemon startup. Marek Marczykowski (12): libxl: allow script for any network interface, not

[libvirt] [PATCH RESENT 03/12] libxl: nodeDevice* support for PCI devices

2013-04-09 Thread Marek Marczykowski
For now only for PCI devices. Mostly copy-paste from old xen driver. --- src/libxl/libxl_driver.c | 193 +++ 1 file changed, 193 insertions(+) diff --git a/src/libxl/libxl_driver.c b/src/libxl/libxl_driver.c index 40a7a6b..011edf8 100644 ---

Re: [libvirt] [PATCH 00/12] A bunch of extensions to libxl driver

2013-04-09 Thread Marek Marczykowski
On 10.04.2013 04:34, Eric Blake wrote: On 04/09/2013 07:53 PM, Marek Marczykowski wrote: This are some additional features to libxl driver. Some of them require change in domain config structures/syntax. Details described with each patch. The last two patches are bugfix for deadlock during

[libvirt] [PATCH RESENT 12/12] libxl: fix deadlock in libxlReconnectDomain

2013-04-09 Thread Marek Marczykowski
Use virDomainObjListRemoveLocked instead of virDomainObjListRemove, as driver-domains is already taken by virDomainObjListForEach. Above deadlock can be triggered when libvirtd is started after some domain have been started by hand (in which case driver will not find libvirt-xml domain config).

Re: [libvirt] [PATCH v4 1/2] Add USB option capability

2013-04-09 Thread Li Zhang
Hi Daniel, Would you help review this ? I have added the test case in [PTACH v4 2/2]. Thanks. :) On 2013年04月07日 16:31, Li Zhang wrote: From: Li Zhang zhlci...@linux.vnet.ibm.com To avoid the collision for creating USB controllers in machine-init() and -device xx command line, it needs to set

Re: [libvirt] [PATCH v4 2/2]testcase: Add a new USB option test case

2013-04-09 Thread Li Zhang
Hi Daniel, Would you please help review this patch? Thanks. :) On 2013年04月07日 16:31, Li Zhang wrote: From: Li Zhang zhlci...@linux.vnet.ibm.com Add one test case to test CLI with -machine xxx,usb=off. Signed-off-by: Li Zhang zhlci...@linux.vnet.ibm.com ---