[RFC 5/5] spapr: Work around spurious warnings from vfio INTx initialization

2019-10-16 Thread David Gibson
Traditional PCI INTx for vfio devices can only perform well if using an in-kernel irqchip. Therefore, vfio_intx_update() issues a warning if an in kernel irqchip is not available. We usually do have an in-kernel irqchip available for pseries machines on POWER hosts. However, because the

[RFC 4/5] spapr: Handle irq backend changes with VFIO PCI devices

2019-10-16 Thread David Gibson
pseries machine type can have one of two different interrupt controllers in use depending on feature negotiation with the guest. Usually this is invisible to devices, because they route to a common set of qemu_irqs which in turn dispatch to the correct back end. VFIO passthrough devices,

[RFC 1/5] kvm: Introduce KVM irqchip change notifier

2019-10-16 Thread David Gibson
Awareness of an in kernel irqchip is usually local to the machine and its top-level interrupt controller. However, in a few cases other things need to know about it. In particular vfio devices need this in order to accelerate interrupt delivery. If interrupt routing is changed, such devices may

[RFC 2/5] vfio/pci: Split vfio_intx_update()

2019-10-16 Thread David Gibson
This splits the vfio_intx_update() function into one part doing the actual reconnection with the KVM irqchip (vfio_intx_update(), now taking an argument with the new routing) and vfio_intx_routing_notifier() which handles calls to the pci device intx routing notifier and calling vfio_intx_update()

[RFC 3/5] vfio/pci: Respond to KVM irqchip change notifier

2019-10-16 Thread David Gibson
VFIO PCI devices already respond to the pci intx routing notifier, in order to update kernel irqchip mappings when routing is updated. However this won't handle the case where the irqchip itself is replaced by a different model while retaining the same routing. This case can happen on the

[RFC 0/5] Handle PAPR irq chip changes for VFIO devices

2019-10-16 Thread David Gibson
The pseries machine type has the odd property that it's root irq chip can be completely changed at runtime. This comes about because PAPR feature negotiation lets the guest choose between the old XICS style or new XIVE style PIC. It's possible, because both PICs are paravirtualized via

Re: [PATCH 0/4] target/arm vector improvements

2019-10-16 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20191017044232.27601-1-richard.hender...@linaro.org/ Hi, This series seems to have some coding style problems. See output below for more information: Subject: [PATCH 0/4] target/arm vector improvements Type: series Message-id:

Re: [Patch v2] checkpatch: sugguest to use qemu_real_host_page_size instead of getpagesize() or sysconf(_SC_PAGESIZE)

2019-10-16 Thread Richard Henderson
On 10/16/19 5:46 PM, Wei Yang wrote: > Signed-off-by: Wei Yang > CC: Richard Henderson > CC: Stefan Hajnoczi > > --- > v2: add "\b" for better match, suggested by Richard Henderson > > --- > scripts/checkpatch.pl | 6 ++ > 1 file changed, 6 insertions(+) Reviewed-by: Richard Henderson

[PATCH 4/4] target/arm: Convert PMULL.8 to gvec

2019-10-16 Thread Richard Henderson
We still need two different helpers, since NEON and SVE2 get the inputs from different locations within the source vector. However, we can convert both to the same internal form for computation. The sve2 helper is not used yet, but adding it with this patch helps illustrate why the neon changes

[PATCH 1/4] target/arm: Vectorize USHL and SSHL

2019-10-16 Thread Richard Henderson
These instructions shift left or right depending on the sign of the input, and 7 bits are significant to the shift. This requires several masks and selects in addition to the actual shifts to form the complete answer. That said, the operation is still a small improvement even for two 64-bit

[PATCH 3/4] target/arm: Convert PMULL.64 to gvec

2019-10-16 Thread Richard Henderson
The gvec form will be needed for implementing SVE2. Signed-off-by: Richard Henderson --- target/arm/helper.h| 4 +--- target/arm/neon_helper.c | 30 -- target/arm/translate-a64.c | 28 +++- target/arm/translate.c | 16

[PATCH 2/4] target/arm: Convert PMUL.8 to gvec

2019-10-16 Thread Richard Henderson
The gvec form will be needed for implementing SVE2. Extend the implementation to operate on uint64_t instead of uint32_t. Use a counted inner loop instead of terminating when op1 goes to zero, looking toward the required implementation for ARMv8.4-DIT. Signed-off-by: Richard Henderson ---

[PATCH 0/4] target/arm vector improvements

2019-10-16 Thread Richard Henderson
The first patch has been seen before. https://patchwork.ozlabs.org/patch/1115039/ It had a bug and I didn't fix it right away and then forgot. Fixed now; I had mixed up the operand ordering for aarch32. The next 3 are something that I noticed while doing other stuff. In particular, pmull is

Re: [Patch v2] checkpatch: sugguest to use qemu_real_host_page_size instead of getpagesize() or sysconf(_SC_PAGESIZE)

2019-10-16 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20191017004633.13229-1-richardw.y...@linux.intel.com/ Hi, This series seems to have some coding style problems. See output below for more information: Subject: [Patch v2] checkpatch: sugguest to use qemu_real_host_page_size instead of getpagesize() or

