Re: [libvirt] [PATCH v2 08/12] qemu: Add length for bps/iops throttling parameters to driver

2016-10-25 Thread John Ferlan
On 10/25/2016 01:30 PM, Erik Skultety wrote: > On Thu, Oct 06, 2016 at 06:38:56PM -0400, John Ferlan wrote: >> Add support for a duration/length for the bps/iops and friends. >> >> Modify the API in order to add the "blkdeviotune." specific definitions >> for the iotune throttling

Re: [libvirt] [PATCH v2 11/12] virsh: Create a macro to add IOTUNE values

2016-10-25 Thread John Ferlan
On 10/25/2016 01:44 PM, Erik Skultety wrote: > On Thu, Oct 06, 2016 at 06:38:59PM -0400, John Ferlan wrote: >> Rework the repetitive lines to add iotune values into easier to read macro >> >> Signed-off-by: John Ferlan >> --- >> tools/virsh-domain.c | 141 >>

Re: [libvirt] [PATCH v11 2/5] qemu: Swap order of RNG hot unplug removal

2016-10-25 Thread Pavel Hrdina
On Tue, Oct 25, 2016 at 03:57:34PM -0400, John Ferlan wrote: > > > On 10/25/2016 08:48 AM, Pavel Hrdina wrote: > > On Mon, Oct 24, 2016 at 06:46:18PM -0400, John Ferlan wrote: > >> Rather than remove the frontend first and then the backend, let's swap the > >> order. The order of addition is add

Re: [libvirt] [PATCH v11 3/5] qemu: Need to remove TLS object in RemoveRNGDevice

2016-10-25 Thread John Ferlan
On 10/25/2016 12:04 PM, Pavel Hrdina wrote: > On Tue, Oct 25, 2016 at 09:19:58AM -0400, John Ferlan wrote: >> >> >> On 10/25/2016 08:53 AM, Pavel Hrdina wrote: >>> On Mon, Oct 24, 2016 at 06:46:19PM -0400, John Ferlan wrote: Commit id '6e6b4bfc' added the object, but forgot the other end.

[libvirt] [PATCH] qemu: Fix depedency order in qemuRemoveDiskDevice

2016-10-25 Thread John Ferlan
Need to remove the drive first, then the secobj and/or encobj if they exist. This is because the drive has a dependency on secobj (or the secret for the networked storage server) and/or the encobj (or the secret for the LUKS encrypted volume). Deleting either object first leaves an drive without

Re: [libvirt] [PATCH v11 2/5] qemu: Swap order of RNG hot unplug removal

2016-10-25 Thread John Ferlan
On 10/25/2016 08:48 AM, Pavel Hrdina wrote: > On Mon, Oct 24, 2016 at 06:46:18PM -0400, John Ferlan wrote: >> Rather than remove the frontend first and then the backend, let's swap the >> order. The order of addition is add the chardev backend if EGD being used, >> then add the RNG object. So

Re: [libvirt] [PATCH v11 1/5] qemu: Move TLS object remove from DetachChr to RemoveChr

2016-10-25 Thread John Ferlan
On 10/25/2016 08:42 AM, Pavel Hrdina wrote: > On Mon, Oct 24, 2016 at 06:46:17PM -0400, John Ferlan wrote: >> Commit id '2c32237' added the TLS object removal to the DetachChrDevice >> all when it should have been added to the RemoveChrDevice since that's >> the norm for similar processing (e.g.

Re: [libvirt] question about rdma migration

2016-10-25 Thread Roy Shterman
Hi Jiri, Sorry about the late response, only now I managed to push iSER into QEMU. Because ISER is registered as a different protocol than iSCSI with the prefix of iser:// I want to add support for it in libvirt. Libvirt code is pretty new for me, wondered if adding VIR_STORAGE_NET_PROTOCOL_ISER

Re: [libvirt] [PATCH v5 03/15] qemu: set/use info->pciConnectFlags when validating/assigning PCI addresses

2016-10-25 Thread Laine Stump
On 10/25/2016 12:53 PM, Andrea Bolognani wrote: On Tue, 2016-10-25 at 09:49 -0400, Laine Stump wrote: Set pciConnectFlags in each device's DeviceInfo and then use those flags later when validating existing addresses in qemuDomainCollectPCIAddress() and when assigning new addresses with

