Re: [Qemu-devel] [PATCH v2 01/16] qom/object: Add a new function object_initialize_child()

2018-07-16 Thread Thomas Huth
On 13.07.2018 23:46, Eduardo Habkost wrote: > On Fri, Jul 13, 2018 at 11:29:17PM +0200, Andreas Färber wrote: >> Am 13.07.2018 um 23:16 schrieb Eduardo Habkost: >>> I wonder if we should deprecate object_initialize() and support >>> only object_initialize_child() later. Initializing an object >>>

Re: [Qemu-devel] [PATCH v2 03/16] hw/arm/bcm2836: Fix crash with device_add bcm2837 on unsupported machines

2018-07-16 Thread Thomas Huth
On 13.07.2018 23:26, Eduardo Habkost wrote: > On Fri, Jul 13, 2018 at 10:27:31AM +0200, Thomas Huth wrote: >> When trying to "device_add bcm2837" on a machine that is not suitable for >> this device, you can quickly crash QEMU afterwards, e.g. with "info qtree": >> >> echo "{'execute':'qmp_capabili

Re: [Qemu-devel] [PATCH v2 01/16] qom/object: Add a new function object_initialize_child()

2018-07-16 Thread Thomas Huth
On 14.07.2018 00:57, Eduardo Habkost wrote: > On Fri, Jul 13, 2018 at 10:27:29AM +0200, Thomas Huth wrote: >> A lot of code is using the object_initialize() function followed by a call >> to object_property_add_child() to add the newly initialized object as a child >> of the current object. Both fu

[Qemu-devel] [PATCH 2/2] MAINTAINERS: New section "Incompatible changes", copy libvir-list

2018-07-16 Thread Markus Armbruster
Libvirt developers would like to be copied on patches to qemu-doc appendix "Deprecated features". Do them the favor. Signed-off-by: Markus Armbruster --- MAINTAINERS | 4 1 file changed, 4 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 20eef3cb61..666e936812 100644 --- a/MAINT

[Qemu-devel] [PATCH 0/2] Make it easier to track feature deprecation

2018-07-16 Thread Markus Armbruster
Markus Armbruster (2): qemu-doc: Move appendix "Deprecated features" to its own file MAINTAINERS: New section "Incompatible changes", copy libvir-list MAINTAINERS | 4 + qemu-deprecated.texi | 234 ++ qemu-doc.texi| 235 +-

[Qemu-devel] [PATCH 1/2] qemu-doc: Move appendix "Deprecated features" to its own file

2018-07-16 Thread Markus Armbruster
Consumers of QEMU need to track feature deprecation. Keeping deprecation documentation in its own file helps in two small ways: * You can track changes the easy and obvious way, with git-log. Before, you had to resort to more complex gittery like "git-log --oneline -L '/@node Deprecated featu

[Qemu-devel] [PATCH 01/13] hw/rdma: Make distinction between device init and start modes

2018-07-16 Thread Yuval Shaia
There are certain operations that are well considered as part of device configuration while others are needed only when "start" command is triggered by the guest driver. An example of device initialization step is msix_init and example of "device start" stage is the creation of a CQ completion hand

[Qemu-devel] [PATCH 02/13] hw/pvrdma: Bugfix - provide the correct attr_mask to query_qp

2018-07-16 Thread Yuval Shaia
Calling rdma_rm_query_qp with attr_mask equals to -1 leads to error where backend query_qp fails to retrieve the needed QP attributes. Fix it by providing the attr_mask we got from driver. Signed-off-by: Yuval Shaia --- hw/rdma/vmw/pvrdma_cmd.c | 5 +++-- 1 file changed, 3 insertions(+), 2 delet

[Qemu-devel] [PATCH 00/13] Misc fixes for pvrdma device

2018-07-16 Thread Yuval Shaia
Hi, Please review some changes i've made for pvrdma device. Thanks, Yuval [Qemu-devel] [PATCH 01/13] hw/rdma: Make distinction between device init and start [Qemu-devel] [PATCH 02/13] hw/pvrdma: Bugfix - provide the correct attr_mask to [Qemu-devel] [PATCH 03/13] hw/rdma: Modify debug macros [Qe

[Qemu-devel] [PATCH 05/13] hw/pvrdma: Make default pkey 0xFFFF

2018-07-16 Thread Yuval Shaia
0x7FFF is not the default pkey - fix it. Signed-off-by: Yuval Shaia --- hw/rdma/vmw/pvrdma_cmd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/rdma/vmw/pvrdma_cmd.c b/hw/rdma/vmw/pvrdma_cmd.c index e7d6589cdc..bb898265a3 100644 --- a/hw/rdma/vmw/pvrdma_cmd.c +++ b/hw/rdm

[Qemu-devel] [PATCH 03/13] hw/rdma: Modify debug macros

2018-07-16 Thread Yuval Shaia
- Add line counter to ease navigation in log - Print rdma instead of pvrdma Signed-off-by: Yuval Shaia --- hw/rdma/rdma_utils.c | 4 hw/rdma/rdma_utils.h | 16 hw/rdma/vmw/pvrdma_main.c | 2 ++ 3 files changed, 18 insertions(+), 4 deletions(-) diff --git a/hw/r

[Qemu-devel] [PATCH 08/13] hw/rdma: Reorder resource cleanup

2018-07-16 Thread Yuval Shaia
To be consistence with allocation do the reverse order in deallocation Signed-off-by: Yuval Shaia --- hw/rdma/rdma_rm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/rdma/rdma_rm.c b/hw/rdma/rdma_rm.c index bf4a5c71b4..1f014b4ab2 100644 --- a/hw/rdma/rdma_rm.c +++ b/hw

[Qemu-devel] [PATCH 09/13] hw/pvrdma: Cosmetic change - indent right