Re: [PATCH v4 00/19] spapr: IRQ subsystem cleanup

2019-10-16 Thread David Gibson
On Wed, Oct 16, 2019 at 06:04:04PM +0200, Greg Kurz wrote: > On Wed, 9 Oct 2019 17:07:59 +1100 > David Gibson wrote: > > > This is a substantial rework to clean up the handling of IRQs in > > spapr. It includes some cleanups to both the XICS and XIVE interrupt > > controller backends, as well

[Patch v2] checkpatch: sugguest to use qemu_real_host_page_size instead of getpagesize() or sysconf(_SC_PAGESIZE)

2019-10-16 Thread Wei Yang
Signed-off-by: Wei Yang CC: Richard Henderson CC: Stefan Hajnoczi --- v2: add "\b" for better match, suggested by Richard Henderson --- scripts/checkpatch.pl | 6 ++ 1 file changed, 6 insertions(+) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index aa9a354a0e..ab68a16fd2

Re: [PATCH] checkpatch: sugguest to use qemu_real_host_page_size instead of getpagesize() or sysconf(_SC_PAGESIZE)

2019-10-16 Thread Wei Yang
On Wed, Oct 16, 2019 at 07:48:50PM +0100, Stefan Hajnoczi wrote: >On Wed, Oct 16, 2019 at 09:24:32AM +0800, Wei Yang wrote: >> Signed-off-by: Wei Yang >> CC: David Gibson >> --- >> scripts/checkpatch.pl | 6 ++ >> 1 file changed, 6 insertions(+) >> >> diff --git a/scripts/checkpatch.pl

Re: [PATCH] checkpatch: sugguest to use qemu_real_host_page_size instead of getpagesize() or sysconf(_SC_PAGESIZE)

