[PATCH v4 09/15] block: add trace events for io_uring

2020-01-14 Thread Stefan Hajnoczi
From: Aarushi Mehta Signed-off-by: Aarushi Mehta Acked-by: Stefano Garzarella Signed-off-by: Stefan Hajnoczi --- block/io_uring.c | 23 --- block/trace-events | 12 2 files changed, 32 insertions(+), 3 deletions(-) diff --git a/block/io_uring.c b/block/io_u

[PATCH v4 07/15] blockdev: adds bdrv_parse_aio to use io_uring

2020-01-14 Thread Stefan Hajnoczi
From: Aarushi Mehta Signed-off-by: Aarushi Mehta Acked-by: Stefano Garzarella Signed-off-by: Stefan Hajnoczi --- block.c | 22 ++ blockdev.c| 12 include/block/block.h | 1 + 3 files changed, 27 insertions(+), 8 deletions(-) diff --

[PATCH v4 12/15] qemu-img: adds option to use aio engine for benchmarking

2020-01-14 Thread Stefan Hajnoczi
From: Aarushi Mehta Signed-off-by: Aarushi Mehta Acked-by: Stefano Garzarella Signed-off-by: Stefan Hajnoczi --- v10: * Add missing space to qemu-img command-line documentation --- qemu-img-cmds.hx | 4 ++-- qemu-img.c | 11 ++- qemu-img.texi| 5 - 3 files changed, 16

[PATCH v4 06/15] util/async: add aio interfaces for io_uring

2020-01-14 Thread Stefan Hajnoczi
From: Aarushi Mehta Signed-off-by: Aarushi Mehta Acked-by: Stefano Garzarella Signed-off-by: Stefan Hajnoczi --- util/async.c | 36 1 file changed, 36 insertions(+) diff --git a/util/async.c b/util/async.c index b1fa5319e5..c192a24a61 100644 --- a/util/as

Re: [PATCH 0/4] migration: Replace gemu_log with qemu_log

2020-01-14 Thread Alex Bennée
Josh Kunz writes: > > Not tested: > * Build/logging with bsd-user. I do not have easy access to a BSD > system. If you have the time we have vm-build-netbsd: make vm-build-netbsd EXTRA_CONFIGURE_OPTS="--disable-system" Which will create a NetBSD image for you and run the build through

[PATCH v4 08/15] block/file-posix.c: extend to use io_uring

2020-01-14 Thread Stefan Hajnoczi
From: Aarushi Mehta Signed-off-by: Aarushi Mehta Reviewed-by: Maxim Levitsky Acked-by: Stefano Garzarella Signed-off-by: Stefan Hajnoczi --- block/file-posix.c | 85 +- 1 file changed, 69 insertions(+), 16 deletions(-) diff --git a/block/file-posi

[PATCH v4 11/15] qemu-io: adds option to use aio engine

2020-01-14 Thread Stefan Hajnoczi
From: Aarushi Mehta Signed-off-by: Aarushi Mehta Acked-by: Stefano Garzarella Signed-off-by: Stefan Hajnoczi --- qemu-io.c | 25 + 1 file changed, 21 insertions(+), 4 deletions(-) diff --git a/qemu-io.c b/qemu-io.c index 91e3276592..3adc5a7d0d 100644 --- a/qemu-io.c +

Re: [PATCH v3 1/2] migration: Fix incorrect integer->float conversion caught by clang

2020-01-14 Thread Juan Quintela
Markus Armbruster wrote: > Markus Armbruster writes: > >> Juan Quintela writes: >> >>> Markus Armbruster wrote: From: Fangrui Song Clang does not like qmp_migrate_set_downtime()'s code to clamp double @value to 0..INT64_MAX: qemu/migration/migration.c:2038:24:

[PATCH v4 10/15] block/io_uring: adds userspace completion polling

2020-01-14 Thread Stefan Hajnoczi
From: Aarushi Mehta Signed-off-by: Aarushi Mehta Acked-by: Stefano Garzarella Signed-off-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 a5c0d16220..56892fd1ab 100644 --- a

[PATCH v4 13/15] qemu-nbd: adds option for aio engines

2020-01-14 Thread Stefan Hajnoczi
From: Aarushi Mehta Signed-off-by: Aarushi Mehta Acked-by: Eric Blake Acked-by: Stefano Garzarella Signed-off-by: Stefan Hajnoczi --- 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 108a51

Re: [PULL 00/29] Migration pull patches (second try)

2020-01-14 Thread Peter Maydell
On Tue, 14 Jan 2020 at 09:26, Juan Quintela wrote: > > The following changes since commit 3c8a6575985b1652b45bfa670b5e1907d642cfa0: > > Merge remote-tracking branch > 'remotes/kraxel/tags/usb-20200113-pull-request' into staging (2020-01-13 > 14:19:57 +) > > are available in the Git reposit

[PATCH v4 14/15] tests/qemu-iotests: enable testing with aio options