2018-07-16 Thread Yuval Shaia
Signed-off-by: Yuval Shaia --- hw/rdma/vmw/pvrdma_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/rdma/vmw/pvrdma_main.c b/hw/rdma/vmw/pvrdma_main.c index 1b1330e113..3d448bffc4 100644 --- a/hw/rdma/vmw/pvrdma_main.c +++ b/hw/rdma/vmw/pvrdma_main.c @@ -430,7 +430

[Qemu-devel] [PATCH 07/13] hw/rdma: Do not allocate memory for non-dma MR

2018-07-16 Thread Yuval Shaia
There is no use in the memory allocated for non-dma MR (one with host_virt equals to NULL). Delete the code that allocates it. Signed-off-by: Yuval Shaia --- hw/rdma/rdma_rm.c | 52 +++ 1 file changed, 21 insertions(+), 31 deletions(-) diff --git a/hw

[Qemu-devel] [PATCH 04/13] hw/pvrdma: Clean CQE before use

2018-07-16 Thread Yuval Shaia
Next CQE is fetched from CQ ring, clean it before usage as it still carries old CQE values. Signed-off-by: Yuval Shaia --- hw/rdma/vmw/pvrdma_qp_ops.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/rdma/vmw/pvrdma_qp_ops.c b/hw/rdma/vmw/pvrdma_qp_ops.c index 99bb5e..a8664f40c8 100644

[Qemu-devel] [PATCH 13/13] hw/rdma: Save pci dev in backend_dev

2018-07-16 Thread Yuval Shaia
This field is not initialized - fix it. Signed-off-by: Yuval Shaia --- hw/rdma/rdma_backend.c| 6 +- hw/rdma/rdma_backend.h| 2 +- hw/rdma/vmw/pvrdma_main.c | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/hw/rdma/rdma_backend.c b/hw/rdma/rdma_backend.c index d2

[Qemu-devel] [PATCH 11/13] hw/rdma: Print backend QP number in hex format

2018-07-16 Thread Yuval Shaia
To be consistent with other prints throughout the code fix places that print it as decimal number. Signed-off-by: Yuval Shaia --- hw/rdma/rdma_rm.c | 4 ++-- hw/rdma/vmw/pvrdma_qp_ops.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/hw/rdma/rdma_rm.c b/hw/rdma

[Qemu-devel] [PATCH 10/13] hw/rdma: Cosmetic change - move to generic function

2018-07-16 Thread Yuval Shaia
To ease maintenance of struct comp_thread move all related code to dedicated function. Signed-off-by: Yuval Shaia --- hw/rdma/rdma_backend.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/rdma/rdma_backend.c b/hw/rdma/rdma_backend.c index 52981d652d..d29acc505b

[Qemu-devel] [PATCH 06/13] hw/rdma: Get rid of unneeded structure

2018-07-16 Thread Yuval Shaia
This structure make no sense - removing it. Signed-off-by: Yuval Shaia --- hw/rdma/rdma_backend.c | 3 +-- hw/rdma/rdma_rm.c | 16 hw/rdma/rdma_rm_defs.h | 10 +++--- 3 files changed, 12 insertions(+), 17 deletions(-) diff --git a/hw/rdma/rdma_backend.c b/hw/rdma/rdma

[Qemu-devel] [PATCH 12/13] hw/rdma: Bugfix: Support non-aligned buffers

2018-07-16 Thread Yuval Shaia
RDMA applications can provide non-aligned buffers to be registered. In such case the DMA address passed by driver is pointing to the beginning of the physical address of the mapped page so we can't distinguish between two addresses from the same page. Fix it by keeping the offset of the virtual ad

Re: [Qemu-devel] [PATCH 1/2] qemu-doc: Move appendix "Deprecated features" to its own file

2018-07-16 Thread Thomas Huth
On 16.07.2018 09:32, Markus Armbruster wrote: > Consumers of QEMU need to track feature deprecation. Keeping > deprecation documentation in its own file helps in two small ways: > > * You can track changes the easy and obvious way, with git-log. > Before, you had to resort to more complex gitte

Re: [Qemu-devel] [PATCH 2/2] MAINTAINERS: New section "Incompatible changes", copy libvir-list

2018-07-16 Thread Thomas Huth
On 16.07.2018 09:32, Markus Armbruster wrote: > Libvirt developers would like to be copied on patches to qemu-doc > appendix "Deprecated features". Do them the favor. > > Signed-off-by: Markus Armbruster > --- > MAINTAINERS | 4 > 1 file changed, 4 insertions(+) > > diff --git a/MAINTAINE

Re: [Qemu-devel] [PATCH 1/2] qemu-doc: Move appendix "Deprecated features" to its own file

2018-07-16 Thread Cornelia Huck
On Mon, 16 Jul 2018 09:32:25 +0200 Markus Armbruster wrote: > Consumers of QEMU need to track feature deprecation. Keeping > deprecation documentation in its own file helps in two small ways: > > * You can track changes the easy and obvious way, with git-log. > Before, you had to resort to mo

Re: [Qemu-devel] [PATCH 2/2] MAINTAINERS: New section "Incompatible changes", copy libvir-list

2018-07-16 Thread Cornelia Huck
On Mon, 16 Jul 2018 09:32:26 +0200 Markus Armbruster wrote: > Libvirt developers would like to be copied on patches to qemu-doc > appendix "Deprecated features". Do them the favor. > > Signed-off-by: Markus Armbruster > --- > MAINTAINERS | 4 > 1 file changed, 4 insertions(+) Reviewed-b

Re: [Qemu-devel] [PATCH 2/2] MAINTAINERS: New section "Incompatible changes", copy libvir-list

2018-07-16 Thread Cornelia Huck
On Mon, 16 Jul 2018 09:54:12 +0200 Thomas Huth wrote: > On 16.07.2018 09:32, Markus Armbruster wrote: > > Libvirt developers would like to be copied on patches to qemu-doc > > appendix "Deprecated features". Do them the favor. > > > > Signed-off-by: Markus Armbruster > > --- > > MAINTAINERS |

