Re: [libvirt] [PATCH v4 02/11] nvdimm: introduce 'pmem' element into xml for NVDIMM memory

2018-12-17 Thread Luyao Zhong
On 2018/12/17 下午7:05, Daniel P. Berrangé wrote: On Mon, Dec 17, 2018 at 05:26:12PM +0800, Luyao Zhong wrote: The 'pmem' option allows users to specify whether the backend storage of memory-backend-file is a real persistent memory: What does this actually do in practice ? Why does it matter

Re: [libvirt] [QEMU PATCH] hw/i386: Remove deprecated machines pc-0.10 and pc-0.11

2018-12-17 Thread Michael S. Tsirkin
On Mon, Dec 17, 2018 at 05:35:22PM -0200, Eduardo Habkost wrote: > On Mon, Dec 17, 2018 at 05:57:37PM +0100, Thomas Huth wrote: > > They've been deprecated for two releases and nobody complained that they > > are still required anymore, so it's time to remove these now. > > And while we're at it,

Re: [libvirt] [PATCH v4 03/11] nvdimm: introduce 'unarmed' element into xml for NVDIMM memory

2018-12-17 Thread Luyao Zhong
On 2018/12/17 下午7:07, Daniel P. Berrangé wrote: On Mon, Dec 17, 2018 at 05:26:13PM +0800, Luyao Zhong wrote: The 'unarmed' option allows users to mark vNVDIMM read-only: Why don't we call this element then ? Just keep the same with QEMU, hah~ :) ...

Re: [libvirt] [QEMU PATCH] hw/i386: Remove deprecated machines pc-0.10 and pc-0.11

2018-12-17 Thread Eduardo Habkost
On Mon, Dec 17, 2018 at 05:57:37PM +0100, Thomas Huth wrote: > They've been deprecated for two releases and nobody complained that they > are still required anymore, so it's time to remove these now. > And while we're at it, mark the other remaining old 0.x machine types > as deprecated (since

[libvirt] [PULL 31/31] hw/i386: Remove deprecated machines pc-0.10 and pc-0.11

2018-12-17 Thread Michael S. Tsirkin
From: Thomas Huth They've been deprecated for two releases and nobody complained that they are still required anymore, so it's time to remove these now. And while we're at it, mark the other remaining old 0.x machine types as deprecated (since they can not properly be used for live-migration

Re: [libvirt] [PATCH 08/10] util: error: Use a more declarative approach in virErrorMsg

2018-12-17 Thread Peter Krempa
On Mon, Dec 17, 2018 at 16:06:34 +, Daniel Berrange wrote: > On Thu, Dec 06, 2018 at 11:42:44AM +, Daniel P. Berrangé wrote: > > On Wed, Dec 05, 2018 at 05:47:49PM +0100, Peter Krempa wrote: > > > Use a macro to declare how the strings for individual error codes. This > > > unifies the

[libvirt] [QEMU PATCH] hw/i386: Remove deprecated machines pc-0.10 and pc-0.11

2018-12-17 Thread Thomas Huth
They've been deprecated for two releases and nobody complained that they are still required anymore, so it's time to remove these now. And while we're at it, mark the other remaining old 0.x machine types as deprecated (since they can not properly be used for live-migration anyway).

Re: [libvirt] [PATCH] util: fix translation of error message strings

2018-12-17 Thread Jiri Denemark
On Mon, Dec 17, 2018 at 16:04:24 +, Daniel P. Berrangé wrote: > The arguments to the N_() macro must only ever be a literal string. It > is not possible to use macro arguments, or use macro string > concatenation in this context. The N_() macro is a no-op whose only > purpose is to act as a

Re: [libvirt] [PATCH] util: fix translation of error message strings

2018-12-17 Thread Peter Krempa
On Mon, Dec 17, 2018 at 16:04:24 +, Daniel Berrange wrote: > The arguments to the N_() macro must only ever be a literal string. It > is not possible to use macro arguments, or use macro string > concatenation in this context. The N_() macro is a no-op whose only > purpose is to act as a