2020-01-14 Thread Stefan Hajnoczi
From: Aarushi Mehta Signed-off-by: Aarushi Mehta Acked-by: Stefano Garzarella Signed-off-by: Stefan Hajnoczi --- tests/qemu-iotests/check | 15 ++- tests/qemu-iotests/common.rc | 14 ++ tests/qemu-iotests/iotests.py | 12 ++-- 3 files changed, 38 insertio

Re: [qemu-web PATCH] documentation: update links to readthedocs

2020-01-14 Thread Stefan Hajnoczi
On Mon, Jan 13, 2020 at 10:35:50AM +, Alex Bennée wrote: > ..and extemporise a little about their state. > > Signed-off-by: Alex Bennée > --- > documentation.md | 9 ++--- > 1 file changed, 6 insertions(+), 3 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP si

[PATCH v4 15/15] tests/qemu-iotests: use AIOMODE with various tests

2020-01-14 Thread Stefan Hajnoczi
From: Aarushi Mehta Signed-off-by: Aarushi Mehta Acked-by: Stefano Garzarella Signed-off-by: Stefan Hajnoczi --- v11: * Drop line-wrapping changes that accidentally broke qemu-iotests --- tests/qemu-iotests/028 | 2 +- tests/qemu-iotests/058 | 2 +- tests/qemu-iotests/089 | 4 ++-- tests/

Re: [PULL 00/29] Migration pull patches (second try)

2020-01-14 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200114092606.1761-1-quint...@redhat.com/ Hi, This series seems to have some coding style problems. See output below for more information: Subject: [PULL 00/29] Migration pull patches (second try) Type: series Message-id: 20200114092606.1761-1-quint...@re

Re: [PATCH] docs/devel: fix stable process doc formatting

2020-01-14 Thread Stefan Hajnoczi
On Mon, Jan 13, 2020 at 11:30:23AM +0100, Cornelia Huck wrote: > Enumeration of stable criteria needs proper bullet points. > > Signed-off-by: Cornelia Huck > --- > docs/devel/stable-process.rst | 6 -- > 1 file changed, 4 insertions(+), 2 deletions(-) Reviewed-by: Stefan Hajnoczi signat

Re: [PULL 00/29] Migration pull patches (second try)

2020-01-14 Thread Peter Maydell
On Tue, 14 Jan 2020 at 09:26, Juan Quintela wrote: > > The following changes since commit 3c8a6575985b1652b45bfa670b5e1907d642cfa0: > > Merge remote-tracking branch > 'remotes/kraxel/tags/usb-20200113-pull-request' into staging (2020-01-13 > 14:19:57 +) > > are available in the Git reposit

Re: [qemu-web PATCH] documentation: update links to readthedocs

2020-01-14 Thread Thomas Huth
On 13/01/2020 11.35, Alex Bennée wrote: > ..and extemporise a little about their state. > > Signed-off-by: Alex Bennée > --- > documentation.md | 9 ++--- > 1 file changed, 6 insertions(+), 3 deletions(-) > > diff --git a/documentation.md b/documentation.md > index f4ef9f4..55d5db6 100644 >

Re: [PULL 00/29] Migration pull patches (second try)

2020-01-14 Thread Peter Maydell
On Tue, 14 Jan 2020 at 11:22, Juan Quintela wrote: > > Peter Maydell wrote: > > Still fails on hosts where ram_addr_t is 32 bits. > > Looks like you still haven't got the fix for the problem > > Dan pointed out where multifd_save_setup() is using the > > wrong type when it calculates p->packetlen

Re: [PULL 00/29] Migration pull patches (second try)

2020-01-14 Thread Juan Quintela
Peter Maydell wrote: > On Tue, 14 Jan 2020 at 09:26, Juan Quintela wrote: >> >> The following changes since commit 3c8a6575985b1652b45bfa670b5e1907d642cfa0: >> >> Merge remote-tracking branch >> 'remotes/kraxel/tags/usb-20200113-pull-request' into staging >> (2020-01-13 14:19:57 +) >> >> ar

Re: [PATCH v2 2/3] memory: Allow a MemoryRegion to be marked no_vhost

2020-01-14 Thread Dr. David Alan Gilbert
* Michael S. Tsirkin (m...@redhat.com) wrote: > On Mon, Jan 13, 2020 at 05:36:46PM +, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > Allow a memory region to be marked as 'no_vhost' and > > exclude that region from vhost's list build. > > > > Signed-off-by: Dr

Re: [PULL 00/29] Migration pull patches (second try)

2020-01-14 Thread Daniel P . Berrangé
On Tue, Jan 14, 2020 at 12:22:10PM +0100, Juan Quintela wrote: > Peter Maydell wrote: > > On Tue, 14 Jan 2020 at 09:26, Juan Quintela wrote: > >> > >> The following changes since commit > >> 3c8a6575985b1652b45bfa670b5e1907d642cfa0: > >> > >> Merge remote-tracking branch > >> 'remotes/kraxel/t

Re: [PATCH v2] qcow2: Assert that host cluster offsets fit in L2 table entries

2020-01-14 Thread Max Reitz
On 13.01.20 17:11, Alberto Garcia wrote: > The standard cluster descriptor in L2 table entries has a field to > store the host cluster offset. When we need to get that offset from an > entry we use L2E_OFFSET_MASK to ensure that we only use the bits that > belong to that field. > > But while that

