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

2019-08-01 Thread Ivan Ren
s->iteration_start_time = qemu_clock_get_ms(QEMU_CLOCK_REALTIME); +/* + * Update s->iteration_initial_bytes to match >>s->iteration_start_time. + */ +s->iteration_initial_bytes = migration_total_bytes(s); >>> >>>Is this one necessary? We have sent out

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

2019-08-01 Thread Wei Yang
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 line, which make it hard >> to

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

2019-08-01 Thread Markus Armbruster
Subject doesn't quite conform to conventions. Suggest hmp: Improve how "info migrate" formats capabilities Wei Yang writes: > Current we put all migration capability in one line, which make it hard > to read them and someone them are missed due to terminal width. > > This patch formats it

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

2019-08-01 Thread Markus Armbruster
Patrick Welche writes: > Public bug reported: > > In brief, an install CD will successfully boot with qemu 4.0.0 built with > glib 2.58.3, but freeze during boot with qemu 4.0.0 built with glib 2.60.0. I > tracked it down to glib's GHashTable improvements. qemu is happy with a glib > built

Re: [Qemu-devel] [PATCH V5 0/6] Packed virtqueue for virtrio

2019-08-01 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20190802040606.22573-1-jasow...@redhat.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 === #!/bin/bash

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

2019-08-01 Thread Jason Wang
Signed-off-by: Jason Wang --- include/hw/virtio/virtio.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/hw/virtio/virtio.h b/include/hw/virtio/virtio.h index 226c94078f..3a4ed3ab34 100644 --- a/include/hw/virtio/virtio.h +++ b/include/hw/virtio/virtio.h @@ -285,7

[Qemu-devel] [PATCH V5 3/6] virtio: basic packed virtqueue support

2019-08-01 Thread Jason Wang
This patch implements basic support for the packed virtqueue. Compare the split virtqueue which has three rings, packed virtqueue only have one which is supposed to have better cache utilization and more hardware friendly. Please refer virtio specification for more information. Signed-off-by:

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

2019-08-01 Thread Jason Wang
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. Signed-off-by: Wei Xu Signed-off-by: Jason Wang --- hw/virtio/virtio.c | 16 ++--

[Qemu-devel] [PATCH V5 4/6] virtio: event suppression support for packed ring

2019-08-01 Thread Jason Wang
This patch implements event suppression through device/driver area. Please refer virtio specification for more information. Signed-off-by: Wei Xu Signed-off-by: Jason Wang --- hw/virtio/virtio.c | 142 ++--- 1 file changed, 133 insertions(+), 9

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