Re: [Qemu-devel] [RFC v3 1/2] libnvdimm: Add flush callback for virtio pmem

2018-07-16 Thread Pankaj Gupta
Hi Luiz, > > > This patch adds functionality to perform flush from guest to host > > over VIRTIO. We are registering a callback based on 'nd_region' type. > > As virtio_pmem driver requires this special flush interface, for rest > > of the region types we are registering existing flush function

[Qemu-devel] [PATCH v2 2/2] virtio-scsi: fix hotplug ->reset() vs event race

2018-07-16 Thread Stefan Hajnoczi
There is a race condition during hotplug when iothread is used. It occurs because virtio-scsi may be processing command queues in the iothread while the monitor performs SCSI device hotplug. When a SCSI device is hotplugged the HotplugHandler->plug() callback is invoked and virtio-scsi emits a re

[Qemu-devel] [PATCH v2 1/2] qdev: add HotplugHandler->post_plug() callback

2018-07-16 Thread Stefan Hajnoczi
The ->pre_plug() callback is invoked before the device is realized. The ->plug() callback is invoked when the device is being realized but before it is reset. This patch adds a ->post_plug() callback which is invoked after the device has been reset. This callback is needed by HotplugHandlers tha

[Qemu-devel] [PULL 5/6] sam460ex: Correct use after free error

2018-07-16 Thread David Gibson
From: BALATON Zoltan Commit 51b0d834c changed error handling to report file name in error message but forgot to move freeing it after usage. Noticed by Coverity. Fixes: CID 1394217 Reported-by: Paolo Bonzini Signed-off-by: BALATON Zoltan Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Davi

[Qemu-devel] [PATCH v2 0/2] virtio-scsi: fix hotplug ->reset() vs event race

2018-07-16 Thread Stefan Hajnoczi
v2: * Drop Error **errp argument to post_plug() handler [Paolo] * Move post_plug() call outside if (dev->hotplugged) The virtio-scsi command virtqueues run during hotplug. This creates the possibility of race conditions since the guest can submit commands while the monitor is performing hotplug

[Qemu-devel] [PULL 6/6] sm501: Fix warning about unreachable code

2018-07-16 Thread David Gibson
From: BALATON Zoltan Coverity warned that the false arm of conditional expression is unreachable when it is inside an if with the same condition. Remove the unreachable code to avoid the warning. Fixes: CID 1394215 Reported-by: Paolo Bonzini Signed-off-by: BALATON Zoltan Reviewed-by: Philippe

[Qemu-devel] [PULL 0/6] ppc-for-3.0 queue 20180716

2018-07-16 Thread David Gibson
The following changes since commit 9277d81f5c2c6f4d0b5e47c8476eb7ee7e5c0beb: docs: Grammar and spelling fixes (2018-07-13 10:16:04 +0100) are available in the Git repository at: git://github.com/dgibson/qemu.git tags/ppc-for-3.0-20180716 for you to fetch changes up to

[Qemu-devel] [PULL 2/6] spapr: Correct inverted test in spapr_pc_dimm_node()

2018-07-16 Thread David Gibson
This function was introduced between v2.11 and v2.12 to replace obsolete ways of specifying the NUMA nodes for DIMMs. It's used to find the correct node for an LMB, by locating which DIMM object it lies within. Unfortunately, one of the checks is inverted, so we check whether the address is less

[Qemu-devel] [PULL 4/6] etsec: fix IRQ (un)masking

2018-07-16 Thread David Gibson
From: Michael Davidsaver Interrupt conditions occurring while masked are not being signaled when later unmasked. The fix is to raise/lower IRQs when IMASK is changed. To avoid problems like this in future, consolidate IRQ pin update logic in one function. Also fix probable typo "IEVENT_TXF | IE

[Qemu-devel] [PULL 1/6] sm501: Update screen on frame buffer address change

2018-07-16 Thread David Gibson
From: BALATON Zoltan When the guest changes the address of the frame buffer we need to refresh the screen to correctly display the new content. This fixes display update problems when changing between screens on AmigaOS. Signed-off-by: BALATON Zoltan Signed-off-by: David Gibson --- hw/display

[Qemu-devel] [PULL 3/6] ppc/xics: fix ICP reset path

2018-07-16 Thread David Gibson
From: Greg Kurz Recent cleanup in commit a028dd423ee6 dropped the ICPStateClass::reset handler. It is now up to child ICP classes to call the DeviceClass::reset handler of the parent class, thanks to device_class_set_parent_reset(). This is a better object programming pattern, but unfortunately i

Re: [Qemu-devel] [PATCH] arm: Add ARMv6-M programmer's model support

2018-07-16 Thread Stefan Hajnoczi
On Fri, Jul 13, 2018 at 01:30:59PM +0300, Julia Suvorova wrote: > Forbid stack alignment change. (CCR) > Reserve FAULTMASK, BASEPRI registers. > Report any fault as HardFault. Disable MemManage, BusFault and > UsageFault, so they always escalated to HardFault. (SHCSR) > > Signed-off-by: Julia Suvo

Re: [Qemu-devel] [PATCH] hw/char/serial: Only retry if qemu_chr_fe_write returns 0

2018-07-16 Thread Igor Mammedov
On Fri, 13 Jul 2018 16:55:15 +0200 Marc-André Lureau wrote: > Hi > > On Tue, Jul 10, 2018 at 3:48 PM, Igor Mammedov wrote: > > On Tue, 5 Jun 2018 11:18:35 +0200 > > Paolo Bonzini wrote: > > > >> On 05/06/2018 09:54, Sergio Lopez wrote: > >> > Only retry on serial_xmit if qemu_chr_fe_write

Re: [Qemu-devel] [PATCH v2 for 3.0 11/16] docker: add expansion for docker-test-FOO to Makefile.include