Re: [libvirt] [PATCH] docs: Improve description of

2018-12-17 Thread Peter Krempa
On Fri, Dec 14, 2018 at 15:13:31 -0700, Jim Fehlig wrote: > /domain/memtune/hard_limit provides a way to cap the memory a VM process > can use, including the amount of memory the process can lock. When memory > locking of a VM is requested, can be used to prevent the > potential host DoS issue

[libvirt] [PATCH v4 08/11] nvdimm: qemu command-line generating for align property

2018-12-17 Thread Luyao Zhong
According to the result parsing from xml, add align property into QEMU command line. Signed-off-by: Luyao Zhong --- src/qemu/qemu_command.c| 14 + .../memory-hotplug-nvdimm-align.x86_64-latest.args | 36 ++ tests/qemuxml2argvtest.c

Re: [libvirt] [PATCH] qemu: Add default address type for vhost-userinterface on aarch64

2018-12-17 Thread wang.yechao255
> On 12/14/18 10:19 AM, Wang Yechao wrote: > > on aarch64, hotadd vhost-user interface with the follow xml file: > > > > > > > > > > > > > > > > will get error like that: > > error: internal error: Nicdev support unavailable > > > > Because there is no device address type specified

[libvirt] [PATCH v4 09/11] nvdimm: qemu command-line generating for pmem property

2018-12-17 Thread Luyao Zhong
According to the result parsing from xml, add pmem property into QEMU command line. Signed-off-by: Luyao Zhong --- src/qemu/qemu_command.c| 14 + .../memory-hotplug-nvdimm-pmem.x86_64-latest.args | 36 ++ tests/qemuxml2argvtest.c

[libvirt] [PATCH v4 10/11] nvdimm: qemu command-line generating for unarmed property

2018-12-17 Thread Luyao Zhong
According to the result parsing from xml, add unarmed property into QEMU command line. Signed-off-by: Luyao Zhong --- src/qemu/qemu_command.c| 16 -- src/qemu/qemu_command.h| 3 +- src/qemu/qemu_hotplug.c

[libvirt] [PATCH v4 06/11] qemu_capabilities: introduce QEMU_CAPS_DEVICE_NVDIMM_UNARMED

2018-12-17 Thread Luyao Zhong
This capability tracks if nvdimm has unarmed attribute or not. Signed-off-by: Luyao Zhong --- src/qemu/qemu_capabilities.c | 8 ++ src/qemu/qemu_capabilities.h | 1 + .../caps_2.10.0.x86_64.replies | 62 -

[libvirt] [PATCH v4 11/11] nvdimm: update news.xml

2018-12-17 Thread Luyao Zhong
add more configure options for NVDIMM Signed-off-by: Luyao Zhong --- docs/news.xml | 9 + 1 file changed, 9 insertions(+) diff --git a/docs/news.xml b/docs/news.xml index 5bdbd34..dde98a1 100644 --- a/docs/news.xml +++ b/docs/news.xml @@ -65,6 +65,15 @@ qemu: Add support for

[libvirt] [PATCH v4 01/11] nvdimm: introduce 'alignsize' element into xml for NVDIMM memory

2018-12-17 Thread Luyao Zhong
NVDIMM emulation will mmap the backend file, it uses host pagesize as the alignment of mapping address before, but some backends may require alignments different from the pagesize. So the 'alignsize' option will be introduced to allow users specifying the proper alignment: ...

[libvirt] [PATCH v4 02/11] nvdimm: introduce 'pmem' element into xml for NVDIMM memory

2018-12-17 Thread Luyao Zhong
The 'pmem' option allows users to specify whether the backend storage of memory-backend-file is a real persistent memory: ... /dev/dax0.0 4094 0 2 ... Signed-off-by: Luyao Zhong

