Re: [PATCH] hw/core/qdev: Increase qdev_realize() kindness

2020-07-04 Thread Paolo Bonzini
On 20/06/20 17:38, Philippe Mathieu-Daudé wrote: > -} else { > -assert(!DEVICE_GET_CLASS(dev)->bus_type); > +} else if (DEVICE_GET_CLASS(dev)->bus_type) { > +error_report("%s: Unexpected bus '%s' for device '%s'", > + __func__,

Re: [PATCH 24/26] hw/usb/usb-hcd: Use UHCI type definitions

2020-07-04 Thread Paolo Bonzini
On 04/07/20 21:44, BALATON Zoltan wrote: > > No it's OK, no need to list all defines. I just did not notice the macro > argument that's why I was wondering where it comes from. This seems to > be used elsewhere at least here: > > hw/audio/es1370.c:#define a(n) if (val & CTRL_##n) strcat (buf, "

Re: [PATCH] hw/arm/bcm2836: Remove unused 'cpu_type' field

2020-07-04 Thread Alistair Francis
On Fri, Jul 3, 2020 at 1:05 PM Philippe Mathieu-Daudé wrote: > > The 'cpu_type' has been moved from BCM283XState to BCM283XClass > in commit 210f47840d, but we forgot to remove the old variable. > Do it now. > > Fixes: 210f47840d ("hw/arm/bcm2836: Hardcode correct CPU type") > Signed-off-by:

[Bug 1885827] Re: building plugin failed on Windows with mingw

2020-07-04 Thread Emilio G. Cota
Xiaolei confirmed to me via email that adding -DBUILDING_DLL is not enough to fix the problem. I looked into this a bit further and it looks like we need an "import library" to be created when compiling the QEMU binary. This is accomplished by adding "-Wl,--out-implib,libqemu_plugin.a" to the

Re: [PATCH v7 09/17] hw/sd/sdcard: Special case the -ENOMEDIUM error

2020-07-04 Thread Philippe Mathieu-Daudé
On 7/5/20 12:18 AM, Philippe Mathieu-Daudé wrote: > On 7/5/20 12:10 AM, Philippe Mathieu-Daudé wrote: >> On 7/4/20 1:42 AM, Philippe Mathieu-Daudé wrote: >>> On 7/3/20 5:16 PM, Philippe Mathieu-Daudé wrote: On 7/3/20 3:23 PM, Peter Maydell wrote: > On Tue, 30 Jun 2020 at 14:39, Philippe

Re: [PATCH v7 09/17] hw/sd/sdcard: Special case the -ENOMEDIUM error

2020-07-04 Thread Philippe Mathieu-Daudé
On 7/5/20 12:10 AM, Philippe Mathieu-Daudé wrote: > On 7/4/20 1:42 AM, Philippe Mathieu-Daudé wrote: >> On 7/3/20 5:16 PM, Philippe Mathieu-Daudé wrote: >>> On 7/3/20 3:23 PM, Peter Maydell wrote: On Tue, 30 Jun 2020 at 14:39, Philippe Mathieu-Daudé wrote: > > As we have no

Re: [PATCH v7 09/17] hw/sd/sdcard: Special case the -ENOMEDIUM error

2020-07-04 Thread Philippe Mathieu-Daudé
On 7/4/20 1:42 AM, Philippe Mathieu-Daudé wrote: > On 7/3/20 5:16 PM, Philippe Mathieu-Daudé wrote: >> On 7/3/20 3:23 PM, Peter Maydell wrote: >>> On Tue, 30 Jun 2020 at 14:39, Philippe Mathieu-Daudé >>> wrote: As we have no interest in the underlying block geometry, directly call

Re: gmake in Solaris 11.4: TFR missing

2020-07-04 Thread Peter Maydell
On Sat, 4 Jul 2020 at 20:15, Michele Denber wrote: > > On 07/04/20 11:57, Philippe Mathieu-Daudé wrote: > > Odd... > > Assuming you are using gcc, have you tried 'configure --host-cc=gcc'? > > OK, so I changed it from > > # /opt/csw/bin/bash ./configure --cc=gcc --extra-cflags="-m32" > > to > >

[PATCH v3 15/16] block/nvme: Move nvme_poll_cb() earlier

2020-07-04 Thread Philippe Mathieu-Daudé
We are going to use this callback in nvme_add_io_queue() in the next commit. To avoid forward-declaring it, move it before. No logical change. Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 18 +- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git

Re: [PATCH v2 11/18] hw/block/nvme: add remaining mandatory controller parameters

2020-07-04 Thread Philippe Mathieu-Daudé
On 7/3/20 4:37 PM, Klaus Jensen wrote: > On Jul 3 13:02, Philippe Mathieu-Daudé wrote: >> On 7/3/20 12:10 PM, Klaus Jensen wrote: >>> On Jul 3 11:21, Philippe Mathieu-Daudé wrote: On 7/3/20 10:46 AM, Klaus Jensen wrote: > On Jul 3 10:31, Philippe Mathieu-Daudé wrote: >> On 7/3/20

[PATCH v3 14/16] block/nvme: Extract nvme_poll_queue()

2020-07-04 Thread Philippe Mathieu-Daudé
As we want to do per-queue polling, extract the nvme_poll_queue() method which operates on a single queue. Signed-off-by: Philippe Mathieu-Daudé --- Stefan better double check here! --- block/nvme.c | 44 +++- 1 file changed, 27 insertions(+), 17

[PATCH v3 13/16] block/nvme: Simplify nvme_create_queue_pair() arguments

2020-07-04 Thread Philippe Mathieu-Daudé
nvme_create_queue_pair() doesn't require BlockDriverState anymore. Replace it by BDRVNVMeState and AioContext to simplify. Reviewed-by: Stefan Hajnoczi Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 13 +++-- 1 file changed, 7 insertions(+), 6 deletions(-) diff --git

[PATCH v3 12/16] block/nvme: Replace BDRV_POLL_WHILE by AIO_WAIT_WHILE

2020-07-04 Thread Philippe Mathieu-Daudé
BDRV_POLL_WHILE() is defined as: #define BDRV_POLL_WHILE(bs, cond) ({ \ BlockDriverState *bs_ = (bs); \ AIO_WAIT_WHILE(bdrv_get_aio_context(bs_), \ cond); }) As we will remove the BlockDriverState use in the next commit, start by using the

[PATCH v3 11/16] block/nvme: Simplify nvme_init_queue() arguments

2020-07-04 Thread Philippe Mathieu-Daudé
nvme_init_queue() doesn't require BlockDriverState anymore. Replace it by BDRVNVMeState to simplify. Reviewed-by: Stefan Hajnoczi Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/block/nvme.c b/block/nvme.c index

[PATCH v3 07/16] block/nvme: Rename local variable

2020-07-04 Thread Philippe Mathieu-Daudé
We are going to modify the code in the next commit. Renaming the 'resp' variable to 'id' first makes the next commit easier to review. No logical changes. Reviewed-by: Stefan Hajnoczi Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 19 +-- 1 file changed, 9

[PATCH v3 10/16] block/nvme: Replace qemu_try_blockalign(bs) by qemu_try_memalign(pg_sz)

2020-07-04 Thread Philippe Mathieu-Daudé
qemu_try_blockalign() is a generic API that call back to the block driver to return its page alignment. As we call from within the very same driver, we already know to page alignment stored in our state. Remove indirections and use the value from BDRVNVMeState. This change is required to later

[PATCH v3 06/16] block/nvme: Use common error path in nvme_add_io_queue()

2020-07-04 Thread Philippe Mathieu-Daudé
Rearrange nvme_add_io_queue() by using a common error path. This will be proven useful in few commits where we add IRQ notification to the IO queues. Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/block/nvme.c

[PATCH v3 09/16] block/nvme: Replace qemu_try_blockalign0 by qemu_try_blockalign/memset

2020-07-04 Thread Philippe Mathieu-Daudé
In the next commit we'll get rid of qemu_try_blockalign(). To ease review, first replace qemu_try_blockalign0() by explicit calls to qemu_try_blockalign() and memset(). Reviewed-by: Stefan Hajnoczi Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 16 +--- 1 file changed, 9

[PATCH v3 05/16] block/nvme: Improve error message when IO queue creation failed

2020-07-04 Thread Philippe Mathieu-Daudé
Do not use the same error message for different failures. Display a different error whether it is the CQ or the SQ. Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/block/nvme.c b/block/nvme.c index

[PATCH v3 08/16] block/nvme: Use union of NvmeIdCtrl / NvmeIdNs structures

2020-07-04 Thread Philippe Mathieu-Daudé
We allocate an unique chunk of memory then use it for two different structures. By using an union, we make it clear the data is overlapping (and we can remove the casts). Suggested-by: Stefan Hajnoczi Reviewed-by: Stefan Hajnoczi Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 31

[PATCH v3 04/16] block/nvme: Define QUEUE_INDEX macros to ease code review

2020-07-04 Thread Philippe Mathieu-Daudé
Use definitions instead of '0' or '1' indexes. Also this will be useful when using multi-queues later. Reviewed-by: Stefan Hajnoczi Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 33 +++-- 1 file changed, 19 insertions(+), 14 deletions(-) diff --git

[PATCH v3 01/16] block/nvme: Replace magic value by SCALE_MS definition

2020-07-04 Thread Philippe Mathieu-Daudé
Use self-explicit SCALE_MS definition instead of magic value. Reviewed-by: Stefan Hajnoczi Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/nvme.c b/block/nvme.c index 374e268915..2f5e3c2adf 100644 ---

[PATCH v3 16/16] block/nvme: Use per-queuepair IRQ notifier and AIO context

2020-07-04 Thread Philippe Mathieu-Daudé
To be able to use multiple queues on the same hardware, we need to have each queuepair able to receive IRQ notifications in the correct AIO context. The AIO context and the notification handler have to be proper to each queue, not to the block driver. Move aio_context and irq_notifier from

[PATCH v3 03/16] block/nvme: Let nvme_create_queue_pair() fail gracefully

2020-07-04 Thread Philippe Mathieu-Daudé
As nvme_create_queue_pair() is allowed to fail, replace the alloc() calls by try_alloc() to avoid aborting QEMU. Reviewed-by: Stefan Hajnoczi Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/block/nvme.c

[PATCH v3 02/16] block/nvme: Avoid further processing if trace event not enabled

2020-07-04 Thread Philippe Mathieu-Daudé
Avoid further processing if TRACE_NVME_SUBMIT_COMMAND_RAW is not enabled. This is an untested intend of performance optimization. Reviewed-by: Stefan Hajnoczi Signed-off-by: Philippe Mathieu-Daudé --- block/nvme.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/block/nvme.c

[PATCH v3 00/16] block/nvme: Various cleanups required to use multiple queues

2020-07-04 Thread Philippe Mathieu-Daudé
Hi, This series is mostly code rearrangement (cleanups) to be able to split the hardware code from the block driver code, to be able to use multiple queues on the same hardware, or multiple block drivers on the same hardware. Missing review: 5, 6, 14, 15 and 16. Since v2: - addressed stefanha

Re: [PATCH v2 12/12] block/nvme: Use per-queue AIO context

2020-07-04 Thread Philippe Mathieu-Daudé
On 7/1/20 6:03 PM, Stefan Hajnoczi wrote: > On Tue, Jun 30, 2020 at 09:13:18PM +0200, Philippe Mathieu-Daudé wrote: >> To be able to use multiple queues on the same hardware, >> we need to have each queue able to receive IRQ notifications >> in the correct AIO context. >> The AIO context and the

Re: [PATCH v2 1/1] disas: mips: Add Loongson 2F disassembler

2020-07-04 Thread Philippe Mathieu-Daudé
Hi Stefan, On 7/3/20 12:44 PM, Stefan Brankovic wrote: > Add disassembler for Loongson 2F instruction set. > > Testing is done by comparing qemu disassembly output, obtained by > using -d in_asm command line option, with appropriate objdump output. > > This disassembler is written as a generic

Re: [PATCH 24/26] hw/usb/usb-hcd: Use UHCI type definitions

2020-07-04 Thread Philippe Mathieu-Daudé
On 7/4/20 9:44 PM, BALATON Zoltan wrote: > On Sat, 4 Jul 2020, Philippe Mathieu-Daudé wrote: >> On 7/4/20 7:17 PM, BALATON Zoltan wrote: >>> On Sat, 4 Jul 2020, Philippe Mathieu-Daudé wrote: Various machine/board/soc models create UHCI device instances with the generic QDEV API, and

Re: gmake in Solaris 11.4: TFR missing

2020-07-04 Thread Michele Denber
Update: actually, after using it for a bit, it appears that XP runs at about the same speed in 5.0 as it did in 2.12. It's just the initial boot that's very slow. Does this message (which I discovered hiding under the QEMU window) have anything to do with it? (qemu:27712): Gtk-WARNING **:

[Bug 1886285] [NEW] Provide SMB option to support Windows 2000

2020-07-04 Thread Dustin Spicuzza
Public bug reported: As of SAMBA 4.11 (https://www.samba.org/samba/history/samba-4.11.0.html), SMB1 is disabled by default (and may be removed in the future). This breaks SMB shares with Windows 2000 guests. Adding the following line to smb.conf fixes this: min protocol = NT1 I would propose

Re: [PATCH 24/26] hw/usb/usb-hcd: Use UHCI type definitions

2020-07-04 Thread BALATON Zoltan
On Sat, 4 Jul 2020, Philippe Mathieu-Daudé wrote: On 7/4/20 7:17 PM, BALATON Zoltan wrote: On Sat, 4 Jul 2020, Philippe Mathieu-Daudé wrote: Various machine/board/soc models create UHCI device instances with the generic QDEV API, and don't need to access USB internals. Simplify header

Re: gmake in Solaris 11.4: TFR missing

2020-07-04 Thread Michele Denber
On 07/04/20 11:57, Philippe Mathieu-Daudé wrote: Odd... Assuming you are using gcc, have you tried 'configure --host-cc=gcc'? OK, so I changed it from # /opt/csw/bin/bash ./configure --cc=gcc --extra-cflags="-m32" to # /opt/csw/bin/bash ./configure --cc=gcc --extra-cflags="-m32"

QEMU | Pipeline #163127090 has failed for master | eb6490f5

2020-07-04 Thread GitLab via
Your pipeline has failed. Project: QEMU ( https://gitlab.com/qemu-project/qemu ) Branch: master ( https://gitlab.com/qemu-project/qemu/-/commits/master ) Commit: eb6490f5 ( https://gitlab.com/qemu-project/qemu/-/commit/eb6490f544388dd24c0d054a96dd304bc7284450 ) Commit Message: Merge

[PULL v2 41/41] vhost-vdpa: introduce vhost-vdpa net client

2020-07-04 Thread Michael S. Tsirkin
From: Cindy Lu This patch set introduces a new net client type: vhost-vdpa. vhost-vdpa net client will set up a vDPA device which is specified by a "vhostdev" parameter. Signed-off-by: Lingshan Zhu Signed-off-by: Tiwei Bie Signed-off-by: Cindy Lu Signed-off-by: Jason Wang Message-Id:

Re: [RFC] virt/acpi: set PSCI flag even when psci_conduit is disabled

2020-07-04 Thread Michael S. Tsirkin
On Fri, Jul 03, 2020 at 11:37:02AM +0100, Peter Maydell wrote: > On Fri, 3 Jul 2020 at 10:44, Heyi Guo wrote: > > > > vms->psci_conduit being disabled only means PSCI is not implemented by > > qemu; it doesn't mean PSCI is not supported on this virtual machine. > > Actually vms->psci_conduit is

[PULL v2 34/41] vhost: implement vhost_dev_start method

2020-07-04 Thread Michael S. Tsirkin
From: Cindy Lu use the vhost_dev_start callback to send the status to backend Signed-off-by: Cindy Lu Message-Id: <20200701145538.22333-8-l...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by: Jason Wang --- hw/virtio/vhost.c | 10 +- 1 file

Re: [PULL 00/41] virtio,acpi: features, fixes, cleanups.

2020-07-04 Thread Michael S. Tsirkin
On Sat, Jul 04, 2020 at 03:05:19PM +0100, Peter Maydell wrote: > On Fri, 3 Jul 2020 at 10:03, Michael S. Tsirkin wrote: > > > > The following changes since commit fc1bff958998910ec8d25db86cd2f53ff125f7ab: > > > > hw/misc/pca9552: Add missing TypeInfo::class_size field (2020-06-29 > > 21:16:10

[PULL v2 39/41] vhost_net: introduce set_config & get_config

2020-07-04 Thread Michael S. Tsirkin
From: Cindy Lu This patch introduces set_config & get_config method which allows vhost_net set/get the config to backend Signed-off-by: Cindy Lu Message-Id: <20200701145538.22333-13-l...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by: Jason Wang ---

[PULL v2 21/41] virtio-mem: Migration sanity checks

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand We want to make sure that certain properties don't change during migration, especially to catch user errors in a nice way. Let's migrate a temporary structure and validate that the properties didn't change. Reviewed-by: Dr. David Alan Gilbert Cc: "Michael S. Tsirkin"

[PULL v2 31/41] virtio-pci: implement queue_enabled method

2020-07-04 Thread Michael S. Tsirkin
From: Jason Wang With version 1, we can detect whether a queue is enabled via queue_enabled. Signed-off-by: Jason Wang Signed-off-by: Cindy Lu Message-Id: <20200701145538.22333-5-l...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by: Jason Wang ---

Failure prints during format or mounting a usb storage device

2020-07-04 Thread Sai Pavan Boddu
Hi, We are seeing some errors when a usb-storage device is formatted or mounted on the guest. Below is commit I have bisected it. ** Errors: / # mount /dev/sda /mnt [New Thread 0x7fffd4680700 (LWP 23270)] [ 33.258454] usb 2-1: reset SuperSpeed Gen 1 USB device number 2 using

[PULL v2 30/41] virtio-bus: introduce queue_enabled method

2020-07-04 Thread Michael S. Tsirkin
From: Jason Wang This patch introduces queue_enabled() method which allows the transport to implement its own way to report whether or not a queue is enabled. Signed-off-by: Jason Wang Signed-off-by: Cindy Lu Message-Id: <20200701145538.22333-4-l...@redhat.com> Reviewed-by: Michael S. Tsirkin

[PULL v2 40/41] vhost-vdpa: introduce vhost-vdpa backend

2020-07-04 Thread Michael S. Tsirkin
From: Cindy Lu Currently we have 2 types of vhost backends in QEMU: vhost kernel and vhost-user. The above patch provides a generic device for vDPA purpose, this vDPA device exposes to user space a non-vendor-specific configuration interface for setting up a vhost HW accelerator, this patch set

[PULL v2 28/41] net: introduce qemu_get_peer

2020-07-04 Thread Michael S. Tsirkin
From: Cindy Lu This is a small function that can get the peer from given NetClientState and queue_index Signed-off-by: Cindy Lu Message-Id: <20200701145538.22333-2-l...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by: Jason Wang --- include/net/net.h

Re: [PATCH 1/2] virtio-ccw: fix virtio_set_ind_atomic

2020-07-04 Thread Michael S. Tsirkin
On Tue, Jun 16, 2020 at 06:50:34AM +0200, Halil Pasic wrote: > The atomic_cmpxchg() loop is broken because we occasionally end up with > old and _old having different values (a legit compiler can generate code > that accessed *ind_addr again to pick up a value for _old instead of > using the value

[PULL v2 37/41] vhost: introduce new VhostOps vhost_force_iommu

2020-07-04 Thread Michael S. Tsirkin
From: Cindy Lu This patch introduces new VhostOps vhost_force_iommu callback to force enable features bit VIRTIO_F_IOMMU_PLATFORM. Signed-off-by: Cindy Lu Message-Id: <20200701145538.22333-11-l...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by: Jason

[PULL v2 18/41] pc: Support for virtio-mem-pci

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand Let's wire it up similar to virtio-pmem. Also disallow unplug, so it's harder for users to shoot themselves into the foot. Reviewed-by: Pankaj Gupta Cc: "Michael S. Tsirkin" Cc: Marcel Apfelbaum Cc: Paolo Bonzini Cc: Richard Henderson Cc: Eduardo Habkost Cc: Eric

[PULL v2 23/41] virtio-mem: Exclude unplugged memory during migration

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand The content of unplugged memory is undefined and should not be migrated, ever. Exclude all unplugged memory during precopy using the precopy notifier infrastructure introduced for free page hinting in virtio-balloon. Unplugged memory is marked as "not dirty", meaning it

[PULL v2 38/41] vhost: implement vhost_force_iommu method

2020-07-04 Thread Michael S. Tsirkin
From: Cindy Lu use the vhost_force_iommu callback to force enable feature bit VIRTIO_F_IOMMU_PLATFORM Signed-off-by: Cindy Lu Message-Id: <20200701145538.22333-12-l...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by: Jason Wang --- hw/virtio/vhost.c

[PULL v2 16/41] hmp: Handle virtio-mem when printing memory device info

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand Print the memory device info just like for other memory devices. Reviewed-by: Dr. David Alan Gilbert Cc: "Dr. David Alan Gilbert" Cc: "Michael S. Tsirkin" Signed-off-by: David Hildenbrand Message-Id: <20200626072248.78761-14-da...@redhat.com> Reviewed-by: Michael S.

[PULL v2 22/41] virtio-mem: Add trace events

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand Let's add some trace events that might come in handy later. Cc: "Michael S. Tsirkin" Cc: "Dr. David Alan Gilbert" Signed-off-by: David Hildenbrand Message-Id: <20200626072248.78761-20-da...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin

[PULL v2 35/41] vhost: introduce new VhostOps vhost_vq_get_addr

2020-07-04 Thread Michael S. Tsirkin
From: Cindy Lu This patch introduces new VhostOps vhost_vq_get_addr_op callback to get the vring addr from the backend Signed-off-by: Cindy Lu Message-Id: <20200701145538.22333-9-l...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by: Jason Wang ---

[PULL v2 33/41] vhost: introduce new VhostOps vhost_dev_start

2020-07-04 Thread Michael S. Tsirkin
From: Cindy Lu This patch introduces new VhostOps vhost_dev_start callback which allows the vhost_net set the start/stop status to backend Signed-off-by: Cindy Lu Message-Id: <20200701145538.22333-7-l...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by:

[PULL v2 12/41] migration/colo: Use ram_block_discard_disable()

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand COLO will copy all memory in a RAM block, disable discarding of RAM. Reviewed-by: Dr. David Alan Gilbert Tested-by: Lukas Straub Cc: "Michael S. Tsirkin" Cc: Hailiang Zhang Cc: Juan Quintela Cc: "Dr. David Alan Gilbert" Signed-off-by: David Hildenbrand Message-Id:

[PULL v2 36/41] vhost: implement vhost_vq_get_addr method

2020-07-04 Thread Michael S. Tsirkin
From: Cindy Lu use vhost_vq_get_addr callback to get the vq address from backend Signed-off-by: Cindy Lu Message-Id: <20200701145538.22333-10-l...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by: Jason Wang --- include/hw/virtio/vhost-backend.h | 4

[PULL v2 32/41] vhost: check the existence of vhost_set_iotlb_callback

2020-07-04 Thread Michael S. Tsirkin
From: Jason Wang Add the check of vhost_set_iotlb_callback before calling Signed-off-by: Jason Wang Signed-off-by: Cindy Lu Message-Id: <20200701145538.22333-6-l...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by: Jason Wang --- hw/virtio/vhost.c | 9

[PULL v2 19/41] virtio-mem: Allow notifiers for size changes

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand We want to send qapi events in case the size of a virtio-mem device changes. This allows upper layers to always know how much memory is actually currently consumed via a virtio-mem device. Unfortuantely, we have to report the id of our proxy device. Let's provide an easy

[PULL v2 09/41] virtio-balloon: Rip out qemu_balloon_inhibit()

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand The only remaining special case is postcopy. It cannot handle concurrent discards yet, which would result in requesting already sent pages from the source. Special-case it in virtio-balloon instead. Introduce migration_in_incoming_postcopy(), to find out if incoming

[PULL v2 27/41] MAINTAINERS: add VT-d entry

2020-07-04 Thread Michael S. Tsirkin
From: Peter Xu Add this entry as suggested by Jason and Michael. CC: Jason Wang CC: Michael S. Tsirkin CC: Paolo Bonzini Signed-off-by: Peter Xu Message-Id: <20200701124418.63060-1-pet...@redhat.com> Acked-by: Jason Wang Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin

[PULL v2 29/41] vhost_net: use the function qemu_get_peer

2020-07-04 Thread Michael S. Tsirkin
From: Cindy Lu user the qemu_get_peer to replace the old process Signed-off-by: Cindy Lu Reviewed-by: Laurent Vivier Message-Id: <20200701145538.22333-3-l...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by: Jason Wang --- hw/net/vhost_net.c | 16

[PULL v2 17/41] numa: Handle virtio-mem in NUMA stats

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand Account the memory to the configured nid. Reviewed-by: Pankaj Gupta Cc: Eduardo Habkost Cc: Marcel Apfelbaum Cc: "Michael S. Tsirkin" Signed-off-by: David Hildenbrand Message-Id: <20200626072248.78761-15-da...@redhat.com> Reviewed-by: Michael S. Tsirkin

[PULL v2 07/41] accel/kvm: Convert to ram_block_discard_disable()

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand Discarding memory does not work as expected. At the time this is called, we cannot have anyone active that relies on discards to work properly. Reviewed-by: Dr. David Alan Gilbert Cc: Paolo Bonzini Signed-off-by: David Hildenbrand Message-Id:

[PULL v2 25/41] tests/acpi: remove stale allowed tables

2020-07-04 Thread Michael S. Tsirkin
From: Andrew Jones Fixes: 93dd625f8bf7 ("tests/acpi: update expected data files") Signed-off-by: Andrew Jones Message-Id: <20200629140938.17566-2-drjo...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- tests/qtest/bios-tables-test-allowed-diff.h | 18

[PULL v2 15/41] MAINTAINERS: Add myself as virtio-mem maintainer

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand Let's make sure patches/bug reports find the right person. Reviewed-by: Dr. David Alan Gilbert Cc: "Michael S. Tsirkin" Cc: Peter Maydell Cc: Markus Armbruster Signed-off-by: David Hildenbrand Message-Id: <20200626072248.78761-13-da...@redhat.com> Reviewed-by:

[PULL v2 26/41] docs: vhost-user: add Virtio status protocol feature

2020-07-04 Thread Michael S. Tsirkin
From: Maxime Coquelin This patch specifies the VHOST_USER_SET_STATUS and VHOST_USER_GET_STATUS requests, which are sent by the master to update and query the Virtio status in the backend. Signed-off-by: Maxime Coquelin Message-Id: <20200618134501.145747-1-maxime.coque...@redhat.com> Acked-by:

[PULL v2 20/41] virtio-pci: Send qapi events when the virtio-mem size changes

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand Let's register the notifier and trigger the qapi event with the right device id. MEMORY_DEVICE_SIZE_CHANGE is similar to BALLOON_CHANGE, however on a memory device level. Don't unregister the notifier (we neither have finalize() nor unrealize() for VirtIOPCIProxy, so

[PULL v2 06/41] vfio: Convert to ram_block_discard_disable()

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand VFIO is (except devices without a physical IOMMU or some mediated devices) incompatible with discarding of RAM. The kernel will pin basically all VM memory. Let's convert to ram_block_discard_disable(), which can now fail, in contrast to qemu_balloon_inhibit(). Leave

[PULL v2 10/41] target/i386: sev: Use ram_block_discard_disable()

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand AMD SEV will pin all guest memory, mark discarding of RAM broken. At the time this is called, we cannot have anyone active that relies on discards to work properly - let's still implement error handling. Reviewed-by: Dr. David Alan Gilbert Cc: "Michael S. Tsirkin" Cc:

[PULL v2 14/41] virtio-pci: Proxy for virtio-mem

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand Let's add a proxy for virtio-mem, make it a memory device, and pass-through the properties. Reviewed-by: Pankaj Gupta Cc: "Michael S. Tsirkin" Cc: Marcel Apfelbaum Cc: "Dr. David Alan Gilbert" Cc: Igor Mammedov Signed-off-by: David Hildenbrand Message-Id:

[PULL v2 24/41] numa: Auto-enable NUMA when any memory devices are possible

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand Let's auto-enable it also when maxmem is specified but no slots are defined. This will result in us properly creating ACPI srat tables, indicating the maximum possible PFN to the guest OS. Based on this, e.g., Linux will enable the swiotlb properly. This avoids having to

[PULL v2 05/41] exec: Introduce ram_block_discard_(disable|require)()

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand We want to replace qemu_balloon_inhibit() by something more generic. Especially, we want to make sure that technologies that really rely on RAM block discards to work reliably to run mutual exclusive with technologies that effectively break it. E.g., vfio will usually

[PULL v2 08/41] s390x/pv: Convert to ram_block_discard_disable()

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand Discarding RAM does not work as expected with protected VMs. Let's switch to ram_block_discard_disable() for now, as we want to get rid of qemu_balloon_inhibit(). Note that it will currently never fail, but might fail in the future with new technologies (e.g.,

[PULL v2 13/41] virtio-mem: Paravirtualized memory hot(un)plug

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand This is the very basic/initial version of virtio-mem. An introduction to virtio-mem can be found in the Linux kernel driver [1]. While it can be used in the current state for hotplug of a smaller amount of memory, it will heavily benefit from resizeable memory regions in

[PULL v2 04/41] pc: Support coldplugging of virtio-pmem-pci devices on all buses

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand E.g., with "pc-q35-4.2", trying to coldplug a virtio-pmem-pci devices results in "virtio-pmem-pci not supported on this bus" Reasons is, that the bus does not support hotplug and, therefore, does not have a hotplug handler. Let's allow coldplugging virtio-pmem

[PULL v2 02/41] Revert "tests/migration: Reduce autoconverge initial bandwidth"

2020-07-04 Thread Michael S. Tsirkin
This reverts commit 6d1da867e65f ("tests/migration: Reduce autoconverge initial bandwidth") since that change makes unit tests much slower for all developers, while it's not a robust way to fix migration tests. Migration tests need to find a more robust way to discover a reasonable bandwidth

[PULL v2 11/41] migration/rdma: Use ram_block_discard_disable()

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand RDMA will pin all guest memory (as documented in docs/rdma.txt). We want to disable RAM block discards - however, to keep it simple use ram_block_discard_is_required() instead of inhibiting. Note: It is not sufficient to limit disabling to pin_all. Even when only

[PULL v2 00/41] virtio,acpi: features, fixes, cleanups.

2020-07-04 Thread Michael S. Tsirkin
v2 of the pull, fixing non-Linux builds. The following changes since commit fc1bff958998910ec8d25db86cd2f53ff125f7ab: hw/misc/pca9552: Add missing TypeInfo::class_size field (2020-06-29 21:16:10 +0100) are available in the Git repository at:

[PULL v2 03/41] virtio-balloon: always indicate S_DONE when migration fails

2020-07-04 Thread Michael S. Tsirkin
From: David Hildenbrand If something goes wrong during precopy, before stopping the VM, we will never send a S_DONE indication to the VM, resulting in the hinted pages not getting released to be used by the guest OS (e.g., Linux). Easy to reproduce: 1. Start migration (e.g., HMP "migrate -d

[PULL v2 01/41] tests: disassemble-aml.sh: generate AML in readable format

2020-07-04 Thread Michael S. Tsirkin
On systems where the IASL tool exists, we can convert extected ACPI tables to ASL format, which is useful for debugging and documentation purposes. This script does this for all ACPI tables under tests/data/acpi/. Signed-off-by: Michael S. Tsirkin --- tests/data/acpi/disassemle-aml.sh |

Re: Failure prints during format or mounting a usb storage device

2020-07-04 Thread Paul Zimmerman
On Sat, Jul 4, 2020 at 11:21 AM Sai Pavan Boddu wrote: > Hi, > > > > We are seeing some errors when a usb-storage device is formatted or > mounted on the guest. Below is commit I have bisected it. > > > > ** > > Errors: > > > > / # mount /dev/sda /mnt > > [New Thread 0x7fffd4680700

Re: [PATCH] net/tap-solaris.c: Include qemu-common.h for TFR macro

2020-07-04 Thread Michele Denber
On 07/04/20 13:11, Thomas Huth wrote: On 04/07/2020 11.23, Peter Maydell wrote: In commit a8d2532645cf5ce4 we cleaned up usage of the qemu-common.h header so that it was always included from .c files and never from other .h files. We missed adding it to net/tap-solaris.c (which previously was

Re: [PATCH 24/26] hw/usb/usb-hcd: Use UHCI type definitions

2020-07-04 Thread Philippe Mathieu-Daudé
On 7/4/20 7:17 PM, BALATON Zoltan wrote: > On Sat, 4 Jul 2020, Philippe Mathieu-Daudé wrote: >> Various machine/board/soc models create UHCI device instances >> with the generic QDEV API, and don't need to access USB internals. >> >> Simplify header inclusions by moving the QOM type names into a

Re: [PATCH 22/26] hw/usb/usb-hcd: Use OHCI type definitions

2020-07-04 Thread Philippe Mathieu-Daudé
On 7/4/20 7:13 PM, BALATON Zoltan wrote: > On Sat, 4 Jul 2020, Philippe Mathieu-Daudé wrote: >> Various machine/board/soc models create OHCI device instances >> with the generic QDEV API, and don't need to access USB internals. >> >> Simplify header inclusions by moving the QOM type names into a

Re: [PATCH 25/26] hw/usb/usb-hcd: Use XHCI type definitions

2020-07-04 Thread Philippe Mathieu-Daudé
On 7/4/20 7:19 PM, BALATON Zoltan wrote: > On Sat, 4 Jul 2020, Philippe Mathieu-Daudé wrote: >> Various machine/board/soc models create XHCI device instances >> with the generic QDEV API, and don't need to access USB internals. >> >> Simplify header inclusions by moving the QOM type names into a

Re: [PULL 00/34] target-arm queue

2020-07-04 Thread Peter Maydell
On Fri, 3 Jul 2020 at 17:54, Peter Maydell wrote: > > I might squeeze in another pullreq before softfreeze, but the > queue was already big enough that I wanted to send this lot out now. > > -- PMM > > The following changes since commit 4abf70a661a5df3886ac9d7c19c3617fa92b922a: > > Merge

[PATCH v2] tests/acceptance: Add a test for the sun4u sparc64 machine

2020-07-04 Thread Thomas Huth
We can use the image from the advent calendar 2018 to test the sun4u machine. It's not using the "QEMU advent calendar" string, so we can not use the do_test_advcal_2018() from boot_linux_console.py, thus let's also put it into a separate file to also be able to add an entry to the MAINTAINERS

Re: [PATCH 25/26] hw/usb/usb-hcd: Use XHCI type definitions

2020-07-04 Thread BALATON Zoltan
On Sat, 4 Jul 2020, Philippe Mathieu-Daudé wrote: Various machine/board/soc models create XHCI device instances with the generic QDEV API, and don't need to access USB internals. Simplify header inclusions by moving the QOM type names into a simple header, with no need to include other "hw/usb"

Re: [PATCH 24/26] hw/usb/usb-hcd: Use UHCI type definitions

2020-07-04 Thread BALATON Zoltan
On Sat, 4 Jul 2020, Philippe Mathieu-Daudé wrote: Various machine/board/soc models create UHCI device instances with the generic QDEV API, and don't need to access USB internals. Simplify header inclusions by moving the QOM type names into a simple header, with no need to include other "hw/usb"

Re: [PATCH 23/26] hw/usb/usb-hcd: Use EHCI type definitions

2020-07-04 Thread BALATON Zoltan
On Sat, 4 Jul 2020, Philippe Mathieu-Daudé wrote: Various machine/board/soc models create EHCI device instances with the generic QDEV API, and don't need to access USB internals. Simplify header inclusions by moving the QOM type names into a simple header, with no need to include other "hw/usb"

Re: [PATCH 22/26] hw/usb/usb-hcd: Use OHCI type definitions

2020-07-04 Thread BALATON Zoltan
On Sat, 4 Jul 2020, Philippe Mathieu-Daudé wrote: Various machine/board/soc models create OHCI device instances with the generic QDEV API, and don't need to access USB internals. Simplify header inclusions by moving the QOM type names into a simple header, with no need to include other "hw/usb"

Re: [PATCH] net/tap-solaris.c: Include qemu-common.h for TFR macro

2020-07-04 Thread Thomas Huth
On 04/07/2020 11.23, Peter Maydell wrote: > In commit a8d2532645cf5ce4 we cleaned up usage of the qemu-common.h header > so that it was always included from .c files and never from other .h files. > We missed adding it to net/tap-solaris.c (which previously was pulling it > in via tap-int.h),

Re: [REPORT] [GSoC - TCG Continuous Benchmarking] [#2] Dissecting QEMU Into Three Main Parts

2020-07-04 Thread Ahmed Karaman
On Sat, Jul 4, 2020 at 10:45 AM Alex Bennée wrote: > > > Aleksandar Markovic writes: > > > On Wednesday, July 1, 2020, Alex Bennée wrote: > > > >> > >> Ahmed Karaman writes: > >> > >> > On Mon, Jun 29, 2020 at 6:03 PM Alex Bennée > >> wrote: > >> >> > >> >> Assuming your test case is constant

[Bug 1885720] Re: qemu/migration/postcopy-ram.c:387: bad return expression ?

2020-07-04 Thread Thomas Huth
Fix has been merged: https://git.qemu.org/?p=qemu.git;a=commitdiff;h=617a32f5295ee4e ** Changed in: qemu Status: In Progress => Fix Committed -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU.

Re: [RFC PATCH v2 3/3] hw/misc/auxbus: Fix MOT/classic I2C mode

2020-07-04 Thread Philippe Mathieu-Daudé
On 6/23/20 1:06 PM, BALATON Zoltan wrote: > On Tue, 23 Jun 2020, Philippe Mathieu-Daudé wrote: >> Since its introduction in commit 6fc7f77fd2 i2c_start_transfer() >> uses incorrectly the direction of the transfer. Fix it now. >> >> Fixes: 6fc7f77fd2 ("introduce aux-bus") >> Reported-by: BALATON

Re: [PATCH v2 0/3] i2c: Match parameters of i2c_start_transfer and i2c_send_recv

2020-07-04 Thread Philippe Mathieu-Daudé
ping? On 6/23/20 8:31 AM, Philippe Mathieu-Daudé wrote: > This is v2 of Zoltan's patch: > https://www.mail-archive.com/qemu-devel@nongnu.org/msg714711.html > > - rebased > - added docstring > - include hw/misc/auxbus.c fix > > Supersedes: <20200621145235.9e241745...@zero.eik.bme.hu> > >

Re: [PULL 00/12] Linux user for 5.1 patches

2020-07-04 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200704162545.311133-1-laur...@vivier.eu/ Hi, This series seems to have some coding style problems. See output below for more information: Subject: [PULL 00/12] Linux user for 5.1 patches Type: series Message-id: 20200704162545.311133-1-laur...@vivier.eu

Re: [PATCH 0/7] accel/kvm: Simplify few functions that can use global kvm_state

2020-07-04 Thread Philippe Mathieu-Daudé
kind ping :) On 6/23/20 12:50 PM, Philippe Mathieu-Daudé wrote: > Following Paolo's idea on kvm_check_extension(): > https://www.mail-archive.com/qemu-devel@nongnu.org/msg713794.html > > CI: > https://travis-ci.org/github/philmd/qemu/builds/701213438 > > Philippe Mathieu-Daudé (7): >

Re: [PATCH] hw/core/qdev: Increase qdev_realize() kindness

2020-07-04 Thread Philippe Mathieu-Daudé
ping? On 6/20/20 5:38 PM, Philippe Mathieu-Daudé wrote: > Since commit 510ef98dca5, qdev_realize() aborts if bus-less > device is realized on a bus. Be kind with the developer by > displaying a hint about what is wrong. > > Signed-off-by: Philippe Mathieu-Daudé > --- > hw/core/qdev.c | 7

Re: [PATCH v2] util/qemu-option: Document the get_opt_value() function

2020-07-04 Thread Philippe Mathieu-Daudé
Cc'ing qemu-trivial. On 6/29/20 9:08 AM, Philippe Mathieu-Daudé wrote: > Coverity noticed commit 950c4e6c94 introduced a dereference before > null check in get_opt_value (CID1391003): > > In get_opt_value: All paths that lead to this null pointer > comparison already dereference the pointer

  1   2   3   >