2018-07-16 Thread Alex Bennée
Philippe Mathieu-Daudé writes: > Hi Alex, > > On 07/13/2018 09:17 AM, Alex Bennée wrote: >> This allows us to run a particular test on all docker images. For >> example: >> >> make docker-test-unit >> >> Will run the unit tests on every supported image. At the same time >> rename docker-test

Re: [Qemu-devel] [RFC PATCH] hw: arm: Add basic support for cprman (clock subsystem)

2018-07-16 Thread Peter Maydell
On 15 July 2018 at 23:06, Guenter Roeck wrote: > Add basic support for BCM283x CPRMAN. Provide support for reading and > writing CPRMAN registers and initialize registers with sensible default > values. During runtime retain any written values. > > Basic CPRMAN support is necessary and sufficient

[Qemu-devel] [PATCH] monitor: Fix tracepoint crash on JSON syntax error

2018-07-16 Thread Markus Armbruster
When tracepoint handle_qmp_command is enabled, we crash on JSON syntax errors. Broken in commit 1cc37471525. Fix by skipping the tracepoint on JSON syntax error. Before the flawed commit, we skipped it by returning early. Fixes: CID 1394216 Signed-off-by: Markus Armbruster --- monitor.c | 2 +

Re: [Qemu-devel] [PATCH] monitor: Fix tracepoint crash on JSON syntax error

2018-07-16 Thread Marc-André Lureau
On Mon, Jul 16, 2018 at 11:10 AM, Markus Armbruster wrote: > When tracepoint handle_qmp_command is enabled, we crash on JSON syntax > errors. Broken in commit 1cc37471525. Fix by skipping the tracepoint > on JSON syntax error. Before the flawed commit, we skipped it by > returning early. > > Fi

Re: [Qemu-devel] QEMU advent calendar

2018-07-16 Thread Thomas Huth
On 13.07.2018 10:34, Richard Jansson wrote: > Hi > > I checked in on the QEMU advent calendar side of which I have very fond > memories. I'm very impressed and grateful for the work that you've put into > this site. My question to you is the following, what are your plans for the > continuation of

Re: [Qemu-devel] [PATCH 11/14] timer: generalize ds1338

2018-07-16 Thread David Gibson
On Thu, Jul 05, 2018 at 11:19:58AM -0700, Michael Davidsaver wrote: > Add class level handling for address space size > and control register. > > Signed-off-by: Michael Davidsaver Reviewed-by: David Gibson Although I don't love the name "addr_size" - just "nvram_size" seems clearer. > --- >

Re: [Qemu-devel] [PATCH v2 0/2] virtio-scsi: fix hotplug ->reset() vs event race

2018-07-16 Thread Igor Mammedov
On Mon, 16 Jul 2018 09:37:30 +0100 Stefan Hajnoczi wrote: > v2: > * Drop Error **errp argument to post_plug() handler [Paolo] > * Move post_plug() call outside if (dev->hotplugged) > > The virtio-scsi command virtqueues run during hotplug. This creates the > possibility of race conditions sin

Re: [Qemu-devel] [PATCH] monitor: Fix tracepoint crash on JSON syntax error

2018-07-16 Thread Peter Xu
On Mon, Jul 16, 2018 at 11:10:12AM +0200, Markus Armbruster wrote: > When tracepoint handle_qmp_command is enabled, we crash on JSON syntax > errors. Broken in commit 1cc37471525. Fix by skipping the tracepoint > on JSON syntax error. Before the flawed commit, we skipped it by > returning early.

Re: [Qemu-devel] [libvirt] [PULL 25/26] block: Remove deprecated -drive option serial

2018-07-16 Thread Daniel P . Berrangé
On Thu, Jul 12, 2018 at 05:47:00PM +0200, Thomas Huth wrote: > On 12.07.2018 08:32, Markus Armbruster wrote: > > Daniel P. Berrangé writes: > [...] > >> For libvirt, I think whenever something is proposed for deprecation > >> we could just CC libvir-list, or ask one of the libvirt people to > >> c

Re: [Qemu-devel] [PATCH] seccomp: allow sched_setscheduler() with SCHED_IDLE policy

2018-07-16 Thread Daniel P . Berrangé
On Wed, Jul 11, 2018 at 04:48:55PM +0200, Eduardo Otubo wrote: > On 10/07/2018 - 16:55:57, Marc-André Lureau wrote: > > Current and upcoming mesa releases rely on a shader disk cash. It uses > > a thread job queue with low priority, set with > > sched_setscheduler(SCHED_IDLE). However, that syscall

Re: [Qemu-devel] [PATCH 2/2] MAINTAINERS: New section "Incompatible changes", copy libvir-list

2018-07-16 Thread Daniel P . Berrangé
On Mon, Jul 16, 2018 at 09:32:26AM +0200, Markus Armbruster wrote: > Libvirt developers would like to be copied on patches to qemu-doc > appendix "Deprecated features". Do them the favor. > > Signed-off-by: Markus Armbruster > --- > MAINTAINERS | 4 > 1 file changed, 4 insertions(+) > > d

Re: [Qemu-devel] [PATCH 1/2] qemu-doc: Move appendix "Deprecated features" to its own file

2018-07-16 Thread Daniel P . Berrangé
On Mon, Jul 16, 2018 at 09:32:25AM +0200, Markus Armbruster wrote: > Consumers of QEMU need to track feature deprecation. Keeping > deprecation documentation in its own file helps in two small ways: > > * You can track changes the easy and obvious way, with git-log. > Before, you had to resort

Re: [Qemu-devel] [PATCH] vhost: fix invalid downcast

2018-07-16 Thread Юрий Котов
+ qemu-stable@ 13.07.2018, 19:16, "Michael S. Tsirkin" : > On Fri, Jul 13, 2018 at 05:04:05PM +0300, Yury Kotov wrote: >>  virtio_queue_get_desc_addr returns 64-bit hwaddr while int is usually >> 32-bit. >>  If returned hwaddr is not equal to 0 but least-significant 32 bits are >>  equal to 0 the

