Re: [Qemu-devel] [RFC] HACKING: Document 'struct' keyword usage

2019-08-02 Thread Thomas Huth
On 01/08/2019 21.23, Paolo Bonzini wrote: > On 01/08/19 20:50, Eduardo Habkost wrote: >> On Wed, Jul 31, 2019 at 10:35:31AM +0200, Thomas Huth wrote: >>> On 30/07/2019 23.07, Eduardo Habkost wrote: Sometimes we use the 'struct' keyword to help us reduce dependencies between header files.

Re: [Qemu-devel] [RFC v1 05/18] vfio/pci: add pasid alloc/free implementation

2019-08-02 Thread Auger Eric
Hi Yi, On 7/26/19 7:18 AM, Liu, Yi L wrote: > Hi Eric, > >> -Original Message- >> From: Auger Eric [mailto:eric.au...@redhat.com] >> Sent: Wednesday, July 24, 2019 5:33 PM >> To: Liu, Yi L ; David Gibson >> >> Subject: Re: [RFC v1 05/18] vfio/pci: add pasid alloc/free implementation >>

Re: [Qemu-devel] [PATCH for-4.1] target/arm: Avoid bogus NSACR traps on M-profile without Security Extension

2019-08-02 Thread Damien Hedde
On 8/1/19 4:38 PM, Peter Maydell wrote: > On Thu, 1 Aug 2019 at 15:20, Damien Hedde wrote: >> >> >> On 8/1/19 12:57 PM, Peter Maydell wrote: >>> In Arm v8.0 M-profile CPUs without the Security Extension and also in >>> v7M CPUs, there is no NSACR register. However, the code we have to handle >>>

Re: [Qemu-devel] [PATCH v9 16/17] block/io_uring: adds fd registration

2019-08-02 Thread Stefan Hajnoczi
On Fri, Aug 02, 2019 at 05:10:30AM +0530, Aarushi Mehta wrote: The fd lifecycle/leak issue remains. After a drive is removed the kernel still has a reference to the file. If this repeats many times our process will run out of open files. A callback is required to unregister the file descriptor

Re: [Qemu-devel] [qemu-s390x] [PATCH RFC 0/2] s390: stop abusing memory_region_allocate_system_memory()

2019-08-02 Thread David Hildenbrand
On 29.07.19 16:52, Igor Mammedov wrote: > While looking into unifying guest RAM allocation to use hostmem backends > for initial RAM (especially when -mempath is used) and retiring > memory_region_allocate_system_memory() API, leaving only single hostmem > backend, > I was inspecting how currently

Re: [Qemu-devel] [PATCH v9 17/17] block/io_uring: enable kernel submission polling

2019-08-02 Thread Stefan Hajnoczi
On Fri, Aug 02, 2019 at 05:10:31AM +0530, Aarushi Mehta wrote: > Signed-off-by: Aarushi Mehta > --- > block/io_uring.c | 17 - > 1 file changed, 16 insertions(+), 1 deletion(-) How does SQPOLL performance compare? > diff --git a/block/io_uring.c b/block/io_uring.c > index 1553cd

Re: [Qemu-devel] [Virtio-fs] [PATCH] virtiofsd: fix compile error if 'F_OFD_GETLK' not defined

2019-08-02 Thread piaojun
Hi Dave and Eric, On 2019/8/1 22:26, Dr. David Alan Gilbert wrote: > * Dr. David Alan Gilbert (dgilb...@redhat.com) wrote: >> * Eric Blake (ebl...@redhat.com) wrote: >>> On 7/29/19 7:27 PM, piaojun wrote: Use F_GETLK for fcntl when F_OFD_GETLK not defined. >>> >>> Which system are you hitting

Re: [Qemu-devel] [qemu-s390x] [PATCH RFC 0/2] s390: stop abusing memory_region_allocate_system_memory()

2019-08-02 Thread David Hildenbrand
On 02.08.19 10:04, David Hildenbrand wrote: > On 29.07.19 16:52, Igor Mammedov wrote: >> While looking into unifying guest RAM allocation to use hostmem backends >> for initial RAM (especially when -mempath is used) and retiring >> memory_region_allocate_system_memory() API, leaving only single hos

Re: [Qemu-devel] [qemu-s390x] [PATCH RFC 0/2] s390: stop abusing memory_region_allocate_system_memory()

2019-08-02 Thread David Hildenbrand
On 02.08.19 10:04, David Hildenbrand wrote: > On 29.07.19 16:52, Igor Mammedov wrote: >> While looking into unifying guest RAM allocation to use hostmem backends >> for initial RAM (especially when -mempath is used) and retiring >> memory_region_allocate_system_memory() API, leaving only single hos

Re: [Qemu-devel] [qemu-s390x] [PATCH RFC 0/2] s390: stop abusing memory_region_allocate_system_memory()

2019-08-02 Thread Christian Borntraeger
On 02.08.19 10:04, David Hildenbrand wrote: > On 29.07.19 16:52, Igor Mammedov wrote: >> While looking into unifying guest RAM allocation to use hostmem backends >> for initial RAM (especially when -mempath is used) and retiring >> memory_region_allocate_system_memory() API, leaving only single

[Qemu-devel] [Bug 1838658] Re: qemu 4.0.0 broken by glib update

2019-08-02 Thread Daniel Berrange
Fedora 30 has been shipping glib2 2.60.0 through to 2.60.5 and QEMU in general has been working normally AFAICT. >From the netbsd bug report it looks like the reproducer was demoed using the sparc emulator - is that the only QEMU arch that is affected ? -- You received this bug notification beca

Re: [Qemu-devel] [qemu-s390x] [PATCH RFC 0/2] s390: stop abusing memory_region_allocate_system_memory()

2019-08-02 Thread David Hildenbrand
On 02.08.19 10:29, Christian Borntraeger wrote: > > > On 02.08.19 10:04, David Hildenbrand wrote: >> On 29.07.19 16:52, Igor Mammedov wrote: >>> While looking into unifying guest RAM allocation to use hostmem backends >>> for initial RAM (especially when -mempath is used) and retiring >>> memory_