Re: xlnx-zynqmp doesn't set psci-conduit on the R-cores

2020-01-14 Thread Peter Maydell
On Sat, 11 Jan 2020 at 21:36, Edgar E. Iglesias wrote: > On Fri, 10 Jan. 2020, 08:42 Peter Maydell, wrote: >> Hi; somebody pointed out to me that hw/arm/xlnx-zynqmp.c only >> sets the psci-conduit on the A-profile cores, not the R. This >> means you can't set the boot-cpu to an R-profile core and

[PULL 00/30] Migration pull patches (3rd try)

2020-01-14 Thread Juan Quintela
The following changes since commit 3c8a6575985b1652b45bfa670b5e1907d642cfa0: Merge remote-tracking branch 'remotes/kraxel/tags/usb-20200113-pull-request' into staging (2020-01-13 14:19:57 +) are available in the Git repository at: https://github.com/juanquintela/qemu.git tags/migration-

[PULL 02/30] migration-test: Add migration multifd test

2020-01-14 Thread Juan Quintela
We set multifd-channels. Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Thomas Huth Tested-by: Wei Yang --- tests/qtest/migration-test.c | 56 1 file changed, 56 insertions(+) diff --git a/tests/qtest/migration-test.c b/test

[PULL 03/30] migration: Make sure that we don't call write() in case of error

2020-01-14 Thread Juan Quintela
If we are exiting due to an error/finish/ Just don't try to even touch the channel with one IO operation. Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert --- migration/ram.c | 25 + 1 file changed, 25 insertions(+) diff --git a/migration/ram.c b/mig

[PULL 07/30] ram.c: remove unneeded labels

2020-01-14 Thread Juan Quintela
From: Daniel Henrique Barboza ram_save_queue_pages() has an 'err' label that can be replaced by 'return -1' instead. Same thing with ram_discard_range(), and in this case we can also get rid of the 'ret' variable and return either '-1' on error or the result of ram_block_discard_range(). CC: Ju

[PULL 01/30] multifd: Initialize local variable

2020-01-14 Thread Juan Quintela
Fill everything with zero, so the padding fields are also initialized. Signed-off-by: Juan Quintela --- migration/ram.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/migration/ram.c b/migration/ram.c index 96feb4062c..b9147bcca3 100644 --- a/migration/ram.c +++ b/migration/

[PULL 04/30] migration-test: introduce functions to handle string parameters

2020-01-14 Thread Juan Quintela
Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert --- tests/qtest/migration-test.c | 37 1 file changed, 37 insertions(+) diff --git a/tests/qtest/migration-test.c b/tests/qtest/migration-test.c index fb70214f44..b0580dd541 100644 --- a/tests/

[PULL 05/30] migration-test: ppc64: fix FORTH test program

2020-01-14 Thread Juan Quintela
From: Laurent Vivier Commit e51e711b1bef has moved the initialization of start_address and end_address after the definition of the command line argument, where the nvramrc is initialized, and thus the loop is between 0 and 0 rather than 1 MiB and 100 MiB. It doesn't affect the result of the test

[PULL 11/30] misc: use QEMU_IS_ALIGNED

2020-01-14 Thread Juan Quintela
From: Marc-André Lureau Signed-off-by: Marc-André Lureau Reviewed-by: Juan Quintela Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Stefan Berger Reviewed-by: Paolo Bonzini Signed-off-by: Juan Quintela --- exec.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/exec

[PULL 10/30] migration: Fix the re-run check of the migrate-incoming command

2020-01-14 Thread Juan Quintela
From: Yury Kotov The current check sets an error but doesn't fail the command. This may cause a problem if new connection attempt by the same URI affects the first connection. Signed-off-by: Yury Kotov Reviewed-by: Juan Quintela Reviewed-by: Darren Kenny Signed-off-by: Juan Quintela --- mig

[PULL 09/30] migration: Fix incorrect integer->float conversion caught by clang

2020-01-14 Thread Juan Quintela
From: Fangrui Song Clang does not like qmp_migrate_set_downtime()'s code to clamp double @value to 0..INT64_MAX: qemu/migration/migration.c:2038:24: error: implicit conversion from 'long' to 'double' changes value from 9223372036854775807 to 9223372036854775808 [-Werror,-Wimplicit-int-floa

[PULL 06/30] runstate: ignore finishmigrate -> prelaunch transition

2020-01-14 Thread Juan Quintela
From: Laurent Vivier Commit 1bd71dce4bf2 tries to prevent a finishmigrate -> prelaunch transition by exiting at the beginning of the main_loop_should_exit() function if the state is already finishmigrate. As the finishmigrate state is set in the migration thread it can happen concurrently to the

[PULL 12/30] migration: add savevm_state_handler_remove()

2020-01-14 Thread Juan Quintela
From: Scott Cheloha Create a function to abstract common logic needed when removing a SaveStateEntry element from the savevm_state.handlers queue. For now we just remove the element. Soon it will involve additional cleanup. Signed-off-by: Scott Cheloha Reviewed-by: Dr. David Alan Gilbert Rev

