Re: [libvirt] [PATCH 5/6] qemu: Reduce memlock limit after detaching hostdev

2015-12-10 Thread John Ferlan
On 12/10/2015 10:03 AM, Andrea Bolognani wrote: > On Wed, 2015-12-09 at 15:15 -0500, John Ferlan wrote: >> On 11/24/2015 08:56 AM, Andrea Bolognani wrote: >>> We increase the limit before plugging in a PCI hostdev or a memory >>> module because some memory might need to be locked due to eg.

Re: [libvirt] [PATCH v2 07/10] conf: Optionally keep domains with invalid XML, but don't allow starting them

2015-12-10 Thread John Ferlan
On 12/01/2015 12:35 PM, Martin Kletzander wrote: > Add new parameter to virDomainObjListLoadConfig() and > virDomainObjListLoadAllConfigs() that controls whether domains with > invalid XML (which could not be parsed) should be kept in order not to > lose track of them. For now, the parameter is

Re: [libvirt] [PATCH v2 06/10] conf: Extract UUID parsing into its own function

2015-12-10 Thread John Ferlan
On 12/01/2015 12:35 PM, Martin Kletzander wrote: > Create virDomainDefParseUUID that parses only the UUID from XML > definition. This will be used in future patch(es). > > Signed-off-by: Martin Kletzander > --- > src/conf/domain_conf.c | 64 >

Re: [libvirt] [PATCH 00/10] VFIO fixes for PCI devices

2015-12-10 Thread Andrea Bolognani
On Wed, 2015-12-09 at 08:09 -0700, Alex Williamson wrote: > > I was under the impression that what the current series > > does, eg. sharing devices in the same IOMMU group between > > the host driver and vfio-pci is safe as long as no guest is > > using them at the same time, and that devices

Re: [libvirt] [PATCH v2 03/10] virsh: Add support for list -reason

2015-12-10 Thread John Ferlan
On 12/01/2015 12:35 PM, Martin Kletzander wrote: > Add new parameter for the list command, --reason. This adds another > optional column in the table output of listed domains. > > Signed-off-by: Martin Kletzander > --- > tests/virshtest.c| 16

Re: [libvirt] [PATCH v2 00/10] Make loading domains with invalid XML possible

2015-12-10 Thread John Ferlan
On 12/01/2015 12:35 PM, Martin Kletzander wrote: > We always had to deal with new parsing errors in a weird way. All of > them needed to go into functions starting the domains. That messes up > the code, it's confusing to newcomers and so on. > > I once had an idea that we can handle this

Re: [libvirt] [PATCH v2 02/10] virsh: Refactor the table output of the list command

2015-12-10 Thread John Ferlan
On 12/01/2015 12:35 PM, Martin Kletzander wrote: > Clean up some duplicate code so it is easier to add new parameters. The > tests need to be adjusted because after this patch there will be > additional spaces at the end of lines in the output of virsh list, but > this affects only the table

Re: [libvirt] [PATCH 4/6] qemu: Use qemuDomainAdjustMaxMemLock()

2015-12-10 Thread John Ferlan
On 12/10/2015 05:43 AM, Andrea Bolognani wrote: > On Wed, 2015-12-09 at 15:15 -0500, John Ferlan wrote: >> On 11/24/2015 08:56 AM, Andrea Bolognani wrote: >>> Replace all uses of the qemuDomainRequiresMlock/virProcessSetMaxMemLock >>> combination with the equivalent qemuDomainAdjustMaxMemLock()

Re: [libvirt] [PATCH 4/6] qemu: Use qemuDomainAdjustMaxMemLock()

2015-12-10 Thread Andrea Bolognani
On Wed, 2015-12-09 at 15:15 -0500, John Ferlan wrote: > On 11/24/2015 08:56 AM, Andrea Bolognani wrote: > > Replace all uses of the qemuDomainRequiresMlock/virProcessSetMaxMemLock > > combination with the equivalent qemuDomainAdjustMaxMemLock() call. > > --- > >  src/qemu/qemu_hotplug.c | 40

Re: [libvirt] [PATCH] vz: Allow to create container based on template

2015-12-10 Thread Mikhail Feoktistov
24.11.2015 17:14, Dmitry Guryanov пишет: On Thu, 2015-11-19 at 14:44 +0300, Mikhail Feoktistov wrote: We shouldn't delete disk from default config if we create container based on template, because we don't have the new disk from XML, only template name. And don't add template section from XML