[Qemu-devel] [PATCH v2] virtiofsd: fix compile error if 'F_OFD_GETLK' not defined

2019-08-02 Thread piaojun
Use F_GETLK for fcntl when F_OFD_GETLK not defined, such as kernel 3.10. Signed-off-by: Jun Piao --- v2: - Use F_OFD_SETLK to replace F_OFD_GETLK in #ifdef. --- contrib/virtiofsd/passthrough_ll.c | 8 1 file changed, 8 insertions(+) diff --git a/contrib/virtiofsd/passthrough_ll.c b/c

Re: [Qemu-devel] [PATCH v3] blockjob: drain all job nodes in block_job_drain

2019-08-02 Thread Vladimir Sementsov-Ogievskiy
01.08.2019 22:44, Max Reitz wrote: > On 30.07.19 21:11, John Snow wrote: >> >> >> On 7/24/19 5:40 AM, Vladimir Sementsov-Ogievskiy wrote: >>> Instead of draining additional nodes in each job code, let's do it in >>> common block_job_drain, draining just all job's children. >>> BlockJobDriver.drain

Re: [Qemu-devel] [PATCH v3 1/9] block: add .bdrv_need_rw_file_child_during_reopen_rw handler

2019-08-02 Thread Vladimir Sementsov-Ogievskiy
01.08.2019 22:06, Max Reitz wrote: > On 01.08.19 16:02, Vladimir Sementsov-Ogievskiy wrote: >> 31.07.2019 15:09, Max Reitz wrote: > > [...] > >>> So -- without having tried, of course -- I think a better design would >>> be to look for bs->file->bs in the ReopenQueue, recursively all of its >>> c

[Qemu-devel] [Bug 1838658] Re: qemu 4.0.0 broken by glib update

2019-08-02 Thread Daniel Berrange
The test image that the netbsd bug points to no longer exists. If I pick the image currently available: http://nycdn.netbsd.org/pub/NetBSD- daily/HEAD/latest/images/NetBSD-9.99.2-sparc.iso And launch it in a QEMU built from today's GIT master, on Fedora 30 with glib2 2.60.5, NetBSD successfull

Re: [Qemu-devel] [PATCH V5 1/6] virtio: basic structure for packed ring

2019-08-02 Thread Jens Freimann
On Fri, Aug 02, 2019 at 12:06:01AM -0400, Jason Wang wrote: From: Wei Xu Define packed ring structure according to Qemu nomenclature, field data(wrap counter, etc) are also included. Signed-off-by: Wei Xu Signed-off-by: Jason Wang --- hw/virtio/virtio.c | 15 +++ 1 file changed, 1

Re: [Qemu-devel] [PATCH V5 6/6] virtio: add property to enable packed virtqueue

2019-08-02 Thread Jens Freimann
On Fri, Aug 02, 2019 at 12:06:06AM -0400, Jason Wang wrote: Signed-off-by: Jason Wang --- include/hw/virtio/virtio.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) Reviewed-by: Jens Freimann

Re: [Qemu-devel] [PATCH V5 2/6] virtio: device/driverr area size calculation refactor for split ring

2019-08-02 Thread Jens Freimann
In subject s/driverr/driver On Fri, Aug 02, 2019 at 12:06:02AM -0400, Jason Wang wrote: From: Wei Xu There is slight size difference between split/packed rings. This is the refactor of split ring as well as a helper to expanding device and driver area size calculation for packed ring. Signe

[Qemu-devel] [PATCH v2] migration: always initial ram_counters for a new migration

2019-08-02 Thread Ivan Ren
From: Ivan Ren This patch fix a multifd migration bug in migration speed calculation, this problem can be reproduced as follows: 1. start a vm and give a heavy memory write stress to prevent the vm be successfully migrated to destination 2. begin a migration with multifd 3. migrate for a long

Re: [Qemu-devel] [PATCH V5 5/6] vhost_net: enable packed ring support

2019-08-02 Thread Jens Freimann
On Fri, Aug 02, 2019 at 12:06:05AM -0400, Jason Wang wrote: Signed-off-by: Jason Wang --- hw/net/vhost_net.c | 2 ++ 1 file changed, 2 insertions(+) Reviewed-by: Jens Freimann

Re: [Qemu-devel] [PATCH v2] migration: always initial ram_counters for a new migration

2019-08-02 Thread no-reply
Patchew URL: https://patchew.org/QEMU/1564736786-26495-1-git-send-email-ivan...@tencent.com/ Hi, This series failed build test on s390x host. Please find the details below. === TEST SCRIPT BEGIN === #!/bin/bash # Testing script will be invoked under the git checkout with # HEAD pointing to a

Re: [Qemu-devel] [PATCH v2] migration: always initial ram_counters for a new migration

2019-08-02 Thread no-reply
Patchew URL: https://patchew.org/QEMU/1564736786-26495-1-git-send-email-ivan...@tencent.com/ Hi, This series failed the asan build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. === TEST SCRIPT BEGIN === #!/b

Re: [Qemu-devel] [qemu-s390x] [PATCH RFC 0/2] s390: stop abusing memory_region_allocate_system_memory()

2019-08-02 Thread Igor Mammedov
On Fri, 2 Aug 2019 10:29:43 +0200 Christian Borntraeger wrote: > On 02.08.19 10:04, David Hildenbrand wrote: > > On 29.07.19 16:52, Igor Mammedov wrote: > >> While looking into unifying guest RAM allocation to use hostmem backends > >> for initial RAM (especially when -mempath is used) and reti

Re: [Qemu-devel] [RFC] virtio-mmio: implement modern (v2) personality (virtio-1)