Re: [Qemu-devel] [PATCH 13/14] timer: ds-rtc model ds1375

2018-07-16 Thread David Gibson
On Thu, Jul 05, 2018 at 11:20:00AM -0700, Michael Davidsaver wrote: > differences from ds1338 > > * Has alarms (not modeled) > * different control register (not modeled) > * smaller address space (0x20 vs. 0x40) > > Signed-off-by: Michael Davidsaver > Reviewed-by: Peter Maydell Reviewed-by: Da

Re: [Qemu-devel] [PATCH 12/14] timer: ds-rtc handle CENTURY bit

2018-07-16 Thread David Gibson
On Thu, Jul 05, 2018 at 11:19:59AM -0700, Michael Davidsaver wrote: > Signed-off-by: Michael Davidsaver > Reviewed-by: Peter Maydell Reviewed-by: David Gibson > --- > hw/timer/ds-rtc.c | 8 +++- > 1 file changed, 7 insertions(+), 1 deletion(-) > > diff --git a/hw/timer/ds-rtc.c b/hw/tim

Re: [Qemu-devel] [PULL 0/4] Linux user for 3.0 patches

2018-07-16 Thread Peter Maydell
On 15 July 2018 at 20:52, Laurent Vivier wrote: > The following changes since commit 9277d81f5c2c6f4d0b5e47c8476eb7ee7e5c0beb: > > docs: Grammar and spelling fixes (2018-07-13 10:16:04 +0100) > > are available in the Git repository at: > > git://github.com/vivier/qemu.git tags/linux-user-for-3

Re: [Qemu-devel] [libvirt] [PULL 25/26] block: Remove deprecated -drive option serial

2018-07-16 Thread Kashyap Chamarthy
On Fri, Jul 13, 2018 at 01:35:02PM +0200, Cornelia Huck wrote: > On Thu, 12 Jul 2018 17:47:00 +0200 > Thomas Huth wrote: > > On 12.07.2018 08:32, Markus Armbruster wrote: > > > Daniel P. Berrangé writes: [...] > > > Our tool to help with getting cc: wrong less often is the MAINTAINERS > > > f

Re: [Qemu-devel] QEMU advent calendar

2018-07-16 Thread Kashyap Chamarthy
On Mon, Jul 16, 2018 at 11:15:43AM +0200, Thomas Huth wrote: > On 13.07.2018 10:34, Richard Jansson wrote: > > Hi > > > > I checked in on the QEMU advent calendar side of which I have very fond > > memories. I'm very impressed and grateful for the work that you've put into > > this site. My questi

Re: [Qemu-devel] [RFC 3/3] pci: Document ownership rules of pci_root_bus_new*()

2018-07-16 Thread Marcel Apfelbaum
On 07/12/2018 10:45 PM, Eduardo Habkost wrote: The ownership rules of pci_root_bus_new*() aren't trivial: the caller owns the new object if parent is NULL, otherwise ownership is transferred to the parent. Clarify that on comments. Signed-off-by: Eduardo Habkost --- include/hw/pci/pci.h |

Re: [Qemu-devel] [RFC 2/3] qdev: Document ownership rules of qbus_create*()

2018-07-16 Thread Marcel Apfelbaum
On 07/12/2018 10:45 PM, Eduardo Habkost wrote: The ownership rules of those functions aren't trivial: the caller owns the new object if parent is NULL, otherwise ownership is transferred to the parent. Clarify that on comments. Signed-off-by: Eduardo Habkost --- include/hw/qdev-core.h | 2

Re: [Qemu-devel] [PATCH 02/13] hw/pvrdma: Bugfix - provide the correct attr_mask to query_qp

2018-07-16 Thread Marcel Apfelbaum
On 07/16/2018 10:40 AM, Yuval Shaia wrote: Calling rdma_rm_query_qp with attr_mask equals to -1 leads to error where backend query_qp fails to retrieve the needed QP attributes. Fix it by providing the attr_mask we got from driver. Signed-off-by: Yuval Shaia --- hw/rdma/vmw/pvrdma_cmd.c |

Re: [Qemu-devel] [PATCH 04/13] hw/pvrdma: Clean CQE before use

2018-07-16 Thread Marcel Apfelbaum
On 07/16/2018 10:40 AM, Yuval Shaia wrote: Next CQE is fetched from CQ ring, clean it before usage as it still carries old CQE values. Signed-off-by: Yuval Shaia --- hw/rdma/vmw/pvrdma_qp_ops.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/rdma/vmw/pvrdma_qp_ops.c b/hw/rdma/vmw/p

Re: [Qemu-devel] [PATCH 05/13] hw/pvrdma: Make default pkey 0xFFFF

2018-07-16 Thread Marcel Apfelbaum
On 07/16/2018 10:40 AM, Yuval Shaia wrote: 0x7FFF is not the default pkey - fix it. Signed-off-by: Yuval Shaia --- hw/rdma/vmw/pvrdma_cmd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/rdma/vmw/pvrdma_cmd.c b/hw/rdma/vmw/pvrdma_cmd.c index e7d6589cdc..bb898265a3

Re: [Qemu-devel] [PATCH 06/13] hw/rdma: Get rid of unneeded structure

2018-07-16 Thread Marcel Apfelbaum
On 07/16/2018 10:40 AM, Yuval Shaia wrote: This structure make no sense - removing it.    What structure? I would explicitly name it in both subject and message. Thanks, Marcel Signed-off-by: Yuval Shaia --- hw/rdma/rdma_backend.c | 3 +-- hw/rdma/rdma_rm.c | 16 +

Re: [Qemu-devel] [PATCH 09/13] hw/pvrdma: Cosmetic change - indent right