[PULL 08/30] migration: Rate limit inside host pages

2020-01-14 Thread Juan Quintela
From: "Dr. David Alan Gilbert" When using hugepages, rate limiting is necessary within each huge page, since a 1G huge page can take a significant time to send, so you end up with bursty behaviour. Fixes: 4c011c37ecb3 ("postcopy: Send whole huge pages") Reported-by: Lin Ma Signed-off-by: Dr. Da

[PULL 15/30] migration/postcopy: reduce memset when it is zero page and matches_target_page_size

2020-01-14 Thread Juan Quintela
From: Wei Yang In this case, page_buffer content would not be used. Skip this to save some time. Signed-off-by: Wei Yang Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/ram.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion

[PULL 16/30] migration/postcopy: wait for decompress thread in precopy

2020-01-14 Thread Juan Quintela
From: Wei Yang Compress is not supported with postcopy, it is safe to wait for decompress thread just in precopy. This is a preparation for later patch. Signed-off-by: Wei Yang Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/ram.c |

[PULL 19/30] migration/postcopy: enable random order target page arrival

2020-01-14 Thread Juan Quintela
From: Wei Yang After using number of target page received to track one host page, we could have the capability to handle random order target page arrival in one host page. This is a preparation for enabling compress during postcopy. Signed-off-by: Wei Yang Reviewed-by: Dr. David Alan Gilbert

[PULL 13/30] migration: savevm_state_handler_insert: constant-time element insertion

2020-01-14 Thread Juan Quintela
From: Scott Cheloha savevm_state's SaveStateEntry TAILQ is a priority queue. Priority sorting is maintained by searching from head to tail for a suitable insertion spot. Insertion is thus an O(n) operation. If we instead keep track of the head of each priority's subqueue within that larger que

[PULL 17/30] migration/postcopy: count target page number to decide the place_needed

2020-01-14 Thread Juan Quintela
From: Wei Yang In postcopy, it requires to place whole host page instead of target page. Currently, it relies on the page offset to decide whether this is the last target page. We also can count the target page number during the iteration. When the number of target page equals (host page size /

[PULL 21/30] migration/multifd: clean pages after filling packet

2020-01-14 Thread Juan Quintela
From: Wei Yang This is a preparation for the next patch: not use multifd during postcopy. Without enabling postcopy, everything looks good. While after enabling postcopy, migration may fail even not use multifd during postcopy. The reason is the pages is not properly cleared and *old* targe

[PULL 18/30] migration/postcopy: set all_zero to true on the first target page

2020-01-14 Thread Juan Quintela
From: Wei Yang For the first target page, all_zero is set to true for this round check. After target_pages introduced, we could leverage this variable instead of checking the address offset. Signed-off-by: Wei Yang Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela Signed-off-by:

[PULL 14/30] migration/ram: Yield periodically to the main loop

2020-01-14 Thread Juan Quintela
From: Yury Kotov Usually, incoming migration coroutine yields to the main loop while its IO-channel is waiting for data to receive. But there is a case when RAM migration and data receive have the same speed: VM with huge zeroed RAM. In this case, IO-channel won't read and thus the main loop is s

[PULL 20/30] migration/postcopy: enable compress during postcopy

2020-01-14 Thread Juan Quintela
From: Wei Yang postcopy requires to place a whole host page, while migration thread migrate memory in target page size. This makes postcopy need to collect all target pages in one host page before placing via userfaultfd. To enable compress during postcopy, there are two problems to solve:

[PULL 23/30] migration/multifd: fix nullptr access in terminating multifd threads

2020-01-14 Thread Juan Quintela
From: Jiahui Cen One multifd channel will shutdown all the other multifd's IOChannel when it fails to receive an IOChannel. In this senario, if some multifds had not received its IOChannel yet, it would try to shutdown its IOChannel which could cause nullptr access at qio_channel_shutdown. Here

[PULL 22/30] migration/multifd: not use multifd during postcopy

2020-01-14 Thread Juan Quintela
From: Wei Yang We don't support multifd during postcopy, but user still could enable both multifd and postcopy. This leads to migration failure. Skip multifd during postcopy. Signed-off-by: Wei Yang Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/ram.c | 9 ++--- 1

[PULL 24/30] migration/multifd: fix destroyed mutex access in terminating multifd threads

2020-01-14 Thread Juan Quintela
From: Jiahui Cen One multifd will lock all the other multifds' IOChannel mutex to inform them to quit by setting p->quit or shutting down p->c. In this senario, if some multifds had already been terminated and multifd_load_cleanup/multifd_save_cleanup had destroyed their mutex, it could cause de

[PULL 29/30] migration: Support QLIST migration

2020-01-14 Thread Juan Quintela
From: Eric Auger Support QLIST migration using the same principle as QTAILQ: 94869d5c52 ("migration: migrate QTAILQ"). The VMSTATE_QLIST_V macro has the same proto as VMSTATE_QTAILQ_V. The change mainly resides in QLIST RAW macros: QLIST_RAW_INSERT_HEAD and QLIST_RAW_REVERSE. Tests also are pro

[PULL 26/30] migration: Define VMSTATE_INSTANCE_ID_ANY

2020-01-14 Thread Juan Quintela
From: Peter Xu Define the new macro VMSTATE_INSTANCE_ID_ANY for callers who wants to auto-generate the vmstate instance ID. Previously it was hard coded as -1 instead of this macro. It helps to change this default value in the follow up patches. No functional change. Signed-off-by: Peter Xu

[PULL 25/30] Bug #1829242 correction.

2020-01-14 Thread Juan Quintela
From: Alexey Romko Added type conversions to ram_addr_t before all left shifts of page indexes to TARGET_PAGE_BITS, to correct overflows when the page address was 4Gb and more. Signed-off-by: Alexey Romko Reviewed-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Juan Quint

[PULL 27/30] migration: Change SaveStateEntry.instance_id into uint32_t

2020-01-14 Thread Juan Quintela
From: Peter Xu It was always used as 32bit, so define it as used to be clear. Instead of using -1 as the auto-gen magic value, we switch to UINT32_MAX. We also make sure that we don't auto-gen this value to avoid overflowed instance IDs without being noticed. Suggested-by: Juan Quintela Signed

[PULL 28/30] apic: Use 32bit APIC ID for migration instance ID

2020-01-14 Thread Juan Quintela
From: Peter Xu Migration is silently broken now with x2apic config like this: -smp 200,maxcpus=288,sockets=2,cores=72,threads=2 \ -device intel-iommu,intremap=on,eim=on After migration, the guest kernel could hang at anything, due to x2apic bit not migrated correctly in IA32_APIC_BASE

Re: [PULL 01/30] multifd: Initialize local variable

2020-01-14 Thread Daniel P . Berrangé
On Tue, Jan 14, 2020 at 12:38:57PM +0100, Juan Quintela wrote: > Fill everything with zero, so the padding fields are also initialized. > > Signed-off-by: Juan Quintela > --- > migration/ram.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Daniel P. Berrangé Regards, Da

[PULL 30/30] multifd: Allocate uint64_t instead of ram_addr_t

2020-01-14 Thread Juan Quintela
We receive that value over the network, and ram_addr_t depends of architecture. Just make enough space for 64bit. Signed-off-by: Juan Quintela --- migration/ram.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/migration/ram.c b/migration/ram.c index d0940387d1..ba6e0eea15 1

Re: [PULL 30/30] multifd: Allocate uint64_t instead of ram_addr_t

2020-01-14 Thread Daniel P . Berrangé
On Tue, Jan 14, 2020 at 12:39:26PM +0100, Juan Quintela wrote: > We receive that value over the network, and ram_addr_t depends of > architecture. Just make enough space for 64bit. > > Signed-off-by: Juan Quintela > --- > migration/ram.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-)