2019-08-02 Thread Peter Maydell
On Fri, 2 Aug 2019 at 01:26, Laszlo Ersek wrote: > But it's extra work, not entirely risk-free (regressions), and I can't > tell if someone out there still uses virtio-mmio (despite me thinking > that would be unreasonable). I wouldn't like to see more work sunk into > it either way :) The main r

Re: [Qemu-devel] [RFC] virtio-mmio: implement modern (v2) personality (virtio-1)

2019-08-02 Thread Paolo Bonzini
On 01/08/19 21:45, Michael S. Tsirkin wrote: >>> OVMF is a heavy-weight guest firmware, which I see entirely out of scope >>> for "micro VMs". And so virtio-mmio/1.0 would seem like a needless & >>> unwelcome complication, from the OVMF maintainership perspective. >> But given that, why not rip out

[Qemu-devel] [PATCH RFC v2 4/4] s390: do not call memory_region_allocate_system_memory() multiple times

2019-08-02 Thread Igor Mammedov
s390 was trying to solve limited KVM memslot size issue by abusing memory_region_allocate_system_memory(), which breaks API contract where the function might be called only once. s390 should have used memory aliases to fragment inital memory into smaller chunks to satisfy KVM's memslot limitation.

[Qemu-devel] [PATCH RFC v2 1/4] hw: add compat machines for 4.2

2019-08-02 Thread Igor Mammedov
From: Cornelia Huck Add 4.2 machine types for arm/i440fx/q35/s390x/spapr. For i440fx and q35, unversioned cpu models are still translated to -v1, as 0788a56bd1ae ("i386: Make unversioned CPU models be aliases") states this should only transition to the latest cpu model version in 4.3 (or later).

[Qemu-devel] [PATCH RFC v2 0/4] s390: stop abusing memory_region_allocate_system_memory()

2019-08-02 Thread Igor Mammedov
Changelog: since v1: - include 4.2 machines patch for adding compat RAM layout on top - 2/4 add missing in v1 patch for splitting too big MemorySection on several memslots - 3/4 amend code path on alias destruction to ensure that RAMBlock is cleaned properly -

[Qemu-devel] [PATCH RFC v2 3/4] memory: make MemoryRegion alias migratable

2019-08-02 Thread Igor Mammedov
use qemu_ram_alloc_from_ptr() to create aliased RAMBlock to the part of original memory region. Change is migration safe as we do not migrate every existing RAMBlock anymore, to make it migratable code has to explicitly call vmstate_register_ram() on MemoryRegion that owns RAMBlock. Signed-off-by

[Qemu-devel] [PATCH RFC v2 2/4] kvm: s390: split too big memory section on several memslots

2019-08-02 Thread Igor Mammedov
Max memslot size supported by kvm on s390 is 8Tb, move logic of splitting RAM on chunks upto 8T to KVM code. This way it will hide KVM specific restrictions in KVM code and won't affect baord level design decisions. Which would allow us to avoid misusing memory_region_allocate_system_memory() API

Re: [Qemu-devel] [PATCH V5 2/6] virtio: device/driverr area size calculation refactor for split ring

2019-08-02 Thread Jason Wang
On 2019/8/2 下午5:03, Jens Freimann wrote: In subject s/driverr/driver Right, let me fix. Thanks On Fri, Aug 02, 2019 at 12:06:02AM -0400, Jason Wang wrote: From: Wei Xu There is slight size difference between split/packed rings. This is the refactor of split ring as well as a helper

Re: [Qemu-devel] [PATCH 14/28] migration: Move the VMStateDescription typedef to typedefs.h

2019-08-02 Thread Paolo Bonzini
On 26/07/19 14:05, Markus Armbruster wrote: > typedef struct VMStateInfo VMStateInfo; > -typedef struct VMStateDescription VMStateDescription; > typedef struct VMStateField VMStateField; This certainly qualifies for typedefs.h. Paolo

Re: [Qemu-devel] [PATCH 27/28] sysemu: Move the VMChangeStateEntry typedef to qemu/typedefs.h

2019-08-02 Thread Paolo Bonzini
On 26/07/19 14:05, Markus Armbruster wrote: > +typedef struct VMChangeStateEntry VMChangeStateEntry; > typedef struct VMStateDescription VMStateDescription; > This is a bit borderline; I'd rather split sysemu/sysemu.h, e.g. adding sysemu/runstate.h that would have VMChangeStateEntry functions.

Re: [Qemu-devel] [Qemu-ppc] [PATCH v2] spapr: quantify error messages regarding capability settings

2019-08-02 Thread Greg Kurz
On Fri, 2 Aug 2019 11:03:48 +1000 Daniel Black wrote: > On Thu, 1 Aug 2019 12:41:59 +0200 > Greg Kurz wrote: > > > On Thu, 1 Aug 2019 13:38:19 +1000 > > Daniel Black wrote: > > > > > Its not immediately obvious how cap-X=Y setting need to be applied > > > to the command line so, for spapr ca

[Qemu-devel] [PATCH v4] blockjob: drain all job nodes in block_job_drain

2019-08-02 Thread Vladimir Sementsov-Ogievskiy
Instead of draining additional nodes in each job code, let's do it in common block_job_drain, draining just all job's children. BlockJobDriver.drain becomes unused, so, drop it at all. It's also a first step to finally get rid of blockjob->blk. Signed-off-by: Vladimir Sementsov-Ogievskiy --- v4

Re: [Qemu-devel] [PATCH 24/28] Include sysemu/hostmem.h less

2019-08-02 Thread Paolo Bonzini
On 26/07/19 14:05, Markus Armbruster wrote: > Move the HostMemoryBackend typedef from sysemu/hostmem.h to > qemu/typedefs.h. This renders a few inclusions of sysemu/hostmem.h > superflouous; drop them. I think this can also qualify for qemu/typedefs.h, even though this patch is also into diminish

Re: [Qemu-devel] [PATCH RFC v2 0/4] s390: stop abusing memory_region_allocate_system_memory()