2018-07-16 Thread Marcel Apfelbaum
On 07/16/2018 10:40 AM, Yuval Shaia wrote: Signed-off-by: Yuval Shaia --- hw/rdma/vmw/pvrdma_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/rdma/vmw/pvrdma_main.c b/hw/rdma/vmw/pvrdma_main.c index 1b1330e113..3d448bffc4 100644 --- a/hw/rdma/vmw/pvrdma_mai

Re: [Qemu-devel] [PATCH 10/13] hw/rdma: Cosmetic change - move to generic function

2018-07-16 Thread Marcel Apfelbaum
On 07/16/2018 10:40 AM, Yuval Shaia wrote: To ease maintenance of struct comp_thread move all related code to dedicated function. Signed-off-by: Yuval Shaia --- hw/rdma/rdma_backend.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/rdma/rdma_backend.c b/h

Re: [Qemu-devel] [PATCH 08/13] hw/rdma: Reorder resource cleanup

2018-07-16 Thread Marcel Apfelbaum
On 07/16/2018 10:40 AM, Yuval Shaia wrote: To be consistence with allocation do the reverse order in deallocation Signed-off-by: Yuval Shaia --- hw/rdma/rdma_rm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/rdma/rdma_rm.c b/hw/rdma/rdma_rm.c index bf4a5c71b4..

Re: [Qemu-devel] [PATCH 11/13] hw/rdma: Print backend QP number in hex format

2018-07-16 Thread Marcel Apfelbaum
On 07/16/2018 10:40 AM, Yuval Shaia wrote: To be consistent with other prints throughout the code fix places that print it as decimal number. Signed-off-by: Yuval Shaia --- hw/rdma/rdma_rm.c | 4 ++-- hw/rdma/vmw/pvrdma_qp_ops.c | 4 ++-- 2 files changed, 4 insertions(+), 4 del

[Qemu-devel] [RFC v2 1/2] arm: Add nRF51 GPIO peripheral

2018-07-16 Thread Steffen Görtz
Signed-off-by: Steffen Görtz --- Changes in v2: - Only call QEMU GPIO update handlers if value changes - Code style changes - Removed unused includes hw/gpio/Makefile.objs| 1 + hw/gpio/nrf51_gpio.c | 320 +++ include/hw/gpio/nrf51_gpio

[Qemu-devel] [RFC v2 2/2] arm: Add nRF51 GPIO tests

2018-07-16 Thread Steffen Görtz
Signed-off-by: Steffen Görtz --- tests/microbit-test.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/tests/microbit-test.c b/tests/microbit-test.c index c502ee3976..a1e2f67855 100644 --- a/tests/microbit-test.c +++ b/tests/microbit-test.c @@ -101,6 +101,12 @@ static void test_nrf51_n

Re: [Qemu-devel] [PATCH 13/13] hw/rdma: Save pci dev in backend_dev

2018-07-16 Thread Marcel Apfelbaum
On 07/16/2018 10:40 AM, Yuval Shaia wrote: This field is not initialized - fix it. What field ? Please use a more readable message. Regarding the subject, maybe you can use "cache pci_dev" or "add a reference to pci_dev " instead of "save". Thanks, Marcel Signed-off-by: Yuval S

Re: [Qemu-devel] [Spice-devel] Ongoing migration: gitlab.com/spice -> gitlab.freedesktop.org/spice

2018-07-16 Thread Victor Toso
Hi, On Thu, Jul 12, 2018 at 05:50:56PM +0200, Victor Toso wrote: > Hi, > > JFYI, CC'ing: > > * qemu-devel > * virt-tools-list > * de...@ovirt.org > > If nobody complains, I'll finish whatever is pending next Monday > morning (GMT+2). Migration is done. All Spice related components can be seen

[Qemu-devel] [PATCH] hw/char/serial: retry write if EAGAIN

2018-07-16 Thread Marc-André Lureau
If the chardev returns -1 with EAGAIN errno on write(), it should try to send it again (EINTR is handled by the chardev itself). This fixes commit 019288bf137183bf3407c9824655b753bfafc99f "hw/char/serial: Only retry if qemu_chr_fe_write returns 0" Tested-by: Igor Mammedov Signed-off-by: Marc-And

Re: [Qemu-devel] [PATCH v2] trace/simple: fix hang in child after fork(2)

2018-07-16 Thread Cornelia Huck
On Sun, 15 Jul 2018 14:42:23 +0200 Paolo Bonzini wrote: > On 13/07/2018 20:42, Stefan Hajnoczi wrote: > > +#ifndef _WIN32 > > +static void stop_writeout_thread(void) > > +{ > > +g_mutex_lock(&trace_lock); > > +trace_writeout_running = false; > > +g_cond_signal(&trace_available_cond);

[Qemu-devel] tcg_register_jit_int() interface problem

2018-07-16 Thread Aleksandar Markovic
Hello, all. Just a little background: One of the fields in an ELF header is e_machine. It is meant to contain "machine architecture". The numerical value is approved by a committee. Some values for common targets are: EM_PPC, EM_PPC64, EM_ARM, EM_AARCH64, etc. The TCG function tcg_register_

Re: [Qemu-devel] tcg_register_jit_int() interface problem

2018-07-16 Thread Laurent Vivier
Le 16/07/2018 à 13:10, Aleksandar Markovic a écrit : > Hello, all. > > > Just a little background: > > > One of the fields in an ELF header is e_machine. It is meant to contain > "machine architecture". The numerical value is approved by a committee. > Some values for common targets are: EM_PPC

Re: [Qemu-devel] [PATCH v2 06/16] hw/display/xlnx_dp: Move problematic code from instance_init to realize

2018-07-16 Thread Thomas Huth
On 13.07.2018 19:13, Paolo Bonzini wrote: > On 13/07/2018 17:59, Thomas Huth wrote: >> Your patch looks good at a first quick glance, but it seems not to work as >> expected: When I now run QEMU like this: >> >> echo "{'execute':'qmp_capabilities'}" \ >> "{'execute':'device-list-properties'," \ >