Re: [libvirt] [PATCH v2 12/12] virsh: Add _length parameters to virsh output

2016-10-25 Thread Erik Skultety
On Thu, Oct 06, 2016 at 06:39:00PM -0400, John Ferlan wrote: > https://bugzilla.redhat.com/show_bug.cgi?id=1349898 > > Add the duration parameters to the virsh input/output for blkdeviotune > command and describe them in the pod file. > > Signed-off-by: John Ferlan > --- >

Re: [libvirt] [PATCH v2 11/12] virsh: Create a macro to add IOTUNE values

2016-10-25 Thread Erik Skultety
On Thu, Oct 06, 2016 at 06:38:59PM -0400, John Ferlan wrote: > Rework the repetitive lines to add iotune values into easier to read macro > > Signed-off-by: John Ferlan > --- > tools/virsh-domain.c | 141 > +-- > 1 file

Re: [libvirt] [PATCH v2 10/12] qemu: Add the length options to the iotune command line

2016-10-25 Thread Erik Skultety
On Thu, Oct 06, 2016 at 06:38:58PM -0400, John Ferlan wrote: > Add in the block I/O throttling length/duration parameter to the command > line if supported. If not supported, fail command creation. > > Add the xml2argvtest for testing. > > Signed-off-by: John Ferlan > --- >

Re: [libvirt] [PATCH v2 09/12] conf: Add support for blkiotune "_length" options

2016-10-25 Thread Erik Skultety
On Thu, Oct 06, 2016 at 06:38:57PM -0400, John Ferlan wrote: > Modify _virDomainBlockIoTuneInfo and rng schema to support the _length > options for bps/iops throttling values. Document the new values. > > Signed-off-by: John Ferlan > --- > docs/formatdomain.html.in

Re: [libvirt] [PATCH v2 08/12] qemu: Add length for bps/iops throttling parameters to driver

2016-10-25 Thread Erik Skultety
On Thu, Oct 06, 2016 at 06:38:56PM -0400, John Ferlan wrote: > Add support for a duration/length for the bps/iops and friends. > > Modify the API in order to add the "blkdeviotune." specific definitions > for the iotune throttling duration/length options > > total_bytes_sec_max_length >

Re: [libvirt] [PATCH v5 03/15] qemu: set/use info->pciConnectFlags when validating/assigning PCI addresses

2016-10-25 Thread Andrea Bolognani
On Tue, 2016-10-25 at 09:49 -0400, Laine Stump wrote: > Set pciConnectFlags in each device's DeviceInfo and then use those > flags later when validating existing addresses in > qemuDomainCollectPCIAddress() and when assigning new addresses with > qemuDomainPCIAddressReserveNextAddr() (rather than

Re: [libvirt] [PATCH v11 3/5] qemu: Need to remove TLS object in RemoveRNGDevice

2016-10-25 Thread Pavel Hrdina
On Tue, Oct 25, 2016 at 09:19:58AM -0400, John Ferlan wrote: > > > On 10/25/2016 08:53 AM, Pavel Hrdina wrote: > > On Mon, Oct 24, 2016 at 06:46:19PM -0400, John Ferlan wrote: > >> Commit id '6e6b4bfc' added the object, but forgot the other end. > >> > >> Signed-off-by: John Ferlan

Re: [libvirt] [PATCH python 1/1] fix crash in libvirt_virDomainPin*

2016-10-25 Thread Martin Kletzander
On Tue, Oct 25, 2016 at 12:42:23PM +0300, Konstantin Neumoin wrote: If we pass large(more than cpunum) cpu mask to any libvirt_virDomainPin* methods, it could leads to crash. So we have to check tuple size and ignore extra tuple members. Signed-off-by: Konstantin Neumoin

[libvirt] [PATCH v5 03/15] qemu: set/use info->pciConnectFlags when validating/assigning PCI addresses

2016-10-25 Thread Laine Stump
Set pciConnectFlags in each device's DeviceInfo and then use those flags later when validating existing addresses in qemuDomainCollectPCIAddress() and when assigning new addresses with qemuDomainPCIAddressReserveNextAddr() (rather than scattering the logic about which devices need which type of