2019-08-02 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20190802093854.5343-1-imamm...@redhat.com/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Subject: [Qemu-devel] [PATCH RFC v2 0/4] s390: stop abusing memory_region_allocate_system_memory() Mes

Re: [Qemu-devel] [PATCH] hmp/info_migration: formatting migration capability output

2019-08-02 Thread Dr. David Alan Gilbert
* Wei Yang (richardw.y...@linux.intel.com) wrote: > On Fri, Aug 02, 2019 at 07:24:34AM +0200, Markus Armbruster wrote: > >Subject doesn't quite conform to conventions. Suggest > > > >hmp: Improve how "info migrate" formats capabilities > > Thanks > > > > >Wei Yang writes: > > > >> Current w

[Qemu-devel] [Bug 1838703] Re: Makefile BUG in edk2 firmware install 4.1.0-rc3

2019-08-02 Thread Philippe Mathieu-Daudé
Related to commit 26ce90fde5c. What distribution/version are you using? -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1838703 Title: Makefile BUG in edk2 firmware install 4.1.0-rc3 Status in QEMU

Re: [Qemu-devel] [PATCH RFC v2 0/4] s390: stop abusing memory_region_allocate_system_memory()

2019-08-02 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20190802093854.5343-1-imamm...@redhat.com/ Hi, This series failed build test on s390x host. Please find the details below. === TEST SCRIPT BEGIN === #!/bin/bash # Testing script will be invoked under the git checkout with # HEAD pointing to a commit that h

[Qemu-devel] [PATCH v3] migration: always initial ram_counters for a new migration

2019-08-02 Thread Ivan Ren
From: Ivan Ren This patch fix a multifd migration bug in migration speed calculation, this problem can be reproduced as follows: 1. start a vm and give a heavy memory write stress to prevent the vm be successfully migrated to destination 2. begin a migration with multifd 3. migrate for a long

Re: [Qemu-devel] [ANNOUNCE] QEMU 4.1.0-rc3 is now available

2019-08-02 Thread Peter Maydell
On Wed, 31 Jul 2019 at 19:17, Peter Maydell wrote: > > On Wed, 31 Jul 2019 at 19:05, Philippe Mathieu-Daudé > wrote: > > > > > Unless there are any release critical bugs discovered, this > > > will be the last release candidate before final release of 4.1.0 > > > on the 6th August. Otherwi

Re: [Qemu-devel] [qemu-s390x] [PATCH RFC 0/2] s390: stop abusing memory_region_allocate_system_memory()