Re: [libvirt] [PATCH v2 0/7] Add multiqueue support for macvtaps

2015-12-10 Thread Laine Stump
On 12/10/2015 02:38 AM, Michal Privoznik wrote: Patches 1, 2, 3, 6, 7 have been ACKed in previous round. However, I did slightly change them to reflect Laine's review suggestions. Patch 4 has not been ACKed yet, patch 5 is new. Michal Privoznik (7): virNetDevMacVLanCreateWithVPortProfile:

Re: [libvirt] [PATCH 5/6] qemu: Reduce memlock limit after detaching hostdev

2015-12-10 Thread John Ferlan
On 12/10/2015 12:36 PM, Andrea Bolognani wrote: > On Thu, 2015-12-10 at 12:11 -0500, John Ferlan wrote: Since the add was in qemuDomainAttachHostPCIDevice, why is the remove not in qemuDomainDetachHostPCIDevice? Doing it here would mean it's call for any host device removal -

Re: [libvirt] [PATCH v3] storage sheepdog: allow to specify redundancy level

2015-12-10 Thread John Ferlan
On 11/19/2015 03:44 AM, Vasiliy Tolstov wrote: > Some storage backends allows to specify per volume redundancy options. > Sheepdog use x format for specify copies, and x:y format to specify > data and parity block count. So you may understand what redundancy is, but I don't believe it's

[libvirt] [PATCH 4/8] qemu_driver: add support to perf event

2015-12-10 Thread Qiaowei Ren
This patch implement the internal driver API for perf event into qemu driver. Signed-off-by: Qiaowei Ren --- include/libvirt/libvirt-domain.h | 1 + src/qemu/qemu_domain.h | 3 + src/qemu/qemu_driver.c | 133 +++

[libvirt] [PATCH v1] libvirtd: Increase NL buffer size for lots of interface

2015-12-10 Thread Leno Hou
1. When switching CPUs to offline/online in a system more than 128 cpus 2. When using virsh to destroy domain in a system with more interface All of above happens nl_recv returned with error: No buffer space available. This patch set socket buffer size to 128K and turn on message peeking for

[libvirt] [PATCH 0/8] Add perf and Intel CMT feature support

2015-12-10 Thread Qiaowei Ren
The series mainly adds Intel CMT feature support into libvirt. CMT is new introduced PQos (Platform Qos) feature to monitor the usage of cache by applications running on the platform. Currently CMT patches has been merged into Linux kernel mainline. The CMT implementation in Linux kernel is based

Re: [libvirt] [PATCH 2/6] process: Add virProcessGetMaxMemLock()

2015-12-10 Thread John Ferlan
On 12/10/2015 11:33 AM, Andrea Bolognani wrote: > On Wed, 2015-12-09 at 12:00 -0500, John Ferlan wrote: >> On 11/24/2015 08:56 AM, Andrea Bolognani wrote: >>> @@ -788,6 +788,48 @@ virProcessSetMaxMemLock(pid_t pid ATTRIBUTE_UNUSED, >>> unsigned long long bytes) >>> } >>> #endif /* !

Re: [libvirt] [PATCH 5/6] qemu: Reduce memlock limit after detaching hostdev

2015-12-10 Thread Andrea Bolognani
On Thu, 2015-12-10 at 12:11 -0500, John Ferlan wrote: > > > Since the add was in qemuDomainAttachHostPCIDevice, why is the remove > > > not in qemuDomainDetachHostPCIDevice?  Doing it here would mean it's > > > call for any host device removal - whether or not it was ever added. > > > > Because

Re: [libvirt] [PATCH v4 10/10] Wait for iommmu device to go away before reprobing the host driver

2015-12-10 Thread Shivaprasad bhat
On Fri, Nov 20, 2015 at 9:07 PM, Laine Stump wrote: > On 11/14/2015 03:39 AM, Shivaprasad G Bhat wrote: >> >> There could be a delay of 1 or 2 seconds before the vfio-pci driver >> is unbound and the device file /dev/vfio/ is actually >> removed. If the file exists, the host

Re: [libvirt] [PATCH 3/6] qemu: Add qemuDomainAdjustMaxMemLock()

2015-12-10 Thread Andrea Bolognani
On Wed, 2015-12-09 at 12:19 -0500, John Ferlan wrote: > On 11/24/2015 08:56 AM, Andrea Bolognani wrote: > > This function detects whether a domain needs RLIMIT_MEMLOCK > > to be set, and if so, uses an appropriate value. > > > > It also stores the original value inside the virDomainObj for > >