[PATCH v2] hw/ppc/prep: Remove the deprecated "prep" machine and the OpenHackware BIOS

2020-01-14 Thread Thomas Huth
It's been deprecated since QEMU v3.1. The 40p machine should be used nowadays instead. Reviewed-by: Philippe Mathieu-Daudé Acked-by: Hervé Poussineau Signed-off-by: Thomas Huth --- v2: Rebase to master (qtests moved to a separate directory) .gitmodules | 3 - MAINTAINERS

Re: [PATCH] block: Use a GString in bdrv_perm_names()

2020-01-14 Thread Max Reitz
On 10.01.20 18:15, Alberto Garcia wrote: > This is a bit more efficient than having to allocate and free memory > for each new permission. > > The default size (30) is enough for "consistent read, write, resize". > > Signed-off-by: Alberto Garcia > --- > block.c | 11 ++- > 1 file chang

Re: [PATCH 01/12] linux-user: Add support for enabling/disabling RTC features using ioctls

2020-01-14 Thread Laurent Vivier
Le 09/01/2020 à 13:59, Filip Bozuta a écrit : > This patch implements functionalities of following ioctls: > > RTC_AIE_ON, RTC_AIE_OFF - Alarm interrupt enabling on/off > > Enable or disable the alarm interrupt, for RTCs that support > alarms. The third ioctl's argument is ignored. > >

Re: [PATCH 02/12] linux-user: Add support for getting/setting RTC time and alarm using ioctls

2020-01-14 Thread Laurent Vivier
Le 09/01/2020 à 13:59, Filip Bozuta a écrit : > This patch implements functionalities of following ioctls: > > RTC_RD_TIME - Getting RTC time > > Returns this RTC's time in the following structure: > > struct rtc_time { > int tm_sec; > int tm_min; >

Re: [PATCH 03/12] linux-user: Add support for getting/setting RTC periodic interrupt and epoch using ioctls

2020-01-14 Thread Laurent Vivier
Le 09/01/2020 à 13:59, Filip Bozuta a écrit : > This patch implements functionalities of following ioctls: > > RTC_IRQP_READ, RTC_IRQP_SET - Getting/Setting IRQ rate > > Read and set the frequency for periodic interrupts, for RTCs > that support periodic interrupts. The periodic interrupt