2019-08-02 Thread Christian Borntraeger
On 02.08.19 10:37, David Hildenbrand wrote: > On 02.08.19 10:29, Christian Borntraeger wrote: >> >> >> On 02.08.19 10:04, David Hildenbrand wrote: >>> On 29.07.19 16:52, Igor Mammedov wrote: While looking into unifying guest RAM allocation to use hostmem backends for initial RAM (espec

Re: [Qemu-devel] [PATCH RFC v2 4/4] s390: do not call memory_region_allocate_system_memory() multiple times

2019-08-02 Thread David Hildenbrand
On 02.08.19 11:38, Igor Mammedov wrote: > s390 was trying to solve limited KVM memslot size issue by abusing > memory_region_allocate_system_memory(), which breaks API contract > where the function might be called only once. > > s390 should have used memory aliases to fragment inital memory into >

Re: [Qemu-devel] [PATCH RFC v2 4/4] s390: do not call memory_region_allocate_system_memory() multiple times

2019-08-02 Thread Christian Borntraeger
On 02.08.19 12:25, David Hildenbrand wrote: > On 02.08.19 11:38, Igor Mammedov wrote: >> s390 was trying to solve limited KVM memslot size issue by abusing >> memory_region_allocate_system_memory(), which breaks API contract >> where the function might be called only once. >> >> s390 should have

Re: [Qemu-devel] [ANNOUNCE] QEMU 4.1.0-rc3 is now available

2019-08-02 Thread Marc-André Lureau
Hi On Fri, Aug 2, 2019 at 2:19 PM Peter Maydell wrote: > > On Wed, 31 Jul 2019 at 19:17, Peter Maydell wrote: > > > > On Wed, 31 Jul 2019 at 19:05, Philippe Mathieu-Daudé > > wrote: > > > > > > > Unless there are any release critical bugs discovered, this > > > > will be the last release c

Re: [Qemu-devel] [ANNOUNCE] QEMU 4.1.0-rc3 is now available

2019-08-02 Thread Peter Maydell
On Fri, 2 Aug 2019 at 11:31, Marc-André Lureau wrote: > > Hi > > On Fri, Aug 2, 2019 at 2:19 PM Peter Maydell wrote: > > > > On Wed, 31 Jul 2019 at 19:17, Peter Maydell > > wrote: > > > > > > On Wed, 31 Jul 2019 at 19:05, Philippe Mathieu-Daudé > > > wrote: > > > > > > > > > Unless there ar

Re: [Qemu-devel] [PATCH] hw: intel_iommu: initialize 'name' in vtd_find_add_as

2019-08-02 Thread Paolo Bonzini
On 01/08/19 18:28, Li Qiang wrote: > The 'name' variable in vtd_find_add_as function is not initialized > now, so when in gdb, we will got following output: > > (gdb) p name > $1 = > "vtd-00.0\000\000\000\000\000\000\000\000\060\330\377\377\377\177\000\000\001\000\000\000\000\000\000\000p\330\377

Re: [Qemu-devel] [PATCH v2] virtiofsd: fix compile error if 'F_OFD_GETLK' not defined

2019-08-02 Thread Dr. David Alan Gilbert
* piaojun (piao...@huawei.com) wrote: > Use F_GETLK for fcntl when F_OFD_GETLK not defined, such as kernel 3.10. > > Signed-off-by: Jun Piao > --- > v2: > - Use F_OFD_SETLK to replace F_OFD_GETLK in #ifdef. > > --- > contrib/virtiofsd/passthrough_ll.c | 8 > 1 file changed, 8 inserti

[Qemu-devel] 回复: 回复: 答复: migrate_set_speed has no effect if the guest is using hugepages.

2019-08-02 Thread Lin Ma
Hi Dave, May I ask that do you have any update about the fix? Thanks, Lin > -邮件原件- > 发件人: Qemu-devel 代 > 表 Lin Ma > 发送时间: 2019年7月15日 17:43 > 收件人: Dr. David Alan Gilbert > 抄送: qemu-devel@nongnu.org > 主题: [Qemu-devel] 回复: 答复: migrate_set_speed has no effect if the guest > is using hugepa

Re: [Qemu-devel] [ANNOUNCE] QEMU 4.1.0-rc3 is now available

2019-08-02 Thread Marc-André Lureau
Hi On Fri, Aug 2, 2019 at 2:44 PM Peter Maydell wrote: > > On Fri, 2 Aug 2019 at 11:31, Marc-André Lureau > wrote: > > > > Hi > > > > On Fri, Aug 2, 2019 at 2:19 PM Peter Maydell > > wrote: > > > > > > On Wed, 31 Jul 2019 at 19:17, Peter Maydell > > > wrote: > > > > > > > > On Wed, 31 Jul 20

Re: [Qemu-devel] [ANNOUNCE] QEMU 4.1.0-rc3 is now available

2019-08-02 Thread Samuel Thibault
Marc-André Lureau, le ven. 02 août 2019 15:07:46 +0400, a ecrit: > And Samuel probably thought the same, since he didn't update the submodule. I'm rather mostly buried under piles of things to do... > According to MAINTAINERS, this is for Samuel to take care of. But I'll > do it if he ask me. Pl

Re: [Qemu-devel] [PATCH v2] virtiofsd: fix compile error if 'F_OFD_GETLK' not defined

2019-08-02 Thread Daniel P . Berrangé
On Fri, Aug 02, 2019 at 11:53:52AM +0100, Dr. David Alan Gilbert wrote: > * piaojun (piao...@huawei.com) wrote: > > Use F_GETLK for fcntl when F_OFD_GETLK not defined, such as kernel 3.10. > > > > Signed-off-by: Jun Piao > > > > --- > > v2: > > - Use F_OFD_SETLK to replace F_OFD_GETLK in #ifdef

[Qemu-devel] [PULL 0/1] Slirp cve 2019 14378 patches

2019-08-02 Thread Marc-André Lureau
The following changes since commit 3bd6cbbb181b6ae60a1d1f33ccd325b45f71aa2a: Update version for v4.1.0-rc3 release (2019-07-30 22:02:05 +0100) are available in the Git repository at: https://github.com/elmarco/qemu.git tags/slirp-CVE-2019-14378-pull-request for you to fetch changes up to e1

[Qemu-devel] [PULL 1/1] slirp: update with CVE-2019-14378 fix

2019-08-02 Thread Marc-André Lureau
Signed-off-by: Marc-André Lureau --- slirp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/slirp b/slirp index f0da672620..126c04acba 16 --- a/slirp +++ b/slirp @@ -1 +1 @@ -Subproject commit f0da6726207b740f6101028b2992f918477a4b08 +Subproject commit 126c04acbabd7ad32c2b0

Re: [Qemu-devel] [PATCH v2] make check-unit: use after free in test-opts-visitor

2019-08-02 Thread Markus Armbruster
Andrey Shinkevich writes: > In struct OptsVisitor, repeated_opts member points to a list in the > unprocessed_opts hash table after the list has been destroyed. A > subsequent call to visit_type_int() references the deleted list. It > results in use-after-free issue. Let's mention the reproducer

Re: [Qemu-devel] [PATCH RFC v2 4/4] s390: do not call memory_region_allocate_system_memory() multiple times

2019-08-02 Thread Igor Mammedov
On Fri, 2 Aug 2019 12:27:50 +0200 Christian Borntraeger wrote: > On 02.08.19 12:25, David Hildenbrand wrote: > > On 02.08.19 11:38, Igor Mammedov wrote: > >> s390 was trying to solve limited KVM memslot size issue by abusing > >> memory_region_allocate_system_memory(), which breaks API contract

[Qemu-devel] [Bug 1838763] [NEW] Bugs in SSH module (ssh.c)

2019-08-02 Thread 周文青
Public bug reported: I installed gcc-8&libssh* on my Ubuntu 18.04 arm64.When I was compiling any version of qemu like 3.1.0 4.0.0or 4.1.0 with SSH support,the GCC went wrong.It said some vars undeclared like'SSH_KNOWN_HOSTS_OTHER','SSH_KNOWN_HOST_UNKNOWN',etc. ** Affects: qemu Importance: Un

Re: [Qemu-devel] [PULL 0/1] Slirp cve 2019 14378 patches

2019-08-02 Thread Peter Maydell
On Fri, 2 Aug 2019 at 12:18, Marc-André Lureau wrote: > > The following changes since commit 3bd6cbbb181b6ae60a1d1f33ccd325b45f71aa2a: > > Update version for v4.1.0-rc3 release (2019-07-30 22:02:05 +0100) > > are available in the Git repository at: > > https://github.com/elmarco/qemu.git tags/

Re: [Qemu-devel] [PATCH] hmp/info_migration: formatting migration capability output

2019-08-02 Thread Markus Armbruster
Wei Yang writes: > On Fri, Aug 02, 2019 at 07:24:34AM +0200, Markus Armbruster wrote: >>Subject doesn't quite conform to conventions. Suggest >> >>hmp: Improve how "info migrate" formats capabilities > > Thanks > >> >>Wei Yang writes: >> >>> Current we put all migration capability in one li

Re: [Qemu-devel] [PATCH RFC v2 4/4] s390: do not call memory_region_allocate_system_memory() multiple times

2019-08-02 Thread Christian Borntraeger
On 02.08.19 13:40, Igor Mammedov wrote: > On Fri, 2 Aug 2019 12:27:50 +0200 > Christian Borntraeger wrote: > >> On 02.08.19 12:25, David Hildenbrand wrote: >>> On 02.08.19 11:38, Igor Mammedov wrote: s390 was trying to solve limited KVM memslot size issue by abusing memory_region_a

[Qemu-devel] [PATCH] qapi: Make visit_next_list()'s comment less confusing

2019-08-02 Thread Markus Armbruster
visit_next_list() returns non-null on success, null on failure. The comment's phrasing "until NULL return or error occurs" is needlessly confusing. Scratch the "or error occurs" part. Signed-off-by: Markus Armbruster --- include/qapi/visitor.h | 8 1 file changed, 4 insertions(+), 4 d

[Qemu-devel] [PATCH v3 00/15] target/arm/kvm: enable SVE in guests

2019-08-02 Thread Andrew Jones
Since Linux kernel v5.2-rc1 KVM has support for enabling SVE in guests. This series provides the QEMU bits for that enablement. First, we select existing CPU properties representing features we want to advertise in addition to the SVE vector lengths and prepare them for a qmp query. Then we introdu

[Qemu-devel] [PATCH v3 02/15] target/arm/cpu: Ensure we can use the pmu with kvm

2019-08-02 Thread Andrew Jones
We first convert the pmu property from a static property to one with its own accessors. Then we use the set accessor to check if the PMU is supported when using KVM. Indeed a 32-bit KVM host does not support the PMU, so this check will catch an attempt to use it at property-set time. Signed-off-by

[Qemu-devel] [PATCH v3 01/15] target/arm/cpu64: Ensure kvm really supports aarch64=off

2019-08-02 Thread Andrew Jones
If -cpu ,aarch64=off is used then KVM must also be used, and it and the host must support running the vcpu in 32-bit mode. Also, if -cpu ,aarch64=on is used, then it doesn't matter if kvm is enabled or not. Signed-off-by: Andrew Jones Reviewed-by: Eric Auger --- target/arm/cpu64.c | 12 ++

[Qemu-devel] [PATCH v3 04/15] tests: arm: Introduce cpu feature tests

2019-08-02 Thread Andrew Jones
Now that Arm CPUs have advertised features lets add tests to ensure we maintain their expected availability with and without KVM. Signed-off-by: Andrew Jones Reviewed-by: Eric Auger --- tests/Makefile.include | 5 +- tests/arm-cpu-features.c | 242 +++ 2

[Qemu-devel] [PATCH v3 05/15] target/arm/helper: zcr: Add build bug next to value range assumption

2019-08-02 Thread Andrew Jones
The current implementation of ZCR_ELx matches the architecture, only implementing the lower four bits, with the rest RAZ/WI. This puts a strict limit on ARM_MAX_VQ of 16. Make sure we don't let ARM_MAX_VQ grow without a corresponding update here. Suggested-by: Dave Martin Signed-off-by: Andrew Jo

[Qemu-devel] [PATCH v3 06/15] target/arm/cpu: Use div-round-up to determine predicate register array size

2019-08-02 Thread Andrew Jones
Unless we're guaranteed to always increase ARM_MAX_VQ by a multiple of four, then we should use DIV_ROUND_UP to ensure we get an appropriate array size. Signed-off-by: Andrew Jones --- target/arm/cpu.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/arm/cpu.h b/target/

[Qemu-devel] [PATCH v3 03/15] target/arm/monitor: Introduce qmp_query_cpu_model_expansion

2019-08-02 Thread Andrew Jones
Add support for the query-cpu-model-expansion QMP command to Arm. We do this selectively, only exposing CPU properties which represent optional CPU features which the user may want to enable/disable. Additionally we restrict the list of queryable cpu models to 'max', 'host', or the current type whe

[Qemu-devel] [PATCH v3 07/15] target/arm: Allow SVE to be disabled via a CPU property

2019-08-02 Thread Andrew Jones
Since 97a28b0eeac14 ("target/arm: Allow VFP and Neon to be disabled via a CPU property") we can disable the 'max' cpu model's VFP and neon features, but there's no way to disable SVE. Add the 'sve=on|off' property to give it that flexibility. We also rename cpu_max_get/set_sve_vq to cpu_max_get/set

[Qemu-devel] [PATCH v3 15/15] target/arm/kvm: host cpu: Add support for sve properties

2019-08-02 Thread Andrew Jones
Allow cpu 'host' to enable SVE when it's available, unless the user chooses to disable it with the added 'sve=off' cpu property. Also give the user the ability to select vector lengths with the sve properties. We don't adopt 'max' cpu's other sve property, sve-max-vq, because that property is diffi

[Qemu-devel] [PATCH v3 09/15] target/arm/kvm64: Fix error returns

2019-08-02 Thread Andrew Jones
A couple return -EINVAL's forgot their '-'s. Signed-off-by: Andrew Jones Reviewed-by: Eric Auger Reviewed-by: Richard Henderson --- target/arm/kvm64.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target/arm/kvm64.c b/target/arm/kvm64.c index 3d91846beb8f..ddde6268b9d

[Qemu-devel] [PATCH v3 10/15] target/arm/kvm64: Move the get/put of fpsimd registers out

2019-08-02 Thread Andrew Jones
Move the getting/putting of the fpsimd registers out of kvm_arch_get/put_registers() into their own helper functions to prepare for alternatively getting/putting SVE registers. No functional change. Signed-off-by: Andrew Jones Reviewed-by: Eric Auger Reviewed-by: Richard Henderson --- target/

[Qemu-devel] [PATCH v3 08/15] target/arm/cpu64: max cpu: Introduce sve properties

2019-08-02 Thread Andrew Jones
Introduce cpu properties to give fine control over SVE vector lengths. We introduce a property for each valid length up to the current maximum supported, which is 2048-bits. The properties are named, e.g. sve128, sve256, sve384, sve512, ..., where the number is the number of bits. See the updates t

[Qemu-devel] [PATCH v3 13/15] target/arm/kvm: scratch vcpu: Preserve input kvm_vcpu_init features

2019-08-02 Thread Andrew Jones
kvm_arm_create_scratch_host_vcpu() takes a struct kvm_vcpu_init parameter. Rather than just using it as an output parameter to pass back the preferred target, use it also as an input parameter, allowing a caller to pass a selected target if they wish and to also pass cpu features. If the caller doe

[Qemu-devel] [PATCH v3 11/15] target/arm/kvm64: Add kvm_arch_get/put_sve

2019-08-02 Thread Andrew Jones
These are the SVE equivalents to kvm_arch_get/put_fpsimd. Note, the swabbing is different than it is for fpsmid because the vector format is a little-endian stream of words. Signed-off-by: Andrew Jones --- target/arm/kvm64.c | 150 +++-- 1 file changed, 14

[Qemu-devel] [PATCH v3 14/15] target/arm/cpu64: max cpu: Support sve properties with KVM

2019-08-02 Thread Andrew Jones
Extend the SVE vq map initialization and validation with KVM's supported vector lengths when KVM is enabled. In order to determine and select supported lengths we add two new KVM functions for getting and setting the KVM_REG_ARM64_SVE_VLS pseudo-register. Signed-off-by: Andrew Jones --- docs/arm

[Qemu-devel] [PATCH v3 12/15] target/arm/kvm64: max cpu: Enable SVE when available

2019-08-02 Thread Andrew Jones
Enable SVE in the KVM guest when the 'max' cpu type is configured and KVM supports it. KVM SVE requires use of the new finalize vcpu ioctl, so we add that now too. For starters SVE can only be turned on or off, getting all vector lengths the host CPU supports when on. We'll add the other SVE CPU pr

Re: [Qemu-devel] [PATCH] qapi: Make visit_next_list()'s comment less confusing

2019-08-02 Thread Eric Blake
On 8/2/19 7:23 AM, Markus Armbruster wrote: > visit_next_list() returns non-null on success, null on failure. The > comment's phrasing "until NULL return or error occurs" is needlessly > confusing. Scratch the "or error occurs" part. > > Signed-off-by: Markus Armbruster > --- > include/qapi/vi

[Qemu-devel] qemu-ga -- virtio driver version reporting

2019-08-02 Thread Tomáš Golembiovský
Hi, I would like to add version reporting of Windows virtio drivers to qemu-ga. Obviously this is specific to Windows as for POSIX systems it corelates with the version of kernel. I would appreciate your ideas on a few topics. Does it make sense to add this information as new (optonal) field to

Re: [Qemu-devel] [PATCH v3] blockjob: drain all job nodes in block_job_drain

2019-08-02 Thread Kevin Wolf
Am 01.08.2019 um 21:44 hat Max Reitz geschrieben: > On 30.07.19 21:11, John Snow wrote: > > > > > > On 7/24/19 5:40 AM, Vladimir Sementsov-Ogievskiy wrote: > >> Instead of draining additional nodes in each job code, let's do it in > >> common block_job_drain, draining just all job's children. > >

Re: [Qemu-devel] [RFC PATCH] numa: add auto_enable_numa to fix broken check in spapr

2019-08-02 Thread David Gibson
On Thu, Aug 01, 2019 at 03:52:58PM +0800, Tao Xu wrote: > Introduce MachineClass::auto_enable_numa for one implicit NUMA node, > and enable it to fix broken check in spapr_validate_node_memory(), when > spapr_populate_memory() creates a implicit node and info then use > nb_numa_nodes which is 0. >

Re: [Qemu-devel] [PATCH 27/28] sysemu: Move the VMChangeStateEntry typedef to qemu/typedefs.h

2019-08-02 Thread Markus Armbruster
Paolo Bonzini writes: > On 26/07/19 14:05, Markus Armbruster wrote: >> +typedef struct VMChangeStateEntry VMChangeStateEntry; >> typedef struct VMStateDescription VMStateDescription; >> > > This is a bit borderline; I'd rather split sysemu/sysemu.h, e.g. adding > sysemu/runstate.h that would h

Re: [Qemu-devel] [RFC PATCH v1 03/22] target/i386: Use prefix, aflag and dflag from DisasContext

2019-08-02 Thread Jan Bobek
Hi Aleksandar, thanks a lot for your feedback! I have to admit that I paid little attention to this particular patch, because it was authored by Richard; I simply included it verbatim. I agree that it would be clearer if it were split into three patches, and the description could be made less conf

Re: [Qemu-devel] [PATCH 24/28] Include sysemu/hostmem.h less

2019-08-02 Thread Markus Armbruster
Paolo Bonzini writes: > On 26/07/19 14:05, Markus Armbruster wrote: >> Move the HostMemoryBackend typedef from sysemu/hostmem.h to >> qemu/typedefs.h. This renders a few inclusions of sysemu/hostmem.h >> superflouous; drop them. > > I think this can also qualify for qemu/typedefs.h, even though

Re: [Qemu-devel] [PATCH 27/28] sysemu: Move the VMChangeStateEntry typedef to qemu/typedefs.h

2019-08-02 Thread Paolo Bonzini
On 02/08/19 15:16, Markus Armbruster wrote: > * VMChangeStateEntry and the three functions using it, obviously, along > with VMChangeStateHandler. > > * vm_state_notify(), because it belongs to the above. > > * The runstate_FOO() functions, because they're named like the new > header? > > *

Re: [Qemu-devel] [RFC PATCH v1 05/22] target/i386: introduce gen_ld_modrm_* helpers

2019-08-02 Thread Jan Bobek
On 7/31/19 3:08 PM, Richard Henderson wrote: > On 7/31/19 10:56 AM, Jan Bobek wrote: >> These help with decoding/loading ModR/M vector operands; the operand's >> register offset is returned, which is suitable for use with gvec >> infrastructure. >> >> Signed-off-by: Jan Bobek >> --- >> target/i38

[Qemu-devel] [PATCH for-4.2 v3 0/2] s390: stop abusing memory_region_allocate_system_memory()

2019-08-02 Thread Igor Mammedov
Changelog: since v2: - break migration from old QEMU (since 2.12-4.1) for guest with >8TB RAM and drop migratable aliases patch as was agreed during v2 review - drop 4.2 machines patch as it's not prerequisite anymore since v1: - include 4.2 machines patch for adding compat

[Qemu-devel] [PATCH for-4.2 v3 1/2] kvm: s390: split too big memory section on several memslots

2019-08-02 Thread Igor Mammedov
Max memslot size supported by kvm on s390 is 8Tb, move logic of splitting RAM in chunks upto 8T to KVM code. This way it will hide KVM specific restrictions in KVM code and won't affect baord level design decisions. Which would allow us to avoid misusing memory_region_allocate_system_memory() API

[Qemu-devel] [PATCH for-4.2 v3 2/2] s390: do not call memory_region_allocate_system_memory() multiple times

2019-08-02 Thread Igor Mammedov
s390 was trying to solve limited KVM memslot size issue by abusing memory_region_allocate_system_memory(), which breaks API contract where the function might be called only once. Beside an invalid use of API, the approach also introduced migration issue, since RAM chunks for each KVM_SLOT_MAX_BYTE

Re: [Qemu-devel] [RFC PATCH v1 06/22] target/i386: introduce gen_gvec_ld_modrm_* helpers

2019-08-02 Thread Jan Bobek
On 7/31/19 6:47 PM, Richard Henderson wrote: > I suppose there aren't so many different combinations, but did you consider > separate callbacks per operand? If you have > > typedef unsigned (*gen_offset)(CPUX86State *, DisasContext *, int); > > static unsigned offset_Pq(CPUX86State *env, DisasCo

Re: [Qemu-devel] [PATCH v2 for-4.1 0/2] backup: Copy only dirty areas

2019-08-02 Thread Kevin Wolf
Am 01.08.2019 um 19:38 hat Max Reitz geschrieben: > Hi, > > In a discussion with Vladimir today, we noticed that the backup job > currently is pretty broken when using copy offloading. I don’t know > about you, but my local filesystem (XFS) supports copy offloading, so > the job uses it automatic

Re: [Qemu-devel] [PATCH for-4.2 v3 2/2] s390: do not call memory_region_allocate_system_memory() multiple times

2019-08-02 Thread David Hildenbrand
On 02.08.19 15:32, Igor Mammedov wrote: > s390 was trying to solve limited KVM memslot size issue by abusing > memory_region_allocate_system_memory(), which breaks API contract > where the function might be called only once. > > Beside an invalid use of API, the approach also introduced migration

Re: [Qemu-devel] [PATCH for-4.2 v3 2/2] s390: do not call memory_region_allocate_system_memory() multiple times

2019-08-02 Thread Christian Borntraeger
On 02.08.19 15:36, David Hildenbrand wrote: > On 02.08.19 15:32, Igor Mammedov wrote: >> s390 was trying to solve limited KVM memslot size issue by abusing >> memory_region_allocate_system_memory(), which breaks API contract >> where the function might be called only once. >> >> Beside an invali

Re: [Qemu-devel] [PATCH for-4.2 v3 2/2] s390: do not call memory_region_allocate_system_memory() multiple times

2019-08-02 Thread David Hildenbrand
On 02.08.19 15:41, Christian Borntraeger wrote: > > > On 02.08.19 15:36, David Hildenbrand wrote: >> On 02.08.19 15:32, Igor Mammedov wrote: >>> s390 was trying to solve limited KVM memslot size issue by abusing >>> memory_region_allocate_system_memory(), which breaks API contract >>> where the f

Re: [Qemu-devel] [PATCH v2 for-4.1 0/2] backup: Copy only dirty areas

2019-08-02 Thread Max Reitz
On 02.08.19 15:34, Kevin Wolf wrote: > Am 01.08.2019 um 19:38 hat Max Reitz geschrieben: >> Hi, >> >> In a discussion with Vladimir today, we noticed that the backup job >> currently is pretty broken when using copy offloading. I don’t know >> about you, but my local filesystem (XFS) supports copy

Re: [Qemu-devel] [PATCH for-4.2 v3 1/2] kvm: s390: split too big memory section on several memslots

2019-08-02 Thread Christian Borntraeger
On 02.08.19 15:32, Igor Mammedov wrote: > Max memslot size supported by kvm on s390 is 8Tb, > move logic of splitting RAM in chunks upto 8T to KVM code. > > This way it will hide KVM specific restrictions in KVM code > and won't affect baord level design decisions. Which would allow > us to avo

Re: [Qemu-devel] [RFC PATCH v1 08/22] target/i386: reimplement (V)PAND, (V)ANDPS, (V)ANDPD

2019-08-02 Thread Jan Bobek
On 7/31/19 3:35 PM, Richard Henderson wrote: > On 7/31/19 10:56 AM, Jan Bobek wrote: >> +#define gen_pand_mm(env, s, modrm) gen_gvec_ld_modrm_mm ((env), (s), >> (modrm), MO_64, tcg_gen_gvec_and, 0112) >> +#define gen_pand_xmm(env, s, modrm) gen_gvec_ld_modrm_xmm ((env), (s), >> (modrm), MO_64

[Qemu-devel] [PATCH] block: Simplify bdrv_filter_default_perms()

2019-08-02 Thread Kevin Wolf
The same change as commit 2b23f28639 ('block/copy-on-read: Fix permissions for inactive node') made for the copy-on-read driver can be made for bdrv_filter_default_perms(): Retaining the old permissions from the BdrvChild if it is given complicates things unnecessary when in the end this only means

  1   2   >