2019-10-16 Thread Wei Yang
On Wed, Oct 16, 2019 at 08:43:32AM -0700, Richard Henderson wrote: >On 10/15/19 6:24 PM, Wei Yang wrote: >> if ($line =~ /\bbzero\(/) { >> ERROR("use memset() instead of bzero()\n" . $herecurr); >> } >> +if ($line =~ /getpagesize\(\)/) {

Re: [PATCH v3 10/10] vfio: unplug failover primary device before migration

2019-10-16 Thread Alex Williamson
On Wed, 16 Oct 2019 22:18:47 +0200 Jens Freimann wrote: > On Tue, Oct 15, 2019 at 07:52:12PM -0600, Alex Williamson wrote: > >On Fri, 11 Oct 2019 13:20:15 +0200 > >Jens Freimann wrote: > > > >> As usual block all vfio-pci devices from being migrated, but make an > >> exception for failover

Re: [PATCH] ssi: xilinx_spips: Filter the non spi registers transactions

2019-10-16 Thread Alistair Francis
On Sun, Oct 13, 2019 at 11:51 PM Sai Pavan Boddu wrote: > > ZynqMP/Versal specific qspi registers should be handled inside > zynqmp_qspi_read/write calls. When few of these transactions are handled by > spi hooks we see state change in spi bus unexpectedly. > > Signed-off-by: Sai Pavan Boddu >

Re: [PATCH] configure: Require Python >= 3.5

2019-10-16 Thread John Snow
On 10/16/19 6:42 PM, Eduardo Habkost wrote: > Python 3.5 is the oldest Python version available on our > supported build platforms, and Python 2 end of life will be 3 > weeks after the planned release date of QEMU 4.2.0. Drop Python > 2 support from configure completely, and require Python 3.5

[PATCH] configure: Require Python >= 3.5

2019-10-16 Thread Eduardo Habkost
Python 3.5 is the oldest Python version available on our supported build platforms, and Python 2 end of life will be 3 weeks after the planned release date of QEMU 4.2.0. Drop Python 2 support from configure completely, and require Python 3.5 or newer. Signed-off-by: Eduardo Habkost ---

Re: Python 2 and test/vm/netbsd

2019-10-16 Thread Eduardo Habkost
On Wed, Oct 16, 2019 at 08:11:57AM +0200, Thomas Huth wrote: > On 16/10/2019 05.00, Eduardo Habkost wrote: > > On Tue, Sep 17, 2019 at 08:31:40PM -0300, Eduardo Habkost wrote: > >> On Mon, Jul 01, 2019 at 07:25:27PM -0300, Eduardo Habkost wrote: > >>> On Mon, Jun 10, 2019 at 01:58:50PM +0100,

Re: [PATCH v10 2/3] block/nbd: nbd reconnect

2019-10-16 Thread Eric Blake
On 10/9/19 3:41 AM, Vladimir Sementsov-Ogievskiy wrote: Implement reconnect. To achieve this: 1. add new modes: connecting-wait: means, that reconnecting is in progress, and there were small number of reconnect attempts, so all requests are waiting for the connection.

[PATCH] enable translating statx syscalls on more arches

2019-10-16 Thread Andrew Kelley
Signed-off-by: Andrew Kelley --- linux-user/aarch64/syscall_nr.h | 13 ++ linux-user/arm/syscall_nr.h | 38 linux-user/i386/syscall_nr.h| 43 linux-user/mips/cpu_loop.c | 6 + linux-user/ppc/syscall_nr.h

Re: Using virtual IOMMU in guest hypervisors other than KVM and Xen?

2019-10-16 Thread Jintack Lim
On Mon, Oct 14, 2019 at 7:50 PM Peter Xu wrote: > > On Mon, Oct 14, 2019 at 01:28:49PM -0700, Jintack Lim wrote: > > Hi, > > Hello, Jintack, > Hi Peter, > > > > I'm trying to pass through a physical network device to a nested VM > > using virtual IOMMU. While I was able to do it successfully

Re: [PATCH v1 22/28] target/riscv: Allow specifying MMU stage

2019-10-16 Thread Alistair Francis
On Wed, Oct 16, 2019 at 12:02 PM Palmer Dabbelt wrote: > > On Mon, 07 Oct 2019 11:05:33 PDT (-0700), alistai...@gmail.com wrote: > > On Thu, Oct 3, 2019 at 8:53 AM Palmer Dabbelt wrote: > >> > >> On Fri, 23 Aug 2019 16:38:47 PDT (-0700), Alistair Francis wrote: > >> > Signed-off-by: Alistair

Re: [PATCH v1 27/28] target/riscv: Add the MSTATUS_MPV_ISSET helper macro

2019-10-16 Thread Alistair Francis
On Tue, Oct 8, 2019 at 11:36 AM Palmer Dabbelt wrote: > > On Fri, 23 Aug 2019 16:39:00 PDT (-0700), Alistair Francis wrote: > > Add a helper macro MSTATUS_MPV_ISSET() which will determine if the > > MSTATUS_MPV bit is set for both 32-bit and 64-bit RISC-V. > > > > Signed-off-by: Alistair Francis

Re: [PATCH v1 21/28] target/riscv: Respect MPRV and SPRV for floating point ops

2019-10-16 Thread Alistair Francis
On Wed, Oct 2, 2019 at 4:52 PM Palmer Dabbelt wrote: > > On Fri, 23 Aug 2019 16:38:44 PDT (-0700), Alistair Francis wrote: > > Respect the contents of MSTATUS.MPRV and HSTATUS.SPRV when performing > > floating point operations when V=0. > > I'm confused as to what this has to do with floating

Re: [PATCH v1 04/28] target/riscv: Fix CSR perm checking for HS mode

2019-10-16 Thread Alistair Francis
On Tue, Sep 10, 2019 at 7:48 AM Palmer Dabbelt wrote: > > On Fri, 23 Aug 2019 16:38:00 PDT (-0700), Alistair Francis wrote: > > Update the CSR permission checking to work correctly when we are in > > HS-mode. > > > > Signed-off-by: Alistair Francis > > --- > > target/riscv/csr.c | 10 --

Re: [PATCH v9 04/15] hw/i386/pc: replace use of strtol with qemu_strtol in x86_load_linux()

2019-10-16 Thread Markus Armbruster
Philippe Mathieu-Daudé writes: > Hi Sergio, > > On 10/15/19 1:23 PM, Sergio Lopez wrote: >> Follow checkpatch.pl recommendation and replace the use of strtol with >> qemu_strtol in x86_load_linux(). > > "with qemu_strtoui" > >> >> Signed-off-by: Sergio Lopez >> --- >> hw/i386/pc.c | 9

Re: [PATCH 5/5] aspeed/i2c: Add trace events

2019-10-16 Thread Jae Hyun Yoo
On 10/16/2019 1:50 AM, Cédric Le Goater wrote: Signed-off-by: Cédric Le Goater Tested-by: Jae Hyun Yoo Thanks for the implementation! -Jae

Re: [PATCH v3 10/10] vfio: unplug failover primary device before migration

2019-10-16 Thread Jens Freimann
On Tue, Oct 15, 2019 at 07:52:12PM -0600, Alex Williamson wrote: On Fri, 11 Oct 2019 13:20:15 +0200 Jens Freimann wrote: As usual block all vfio-pci devices from being migrated, but make an exception for failover primary devices. This is achieved by setting unmigratable to 0 but also add a

Re: [PATCH 4/5] aspeed/i2c: Add support for DMA transfers

2019-10-16 Thread Jae Hyun Yoo
On 10/16/2019 1:50 AM, Cédric Le Goater wrote: The I2C controller of the Aspeed AST2500 and AST2600 SoCs supports DMA transfers to and from DRAM. A pair of registers defines the buffer address and the length of the DMA transfer. The address should be aligned on 4 bytes and the maximum length

Re: [PATCH 2/5] aspeed/i2c: Check SRAM enablement on A2500

2019-10-16 Thread Jae Hyun Yoo
On 10/16/2019 1:50 AM, Cédric Le Goater wrote: The SRAM must be enabled before using the Buffer Pool mode or the DMA mode. This is not required on other SoCs. Signed-off-by: Cédric Le Goater Tested-by: Jae Hyun Yoo

Re: [PATCH 1/5] aspeed/i2c: Add support for pool buffer transfers

2019-10-16 Thread Jae Hyun Yoo
On 10/16/2019 1:50 AM, Cédric Le Goater wrote: The Aspeed I2C controller can operate in different transfer modes : - Byte Buffer mode, using a dedicated register to transfer a byte. This is what the model supports today. - Pool Buffer mode, using an internal SRAM to transfer

Re: [PATCH 3/5] aspeed: Add a DRAM memory region at the SoC level

2019-10-16 Thread Jae Hyun Yoo
On 10/16/2019 1:50 AM, Cédric Le Goater wrote: Currently, we link the DRAM memory region to the FMC model (for DMAs) through a property alias at the SoC level. The I2C model will need a similar region for DMA support, add a DRAM region property at the SoC level for both model to use.

Re: [PATCH v8 0/8] Add Qemu to SeaBIOS LCHS interface

2019-10-16 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20191016164145.115898-1-sam...@google.com/ Hi, This series seems to have some coding style problems. See output below for more information: Subject: [PATCH v8 0/8] Add Qemu to SeaBIOS LCHS interface Type: series Message-id:

Re: [PATCH v10 14/15] hw/i386: Introduce the microvm machine type

2019-10-16 Thread Marc-André Lureau
Hi On Wed, Oct 16, 2019 at 12:24 PM Sergio Lopez wrote: > > microvm is a machine type inspired by Firecracker and constructed > after its machine model. > > It's a minimalist machine type without PCI nor ACPI support, designed > for short-lived guests. microvm also establishes a baseline for >

[PATCH 08/10] image-fuzzer: Encode file name and file format to bytes

2019-10-16 Thread Eduardo Habkost
Callers of create_image() will pass strings as arguments, but the Image class will expect bytes objects to be provided. Encode them inside create_image(). Signed-off-by: Eduardo Habkost --- tests/image-fuzzer/qcow2/layout.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

[PATCH 07/10] image-fuzzer: Use bytes constant for field values

2019-10-16 Thread Eduardo Habkost
Field values are supposed to be bytes objects, not unicode strings. Change two constants that were declared as strings. Signed-off-by: Eduardo Habkost --- tests/image-fuzzer/qcow2/layout.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

[PATCH 06/10] image-fuzzer: Return bytes objects on string fuzzing functions

2019-10-16 Thread Eduardo Habkost
No caller of fuzzer functions is interested in unicode string values, so replace them with bytes sequences. Signed-off-by: Eduardo Habkost --- tests/image-fuzzer/qcow2/fuzz.py | 42 1 file changed, 21 insertions(+), 21 deletions(-) diff --git

[PATCH 05/10] image-fuzzer: Use %r for all fiels at Field.__repr__()

2019-10-16 Thread Eduardo Habkost
This makes the formatting code simpler, and safer if we change the type of self.value from str to bytes. Signed-off-by: Eduardo Habkost --- tests/image-fuzzer/qcow2/layout.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/image-fuzzer/qcow2/layout.py

[PATCH 04/10] image-fuzzer: Use io.StringIO

2019-10-16 Thread Eduardo Habkost
StringIO.StringIO is not available on Python 3, but io.StringIO is available on both Python 2 and 3. io.StringIO is slightly different from the Python 2 StringIO module, though, so we need bytes coming from subprocess.Popen() to be explicitly decoded. Signed-off-by: Eduardo Habkost ---

[PATCH 09/10] image-fuzzer: Run using python3

2019-10-16 Thread Eduardo Habkost
image-fuzzer is now supposed to be ready to run using Python 3. Remove the __future__ imports and change the interpreter line to "#!/usr/bin/env python3". Signed-off-by: Eduardo Habkost --- tests/image-fuzzer/qcow2/__init__.py | 1 - tests/image-fuzzer/qcow2/layout.py | 1 -

[PATCH 10/10] image-fuzzer: Use errors parameter of subprocess.Popen()

2019-10-16 Thread Eduardo Habkost
Instead of manually encoding stderr and stdout output, use `errors` parameter of subprocess.Popen(). This will make process.communicate() return unicode strings instead of bytes objects. Signed-off-by: Eduardo Habkost --- tests/image-fuzzer/runner.py | 11 --- 1 file changed, 4

[PATCH 03/10] image-fuzzer: Explicitly use integer division operator

2019-10-16 Thread Eduardo Habkost
Most of the division expressions in image-fuzzer assume integer division. Use the // operator to keep the same behavior when we move to Python 3. Signed-off-by: Eduardo Habkost --- tests/image-fuzzer/qcow2/fuzz.py | 12 - tests/image-fuzzer/qcow2/layout.py | 40

[PATCH 01/10] image-fuzzer: Open image files in binary mode

2019-10-16 Thread Eduardo Habkost
This probably never caused problems because on Linux there's no actual newline conversion happening, but on Python 3 the binary/text distinction is stronger and we must explicitly open the image file in binary mode. Signed-off-by: Eduardo Habkost --- tests/image-fuzzer/qcow2/layout.py | 2 +- 1

[PATCH 02/10] image-fuzzer: Write bytes instead of string to image file

2019-10-16 Thread Eduardo Habkost
This is necessary for Python 3 compatibility. Signed-off-by: Eduardo Habkost --- tests/image-fuzzer/qcow2/layout.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/image-fuzzer/qcow2/layout.py b/tests/image-fuzzer/qcow2/layout.py index c57418fa15..fe273d4143 100644

[PATCH 00/10] image-fuzzer: Port to Python 3

2019-10-16 Thread Eduardo Habkost
This series ports image-fuzzer to Python 3. Eduardo Habkost (10): image-fuzzer: Open image files in binary mode image-fuzzer: Write bytes instead of string to image file image-fuzzer: Explicitly use integer division operator image-fuzzer: Use io.StringIO image-fuzzer: Use %r for all

Re: [PATCH v4 0/4] qcow2: advanced compression options

2019-10-16 Thread no-reply
Patchew URL: https://patchew.org/QEMU/157124-882302-1-git-send-email-andrey.shinkev...@virtuozzo.com/ Hi, This series failed the docker-mingw@fedora build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally.

Re: [PATCH v4 0/4] qcow2: advanced compression options

2019-10-16 Thread no-reply
Patchew URL: https://patchew.org/QEMU/157124-882302-1-git-send-email-andrey.shinkev...@virtuozzo.com/ Hi, This series failed the docker-quick@centos7 build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally.

Re: [PATCH v1 22/28] target/riscv: Allow specifying MMU stage

2019-10-16 Thread Palmer Dabbelt
On Mon, 07 Oct 2019 11:05:33 PDT (-0700), alistai...@gmail.com wrote: On Thu, Oct 3, 2019 at 8:53 AM Palmer Dabbelt wrote: On Fri, 23 Aug 2019 16:38:47 PDT (-0700), Alistair Francis wrote: > Signed-off-by: Alistair Francis > --- > target/riscv/cpu_helper.c | 39

Re: [PATCH v3] target/arm/arch_dump: Add SVE notes

2019-10-16 Thread Richard Henderson
On 10/16/19 9:37 AM, Andrew Jones wrote: > When dumping a guest with dump-guest-memory also dump the SVE > registers if they are in use. > > Signed-off-by: Andrew Jones > --- > v3: > - Pulled sve_bswap64 out of kvm64.c and reused it here > - Changed fpsr_offset and sve_size to only align to

Re: [PATCH] checkpatch: sugguest to use qemu_real_host_page_size instead of getpagesize() or sysconf(_SC_PAGESIZE)

2019-10-16 Thread Stefan Hajnoczi
On Wed, Oct 16, 2019 at 09:24:32AM +0800, Wei Yang wrote: > Signed-off-by: Wei Yang > CC: David Gibson > --- > scripts/checkpatch.pl | 6 ++ > 1 file changed, 6 insertions(+) > > diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl > index aa9a354a0e..4b360ed310 100755 > ---

Re: [PATCH] virito: Use auto rcu_read macros

2019-10-16 Thread Stefan Hajnoczi
On Mon, Oct 14, 2019 at 06:54:40PM +0100, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Use RCU_READ_LOCK_GUARD and WITH_RCU_READ_LOCK_GUARD > to replace the manual rcu_read_(un)lock calls. > > I think the only change is virtio_load which was missing unlocks > in

Re: [PATCH 0/5] travis.yml improvements: Update libraries, build with arm64

2019-10-16 Thread Alex Bennée
Thomas Huth writes: > Update / add some libraries that we use in the Travis builds, and > enable compiling on the aarch64 host, too. Queued 1-3 to testing/next and I'll have a play with 4/5 but probably won't include them in the final PR unless they seem solid. > > Thomas Huth (5): >

[Bug 1848244] Re: QEMU KVM IGD SandyBridge Passthrough crash

2019-10-16 Thread Anastasios Vacharakis
Solved: I added kvm.ignore_msrs=1 to kernel parameter! -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1848244 Title: QEMU KVM IGD SandyBridge Passthrough crash Status in QEMU: New Bug

[Bug 1846427] Re: 4.1.0: qcow2 corruption on savevm/quit/loadvm cycle

2019-10-16 Thread psyhomb
I can confirm exactly the same issue on Arch linux running qemu-4.1.0. After downgrading from 4.1.0 => 4.0.0 everything is running normal again, no corruption detected and all qcow2 images stays healthy. -- You received this bug notification because you are a member of qemu- devel-ml, which is

[Bug 1847793] Re: qemu 4.1.0 - Corrupt guest filesystem after new vm install

2019-10-16 Thread psyhomb
I can confirm exactly the same issue on Arch linux with ext4 filesystem (qemu-4.1.0). After downgrading from 4.1.0 => 4.0.0 everything is running normal again, no corruption detected and all qcow2 images stays healthy. -- You received this bug notification because you are a member of qemu-

[PATCH] migration: savevm_state_insert_handler: constant-time element insertion

2019-10-16 Thread Scott Cheloha
Registering a SaveStateEntry object via savevm_state_insert_handler() is an O(n) operation because the list is a priority queue maintained by walking the list from head to tail to find a suitable insertion point. This adds considerable overhead for VMs with many such objects. For instance, ppc64

[PATCH v2 6/6] block/block-copy: increase buffered copy request

2019-10-16 Thread Vladimir Sementsov-Ogievskiy
No reason to limit buffered copy to one cluster. Let's allow up to 1 MiB. Signed-off-by: Vladimir Sementsov-Ogievskiy --- include/block/block-copy.h | 2 +- block/block-copy.c | 48 +- 2 files changed, 33 insertions(+), 17 deletions(-) diff --git

[PATCH v2 1/6] block/block-copy: allocate buffer in block_copy_with_bounce_buffer

2019-10-16 Thread Vladimir Sementsov-Ogievskiy
Move bounce_buffer allocation block_copy_with_bounce_buffer. This commit simplifies further work on implementing copying by larger chunks (of different size) and further asynchronous handling of block_copy iterations (with help of block/aio_task API). Allocation works fast, a lot faster than disk

[PATCH v2 0/6] block-copy: memory limit

2019-10-16 Thread Vladimir Sementsov-Ogievskiy
I'm going to bring block-status driven, async copying process to block-copy, to make it fast. The first step is to limit memory usage of backup, here is it. v2: [mostly by Max's comments] Now based on master (Thank you Max!) 01: add Max's r-b 02: add Max's r-b 03: - refactor block_copy_do_copy

[PATCH v2 3/6] block/block-copy: refactor copying

2019-10-16 Thread Vladimir Sementsov-Ogievskiy
Merge copying code into one function block_copy_do_copy, which only calls bdrv_ io functions and don't do any synchronization (like dirty bitmap set/reset). Refactor block_copy() function so that it takes full decision about size of chunk to be copied and does all the synchronization (checking

[PATCH v2 2/6] block/block-copy: limit copy_range_size to 16 MiB

2019-10-16 Thread Vladimir Sementsov-Ogievskiy
Large copy range may imply memory allocation and large io effort, so using 2G copy range request may be bad idea. Let's limit it to 16 MiB. It also helps the following patch to refactor copy-with-offload fallback to copy-with-bounce-buffer. Note, that total memory usage of backup is still not

[PATCH v2 4/6] util: introduce SharedResource

2019-10-16 Thread Vladimir Sementsov-Ogievskiy
Introduce an API for some shared splittable resource, like memory. It's going to be used by backup. Backup uses both read/write io and copy_range. copy_range may consume memory implictly, so the new API is abstract: it doesn't allocate any real memory by but only hands out tickets. The idea is

[PATCH v2 5/6] block/block-copy: add memory limit

2019-10-16 Thread Vladimir Sementsov-Ogievskiy
Currently total allocation for parallel requests to block-copy instance is unlimited. Let's limit it to 128 MiB. For now block-copy is used only in backup, so actually we limit total allocation for backup job. Signed-off-by: Vladimir Sementsov-Ogievskiy --- include/block/block-copy.h | 3 +++

Re: [PATCH v1 1/5] contrib/gitdm: add more entries individuals and academics

2019-10-16 Thread Philippe Mathieu-Daudé
On 10/14/19 3:59 PM, Alex Bennée wrote: Again this is guess work based on public websites. Please confirm. Signed-off-by: Alex Bennée Cc: Emanuele Giuseppe Esposito Cc: Bastian Koppelmann Cc: "Kővágó, Zoltán" Cc: Li Qiang Cc: Li Qiang --- contrib/gitdm/group-map-academics | 3 +++

Re: [PATCH] Added hardfloat conversion from float32 to float64

2019-10-16 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20191016073240.12473-1-mky...@tachyum.com/ Hi, This series seems to have some coding style problems. See output below for more information: Subject: [PATCH] Added hardfloat conversion from float32 to float64 Type: series Message-id:

Re: [PATCH] s390x/cpumodel: Add missing visit_free

2019-10-16 Thread David Hildenbrand
On 16.10.19 16:54, Andrew Jones wrote: Beata Michalska noticed this missing visit_free() while reviewing arm's implementation of qmp_query_cpu_model_expansion(), which is modeled off this s390x implementation. Nice to see ARM support getting added. Signed-off-by: Andrew Jones ---

[PATCH v8 8/8] hd-geo-test: Add tests for lchs override

2019-10-16 Thread Sam Eiderman
From: Sam Eiderman Add QTest tests to check the logical geometry override option. The tests in hd-geo-test are out of date - they only test IDE and do not test interesting MBRs. Creating qcow2 disks with specific size and MBR layout is currently unused - we only use a default empty MBR.

[PATCH v8 7/8] bootdevice: FW_CFG interface for LCHS values

2019-10-16 Thread Sam Eiderman
From: Sam Eiderman Using fw_cfg, supply logical CHS values directly from QEMU to the BIOS. Non-standard logical geometries break under QEMU. A virtual disk which contains an operating system which depends on logical geometries (consistent values being reported from BIOS INT13 AH=08) will most

[PATCH v8 5/8] bootdevice: Gather LCHS from all relevant devices

2019-10-16 Thread Sam Eiderman
From: Sam Eiderman Relevant devices are: * ide-hd (and ide-cd, ide-drive) * scsi-hd (and scsi-cd, scsi-disk, scsi-block) * virtio-blk-pci We do not call del_boot_device_lchs() for ide-* since we don't need to - IDE block devices do not support unplugging. Reviewed-by: Karl Heubaum

Re: [SeaBIOS] Re: [PATCH v7 7/8] bootdevice: FW_CFG interface for LCHS values

2019-10-16 Thread Philippe Mathieu-Daudé
On 10/16/19 5:19 PM, Sam Eiderman wrote: Sure! Philippe withdrew his R-b on 7/8, as I explained 7/8 is fine (only need to remove a bad comment) the problem was in the tests 8/8 - should I include the original R/b? I withdrew it because John was preparing his pull request, and I needed more

[PATCH v8 6/8] bootdevice: Refactor get_boot_devices_list

2019-10-16 Thread Sam Eiderman
From: Sam Eiderman Move device name construction to a separate function. We will reuse this function in the following commit to pass logical CHS parameters through fw_cfg much like we currently pass bootindex. Reviewed-by: Karl Heubaum Reviewed-by: Arbel Moshe Reviewed-by: Philippe

[PATCH v8 4/8] scsi: Propagate unrealize() callback to scsi-hd

2019-10-16 Thread Sam Eiderman
From: Sam Eiderman We will need to add LCHS removal logic to scsi-hd's unrealize() in the next commit. Reviewed-by: Karl Heubaum Reviewed-by: Arbel Moshe Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Sam Eiderman Signed-off-by: Sam Eiderman --- hw/scsi/scsi-bus.c | 16

[PATCH v8 1/8] block: Refactor macros - fix tabbing

2019-10-16 Thread Sam Eiderman
From: Sam Eiderman Fixing tabbing in block related macros. Reviewed-by: Karl Heubaum Reviewed-by: Arbel Moshe Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Sam Eiderman Signed-off-by: Sam Eiderman --- hw/ide/qdev.c| 2 +- include/hw/block/block.h | 16 2

[PATCH v8 3/8] bootdevice: Add interface to gather LCHS

2019-10-16 Thread Sam Eiderman
From: Sam Eiderman Add an interface to provide direct logical CHS values for boot devices. We will use this interface in the next commits. Reviewed-by: Karl Heubaum Reviewed-by: Arbel Moshe Signed-off-by: Sam Eiderman Signed-off-by: Sam Eiderman --- bootdevice.c| 55

[PATCH v8 1/1] hd-geo-test: Add tests for lchs override

2019-10-16 Thread Sam Eiderman
From: Sam Eiderman Add QTest tests to check the logical geometry override option. The tests in hd-geo-test are out of date - they only test IDE and do not test interesting MBRs. Creating qcow2 disks with specific size and MBR layout is currently unused - we only use a default empty MBR.

[PATCH v8 2/8] block: Support providing LCHS from user

2019-10-16 Thread Sam Eiderman
From: Sam Eiderman Add logical geometry variables to BlockConf. A user can now supply "lcyls", "lheads" & "lsecs" for any HD device that supports CHS ("cyls", "heads", "secs"). These devices include: * ide-hd * scsi-hd * virtio-blk-pci In future commits we will use the provided

[PATCH v8 0/8] Add Qemu to SeaBIOS LCHS interface

2019-10-16 Thread Sam Eiderman
v1: Non-standard logical geometries break under QEMU. A virtual disk which contains an operating system which depends on logical geometries (consistent values being reported from BIOS INT13 AH=08) will most likely break under QEMU/SeaBIOS if it has non-standard logical geometries - for example

[PATCH v3] target/arm/arch_dump: Add SVE notes

2019-10-16 Thread Andrew Jones
When dumping a guest with dump-guest-memory also dump the SVE registers if they are in use. Signed-off-by: Andrew Jones --- v3: - Pulled sve_bswap64 out of kvm64.c and reused it here - Changed fpsr_offset and sve_size to only align to a 16 byte boundary from the note payload offset, not

Re: [PATCH v10 13/15] docs/microvm.rst: document the new microvm machine type

2019-10-16 Thread Marc-André Lureau
Hi On Wed, Oct 16, 2019 at 12:19 PM Sergio Lopez wrote: > > Document the new microvm machine type. > > Signed-off-by: Sergio Lopez > Reviewed-by: Michael S. Tsirkin > --- > docs/microvm.rst | 98 > 1 file changed, 98 insertions(+) > create

[PATCH v4 4/4] tests/qemu-iotests: add case for block-stream compress

2019-10-16 Thread Andrey Shinkevich
Add a case to the iotest #030 that tests the 'compress' option for a block-stream job. Signed-off-by: Andrey Shinkevich --- tests/qemu-iotests/030 | 51 +- tests/qemu-iotests/030.out | 4 ++-- 2 files changed, 52 insertions(+), 3 deletions(-)

[PATCH v4 1/4] block: support compressed write at generic layer

2019-10-16 Thread Andrey Shinkevich
To inform the block layer about writing all the data compressed, we introduce the 'compress' command line option. Based on that option, the written data will be aligned by the cluster size at the generic layer. Suggested-by: Roman Kagan Suggested-by: Vladimir Sementsov-Ogievskiy Signed-off-by:

[PATCH v4 2/4] qcow2: Allow writing compressed data of multiple clusters

2019-10-16 Thread Andrey Shinkevich
QEMU currently supports writing compressed data of the size equal to one cluster. This patch allows writing QCOW2 compressed data that exceed one cluster. Now, we split buffered data into separate clusters and write them compressed using the existing functionality. Suggested-by: Pavel Butsykin

[PATCH v4 0/4] qcow2: advanced compression options

2019-10-16 Thread Andrey Shinkevich
New enhancements for writing compressed data to QCOW2 image. v4: The 'compression' support at the block generic layer has been accumulated in the separate patch 1/4. A little code refactoring was made. v3: Instead of introducing multiple key options for many drivers, the

[PATCH v4 3/4] tests/qemu-iotests: add case to write compressed data of multiple clusters

2019-10-16 Thread Andrey Shinkevich
Add the test case to the iotest #214 that checks possibility of writing compressed data of more than one cluster size. Signed-off-by: Andrey Shinkevich --- tests/qemu-iotests/214 | 35 +++ tests/qemu-iotests/214.out | 15 +++ 2 files changed, 50

Re: [PATCH v5 1/9] target/arm/monitor: Introduce qmp_query_cpu_model_expansion

2019-10-16 Thread Andrew Jones
On Wed, Oct 16, 2019 at 04:16:57PM +0100, Beata Michalska wrote: > On Wed, 16 Oct 2019 at 14:50, Andrew Jones wrote: > > > > On Wed, Oct 16, 2019 at 02:24:50PM +0100, Beata Michalska wrote: > > > On Tue, 15 Oct 2019 at 12:56, Beata Michalska > > > wrote: > > > > > > > > On Tue, 15 Oct 2019 at

Re: [PATCH v4 00/19] spapr: IRQ subsystem cleanup

2019-10-16 Thread Greg Kurz
On Wed, 9 Oct 2019 17:07:59 +1100 David Gibson wrote: > This is a substantial rework to clean up the handling of IRQs in > spapr. It includes some cleanups to both the XICS and XIVE interrupt > controller backends, as well as more to the common spapr irq handling > infrastructure. > Patches

[PATCH 0/2] virtiofsd: add net and pid namespace sandboxing

2019-10-16 Thread Stefan Hajnoczi
These patches are based on gitlab.com/virtio-fs/qemu.git virtio-fs-dev. virtiofsd is sandboxed so that it does not have access to the system in the event that the process is compromised. At the moment we use seccomp and mount namespaces to restrict the list of allowed syscalls and only give

[PATCH 2/2] virtiofsd: move to a new pid namespace

2019-10-16 Thread Stefan Hajnoczi
virtiofsd needs access to /proc/self/fd. Let's move to a new pid namespace so that a compromised process cannot see another other processes running on the system. One wrinkle in this approach: unshare(CLONE_NEWPID) affects *child* processes and not the current process. Therefore we need to fork

[PATCH 1/2] virtiofsd: move to an empty network namespace

2019-10-16 Thread Stefan Hajnoczi
If the process is compromised there should be no network access. Use an empty network namespace to sandbox networking. Signed-off-by: Stefan Hajnoczi --- contrib/virtiofsd/passthrough_ll.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/contrib/virtiofsd/passthrough_ll.c

Re: [RFC PATCH 0/4] Introduce Advanced Watch Dog module

2019-10-16 Thread Zhang Chen
On Wed, Oct 16, 2019 at 11:35 PM wrote: > > Patchew URL: > https://patchew.org/QEMU/20191016112209.9024-1-chen.zh...@intel.com/ > > > > Hi, > > This series failed the docker-quick@centos7 build test. Please find the > testing commands and > their output below. If you have Docker installed, you

Re: [PATCH] checkpatch: sugguest to use qemu_real_host_page_size instead of getpagesize() or sysconf(_SC_PAGESIZE)

2019-10-16 Thread Richard Henderson
On 10/15/19 6:24 PM, Wei Yang wrote: > if ($line =~ /\bbzero\(/) { > ERROR("use memset() instead of bzero()\n" . $herecurr); > } > + if ($line =~ /getpagesize\(\)/) { > + ERROR("use qemu_real_host_page_size instead

Re: [RFC PATCH 0/4] Introduce Advanced Watch Dog module

2019-10-16 Thread Zhang Chen
On Wed, Oct 16, 2019 at 11:35 PM wrote: > Patchew URL: > https://patchew.org/QEMU/20191016112209.9024-1-chen.zh...@intel.com/ > > > > Hi, > > This series failed the docker-quick@centos7 build test. Please find the > testing commands and > their output below. If you have Docker installed, you can

Re: [PATCH v2] target/arm/arch_dump: Add SVE notes

2019-10-16 Thread Richard Henderson
On 10/16/19 2:13 AM, Andrew Jones wrote: > On Thu, Oct 10, 2019 at 01:33:02PM -0400, Richard Henderson wrote: >> Ah, I wonder if you changed things around with the ifdefs due to the pregs. >> There's no trivial solution for those. It'd be nice to share the bswapping >> subroutine that you add in

Re: [PATCH] Added hardfloat conversion from float32 to float64

2019-10-16 Thread Richard Henderson
On 10/16/19 12:32 AM, Matus Kysel wrote: > +float64 float32_to_float64(float32 a, float_status *status) > +{ > +if (unlikely(!float32_is_normal(a))) { > +return soft_float32_to_float64(a, status); > +} else if (float32_is_zero(a)) { > +return float64_set_sign(float64_zero,

Re: [RFC PATCH 0/4] Introduce Advanced Watch Dog module

2019-10-16 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20191016112209.9024-1-chen.zh...@intel.com/ Hi, This series failed the docker-quick@centos7 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

  1   2   3   >