[libvirt] [PATCH v4 04/11] qemu_capabilities: introduce QEMU_CAPS_OBJECT_MEMORY_FILE_ALIGN

2018-12-17 Thread Luyao Zhong
This capability tracks if memory-backend-file has align attribute or not. Signed-off-by: Luyao Zhong --- src/qemu/qemu_capabilities.c | 4 +++- src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml | 1 +

[libvirt] [PATCH v4 07/11] nvdimm: use DO_TEST_CAPS_LATEST to do nvdimm qemuxml2argvdata test

2018-12-17 Thread Luyao Zhong
Depracate DO_TEST to do nvdimm qemuxml2argvdata tests, because DO_TEST_CAPS_LATEST is a better choice. the DO_TEST need to specify all qemu capabilities and is not easy for scaling. Signed-off-by: Luyao Zhong --- .../memory-hotplug-nvdimm-access.args | 31 ---

[libvirt] [PATCH v4 00/11] update NVDIMM support

2018-12-17 Thread Luyao Zhong
Hi libvirt experts, There are some gaps between qemu and libvirt, libvirt has not supported several config options about NVDIMM memory while qemu has now, including 'align', 'pmem', 'unarmed'. So these three options is introduced in this patch set. Regards, Luyao Zhong Luyao Zhong (11):

[libvirt] [PATCH v4 03/11] nvdimm: introduce 'unarmed' element into xml for NVDIMM memory

2018-12-17 Thread Luyao Zhong
The 'unarmed' option allows users to mark vNVDIMM read-only: ... /dev/dax0.0 4094 0 2 ... Signed-off-by: Luyao Zhong --- docs/formatdomain.html.in | 45

[libvirt] [PATCH v4 05/11] qemu_capabilities: introduce QEMU_CAPS_OBJECT_MEMORY_FILE_PMEM

2018-12-17 Thread Luyao Zhong
This capability tracks if memory-backend-file has pmem attribute or not. Signed-off-by: Luyao Zhong --- src/qemu/qemu_capabilities.c | 4 src/qemu/qemu_capabilities.h | 3 +++ tests/qemucapabilitiesdata/caps_3.1.0.ppc64.xml | 1 +

Re: [libvirt] [PATCH] qemu: Add default address type for vhost-userinterface on aarch64

2018-12-17 Thread Michal Privoznik
On 12/17/18 9:30 AM, wang.yechao...@zte.com.cn wrote: >> On 12/14/18 10:19 AM, Wang Yechao wrote: >>> on aarch64, hotadd vhost-user interface with the follow xml file: >>> >>> >>> >>> >>> >>> >>> >>> will get error like that: >>> error: internal error: Nicdev support unavailable >>>

Re: [libvirt] [PATCH] lxc: Set max uid/gid mappings for user namespace

2018-12-17 Thread Daniel P . Berrangé
On Sat, Dec 15, 2018 at 10:02:34AM +, Radostin Stoyanov wrote: > There is a limit on the number of lines in the /proc//{g,u}id_map > files. In Linux 4.14 and earlier, this limit was (arbitrarily) set at > 5 lines. Since Linux 4.15, which was released on 28 Jan 2018, the limit > is 340 lines. >

Re: [libvirt] [PATCH v2] Drop UML driver

2018-12-17 Thread Daniel P . Berrangé
On Fri, Dec 14, 2018 at 09:04:03PM +0100, Michal Privoznik wrote: > The driver is unmaintained, untested and severely broken for > quite some time now. Since nobody even reported any issue with it > let us drop it. > > Signed-off-by: Michal Privoznik [snip] > diff --git a/libvirt.spec.in

Re: [libvirt] [PATCH v4 03/11] nvdimm: introduce 'unarmed' element into xml for NVDIMM memory

2018-12-17 Thread Daniel P . Berrangé
On Mon, Dec 17, 2018 at 05:26:13PM +0800, Luyao Zhong wrote: > The 'unarmed' option allows users to mark vNVDIMM read-only: Why don't we call this element then ? > > > ... > > > /dev/dax0.0 > > > 4094 > 0 > > 2