[libvirt] [PATCH v5 09/15] [ACKED] qemu: only force an available legacy-PCI slot on domains with pci-root

2016-10-25 Thread Laine Stump
Andrea had the right idea when he disabled the "reserve an extra unused slot" bit for aarch64/virt. For *any* PCI Express-based machine, it is pointless since 1) an extra legacy-PCI slot can't be used for hotplug, since hotplug into legacy PCI slots doesn't work on PCI Express machinetypes, and 2)

[libvirt] [PATCH v5 15/15] qemu: initially reserve one open pcie-root-port for hotplug

2016-10-25 Thread Laine Stump
For machinetypes with a pci-root bus (all legacy PCI), libvirt will make a "fake" reservation for one extra slot prior to assigning addresses to unaddressed PCI endpoint devices in the domain. This will trigger auto-adding of a pci-bridge for the final device to be assigned an address *if that

[libvirt] [PATCH v5 08/15] qemu: assign nec-xhci (USB3) controller to a PCIe address when appropriate

2016-10-25 Thread Laine Stump
The nec-usb-xhci device (which is a USB3 controller) has always presented itself as a PCI device when plugged into a legacy PCI slot, and a PCIe device when plugged into a PCIe slot, but libvirt has always auto-assigned it to a legacy PCI slot. This patch changes that behavior to auto-assign to a

[libvirt] [PATCH v5 11/15] [RFC] qemu: if pci-bridge is in PCIe config w/o dmi-to-pci-bridge, add it

2016-10-25 Thread Laine Stump
I'm undecided if it is worthwhile to add this... Up until now it has been legal to have something like this in the xml: (for example, see the existing test case "usb-controller-default-q35"). This is handled in qemuDomainPCIAddressSetCreate() when it's adding in controllers to fill holes

[libvirt] [PATCH v5 12/15] [ACKED] qemu: don't force-add a dmi-to-pci-bridge just on principle

2016-10-25 Thread Laine Stump
Now the a dmi-to-pci-bridge is automatically added just as it's needed (when a pci-bridge is being added), we no longer have any need to force-add one to every single Q35 domain. --- src/qemu/qemu_domain.c | 12 tests/qemuxml2argvdata/qemuxml2argv-pcie-root.args |

[libvirt] [PATCH v5 04/15] qemu: set/use proper pciConnectFlags during hotplug

2016-10-25 Thread Laine Stump
Before now, all the qemu hotplug functions assumed that all devices to be hotplugged were legacy PCI endpoint devices (VIR_PCI_CONNECT_TYPE_PCI_DEVICE). This worked out "okay", because all devices *are* legacy PCI endpoint devices on x86/440fx machinetypes, and hotplug didn't work properly on

[libvirt] [PATCH v5 13/15] [ACKED] qemu: add a USB3 controller to Q35 domains by default

2016-10-25 Thread Laine Stump
Previously we added a set of EHCI+UHCI controllers to Q35 machines to mimic real hardware as closely as possible, but recent discussions have pointed out that the nec-usb-xhci (USB3) controller is much more virtualization-friendly (uses less CPU), so this patch switches the default for Q35

[libvirt] [PATCH v5 07/15] qemu: assign e1000e network devices to PCIe slots when appropriate

2016-10-25 Thread Laine Stump
The e1000e is an emulated network device based on the Intel 82574, present in qemu 2.7.0 and later. Among other differences from the e1000, it presents itself as a PCIe device rather than legacy PCI. In order to get it assigned to a PCIe controller, this patch updates the flags setting for network

[libvirt] [PATCH v5 14/15] [ACKED] qemu: try to put ich9 sound device at 00:1B.0

2016-10-25 Thread Laine Stump
Real Q35 hardware has an ICH9 chip that includes several integrated devices at particular addresses (see the file docs/q35-chipset.cfg in the qemu source). libvirt already attempts to put the first two sets of ich9 USB2 controllers it finds at 00:1D.* and 00:1A.* to match the real hardware. This

[libvirt] [PATCH v5 01/15] qemu: new functions qemuDomainMachineHasPCI[e]Root()