Re: [PATCH 04/12] linux-user: Add support for getting/setting RTC wakeup alarm using ioctls

2020-01-14 Thread Laurent Vivier
Le 09/01/2020 à 13:59, Filip Bozuta a écrit : > This patch implements functionalities of following ioctls: > > RTC_WKALM_SET, RTC_WKALM_GET - Getting/Setting wakeup alarm > > Some RTCs support a more powerful alarm interface, using these > ioctls to read or write the RTC's alarm time (res

Re: [PATCH 00/12] linux-user: Add support for real time clock and

2020-01-14 Thread Philippe Mathieu-Daudé
Hi Filip, This is v5. On 1/9/20 1:59 PM, Filip Bozuta wrote: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This series covers following RTC and sound timer ioctls: RTC ioctls(22): * RTC_AIE_ON * RTC_ALM_SET * RTC_WKALM_SET

Re: [PATCH 05/12] linux-user: Add support for getting/setting RTC PLL correction using ioctls

2020-01-14 Thread Laurent Vivier
Le 09/01/2020 à 13:59, Filip Bozuta a écrit : > This patch implements functionalities of following ioctls: > > RTC_PLL_GET - Getting PLL correction > > Read the PLL correction for RTCs that support PLL. The PLL correction > is returned in the following structure: > > struct rtc_p

Re: [PATCH 06/12] linux-user: Add support for read/clear RTC voltage low detector using ioctls

2020-01-14 Thread Laurent Vivier
Le 09/01/2020 à 13:59, Filip Bozuta a écrit : > RTC_VL_READ - Read voltage low detection information > > Read the voltage low for RTCs that support voltage low. > The third ioctl's' argument points to an int in which > the voltage low is returned. > > RTC_VL_CLR - Clear voltage low in

Re: [PATCH 07/12] linux-user: Add support for getting alsa timer version and id

2020-01-14 Thread Laurent Vivier
Le 09/01/2020 à 13:59, Filip Bozuta a écrit : > This patch implements functionalities of following ioctls: > > SNDRV_TIMER_IOCTL_PVERSION - Getting the sound timer version > > Read the sound timer version. The third ioctl's argument is > a pointer to an int in which the specified timers v

Re: [PULL 00/30] Migration pull patches (3rd try)

2020-01-14 Thread Juan Quintela
Juan Quintela wrote: > The following changes since commit 3c8a6575985b1652b45bfa670b5e1907d642cfa0: > > Merge remote-tracking branch > 'remotes/kraxel/tags/usb-20200113-pull-request' into staging (2020-01-13 > 14:19:57 +) > > are available in the Git repository at: > > https://github.com

Re: [PATCH] target/arm: add PMU feature to cortex-r5 and cortex-r5f

2020-01-14 Thread Philippe Mathieu-Daudé
On 1/14/20 11:59 AM, Clement Deschamps wrote: Maybe describe here: The PMU is not optional on cortex-r5 and cortex-r5f (see the "Features" chapter of the Technical Reference Manual). Signed-off-by: Clement Deschamps Reviewed-by: Philippe Mathieu-Daudé --- See cortex-r5 TRM - 1.3 Features

Re: [PATCH 08/12] linux-user: Add support for setting alsa timer enhanced read using ioctl

2020-01-14 Thread Laurent Vivier
Le 09/01/2020 à 13:59, Filip Bozuta a écrit : > This patch implements functionalities of following ioctl: > > SNDRV_TIMER_IOCTL_TREAD - Setting enhanced time read > > Sets enhanced time read which is used for reading time with timestamps > and events. The third ioctl's argument is a point

Re: [PATCH 00/12] linux-user: Add support for real time clock and

2020-01-14 Thread Laurent Vivier
Le 14/01/2020 à 13:39, Philippe Mathieu-Daudé a écrit : > Hi Filip, > > This is v5. > > On 1/9/20 1:59 PM, Filip Bozuta wrote: >> MIME-Version: 1.0 >> Content-Type: text/plain; charset=UTF-8 >> Content-Transfer-Encoding: 8bit >> >> This series covers following RTC and sound timer ioctls: >> >>   

Re: [PATCH] block: Use a GString in bdrv_perm_names()

2020-01-14 Thread Philippe Mathieu-Daudé
On 1/10/20 6:15 PM, Alberto Garcia wrote: This is a bit more efficient than having to allocate and free memory for each new permission. The default size (30) is enough for "consistent read, write, resize". Signed-off-by: Alberto Garcia --- block.c | 11 ++- 1 file changed, 6 inserti

[PULL 00/30] Migration pull patches (take 4)

2020-01-14 Thread Juan Quintela
The following changes since commit 3c8a6575985b1652b45bfa670b5e1907d642cfa0: Merge remote-tracking branch 'remotes/kraxel/tags/usb-20200113-pull-request' into staging (2020-01-13 14:19:57 +) are available in the Git repository at: https://github.com/juanquintela/qemu.git tags/migration-

Re: [PATCH 09/12] linux-user: Add support for getting/setting specified alsa timer parameters using ioctls