[libvirt] [PATCH 05/10] tests: use virtTestDifferenceFull in tests where we have output file

2015-12-10 Thread Pavel Hrdina
This will enable regenerate functionality for those tests to make developer lives easier while updating tests. Signed-off-by: Pavel Hrdina --- tests/domainsnapshotxml2xmltest.c | 2 +- tests/interfacexml2xmltest.c | 2 +- tests/lxcconf2xmltest.c | 2 +-

[libvirt] [PATCH 01/10] xen: move virDomainDefPostParse to xenParseSxpr

2015-12-10 Thread Pavel Hrdina
This patch partially reverts previous commit 91a00424 and moves the post parse function to xenParseSxpr. This update is required because xen driver calls xenParseSxpr directly. Signed-off-by: Pavel Hrdina --- src/xen/xend_internal.c | 6 -- src/xenconfig/xen_sxpr.c |

[libvirt] [PATCH 06/10] tests: skip regeneration for problematic test

2015-12-10 Thread Pavel Hrdina
While parsing qemu command line, we don't support parsing everything and some staff cannot be parsed out of the command line. Skip regenerating expected output for those tests. Signed-off-by: Pavel Hrdina --- tests/qemuargv2xmltest.c | 13 - tests/testutils.c

[libvirt] [PATCH 09/10 v2] device: cleanup input device code

2015-12-10 Thread Pavel Hrdina
The current code was a little bit odd. At first we've removed all possible implicit input devices from domain definition to add them later back if there was any graphics device defined while parsing XML description. That's not all, while formating domain definition to XML description we at first

[libvirt] [PATCH 03/10] tests.testutils: use VIR_TEST_REGENERATE_OUTPUT for virTestDifferenceFull

2015-12-10 Thread Pavel Hrdina
This patch enable regeneration of expected output file for virTestDifferenceFull. It also introduces new virTestDifferenceFullNoRegenerate function for special cases, where we don't want to regenerate output. Signed-off-by: Pavel Hrdina --- tests/qemuxml2xmltest.c | 8

[libvirt] [PATCH 04/10] tests.testutils: use virTestDifferenceFull in virtTestCompareToFile

2015-12-10 Thread Pavel Hrdina
Let's use the new virTestDifferenceFull function that will regenerate the expected output and fail the test to let developer know that there something was updated. Signed-off-by: Pavel Hrdina --- tests/testutils.c | 10 +++--- 1 file changed, 3 insertions(+), 7

[libvirt] [PATCH] Revert "admin: Rename virAdmConnect to virAdmDaemon"

2015-12-10 Thread Erik Skultety
Commmit df8192aa introduced admin related rename and some minor (caused by automated approach, aka sed) and some more severe isues along with it. First reason to revert is the inconsistency with libvirt library. Although we deal with the daemon directly rather than with a specific hypervisor, we

[libvirt] [PATCH] qemu: align the cur_balloon too if not explicitly specified by the user

2015-12-10 Thread Shivaprasad G Bhat
As of now, the cur_ballon is set to actual memory if not specified by the user. When the user specified memory is not aligned the cur_balloon alone ends up unaligned. For qemu in function qemuDomainAttachMemory(), the cur_balloon wouldn't add up to the actual memory as the cur_ballon was not

Re: [libvirt] [PATCH 3/6] qemu: Add qemuDomainAdjustMaxMemLock()

2015-12-10 Thread Andrea Bolognani
On Wed, 2015-12-09 at 13:02 -0500, John Ferlan wrote: > On 11/24/2015 08:56 AM, Andrea Bolognani wrote: > [...] > > > +} > > + > > +/* Don't do anything unless we're actually setting a limit */ > > +if (bytes) { > > +if (virProcessSetMaxMemLock(vm->pid, bytes) < 0) > > +   

Re: [libvirt] [PATCH 2/6] process: Add virProcessGetMaxMemLock()

2015-12-10 Thread Andrea Bolognani
On Wed, 2015-12-09 at 12:00 -0500, John Ferlan wrote: > On 11/24/2015 08:56 AM, Andrea Bolognani wrote: > > @@ -788,6 +788,48 @@ virProcessSetMaxMemLock(pid_t pid ATTRIBUTE_UNUSED, > > unsigned long long bytes) > >  } > >  #endif /* ! (HAVE_SETRLIMIT && defined(RLIMIT_MEMLOCK)) */ > >   > > +#if