Re: [Qemu-devel] tcg_register_jit_int() interface problem

2018-07-16 Thread Aleksandar Markovic
> From: Laurent Vivier > Sent: Monday, July 16, 2018 1:30 PM > > Le 16/07/2018 à 13:10, Aleksandar Markovic a écrit : > > Hello, all. > > > > > > Just a little background: > > > > > > One of the fields in an ELF header is e_machine. It is meant to contain > > "machine architecture". The numerical

Re: [Qemu-devel] [PATCH 1/2] qga-win: prevent crash when executing fsinfo command

2018-07-16 Thread Sameeh Jubran
I've found another bug which is related to this one, where pci_controller might also be null: in the function "build_guest_disk_info" in "qga/commands-win32.c" if (bus == BusTypeScsi || bus == BusTypeAta || bus == BusTypeRAID #if (_WIN32_WINNT >= 0x0600) /* This bus type is not supported before

Re: [Qemu-devel] [PATCH] qga-win: Handle fstrim for OSes lower than Win8

2018-07-16 Thread Sameeh Jubran
ping. On Sun, Jun 24, 2018 at 3:45 PM, Sameeh Jubran wrote: > From: Sameeh Jubran > > The defrag.exe tool which is used for executing the fstrim command > on Windows doesn't support retrim for OSes lower than Win8. This > commit handles this case and returns a suitable error. > > Output of fstr

Re: [Qemu-devel] [RFC v3 2/2] virtio-pmem: Add virtio pmem driver

2018-07-16 Thread Pankaj Gupta
> > > This patch adds virtio-pmem driver for KVM guest. > > > > Guest reads the persistent memory range information from Qemu over > > VIRTIO and registers it on nvdimm_bus. It also creates a nd_region > > object with the persistent memory range information so that existing > > 'nvdimm/pmem' d

Re: [Qemu-devel] [PATCH V1 RESEND 1/6] hmat acpi: Build Memory Subsystem Address Range Structure(s) in ACPI HMAT

2018-07-16 Thread Igor Mammedov
On Tue, 19 Jun 2018 23:20:52 +0800 Liu Jingqi wrote: > HMAT is defined in ACPI 6.2: 5.2.27 Heterogeneous Memory Attribute Table > (HMAT). > The specification references below link: > http://www.uefi.org/sites/default/files/resources/ACPI_6_2.pdf > > It describes the memory attributes, such as m

Re: [Qemu-devel] tcg_register_jit_int() interface problem