2020-01-14 Thread Laurent Vivier
Le 09/01/2020 à 13:59, Filip Bozuta a écrit : > This patch implements functionalities of following ioctls: > > SNDRV_TIMER_IOCTL_GINFO - Getting information about specified timer > > Read information about the specified timer. The information about the > timer is returned in the following

[PULL 06/30] migration-test: ppc64: fix FORTH test program

2020-01-14 Thread Juan Quintela
From: Laurent Vivier Commit e51e711b1bef has moved the initialization of start_address and end_address after the definition of the command line argument, where the nvramrc is initialized, and thus the loop is between 0 and 0 rather than 1 MiB and 100 MiB. It doesn't affect the result of the test

[PULL 01/30] multifd: Initialize local variable

2020-01-14 Thread Juan Quintela
Fill everything with zero, so the padding fields are also initialized. Signed-off-by: Juan Quintela Reviewed-by: Daniel P. Berrangé --- migration/ram.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/migration/ram.c b/migration/ram.c index 96feb4062c..b9147bcca3 100644 --- a

[PULL 11/30] migration: Fix the re-run check of the migrate-incoming command

2020-01-14 Thread Juan Quintela
From: Yury Kotov The current check sets an error but doesn't fail the command. This may cause a problem if new connection attempt by the same URI affects the first connection. Signed-off-by: Yury Kotov Reviewed-by: Juan Quintela Reviewed-by: Darren Kenny Signed-off-by: Juan Quintela --- mig

[PULL 04/30] migration: Make sure that we don't call write() in case of error

2020-01-14 Thread Juan Quintela
If we are exiting due to an error/finish/ Just don't try to even touch the channel with one IO operation. Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert --- migration/ram.c | 25 + 1 file changed, 25 insertions(+) diff --git a/migration/ram.c b/mig

[PULL 02/30] multifd: Allocate uint64_t instead of ram_addr_t

2020-01-14 Thread Juan Quintela
We receive that value over the network, and ram_addr_t depends of architecture. Just make enough space for 64bit. Signed-off-by: Juan Quintela Reviewed-by: Daniel P. Berrangé --- migration/ram.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/migration/ram.c b/migration/ram

[PULL 09/30] migration: Rate limit inside host pages

2020-01-14 Thread Juan Quintela
From: "Dr. David Alan Gilbert" When using hugepages, rate limiting is necessary within each huge page, since a 1G huge page can take a significant time to send, so you end up with bursty behaviour. Fixes: 4c011c37ecb3 ("postcopy: Send whole huge pages") Reported-by: Lin Ma Signed-off-by: Dr. Da

Re: [PATCH 10/12] linux-user: Add support for selecting alsa timer using ioctl