[libvirt] [PATCH v2] qemu: Assign device address before qemuDomainSupportsNicdev

2018-12-17 Thread Wang Yechao
qemuDomainSupportsNicdev will check the device address type on aarch64. If it is invoked before device address assigned, hotadd vhostuser interface with no address specified will get error. Let qemuDomainEnsurePCIAddress run before qemuDomainSupportsNicdev. Signed-off-by: Wang Yechao --- v1

Re: [libvirt] [PATCH v4 02/11] nvdimm: introduce 'pmem' element into xml for NVDIMM memory

2018-12-17 Thread Daniel P . Berrangé
On Mon, Dec 17, 2018 at 05:26:12PM +0800, Luyao Zhong wrote: > The 'pmem' option allows users to specify whether the backend > storage of memory-backend-file is a real persistent memory: What does this actually do in practice ? Why does it matter and if it does, why can't libvirt set the right

Re: [libvirt] [PATCH] util: require command args to be non-NULL

2018-12-17 Thread Michal Privoznik
On 12/17/18 2:20 PM, Daniel P. Berrangé wrote: > The virCommand APIs do not expect to be given a NULL value for an arg > name or value. Such a mistake can lead to execution of the wrong > command, as the NULL may prematurely terminate the list of args. > Detect this and report suitable error

[libvirt] [jenkins-ci PATCH 6/6] guests: Simplify FreeBSD symlink kludge

2018-12-17 Thread Andrea Bolognani
Now that we no longer support FreeBSD 10, we don't need to special-case the readline symlinks. Signed-off-by: Andrea Bolognani --- guests/playbooks/update/tasks/kludges.yml | 17 ++--- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git

[libvirt] [PATCH] tests: ignore XML files starting with a .

2018-12-17 Thread Daniel P . Berrangé
If an editor has an XML file open, it may create a temporary . file. The existance of this file will cause the virschematest to fail, so just skip these editor temp files. Signed-off-by: Daniel P. Berrangé --- tests/virschematest.c | 2 ++ 1 file changed, 2 insertions(+) diff --git

[libvirt] [PATCH] util: require command args to be non-NULL

2018-12-17 Thread Daniel P . Berrangé
The virCommand APIs do not expect to be given a NULL value for an arg name or value. Such a mistake can lead to execution of the wrong command, as the NULL may prematurely terminate the list of args. Detect this and report suitable error messages. This identified a flaw in the storage test which

[libvirt] [PATCH v3] Drop UML driver

2018-12-17 Thread Michal Privoznik
The driver is unmaintained, untested and severely broken for quite some time now. Since nobody even reported any issue with it let us drop it. Signed-off-by: Michal Privoznik --- diff to v2: - Add 'Obsoletes' line into the spec file as suggested by Dan. configure.ac |

[libvirt] [PATCH] src: Document autostart for session demon

2018-12-17 Thread Michal Privoznik
The autostart under session daemon might not behave as you'd expect it to behave. This patch is inspired by latest libvirt-users discussion: https://www.redhat.com/archives/libvirt-users/2018-December/msg00047.html Signed-off-by: Michal Privoznik --- src/libvirt-domain.c | 5 + 1 file

[libvirt] [jenkins-ci PATCH 4/6] Stop building on FreeBSD 10

2018-12-17 Thread Andrea Bolognani
Signed-off-by: Andrea Bolognani --- guests/playbooks/build/jobs/defaults.yml | 1 - guests/playbooks/build/projects/libvirt-dbus.yml | 2 -- guests/playbooks/build/projects/libvirt-ocaml.yml | 1 - guests/playbooks/build/projects/libvirt-tck.yml | 1 -

[libvirt] [jenkins-ci PATCH 3/6] Build on FreeBSD 12