2016-10-25 Thread Laine Stump
These functions provide a simple one line method of learning if the current domain has a pci-root or pcie-root bus. --- src/qemu/qemu_domain.c | 30 ++ src/qemu/qemu_domain.h | 2 ++ 2 files changed, 32 insertions(+) diff --git a/src/qemu/qemu_domain.c

[libvirt] [PATCH v5 10/15] qemu: auto-add pcie-root-port/dmi-to-pci-bridge controllers as needed

2016-10-25 Thread Laine Stump
Previously libvirt would only add pci-bridge devices automatically when an address was requested for a device that required a legacy PCI slot and none was available. This patch expands that support to dmi-to-pci-bridge (which is needed in order to add a pci-bridge on a machine with a pcie-root),

[libvirt] [PATCH v5 05/15] qemu: set pciConnectFlags to 0 instead of PCI|HOTPLUGGABLE if device isn't PCI

2016-10-25 Thread Laine Stump
This patch cleans up the connect flags for certain types/models of devices that aren't PCI to return 0. In the future that may be used as an indicator to the caller about whether or not a device needs a PCI address. For now it's just ignored, except for in virDomainPCIAddressEnsureAddr() - called

[libvirt] [PATCH v5 00/15] Use more PCIe less legacy PCI

2016-10-25 Thread Laine Stump
These are just the rebased versions of the patches from v4 that I haven't yet pushed, to make review easier. Patch 1 and 2 (and several others) are already ACKed, but included for completeness. Laine Stump (15): qemu: new functions qemuDomainMachineHasPCI[e]Root() qemu: new functions to

[libvirt] [PATCH v5 06/15] qemu: assign virtio devices to PCIe slot when appropriate