2020-01-14 Thread Laurent Vivier
Le 09/01/2020 à 13:59, Filip Bozuta a écrit : > This patch implements functionality of following ioctl: > > SNDRV_TIMER_IOCTL_SELECT - Selecting timer > > Selects the timer which id is specified. The timer id is specified in the > following strcuture: > > struct snd_timer_select { >

[PULL 14/30] migration: savevm_state_handler_insert: constant-time element insertion

2020-01-14 Thread Juan Quintela
From: Scott Cheloha savevm_state's SaveStateEntry TAILQ is a priority queue. Priority sorting is maintained by searching from head to tail for a suitable insertion spot. Insertion is thus an O(n) operation. If we instead keep track of the head of each priority's subqueue within that larger que

[PULL 10/30] migration: Fix incorrect integer->float conversion caught by clang

2020-01-14 Thread Juan Quintela
From: Fangrui Song Clang does not like qmp_migrate_set_downtime()'s code to clamp double @value to 0..INT64_MAX: qemu/migration/migration.c:2038:24: error: implicit conversion from 'long' to 'double' changes value from 9223372036854775807 to 9223372036854775808 [-Werror,-Wimplicit-int-floa

[PULL 03/30] migration-test: Add migration multifd test

2020-01-14 Thread Juan Quintela
We set multifd-channels. Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Thomas Huth Tested-by: Wei Yang --- tests/qtest/migration-test.c | 56 1 file changed, 56 insertions(+) diff --git a/tests/qtest/migration-test.c b/test

[PULL 05/30] migration-test: introduce functions to handle string parameters

2020-01-14 Thread Juan Quintela
Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert --- tests/qtest/migration-test.c | 37 1 file changed, 37 insertions(+) diff --git a/tests/qtest/migration-test.c b/tests/qtest/migration-test.c index fb70214f44..b0580dd541 100644 --- a/tests/

[PULL 15/30] migration/ram: Yield periodically to the main loop

2020-01-14 Thread Juan Quintela
From: Yury Kotov Usually, incoming migration coroutine yields to the main loop while its IO-channel is waiting for data to receive. But there is a case when RAM migration and data receive have the same speed: VM with huge zeroed RAM. In this case, IO-channel won't read and thus the main loop is s

[PULL 13/30] migration: add savevm_state_handler_remove()

2020-01-14 Thread Juan Quintela
From: Scott Cheloha Create a function to abstract common logic needed when removing a SaveStateEntry element from the savevm_state.handlers queue. For now we just remove the element. Soon it will involve additional cleanup. Signed-off-by: Scott Cheloha Reviewed-by: Dr. David Alan Gilbert Rev

[PULL 07/30] runstate: ignore finishmigrate -> prelaunch transition

2020-01-14 Thread Juan Quintela
From: Laurent Vivier Commit 1bd71dce4bf2 tries to prevent a finishmigrate -> prelaunch transition by exiting at the beginning of the main_loop_should_exit() function if the state is already finishmigrate. As the finishmigrate state is set in the migration thread it can happen concurrently to the

[PULL 19/30] migration/postcopy: set all_zero to true on the first target page

2020-01-14 Thread Juan Quintela
From: Wei Yang For the first target page, all_zero is set to true for this round check. After target_pages introduced, we could leverage this variable instead of checking the address offset. Signed-off-by: Wei Yang Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela Signed-off-by:

[PULL 18/30] migration/postcopy: count target page number to decide the place_needed

2020-01-14 Thread Juan Quintela
From: Wei Yang In postcopy, it requires to place whole host page instead of target page. Currently, it relies on the page offset to decide whether this is the last target page. We also can count the target page number during the iteration. When the number of target page equals (host page size /

[PULL 08/30] ram.c: remove unneeded labels

2020-01-14 Thread Juan Quintela
From: Daniel Henrique Barboza ram_save_queue_pages() has an 'err' label that can be replaced by 'return -1' instead. Same thing with ram_discard_range(), and in this case we can also get rid of the 'ret' variable and return either '-1' on error or the result of ram_block_discard_range(). CC: Ju

[PULL 17/30] migration/postcopy: wait for decompress thread in precopy

2020-01-14 Thread Juan Quintela
From: Wei Yang Compress is not supported with postcopy, it is safe to wait for decompress thread just in precopy. This is a preparation for later patch. Signed-off-by: Wei Yang Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/ram.c |

Re: [PATCH v28 17/22] hw/rx: RX Target hardware definition

2020-01-14 Thread Yoshinori Sato
On Mon, 13 Jan 2020 18:17:14 +0900, Igor Mammedov wrote: > > On Sun, 12 Jan 2020 21:49:08 +0900 > Yoshinori Sato wrote: > > > rx62n - RX62N cpu. > > rx-virt - RX QEMU virtual target. > > > > v23 changes. > > Add missing includes. > > > > v21 changes. > > rx_load_image move to rx-virt.c > > >

[PULL 12/30] misc: use QEMU_IS_ALIGNED

2020-01-14 Thread Juan Quintela
From: Marc-André Lureau Signed-off-by: Marc-André Lureau Reviewed-by: Juan Quintela Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Stefan Berger Reviewed-by: Paolo Bonzini Signed-off-by: Juan Quintela --- exec.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/exec

[PULL 21/30] migration/postcopy: enable compress during postcopy

2020-01-14 Thread Juan Quintela
From: Wei Yang postcopy requires to place a whole host page, while migration thread migrate memory in target page size. This makes postcopy need to collect all target pages in one host page before placing via userfaultfd. To enable compress during postcopy, there are two problems to solve:

[PULL 28/30] migration: Change SaveStateEntry.instance_id into uint32_t

2020-01-14 Thread Juan Quintela
From: Peter Xu It was always used as 32bit, so define it as used to be clear. Instead of using -1 as the auto-gen magic value, we switch to UINT32_MAX. We also make sure that we don't auto-gen this value to avoid overflowed instance IDs without being noticed. Suggested-by: Juan Quintela Signed

[PULL 24/30] migration/multifd: fix nullptr access in terminating multifd threads

2020-01-14 Thread Juan Quintela
From: Jiahui Cen One multifd channel will shutdown all the other multifd's IOChannel when it fails to receive an IOChannel. In this senario, if some multifds had not received its IOChannel yet, it would try to shutdown its IOChannel which could cause nullptr access at qio_channel_shutdown. Here

[PULL 25/30] migration/multifd: fix destroyed mutex access in terminating multifd threads

2020-01-14 Thread Juan Quintela
From: Jiahui Cen One multifd will lock all the other multifds' IOChannel mutex to inform them to quit by setting p->quit or shutting down p->c. In this senario, if some multifds had already been terminated and multifd_load_cleanup/multifd_save_cleanup had destroyed their mutex, it could cause de

[PULL 16/30] migration/postcopy: reduce memset when it is zero page and matches_target_page_size

2020-01-14 Thread Juan Quintela
From: Wei Yang In this case, page_buffer content would not be used. Skip this to save some time. Signed-off-by: Wei Yang Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/ram.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion

[PULL 30/30] migration: Support QLIST migration

2020-01-14 Thread Juan Quintela
From: Eric Auger Support QLIST migration using the same principle as QTAILQ: 94869d5c52 ("migration: migrate QTAILQ"). The VMSTATE_QLIST_V macro has the same proto as VMSTATE_QTAILQ_V. The change mainly resides in QLIST RAW macros: QLIST_RAW_INSERT_HEAD and QLIST_RAW_REVERSE. Tests also are pro

<    1   2   3   4   5   >