2018-12-17 Thread Andrea Bolognani
Signed-off-by: Andrea Bolognani --- guests/playbooks/build/jobs/defaults.yml | 1 + guests/playbooks/build/projects/libvirt-dbus.yml | 2 ++ guests/playbooks/build/projects/libvirt-ocaml.yml | 1 + guests/playbooks/build/projects/libvirt-tck.yml | 1 +

[libvirt] [jenkins-ci PATCH 5/6] guests: Drop FreeBSD 10

2018-12-17 Thread Andrea Bolognani
Signed-off-by: Andrea Bolognani --- guests/host_vars/libvirt-freebsd-10/main.yml | 22 - guests/inventory | 1 - guests/vars/vault.yml| 86 ++-- 3 files changed, 41 insertions(+), 68 deletions(-) delete mode 100644

[libvirt] [jenkins-ci PATCH 2/6] guests: Add FreeBSD 12

2018-12-17 Thread Andrea Bolognani
Signed-off-by: Andrea Bolognani --- guests/host_vars/libvirt-freebsd-12/main.yml | 22 + guests/inventory | 1 + guests/vars/vault.yml| 86 ++-- 3 files changed, 68 insertions(+), 41 deletions(-) create mode 100644

[libvirt] [jenkins-ci PATCH 1/6] guests: Fix FreeBSD symlink kludge

2018-12-17 Thread Andrea Bolognani
The version check was not written in a future-proof manner, as all versions of FreeBSD after 10 need the kludge. Signed-off-by: Andrea Bolognani --- guests/playbooks/update/tasks/kludges.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git

[libvirt] [jenkins-ci PATCH 0/6] Add FreeBSD 12, drop FreeBSD 12

2018-12-17 Thread Andrea Bolognani
FreeBSD 12 was released, like, almost a week ago! Andrea Bolognani (6): guests: Fix FreeBSD symlink kludge guests: Add FreeBSD 12 Build on FreeBSD 12 Stop building on FreeBSD 10 guests: Drop FreeBSD 10 guests: Simplify FreeBSD symlink kludge .../main.yml

[libvirt] [PATCH] util: fix translation of error message strings

2018-12-17 Thread Daniel P . Berrangé
The arguments to the N_() macro must only ever be a literal string. It is not possible to use macro arguments, or use macro string concatenation in this context. The N_() macro is a no-op whose only purpose is to act as a marker for xgettext when it extracts translatable strings from the source

Re: [libvirt] [PATCH 08/10] util: error: Use a more declarative approach in virErrorMsg

2018-12-17 Thread Daniel P . Berrangé
On Thu, Dec 06, 2018 at 11:42:44AM +, Daniel P. Berrangé wrote: > On Wed, Dec 05, 2018 at 05:47:49PM +0100, Peter Krempa wrote: > > Use a macro to declare how the strings for individual error codes. This > > unifies the used condition and will allow simplifying the code further. > > > >

[libvirt] [jenkins-ci PATCH] guests: Fix duplicated key in vault

2018-12-17 Thread Andrea Bolognani
Commit d3904591a2d2 added the Jenkins secret for FreeBSD 12 to the vault, but mistakenly created a second entry for the existing libvirt-freebsd-11 key instead of introducing a new entry for the libvirt-freebsd-12 key. Signed-off-by: Andrea Bolognani --- Pushed under the binary blob update rule.

Re: [libvirt] [PATCH] src: Document autostart for session demon

2018-12-17 Thread Daniel P . Berrangé
On Mon, Dec 17, 2018 at 02:50:59PM +0100, Michal Privoznik wrote: > The autostart under session daemon might not behave as you'd > expect it to behave. This patch is inspired by latest > libvirt-users discussion: > > https://www.redhat.com/archives/libvirt-users/2018-December/msg00047.html > >

[libvirt] [PATCH] cpu: Add support for "stibp" x86_64 feature