2016-10-25 Thread Laine Stump
libvirt previously assigned nearly all devices to a "hotpluggable" legacy PCI slot even on machines with a PCIe root bus (and even though most such machines don't even support hotplug on legacy PCI slots!) Forcing all devices onto legacy PCI slots means that the domain will need a

[libvirt] [PATCH v5 02/15] qemu: new functions to calculate/set device pciConnectFlags

2016-10-25 Thread Laine Stump
The lowest level function of this trio (qemuDomainDeviceCalculatePCIConnectFlags()) aims to be the single authority for the virDomainPCIConnectFlags to use for any given device using a particular arch/machinetype/qemu-binary. qemuDomainFillDevicePCIConnectFlags() sets info->pciConnectFlags in a

Re: [libvirt] [PATCH v2 07/12] caps: Add new capability for the bps/iops throttling length

2016-10-25 Thread Erik Skultety
On Thu, Oct 06, 2016 at 06:38:55PM -0400, John Ferlan wrote: > Add the capability to detect if the qemu binary can support the feature > to use bps-max-length and friends. > > Signed-off-by: John Ferlan > --- this patch caused a rebase conflict but you'd come across that for

Re: [libvirt] [PATCH v2 04/12] qemu: Introduce qemuDomainSetBlockIoTuneSetDefaults

2016-10-25 Thread John Ferlan
On 10/25/2016 09:05 AM, Erik Skultety wrote: > On Thu, Oct 06, 2016 at 06:38:52PM -0400, John Ferlan wrote: >> Create a helper to set the bytes/iops iotune default values based on >> the current qemu setting >> >> Signed-off-by: John Ferlan >> --- >> src/qemu/qemu_driver.c

Re: [libvirt] [PATCH v11 3/5] qemu: Need to remove TLS object in RemoveRNGDevice

2016-10-25 Thread John Ferlan
On 10/25/2016 08:53 AM, Pavel Hrdina wrote: > On Mon, Oct 24, 2016 at 06:46:19PM -0400, John Ferlan wrote: >> Commit id '6e6b4bfc' added the object, but forgot the other end. >> >> Signed-off-by: John Ferlan >> --- >> src/qemu/qemu_hotplug.c | 12 +++- >> 1 file

Re: [libvirt] [PATCH v4 12/25] qemu: new functions to calculate/set device pciConnectFlags

2016-10-25 Thread Andrea Bolognani
On Fri, 2016-10-14 at 15:54 -0400, Laine Stump wrote: > The lowest level function of this trio > (qemuDomainDeviceCalculatePCIConnectFlags()) aims to be the single > authority for the virDomainPCIConnectFlags to use for any given device > using a particular arch/machinetype/qemu-binary. >  >

Re: [libvirt] [PATCH v2 04/12] qemu: Introduce qemuDomainSetBlockIoTuneSetDefaults

2016-10-25 Thread Erik Skultety
On Thu, Oct 06, 2016 at 06:38:52PM -0400, John Ferlan wrote: > Create a helper to set the bytes/iops iotune default values based on > the current qemu setting > > Signed-off-by: John Ferlan > --- > src/qemu/qemu_driver.c | 66 >

Re: [libvirt] [PATCH v2 05/12] qemu: Use qemuDomainsetBlockIoTuneSetDefaults for config

2016-10-25 Thread Erik Skultety
On Thu, Oct 06, 2016 at 06:38:53PM -0400, John Ferlan wrote: > Rather than repeat the lines in the persistent def, use the same helper > to set config values. > > This also fixes a bug where config values for *_max and size_iops_sec would > be set back to 0 if a config value was set. Is there a

Re: [libvirt] [PATCH v11 3/5] qemu: Need to remove TLS object in RemoveRNGDevice

2016-10-25 Thread Pavel Hrdina
On Mon, Oct 24, 2016 at 06:46:19PM -0400, John Ferlan wrote: > Commit id '6e6b4bfc' added the object, but forgot the other end. > > Signed-off-by: John Ferlan > --- > src/qemu/qemu_hotplug.c | 12 +++- > 1 file changed, 11 insertions(+), 1 deletion(-) ACK if you

Re: [libvirt] [PATCH v11 2/5] qemu: Swap order of RNG hot unplug removal

2016-10-25 Thread Pavel Hrdina
On Mon, Oct 24, 2016 at 06:46:18PM -0400, John Ferlan wrote: > Rather than remove the frontend first and then the backend, let's swap the > order. The order of addition is add the chardev backend if EGD being used, > then add the RNG object. So there's a dependency there. When we remove, > unplug

Re: [libvirt] [PATCH v11 1/5] qemu: Move TLS object remove from DetachChr to RemoveChr

2016-10-25 Thread Pavel Hrdina
On Mon, Oct 24, 2016 at 06:46:17PM -0400, John Ferlan wrote: > Commit id '2c32237' added the TLS object removal to the DetachChrDevice > all when it should have been added to the RemoveChrDevice since that's > the norm for similar processing (e.g. disk) > > Signed-off-by: John Ferlan

Re: [libvirt] [RFC] qemu: Use virtio-pci by default for mach-virt guests

2016-10-25 Thread Pavel Hrdina
On Tue, Oct 25, 2016 at 02:10:37PM +0200, Martin Kletzander wrote: > On Mon, Oct 24, 2016 at 06:24:07PM +0200, Andrea Bolognani wrote: > >On Mon, 2016-10-24 at 17:47 +0200, Pavel Hrdina wrote: > >> > > I like that this makes pci truly the default in a simple manner, but  > >> > > still allows

Re: [libvirt] [PATCH 1/1] qemu: host NUMA hugepage policy without guest NUMA

2016-10-25 Thread Martin Kletzander
On Tue, Oct 25, 2016 at 01:10:23PM +1100, Sam Bobroff wrote: On Tue, Oct 18, 2016 at 10:43:31PM +0200, Martin Kletzander wrote: On Mon, Oct 17, 2016 at 03:45:09PM +1100, Sam Bobroff wrote: >On Fri, Oct 14, 2016 at 10:19:42AM +0200, Martin Kletzander wrote: >>On Fri, Oct 14, 2016 at 11:52:22AM

Re: [libvirt] [RFC] qemu: Use virtio-pci by default for mach-virt guests

2016-10-25 Thread Martin Kletzander
On Mon, Oct 24, 2016 at 06:24:07PM +0200, Andrea Bolognani wrote: On Mon, 2016-10-24 at 17:47 +0200, Pavel Hrdina wrote: > > I like that this makes pci truly the default in a simple manner, but  > > still allows switching back to mmio if necessary. On the other hand, it  > > puts the potential

Re: [libvirt] [PATCH 5/6] Fix crash on usb-serial hotplug

2016-10-25 Thread John Ferlan
On 10/21/2016 09:58 AM, Ján Tomko wrote: > For domains with no USB address cache, we should not attempt > to generate a USB address. > > https://bugzilla.redhat.com/show_bug.cgi?id=1387665 > --- > src/qemu/qemu_hotplug.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > ACK John

Re: [libvirt] [PATCH 6/6] Do not try to release virtio serial addresses

2016-10-25 Thread John Ferlan
On 10/21/2016 09:58 AM, Ján Tomko wrote: > Return 0 instead of 1, so that qemuDomainAttachChrDevice does not > assume the address neeeds to be released on error. > > No functional change, since qemuDomainReleaseDeviceAddress has been a noop > for virtio serial addresses since the address cache

Re: [libvirt] [PATCH 4/6] Also create the USB address cache for domains with all the USB addresses

2016-10-25 Thread John Ferlan
$SUBJ... The "Also" just seems misplaced. especially with the "Also generate the..." below... How about "At Reconnect, recreate the USB address cache" ? On 10/21/2016 09:58 AM, Ján Tomko wrote: > When starting a new domain, we allocate the USB addresses and keep > an address cache in the

Re: [libvirt] [PATCH 1/6] Add 'FromCache' to virDomainVirtioSerialAddrAutoAssign

2016-10-25 Thread John Ferlan
On 10/21/2016 09:58 AM, Ján Tomko wrote: > We dropped the cache from QEMU's private domain object. s/We dropped the cache/Commit id '?' dropped the cache Is it commit id '19a148b7c8'? > Assume the callers do not have the cache by default and use > a longer name for the internal ones that

Re: [libvirt] [PATCH 3/6] Return directly from qemuDomainAttachChrDeviceAssignAddr

2016-10-25 Thread John Ferlan
On 10/21/2016 09:58 AM, Ján Tomko wrote: > This function should never need a cleanup section. > --- > src/qemu/qemu_hotplug.c | 28 ++-- > 1 file changed, 10 insertions(+), 18 deletions(-) > ACK John -- libvir-list mailing list libvir-list@redhat.com

Re: [libvirt] [PATCH 2/6] Introduce virDomainVirtioSerialAddrAutoAssign again

2016-10-25 Thread John Ferlan
On 10/21/2016 09:58 AM, Ján Tomko wrote: > This time do not require an address cache as a parameter. Essentially reworking commit id '925fa4b90', right? Provide the reference... > > Simplify qemuDomainAttachChrDeviceAssignAddr to not generate > the virtio serial address cache for devices of

[libvirt] how to install and remove Libvirt cleanly

2016-10-25 Thread zhun...@gmail.com
I just want to know how to uninstall Libvirt which installed by source code cleanly.because I found make uninstall can not remove all the installed file.so that I install it later failed. zhun...@gmail.com -- libvir-list mailing list libvir-list@redhat.com

[libvirt] [PATCH python 1/1] fix crash in libvirt_virDomainPin*

2016-10-25 Thread Konstantin Neumoin
If we pass large(more than cpunum) cpu mask to any libvirt_virDomainPin* methods, it could leads to crash. So we have to check tuple size and ignore extra tuple members. Signed-off-by: Konstantin Neumoin --- libvirt-override.c | 8 1 file changed, 4

Re: [libvirt] [PATCH 0/4] Add VCPU halted to domain statistics

2016-10-25 Thread Viktor Mihajlovski
On 25.10.2016 00:56, John Ferlan wrote: > [...] > Now pushed > > John > Thanks! -- Mit freundlichen Grüßen/Kind Regards Viktor Mihajlovski IBM Deutschland Research & Development GmbH Vorsitzender des Aufsichtsrats: Martina Köderitz Geschäftsführung: Dirk Wittkopp Sitz der Gesellschaft:

[libvirt] [jenkins-ci PATCH] jobs: change maintainer email address

2016-10-25 Thread Pavel Hrdina
Signed-off-by: Pavel Hrdina --- Pushed as trivial. jobs/defaults.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jobs/defaults.yaml b/jobs/defaults.yaml index 23d9ae7..b21bff3 100644 --- a/jobs/defaults.yaml +++ b/jobs/defaults.yaml @@ -9,4 +9,4 @@