2018-07-16 Thread Peter Maydell
On 16 July 2018 at 12:36, Aleksandar Markovic wrote: >> From: Laurent Vivier >> Le 16/07/2018 à 13:10, Aleksandar Markovic a écrit : >> > For MIPS, the situation is different: Up until recently, MIPS had only >> > one value for e_machine: that was EM_MIPS (used for both 32-bit and >> > 64-bit MIP

Re: [Qemu-devel] [PATCH V1 RESEND 0/6] Build ACPI Heterogeneous Memory Attribute Table (HMAT)

2018-07-16 Thread Igor Mammedov
On Tue, 19 Jun 2018 23:20:51 +0800 Liu Jingqi wrote: > This series of patches will build Heterogeneous Memory Attribute Table (HMAT) > according to the command line. The ACPI HMAT describes the memory attributes, > such as memory side cache attributes and bandwidth and latency details, > related

Re: [Qemu-devel] [PATCH V1 RESEND 6/6] hmat acpi: Implement _HMA method to update HMAT at runtime

2018-07-16 Thread Igor Mammedov
On Tue, 19 Jun 2018 23:20:57 +0800 Liu Jingqi wrote: > OSPM evaluates HMAT only during system initialization. > Any changes to the HMAT state at runtime or information > regarding HMAT for hot plug are communicated using _HMA method. > > _HMA is an optional object that enables the platform to pr

Re: [Qemu-devel] [PATCH 0/6] accel/tcg: Support execution from MMIO and small MMU regions

2018-07-16 Thread KONRAD Frederic
Hi Peter, Nice! Thanks for that. A little question though.. What will happen in the case where the CPU start executing code at random place because of eg: a badly configured kernel? Seeing the patch 5 I guess it will really execute stuff.. So maybe this is less user-friendly? Cheers, Fred On

Re: [Qemu-devel] [PATCH v2 2/2] virtio-scsi: fix hotplug ->reset() vs event race

2018-07-16 Thread Michael S. Tsirkin
On Mon, Jul 16, 2018 at 09:37:32AM +0100, Stefan Hajnoczi wrote: > There is a race condition during hotplug when iothread is used. It > occurs because virtio-scsi may be processing command queues in the > iothread while the monitor performs SCSI device hotplug. > > When a SCSI device is hotplugge

Re: [Qemu-devel] [PATCH 4/7 V9] hostmem-file: add the 'pmem' option

2018-07-16 Thread Igor Mammedov
On Tue, 10 Jul 2018 18:30:17 +0800 junyan...@gmx.com wrote: > From: Junyan He > > When QEMU emulates vNVDIMM labels and migrates vNVDIMM devices, it > needs to know whether the backend storage is a real persistent memory, > in order to decide whether special operations should be performed to > e

Re: [Qemu-devel] tcg_register_jit_int() interface problem

2018-07-16 Thread Aleksandar Markovic
> From: Peter Maydell > Sent: Monday, July 16, 2018 1:55 PM > > On 16 July 2018 at 12:36, Aleksandar Markovic wrote: > >> From: Laurent Vivier > >> Le 16/07/2018 à 13:10, Aleksandar Markovic a écrit : > >> > For MIPS, the situation is different: Up until recently, MIPS had only > >> > one value

[Qemu-devel] [PATCH v3 03/17] hw/arm/bcm2836: Fix crash with device_add bcm2837 on unsupported machines

2018-07-16 Thread Thomas Huth
When trying to "device_add bcm2837" on a machine that is not suitable for this device, you can quickly crash QEMU afterwards, e.g. with "info qtree": echo "{'execute':'qmp_capabilities'} {'execute':'device_add', " \ "'arguments':{'driver':'bcm2837'}} {'execute': 'human-monitor-command', " \ "'ar

[Qemu-devel] [PATCH v3 01/17] qom/object: Add a new function object_initialize_child()

2018-07-16 Thread Thomas Huth
A lot of code is using the object_initialize() function followed by a call to object_property_add_child() to add the newly initialized object as a child of the current object. Both functions increase the reference counter of the new object, but many spots that call these two functions then forget t

[Qemu-devel] [PATCH v3 00/17] Fix crashes with introspection of ARM devices

2018-07-16 Thread Thomas Huth
As discovered recently, you can crash QEMU with a lot of devices that do not get the reference counting of child objects right. You just have to run 'device-list-properties' and call 'info qtree' afterwards. This patch series fixes these problems in the ARM code. When all patches have been applied,

[Qemu-devel] [PATCH v3 02/17] hw/core/sysbus: Add a function for creating and attaching an object

2018-07-16 Thread Thomas Huth
A lot of functions are initializing an object and attach it immediately afterwards to the system bus. Provide a common function for this, which also uses object_initialize_child() to make sure that the reference counter is correctly initialized to 1 afterwards. Reviewed-by: Richard Henderson Revi

[Qemu-devel] [PATCH v3 05/17] hw/cpu/a15mpcore: Fix introspection problem with the a15mpcore_priv device

2018-07-16 Thread Thomas Huth
There is a memory management problem when introspecting the a15mpcore_priv device. It can be seen with valgrind when running QEMU like this: echo "{'execute':'qmp_capabilities'} {'execute':'device-list-properties'," \ "'arguments':{'typename':'a15mpcore_priv'}}"\ "{'execute': 'human-monitor-comm

[Qemu-devel] [PATCH v8 2/5] tpm: implement virtual memory device for TPM PPI

2018-07-16 Thread Marc-André Lureau
From: Stefan Berger Implement a virtual memory device for the TPM Physical Presence interface. The memory is located at 0xFED45000 and used by ACPI to send messages to the firmware (BIOS) and by the firmware to provide parameters for each one of the supported codes. This device should be used by

[Qemu-devel] [PATCH v3 07/17] hw/cpu/a9mpcore: Fix introspection problems with the "a9mpcore_priv" device

2018-07-16 Thread Thomas Huth
Running QEMU with valgrind indicates a problem here: echo "{'execute':'qmp_capabilities'} {'execute':'device-list-properties'," \ "'arguments':{'typename':'a9mpcore_priv'}}" \ "{'execute': 'human-monitor-command', " \ "'arguments': {'command-line': 'info qtree'}}" | \ valgrind -q aarch64-softm

[Qemu-devel] [PATCH v8 0/5] Add support for TPM Physical Presence interface

2018-07-16 Thread Marc-André Lureau
Hi, The following patches implement the TPM Physical Presence Interface that allows a user to set a command via ACPI (sysfs entry in Linux) that, upon the next reboot, the firmware looks for and acts upon by sending sequences of commands to the TPM. A dedicated memory region is added to the TPM C

[Qemu-devel] [PATCH v3 06/17] hw/arm/msf2-soc: Fix introspection problem with the "msf2-soc" device

2018-07-16 Thread Thomas Huth
Valgrind currently reports a problem when running QEMU like this: echo "{'execute':'qmp_capabilities'} {'execute':'device-list-properties'," \ "'arguments':{'typename':'msf2-soc'}}" \ "{'execute': 'human-monitor-command', " \ "'arguments': {'command-line': 'info qtree'}}" | \ valgrind -q aarch

[Qemu-devel] [PATCH v3 04/17] hw/arm/armv7: Fix crash when introspecting the "iotkit" device

2018-07-16 Thread Thomas Huth
QEMU currently crashes when introspecting the "iotkit" device and runnint "info qtree" afterwards, e.g. when running QEMU like this: echo "{'execute':'qmp_capabilities'} {'execute':'device-list-properties'," \ "'arguments':{'typename':'iotkit'}}" "{'execute': 'human-monitor-command', " \ "'argum

[Qemu-devel] [PATCH v8 1/5] tpm: add a "ppi" boolean property

2018-07-16 Thread Marc-André Lureau
The following patches implement the TPM Physical Presence Interface, make use of a new memory region and a fw_cfg entry. Enable PPI by default with >2.12 machine type, to avoid migration issues. Signed-off-by: Marc-André Lureau Reviewed-by: Igor Mammedov --- include/hw/compat.h | 10 ++

[Qemu-devel] [PATCH v3 13/17] hw/*/realview: Fix introspection problem with 'realview_mpcore' & 'realview_gic'

2018-07-16 Thread Thomas Huth
echo "{'execute':'qmp_capabilities'} {'execute':'device-list-properties'," \ "'arguments':{'typename':'realview_mpcore'}}" \ "{'execute': 'human-monitor-command', " \ "'arguments': {'command-line': 'info qtree'}}" | \ valgrind -q aarch64-softmmu/qemu-system-aarch64 -M none,accel=qtest -qmp stdi

[Qemu-devel] [PATCH v3 08/17] hw/arm/fsl-imx6: Fix introspection problems with the "fsl, imx6" device

2018-07-16 Thread Thomas Huth
Running QEMU with valgrind indicates a problem here: echo "{'execute':'qmp_capabilities'} {'execute':'device-list-properties'," \ "'arguments':{'typename':'fsl,imx6'}}" \ "{'execute': 'human-monitor-command', " \ "'arguments': {'command-line': 'info qtree'}}" | \ valgrind -q aarch64-softmmu/qe

  1   2   3   >