2019-08-01 Thread Jason Wang
Signed-off-by: Jason Wang --- hw/net/vhost_net.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/net/vhost_net.c b/hw/net/vhost_net.c index a6b719035c..5b97997035 100644 --- a/hw/net/vhost_net.c +++ b/hw/net/vhost_net.c @@ -49,6 +49,7 @@ static const int kernel_feature_bits[] = {

[Qemu-devel] [PATCH V5 0/6] Packed virtqueue for virtrio

2019-08-01 Thread Jason Wang
Hi: This is an updated version of packed virtqueue support based on Wei's V4. Tested with, virtio-blk, virito-net (with vhost_net), virtio-scsi, scp during migration etc. Please review. Changes from V4: - using SET/GET_VRING_BASE to set/get last_used_idx/wrap_counter - fix

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

2019-08-01 Thread Jason Wang
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, 15 insertions(+) diff --git a/hw/virtio/virtio.c

Re: [Qemu-devel] [PATCH 1/2] rdmacm-mux: fix strcpy string warning

2019-08-01 Thread Yuval Shaia
On Tue, Jul 16, 2019 at 02:07:18PM +0400, Marc-André Lureau wrote: > ../contrib/rdmacm-mux/main.c: In function ‘parse_args’: > ../contrib/rdmacm-mux/main.c:118:13: error: ‘strncpy’ specified bound 3835 > equals destination size [-Werror=stringop-truncation] > 118 |

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

2019-08-01 Thread Wei Yang
Current we put all migration capability in one line, which make it hard to read them and someone them are missed due to terminal width. This patch formats it to print 4 in one line, which looks like this now: capabilities: xbzrle: off rdma-pin-all: offauto-converge:

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

2019-08-01 Thread Daniel Black
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 capability error messages, this > > has been clarified to: > > ... > >

Re: [Qemu-devel] [PATCH] migration: always initial RAMBlock.bmap to 1 for new migration

2019-08-01 Thread Wei Yang
On Thu, Aug 01, 2019 at 03:58:54PM +0800, Ivan Ren wrote: >>>- * Here we didn't set RAMBlock.bmap simply because it is >already >>>- * set in ram_list.dirty_memory[DIRTY_MEMORY_MIGRATION] in >>>- * ram_block_add, and that's where we'll sync the dirty >bitmaps.

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

2019-08-01 Thread Wei Yang
On Thu, Aug 01, 2019 at 04:10:34PM +0800, Ivan Ren wrote: >>> s->iteration_start_time = qemu_clock_get_ms(QEMU_CLOCK_REALTIME); >>>+/* >>>+ * Update s->iteration_initial_bytes to match >s->iteration_start_time. >>>+ */ >>>+s->iteration_initial_bytes = migration_total_bytes(s);

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

2019-08-01 Thread Laszlo Ersek
On 08/01/19 01:58, Paolo Bonzini wrote: > On 30/07/19 18:06, Laszlo Ersek wrote: >> On 07/29/19 14:57, Sergio Lopez wrote: >>> Implement the modern (v2) personality, according to the VirtIO 1.0 >>> specification. >>> >>> Support for v2 among guests is not as widespread as it'd be >>> desirable.

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

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta --- block/io_uring.c | 17 - 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/block/io_uring.c b/block/io_uring.c index 1553cd2e58..2a1d79704a 100644 --- a/block/io_uring.c +++ b/block/io_uring.c @@ -288,6 +288,17 @@ static int

[Qemu-devel] [PATCH v9 14/17] tests/qemu-iotests: enable testing with aio options

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi --- tests/qemu-iotests/check | 15 ++- tests/qemu-iotests/common.rc | 14 ++ tests/qemu-iotests/iotests.py | 9 - 3 files changed, 36 insertions(+), 2 deletions(-) diff --git

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

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta --- block/io_uring.c | 107 - block/trace-events | 1 + 2 files changed, 107 insertions(+), 1 deletion(-) diff --git a/block/io_uring.c b/block/io_uring.c index 86f32e18a1..1553cd2e58 100644 --- a/block/io_uring.c +++

[Qemu-devel] [PATCH v9 13/17] qemu-nbd: adds option for aio engines

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi Acked-by: Eric Blake --- qemu-nbd.c| 12 qemu-nbd.texi | 4 ++-- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/qemu-nbd.c b/qemu-nbd.c index a8cb39e510..7bb479f3c0 100644 --- a/qemu-nbd.c +++

[Qemu-devel] [PATCH v9 12/17] qemu-img: adds option to use aio engine for benchmarking

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta --- qemu-img-cmds.hx | 4 ++-- qemu-img.c | 11 ++- qemu-img.texi| 5 - 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/qemu-img-cmds.hx b/qemu-img-cmds.hx index 1c93e6d185..77b5a8dda8 100644 --- a/qemu-img-cmds.hx +++

[Qemu-devel] [PATCH v9 11/17] qemu-io: adds option to use aio engine

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta --- qemu-io.c | 25 + 1 file changed, 21 insertions(+), 4 deletions(-) diff --git a/qemu-io.c b/qemu-io.c index f64eca6940..0abb4af134 100644 --- a/qemu-io.c +++ b/qemu-io.c @@ -130,7 +130,8 @@ static void open_help(void) " -C, -- use

[Qemu-devel] [PATCH v9 15/17] tests/qemu-iotests: use AIOMODE with various tests

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi --- tests/qemu-iotests/028 | 3 ++- tests/qemu-iotests/058 | 2 +- tests/qemu-iotests/089 | 4 ++-- tests/qemu-iotests/091 | 7 --- tests/qemu-iotests/109 | 3 ++- tests/qemu-iotests/147 | 5 +++-- tests/qemu-iotests/181 | 10

[Qemu-devel] [PATCH v9 09/17] block: add trace events for io_uring

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi --- block/io_uring.c | 22 +++--- block/trace-events | 12 2 files changed, 31 insertions(+), 3 deletions(-) diff --git a/block/io_uring.c b/block/io_uring.c index 902b106954..c8e6526747 100644 ---

[Qemu-devel] [PATCH v9 06/17] util/async: add aio interfaces for io_uring

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi --- util/async.c | 36 1 file changed, 36 insertions(+) diff --git a/util/async.c b/util/async.c index 8d2105729c..2e0a5e20ac 100644 --- a/util/async.c +++ b/util/async.c @@ -276,6 +276,14 @@

[Qemu-devel] [PATCH v9 10/17] block/io_uring: adds userspace completion polling

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi --- block/io_uring.c | 17 - 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/block/io_uring.c b/block/io_uring.c index c8e6526747..86f32e18a1 100644 --- a/block/io_uring.c +++ b/block/io_uring.c @@ -238,6

[Qemu-devel] [PATCH v9 07/17] blockdev: adds bdrv_parse_aio to use io_uring

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi --- block.c | 22 ++ blockdev.c| 12 include/block/block.h | 1 + 3 files changed, 27 insertions(+), 8 deletions(-) diff --git a/block.c b/block.c index cbd8da5f3b..401831e28d

[Qemu-devel] [PATCH v9 04/17] block/io_uring: implements interfaces for io_uring

2019-08-01 Thread Aarushi Mehta
Aborts when sqe fails to be set as sqes cannot be returned to the ring. Adds slow path for short reads for older kernels Signed-off-by: Aarushi Mehta Signed-off-by: Stefan Hajnoczi Reviewed-by: Stefan Hajnoczi --- MAINTAINERS | 7 + block/Makefile.objs | 3 +

[Qemu-devel] [PATCH v9 08/17] block/file-posix.c: extend to use io_uring

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi Reviewed-by: Maxim Levitsky --- block/file-posix.c | 99 -- 1 file changed, 79 insertions(+), 20 deletions(-) diff --git a/block/file-posix.c b/block/file-posix.c index 4479cc7ab4..4aa42f826f

[Qemu-devel] [PATCH v9 05/17] stubs: add stubs for io_uring interface

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi --- MAINTAINERS | 1 + stubs/Makefile.objs | 1 + stubs/io_uring.c| 32 3 files changed, 34 insertions(+) create mode 100644 stubs/io_uring.c diff --git a/MAINTAINERS b/MAINTAINERS index

[Qemu-devel] [PATCH v9 01/17] configure: permit use of io_uring

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi Reviewed-by: Maxim Levitsky --- configure | 27 +++ 1 file changed, 27 insertions(+) diff --git a/configure b/configure index 714e7fb6a1..493dbc2ec5 100755 --- a/configure +++ b/configure @@ -371,6 +371,7 @@

[Qemu-devel] [PATCH v9 02/17] qapi/block-core: add option for io_uring

2019-08-01 Thread Aarushi Mehta
Only enumerates option for devices that support it. Since QAPI schema supports io_uring, which is the actual name of the Linux API, it is preferred over io-uring. Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi --- qapi/block-core.json | 4 +++- 1 file changed, 3 insertions(+), 1

[Qemu-devel] [PATCH v9 00/17] Add support for io_uring

2019-08-01 Thread Aarushi Mehta
This patch series adds support for the newly developed io_uring Linux AIO interface. Linux io_uring is faster than Linux's AIO asynchronous I/O code, offers efficient buffered asynchronous I/O support, the ability to do I/O without performing a system call via polled I/O, and other efficiency

[Qemu-devel] [PATCH v9 03/17] block/block: add BDRV flag for io_uring

2019-08-01 Thread Aarushi Mehta
Signed-off-by: Aarushi Mehta Reviewed-by: Stefan Hajnoczi Reviewed-by: Maxim Levitsky --- include/block/block.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/block/block.h b/include/block/block.h index 50a07c1c33..e29baa172c 100644 --- a/include/block/block.h +++

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

2019-08-01 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20190801173900.23851-1-mre...@redhat.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 === #!/bin/bash make

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

2019-08-01 Thread Toolybird
Public bug reported: DESTDIR installs end up with wrong paths in JSON files installed to $prefix/share/qemu/firmware. For example, the file: 50-edk2-x86_64-secure.json ends up incorrectly with: "filename": "/build/qemu/pkg/qemu/usr/share/qemu/edk2-x86_64-secure- code.fd", instead of the

Re: [Qemu-devel] [PATCH 7/7] target/sparc: Switch to do_transaction_failed() hook

2019-08-01 Thread Richard Henderson
On 8/1/19 11:30 AM, Peter Maydell wrote: > Switch the SPARC target from the old unassigned_access hook to the > new do_transaction_failed hook. > > This will cause the "if transaction failed" code paths added in > the previous commits to become active if the access is to an > unassigned address.

Re: [Qemu-devel] [PATCH 6/7] target/sparc: Remove unused ldl_phys from dump_mmu()

2019-08-01 Thread Richard Henderson
On 8/1/19 11:30 AM, Peter Maydell wrote: > The dump_mmu() function does a ldl_phys() at the start, but > then never uses the value it loads at all. Remove the > unused code. > > Signed-off-by: Peter Maydell > --- > target/sparc/mmu_helper.c | 4 +--- > 1 file changed, 1 insertion(+), 3

Re: [Qemu-devel] [PATCH 5/7] target/sparc: Handle bus errors in mmu_probe()

2019-08-01 Thread Richard Henderson
On 8/1/19 11:30 AM, Peter Maydell wrote: > +/* > + * TODO: MMU probe operations are supposed to set the fault > + * status registers, but we don't do this. > + */ Well, the todo should be using sparc_cpu_tlb_fill with probe=true, since this function appears to be otherwise

Re: [Qemu-devel] [PATCH 4/7] target/sparc: Correctly handle bus errors in page table walks

2019-08-01 Thread Richard Henderson
On 8/1/19 11:30 AM, Peter Maydell wrote: > Currently we use the ldl_phys() function to read page table entries. > With the unassigned_access hook in place, if these hit an unassigned > area of memory then the hook will cause us to wrongly generate > an exception with a fault address matching the

Re: [Qemu-devel] [PATCH 3/7] target/sparc: Check for transaction failures in MXCC stream ASI accesses

2019-08-01 Thread Richard Henderson
On 8/1/19 11:30 AM, Peter Maydell wrote: > Currently the ld/st_asi helper functions make calls to the > ld*_phys() and st*_phys() functions for those ASIs which > imply direct accesses to physical addresses. These implicitly > rely on the unassigned_access hook to cause them to generate > an MMU

Re: [Qemu-devel] [PATCH 2/7] target/sparc: Check for transaction failures in MMU passthrough ASIs

2019-08-01 Thread Richard Henderson
On 8/1/19 11:30 AM, Peter Maydell wrote: > Currently the ld/st_asi helper functions make calls to the > ld*_phys() and st*_phys() functions for those ASIs which > imply direct accesses to physical addresses. These implicitly > rely on the unassigned_access hook to cause them to generate > an MMU

Re: [Qemu-devel] [PATCH 1/7] target/sparc: Factor out the body of sparc_cpu_unassigned_access()

2019-08-01 Thread Richard Henderson
On 8/1/19 11:30 AM, Peter Maydell wrote: > Currently the SPARC target uses the old-style do_unassigned_access > hook. We want to switch it over to do_transaction_failed, but to do > this we must first remove all the direct calls in ldst_helper.c to > cpu_unassigned_access(). Factor out the body

Re: [Qemu-devel] [PATCH v4 53/54] include/exec: wrap cpu_ldst.h in CONFIG_TCG

2019-08-01 Thread Richard Henderson
On 7/31/19 9:07 AM, Alex Bennée wrote: > This gets around a build problem with --disable-tcg. > > Signed-off-by: Alex Bennée > --- > include/exec/exec-all.h | 2 ++ > 1 file changed, 2 insertions(+) Reviewed-by: Richard Henderson r~

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

2019-08-01 Thread Michael S. Tsirkin
On Thu, Aug 01, 2019 at 01:58:35AM +0200, Paolo Bonzini wrote: > On 30/07/19 18:06, Laszlo Ersek wrote: > > On 07/29/19 14:57, Sergio Lopez wrote: > >> Implement the modern (v2) personality, according to the VirtIO 1.0 > >> specification. > >> > >> Support for v2 among guests is not as widespread

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

2019-08-01 Thread Max Reitz
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 becomes unused, so, drop it at all. >>

Re: [Qemu-devel] [PATCH v4 43/54] plugin: add API symbols to qemu-plugins.symbols

2019-08-01 Thread Richard Henderson
On 7/31/19 9:07 AM, Alex Bennée wrote: > +# > +# See if --dynamic-list is supported by the linker > + > +cat > $TMPTXT < +{ > + foo; > +}; > +EOF > + > +cat > $TMPC < +#include > +void foo(void); > + > +void foo(void) > +{ > + printf("foo\n"); > +} > + >

Re: [Qemu-devel] [RFC PATCH 4/5] hw/i386: Generate apicid based on cpu_type

2019-08-01 Thread Moger, Babu
Hi Eduardo, Thanks for the quick comments. I will look into your comments closely and will let you know if I have questions. > -Original Message- > From: Eduardo Habkost > Sent: Thursday, August 1, 2019 2:29 PM > To: Moger, Babu > Cc: marcel.apfelb...@gmail.com; m...@redhat.com;

Re: [Qemu-devel] [PATCH v4 42/54] translator: inject instrumentation from plugins

2019-08-01 Thread Richard Henderson
On 7/31/19 9:07 AM, Alex Bennée wrote: > From: "Emilio G. Cota" > > Signed-off-by: Emilio G. Cota > Signed-off-by: Alex Bennée > > --- > v4 > - note we can't inject instrumentation if ! DISAS_NEXT > --- > accel/tcg/translator.c | 20 > 1 file changed, 20 insertions(+)

Re: [Qemu-devel] [RFC PATCH 4/5] hw/i386: Generate apicid based on cpu_type

2019-08-01 Thread Eduardo Habkost
Thanks for the patches. I still haven't looked closely at all patches in the series, but patches 1-3 seem good on the first look. A few comments on this one: On Wed, Jul 31, 2019 at 11:20:50PM +, Moger, Babu wrote: > Check the cpu_type before calling the apicid functions > from topology.h.

Re: [Qemu-devel] [PATCH v4 31/54] target/arm: fetch code with translator_ld

2019-08-01 Thread Richard Henderson
On 7/31/19 9:06 AM, Alex Bennée wrote: > From: "Emilio G. Cota" > > Now the arm_ld*_code functions are only used at translate time we can > just pass down to translator_ld functions. > > Signed-off-by: Emilio G. Cota > [AJB: convert from plugin_insn_append to translator_ld] > Signed-off-by:

Re: [Qemu-devel] [PATCH v4 30/54] translator: add translator_ld{ub, sw, uw, l, q}

2019-08-01 Thread Richard Henderson
On 7/31/19 9:06 AM, Alex Bennée wrote: > +#ifdef CONFIG_USER_ONLY > + > +#define DO_LOAD(type, name, shift) \ > +set_helper_retaddr(1); \ > +ret = name ## _p(g2h(pc)); \ > +clear_helper_retaddr(); > + > +#else > + > +#define

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

2019-08-01 Thread Paolo Bonzini
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. Document that practice. >>> >>> Signed-off-by:

Re: [Qemu-devel] [PATCH] vhost-vsock: report QMP event when set running

2019-08-01 Thread Michael S. Tsirkin
On Thu, Aug 01, 2019 at 05:25:04PM +0200, Markus Armbruster wrote: > Ning Bo writes: > > > Report vsock running event so that the upper application can > > control boot sequence. > > see https://github.com/kata-containers/runtime/pull/1918 > > Please provide a more complete summary of the use

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

2019-08-01 Thread Max Reitz
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 >> children, and move all of those entries into a

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

2019-08-01 Thread Eduardo Habkost
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. Document that practice. > > > > Signed-off-by: Eduardo Habkost > > --- > > I wonder if

Re: [Qemu-devel] [PATCH 3/3] iotests: Test migration with all kinds of filter nodes

2019-08-01 Thread Max Reitz
On 01.08.19 17:17, Kevin Wolf wrote: > This test case is motivated by commit 2b23f28639 ('block/copy-on-read: > Fix permissions for inactive node'). Instead of just testing > copy-on-read on migration, let's stack all sorts of filter nodes on top > of each other and try if the resulting VM can

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

2019-08-01 Thread Andrey Shinkevich
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. Also, the Visitor object call back functions are supposed to set

Re: [Qemu-devel] [PATCH v4 29/54] plugin-gen: add plugin_insn_append

2019-08-01 Thread Richard Henderson
On 7/31/19 9:06 AM, Alex Bennée wrote: > From: "Emilio G. Cota" > > By adding it to plugin-gen's header file, we can export is as > an inline, since tcg.h is included in the header (we need tcg_ctx). > > Signed-off-by: Emilio G. Cota > [AJB: use g_byte_array] > Signed-off-by: Alex Bennée > >

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

2019-08-01 Thread Andrey Shinkevich
On 01/08/2019 10:13, Markus Armbruster wrote: > 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 >>

Re: [Qemu-devel] [PATCH v4 24/54] plugins: implement helpers for resolving hwaddr

2019-08-01 Thread Richard Henderson
On 8/1/19 7:14 AM, Aaron Lindsay OS via Qemu-devel wrote: > On Jul 31 17:06, Alex Bennée wrote: >> We need to keep a local per-cpu copy of the data as other threads may >> be running. We use a automatically growing array and re-use the space >> for subsequent queries. > > [...] > >> +bool

[Qemu-devel] [PATCH 7/7] target/sparc: Switch to do_transaction_failed() hook

2019-08-01 Thread Peter Maydell
Switch the SPARC target from the old unassigned_access hook to the new do_transaction_failed hook. This will cause the "if transaction failed" code paths added in the previous commits to become active if the access is to an unassigned address. In particular we'll now handle bus errors during page

[Qemu-devel] [PATCH 1/7] target/sparc: Factor out the body of sparc_cpu_unassigned_access()

2019-08-01 Thread Peter Maydell
Currently the SPARC target uses the old-style do_unassigned_access hook. We want to switch it over to do_transaction_failed, but to do this we must first remove all the direct calls in ldst_helper.c to cpu_unassigned_access(). Factor out the body of the hook function's code into a new

[Qemu-devel] [PATCH 2/7] target/sparc: Check for transaction failures in MMU passthrough ASIs

2019-08-01 Thread Peter Maydell
Currently the ld/st_asi helper functions make calls to the ld*_phys() and st*_phys() functions for those ASIs which imply direct accesses to physical addresses. These implicitly rely on the unassigned_access hook to cause them to generate an MMU fault if the access fails. Switch to using the

[Qemu-devel] [PATCH 4/7] target/sparc: Correctly handle bus errors in page table walks

2019-08-01 Thread Peter Maydell
Currently we use the ldl_phys() function to read page table entries. With the unassigned_access hook in place, if these hit an unassigned area of memory then the hook will cause us to wrongly generate an exception with a fault address matching the address of the page table entry. Change to using

[Qemu-devel] [PATCH 3/7] target/sparc: Check for transaction failures in MXCC stream ASI accesses

2019-08-01 Thread Peter Maydell
Currently the ld/st_asi helper functions make calls to the ld*_phys() and st*_phys() functions for those ASIs which imply direct accesses to physical addresses. These implicitly rely on the unassigned_access hook to cause them to generate an MMU fault if the access fails. Switch to using the

[Qemu-devel] [PATCH 6/7] target/sparc: Remove unused ldl_phys from dump_mmu()

2019-08-01 Thread Peter Maydell
The dump_mmu() function does a ldl_phys() at the start, but then never uses the value it loads at all. Remove the unused code. Signed-off-by: Peter Maydell --- target/sparc/mmu_helper.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/target/sparc/mmu_helper.c

[Qemu-devel] [PATCH 5/7] target/sparc: Handle bus errors in mmu_probe()

2019-08-01 Thread Peter Maydell
Convert the mmu_probe() function to using address_space_ldl() rather than ldl_phys(), so we can explicitly detect memory transaction failures. This makes no practical difference at the moment, because ldl_phys() will return 0 on a transaction failure, and we treat transaction failures and 0 PDEs

[Qemu-devel] [PATCH 0/7] target/sparc: Convert to do_transaction_failed hook

2019-08-01 Thread Peter Maydell
This patchset converts the SPARC target away from the old broken do_unassigned_access hook to the new (added in 2017...) do_transaction_failed hook. In the process it fixes a number of bugs in corner cases. The SPARC ld/st-with-ASI helper functions are odd in that they make use of the

Re: [Qemu-devel] [PATCH v4 23/54] tcg: let plugins instrument virtual memory accesses

2019-08-01 Thread Richard Henderson
On 7/31/19 9:06 AM, Alex Bennée wrote: > From: "Emilio G. Cota" > > To capture all memory accesses we need hook into all the various > helper functions that are involved in memory operations as well as the > injected inline helper calls. A later commit will allow us to resolve > the actual guest

[Qemu-devel] [Bug 1745312] Re: Regression report: Disk subsystem I/O failures/issues surfacing in DOS/early Windows [two separate issues: one bisected, one root-caused]

2019-08-01 Thread Mdasoh Kyaeppd
Can confirm the DOS issue is present. Here are some steps to recreate: wget http://www.freedos.org/download/download/FD12CD.iso apt-get install mbr fdisk parted dosfstools qemu-system-x86 # dd if=/dev/zero of=dos.img bs=512 count=1032192 # losetup /dev/loop0 dos.img # fdisk -u=cylinders

Re: [Qemu-devel] [PATCH v4 22/54] atomic_template: add inline trace/plugin helpers

2019-08-01 Thread Richard Henderson
On 7/31/19 9:06 AM, Alex Bennée wrote: > From: "Emilio G. Cota" > > In preparation for plugin support. > > Signed-off-by: Emilio G. Cota > Signed-off-by: Alex Bennée > > --- > v4 > - move common stuff to atomic_common.inc.c > - fix ups for widened uint16_t info > - drop haddr in

Re: [Qemu-devel] [PATCH v2 for-4.1 2/2] iotests: Test backup job with two guest writes

2019-08-01 Thread Vladimir Sementsov-Ogievskiy
01.08.2019 20:39, Max Reitz wrote: > Perform two guest writes to not yet backed up areas of an image, where > the former touches an inner area of the latter. > > Before HEAD^, copy offloading broke this in two ways: > (1) The target image differs from the reference image (what the source >

Re: [Qemu-devel] [PATCH 2/3] iotests: Enable -d for Python non-unittest tests

2019-08-01 Thread Max Reitz
On 01.08.19 17:17, Kevin Wolf wrote: > The part of iotests.main() that is related to the implementation of the > debug option -d and enables QEMU and QMP logging is not only useful in > tests that use the Python unittest framework, but also in tests that > work by comparing with a reference

Re: [Qemu-devel] [PATCH for-4.1 2/2] iotests: Test backup job with two guest writes

2019-08-01 Thread Vladimir Sementsov-Ogievskiy
01.08.2019 20:43, Vladimir Sementsov-Ogievskiy wrote: > 01.08.2019 20:35, Max Reitz wrote: >> On 01.08.19 19:25, Vladimir Sementsov-Ogievskiy wrote: >>> 01.08.2019 20:06, Max Reitz wrote: On 01.08.19 18:03, Vladimir Sementsov-Ogievskiy wrote: > 01.08.2019 18:12, Max Reitz wrote: >>

Re: [Qemu-devel] [PATCH for-4.1 2/2] iotests: Test backup job with two guest writes

2019-08-01 Thread Vladimir Sementsov-Ogievskiy
01.08.2019 20:35, Max Reitz wrote: > On 01.08.19 19:25, Vladimir Sementsov-Ogievskiy wrote: >> 01.08.2019 20:06, Max Reitz wrote: >>> On 01.08.19 18:03, Vladimir Sementsov-Ogievskiy wrote: 01.08.2019 18:12, Max Reitz wrote: > Perform two guest writes to not yet backed up areas of an

Re: [Qemu-devel] [PATCH 1/3] iotests: Move migration helpers to iotests.py

2019-08-01 Thread Max Reitz
On 01.08.19 17:17, Kevin Wolf wrote: > 234 implements functions that are useful for doing migration between two > VMs. Move them to iotests.py so that other test cases can use them, too. > > Signed-off-by: Kevin Wolf > --- > tests/qemu-iotests/234| 30 +++--- >

[Qemu-devel] [PATCH v2 for-4.1 2/2] iotests: Test backup job with two guest writes

2019-08-01 Thread Max Reitz
Perform two guest writes to not yet backed up areas of an image, where the former touches an inner area of the latter. Before HEAD^, copy offloading broke this in two ways: (1) The target image differs from the reference image (what the source was when the backup started). (2) But you will

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

2019-08-01 Thread Max Reitz
The backup job must only copy areas that the copy_bitmap reports as dirty. This is always the case when using traditional non-offloading backup, because it copies each cluster separately. When offloading the copy operation, we sometimes copy more than one cluster at a time, but we only check

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

2019-08-01 Thread Max Reitz
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 automatically. That means, that backup is broken and has been broken

Re: [Qemu-devel] [PATCH for-4.1 2/2] iotests: Test backup job with two guest writes

2019-08-01 Thread Max Reitz
On 01.08.19 19:25, Vladimir Sementsov-Ogievskiy wrote: > 01.08.2019 20:06, Max Reitz wrote: >> On 01.08.19 18:03, Vladimir Sementsov-Ogievskiy wrote: >>> 01.08.2019 18:12, Max Reitz wrote: Perform two guest writes to not yet backed up areas of an image, where the former touches an inner

Re: [Qemu-devel] [PATCH for-4.1 2/2] iotests: Test backup job with two guest writes

2019-08-01 Thread Vladimir Sementsov-Ogievskiy
01.08.2019 20:06, Max Reitz wrote: > On 01.08.19 18:03, Vladimir Sementsov-Ogievskiy wrote: >> 01.08.2019 18:12, Max Reitz wrote: >>> Perform two guest writes to not yet backed up areas of an image, where >>> the former touches an inner area of the latter. >>> >>> Before HEAD^, copy offloading

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

2019-08-01 Thread Aleksandar Markovic
On Tue, Jul 30, 2019 at 11:07 PM Eduardo Habkost wrote: > Sometimes we use the 'struct' keyword to help us reduce > dependencies between header files. Document that practice. > > Signed-off-by: Eduardo Habkost > --- > I wonder if this is too terse? Should we give examples? > --- > I am

Re: [Qemu-devel] [PATCH v4 18/54] cputlb: introduce get_page_addr_code_hostp

2019-08-01 Thread Richard Henderson
On 7/31/19 9:06 AM, Alex Bennée wrote: > From: "Emilio G. Cota" > > This will be used by plugins to get the host address > of instructions. > > Signed-off-by: Emilio G. Cota > Signed-off-by: Alex Bennée > --- > accel/tcg/cputlb.c | 14 +- > include/exec/exec-all.h | 38

Re: [Qemu-devel] [PATCH v4 17/54] cputlb: document get_page_addr_code

2019-08-01 Thread Richard Henderson
On 7/31/19 9:06 AM, Alex Bennée wrote: > From: "Emilio G. Cota" > > Suggested-by: Alex Bennée > Signed-off-by: Emilio G. Cota > Signed-off-by: Alex Bennée > --- > accel/tcg/cputlb.c | 5 - > include/exec/exec-all.h | 24 +--- > 2 files changed, 21 insertions(+),

Re: [Qemu-devel] [PATCH for-4.1 2/2] iotests: Test backup job with two guest writes

2019-08-01 Thread Max Reitz
On 01.08.19 18:03, Vladimir Sementsov-Ogievskiy wrote: > 01.08.2019 18:12, Max Reitz wrote: >> Perform two guest writes to not yet backed up areas of an image, where >> the former touches an inner area of the latter. >> >> Before HEAD^, copy offloading broke this in two ways: >> (1) The output

[Qemu-devel] [PATCH 4/4] virtiofsd: add --thread-pool-size=NUM option

2019-08-01 Thread Stefan Hajnoczi
Add an option to control the size of the thread pool. Requests are now processed in parallel by default. Signed-off-by: Stefan Hajnoczi --- contrib/virtiofsd/fuse_i.h| 1 + contrib/virtiofsd/fuse_lowlevel.c | 8 ++-- contrib/virtiofsd/fuse_virtio.c | 4 ++-- 3 files changed, 9

[Qemu-devel] [PATCH 3/4] virtiofsd: fix lo_destroy() resource leaks

2019-08-01 Thread Stefan Hajnoczi
Now that lo_destroy() is serialized we can call unref_inode() so that all inode resources are freed. Signed-off-by: Stefan Hajnoczi --- contrib/virtiofsd/passthrough_ll.c | 43 ++ 1 file changed, 20 insertions(+), 23 deletions(-) diff --git

[Qemu-devel] [PATCH 0/4] virtiofsd: multithreading preparation part 3

2019-08-01 Thread Stefan Hajnoczi
This patch series introduces the virtiofsd --thread-pool-size=NUM and sets the default value to 64. Each virtqueue has its own thread pool for processing requests. Blocking requests no longer pause virtqueue processing and I/O performance should be greatly improved when the queue depth is

[Qemu-devel] [PATCH 2/4] virtiofsd: prevent FUSE_INIT/FUSE_DESTROY races

2019-08-01 Thread Stefan Hajnoczi
When running with multiple threads it can be tricky to handle FUSE_INIT/FUSE_DESTROY in parallel with other request types or in parallel with themselves. Serialize FUSE_INIT and FUSE_DESTROY so that malicious clients cannot trigger race conditions. Signed-off-by: Stefan Hajnoczi ---

[Qemu-devel] [Bug 1838475] Re: qemu-system-arm exits when cortex-m4 floating point used and irq occurs

2019-08-01 Thread KD
I confirm that this fixes the issue above. Thank you for your help! It is much appreciated. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1838475 Title: qemu-system-arm exits when cortex-m4

[Qemu-devel] [PATCH 1/4] virtiofsd: process requests in a thread pool

2019-08-01 Thread Stefan Hajnoczi
Introduce a thread pool so that fv_queue_thread() just pops VuVirtqElements and hands them to the thread pool. For the time being only one worker thread is allowed since passthrough_ll.c is not thread-safe yet. Future patches will lift this restriction so that multiple FUSE requests can be

[Qemu-devel] [PATCH for 4.2 v5 10/12] target/mips: Style improvements in machine.c

2019-08-01 Thread Aleksandar Markovic
From: Aleksandar Markovic Fixes mostly errors and warings reported by 'checkpatch.pl -f'. Signed-off-by: Aleksandar Markovic --- target/mips/machine.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target/mips/machine.c b/target/mips/machine.c index e23b767..06887d8

[Qemu-devel] [PATCH for 4.2 v5 09/12] target/mips: Style improvements in internal.h

2019-08-01 Thread Aleksandar Markovic
From: Aleksandar Markovic Fixes mostly errors and warings reported by 'checkpatch.pl -f'. Signed-off-by: Aleksandar Markovic --- target/mips/internal.h | 57 +++--- 1 file changed, 35 insertions(+), 22 deletions(-) diff --git

[Qemu-devel] [PATCH for 4.2 v5 08/12] target/mips: Style improvements in helper.c

2019-08-01 Thread Aleksandar Markovic
From: Aleksandar Markovic Fixes mostly errors and warings reported by 'checkpatch.pl -f'. Signed-off-by: Aleksandar Markovic --- target/mips/helper.c | 98 1 file changed, 60 insertions(+), 38 deletions(-) diff --git a/target/mips/helper.c

[Qemu-devel] [PATCH for 4.2 v5 11/12] tests/tcg: target/mips: Add optional printing of more detailed failure info

2019-08-01 Thread Aleksandar Markovic
From: Aleksandar Markovic There is a need for printing input and output data for failure cases, for debugging purpose. This is achieved by this patch, and only if a preprocessor constant is manually set to 1. (Assumption is that the need for such printout is relatively rare.) Signed-off-by:

[Qemu-devel] [PATCH for 4.2 v5 07/12] target/mips: Style improvements in cpu.c

2019-08-01 Thread Aleksandar Markovic
From: Aleksandar Markovic Fixes mostly errors and warings reported by 'checkpatch.pl -f'. Signed-off-by: Aleksandar Markovic --- target/mips/cpu.c | 17 +++-- 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/target/mips/cpu.c b/target/mips/cpu.c index

[Qemu-devel] [PATCH for 4.2 v5 05/12] target/mips: Add support for emulation of CRC32 group of instructions

2019-08-01 Thread Aleksandar Markovic
From: Yongbok Kim Add emulation of MIPS' CRC32 (Cyclic Redundancy Check) instructions. Reuse zlib crc32() and Linux crc32c(). Note that, at the time being, there is no MIPS CPU that supports CRC32 instructions (they are an optional part of MIPS64/32 R6 anf nanoMIPS ISAs). Signed-off-by: Yongbok

  1   2   3   >