2018-12-17 Thread Jiri Denemark
QEMU commit v3.1.0-4-g0e89165829 KVM patch: https://lore.kernel.org/lkml/20181205191956.31480-1-ehabk...@redhat.com/ Signed-off-by: Jiri Denemark --- src/cpu_map/x86_features.xml | 3 +++ tests/cputestdata/x86_64-cpuid-Core-i7-5600U-ibrs-disabled.xml | 2 +-

Re: [libvirt] [PATCH v3] Drop UML driver

2018-12-17 Thread Daniel P . Berrangé
On Mon, Dec 17, 2018 at 02:34:30PM +0100, Michal Privoznik wrote: > The driver is unmaintained, untested and severely broken for > quite some time now. Since nobody even reported any issue with it > let us drop it. > > Signed-off-by: Michal Privoznik > --- > > diff to v2: > - Add 'Obsoletes'

[libvirt] [PATCH 0/3] Fix a couple of coverity found issues

2018-12-17 Thread John Ferlan
The first two are coverity found and the last was "extra" as I looked in the code. John Ferlan (3): tests: Return failures immediately in virErrorTestMsgs remote: Resolve resource leak remote: Handle xdr char ** data return fields more consistently src/remote/remote_daemon_dispatch.c | 42

[libvirt] [PATCH 2/3] remote: Resolve resource leak

2018-12-17 Thread John Ferlan
Using a combination of VIR_ALLOC and VIR_STRDUP into a local variable and then jumping to error on the VIR_STRDUP before assiging it into the @data would cause a memory leak. Let's just avoid that by assiging directly into @data. Signed-off-by: John Ferlan ---

[libvirt] [PATCH 1/3] tests: Return failures immediately in virErrorTestMsgs

2018-12-17 Thread John Ferlan
Rather than chancing calling strchr when @err_noinfo == NULL or calling virErrorTestMsgFormatInfoOne when @err_info == NULL, both of which would fail, let's just return -1 immediately when we encounter an error. Signed-off-by: John Ferlan --- tests/virerrortest.c | 11 +-- 1 file

[libvirt] [PATCH 3/3] remote: Handle xdr char ** data return fields more consistently

2018-12-17 Thread John Ferlan
For consistency, handle the @data "char **" (or remote_string) assignments and processing similarly between various APIs Signed-off-by: John Ferlan --- src/remote/remote_daemon_dispatch.c | 25 +++-- 1 file changed, 7 insertions(+), 18 deletions(-) diff --git

Re: [libvirt] [PATCH] cpu: Add support for "stibp" x86_64 feature

2018-12-17 Thread Ján Tomko
On Mon, Dec 17, 2018 at 04:47:16PM +0100, Jiri Denemark wrote: QEMU commit v3.1.0-4-g0e89165829 KVM patch: https://lore.kernel.org/lkml/20181205191956.31480-1-ehabk...@redhat.com/ Signed-off-by: Jiri Denemark --- src/cpu_map/x86_features.xml | 3 +++

Re: [libvirt] [jenkins-ci PATCH 0/6] Add FreeBSD 12, drop FreeBSD 12

2018-12-17 Thread Daniel P . Berrangé
On Mon, Dec 17, 2018 at 02:54:22PM +0100, Andrea Bolognani wrote: > FreeBSD 12 was released, like, almost a week ago! > > Andrea Bolognani (6): > guests: Fix FreeBSD symlink kludge > guests: Add FreeBSD 12 > Build on FreeBSD 12 > Stop building on FreeBSD 10 > guests: Drop FreeBSD 10 >

Re: [libvirt] [PATCH] tests: ignore XML files starting with a .

2018-12-17 Thread Andrea Bolognani
On Mon, 2018-12-17 at 14:42 +, Daniel P. Berrangé wrote: > If an editor has an XML file open, it may create a temporary . file. The > existance of this file will cause the virschematest to fail, so just > skip these editor temp files. > > Signed-off-by: Daniel P. Berrangé > --- >