Re: [Qemu-devel] [Qemu-ppc] [PATCH v2 3/3] pcie: Simplify pci_adjust_config_limit()

2019-04-25 Thread Alexey Kardashevskiy
On 24/04/2019 14:19, David Gibson wrote: > Since c2077e2c "pci: Adjust PCI config limit based on bus topology", > pci_adjust_config_limit() has been used in the config space read and write > paths to only permit access to extended config space on buses which permit > it. Specifically it prevent

[Qemu-devel] [PULL 31/36] target/ppc/kvm: Convert DPRINTF to traces

2019-04-25 Thread David Gibson
From: Greg Kurz Signed-off-by: Greg Kurz Message-Id: <155445152490.302073.17033451726459859333.st...@bahia.lan> Signed-off-by: David Gibson --- target/ppc/kvm.c| 68 - target/ppc/trace-events | 25 +++ 2 files changed, 52 insertions(+

[Qemu-devel] [PULL 25/36] target/ppc: Style fixes for translate/vsx-impl.inc.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/translate/vsx-impl.inc.c | 15 --- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/target/ppc/translate/vsx-impl.inc.c b/target/ppc/translate/vsx-impl.inc.c index 489b2436e

[Qemu-devel] [PULL 33/36] ppc/spapr: Use proper HPTE accessors for H_READ

2019-04-25 Thread David Gibson
From: Benjamin Herrenschmidt Signed-off-by: Benjamin Herrenschmidt Signed-off-by: Cédric Le Goater Message-Id: <20190411080004.8690-3-...@kaod.org> Signed-off-by: David Gibson --- hw/ppc/spapr_hcall.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/hw/ppc/spapr

[Qemu-devel] [PULL 32/36] target/ppc: Don't check UPRT in radix mode when in HV real mode

2019-04-25 Thread David Gibson
From: Benjamin Herrenschmidt It appears that during kexec, we run for a while in hypervisor real mode with LPCR:HR set and LPCR:UPRT clear, which trips the assertion in ppc_radix64_handle_mmu_fault(). First this shouldn't be an assertion, it's a guest error. Then we shouldn't be checking these

[Qemu-devel] [PULL 22/36] target/ppc: Style fixes for translate_init.inc.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/translate_init.inc.c | 243 +++- 1 file changed, 148 insertions(+), 95 deletions(-) diff --git a/target/ppc/translate_init.inc.c b/target/ppc/translate_init.inc.c index 2

[Qemu-devel] [PULL 34/36] ppc/hash64: Rework R and C bit updates

2019-04-25 Thread David Gibson
From: Benjamin Herrenschmidt With MT-TCG, we are now running translation in a racy way, thus we need to mimic hardware when it comes to updating the R and C bits, by doing byte stores. The current "store_hpte" abstraction is ill suited for this, we replace it with two separate callbacks for sett

[Qemu-devel] [PULL 20/36] target/ppc: Style fixes for mmu_helper.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/mmu_helper.c | 137 1 file changed, 84 insertions(+), 53 deletions(-) diff --git a/target/ppc/mmu_helper.c b/target/ppc/mmu_helper.c index ab72473eeb..d226b3

[Qemu-devel] [PULL 24/36] target/ppc: Style fixes for translate/fp-impl.inc.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/translate/fp-impl.inc.c | 52 ++ 1 file changed, 32 insertions(+), 20 deletions(-) diff --git a/target/ppc/translate/fp-impl.inc.c b/target/ppc/translate/fp-impl.inc.c i

[Qemu-devel] [PATCH] vhost-user: fix reconnection support for host notifier

2019-04-25 Thread Tiwei Bie
We need to destroy the host notifiers when cleaning up the backend. Otherwise, some resources are not released after the connection is closed, and it may prevent the external backend from reopening them (e.g. VFIO files) during restart. Fixes: 44866521bd6e ("vhost-user: support registering externa

[Qemu-devel] [PULL 29/36] spapr: Drop duplicate PCI swizzle code

2019-04-25 Thread David Gibson
From: Greg Kurz LSI mapping in spapr currently open-codes standard PCI swizzling. It thus duplicates the code of pci_swizzle_map_irq_fn(). Expose the swizzling formula so that it can be used with a slot number when building the device tree. Simply drop pci_spapr_map_irq() and call pci_swizzle_ma

[Qemu-devel] [PATCH] checkpatch: allow SPDX-License-Identifier

2019-04-25 Thread Peter Xu
According to: https://spdx.org/ids-how, let's still allow QEMU to use the SPDX license identifier: // SPDX-License-Identifier: *** CC: Paolo Bonzini Signed-off-by: Peter Xu --- scripts/checkpatch.pl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/checkpatch.pl b/s

[Qemu-devel] [PULL 30/36] target/ppc/trace-events: Fix trivial typo

2019-04-25 Thread David Gibson
From: Greg Kurz Signed-off-by: Greg Kurz Message-Id: <155445151931.302073.18436485925081597460.st...@bahia.lan> Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: David Gibson --- target/ppc/trace-events | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target/ppc/trace-

[Qemu-devel] [PULL 23/36] target/ppc: Style fixes for translate.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/translate.c | 504 + 1 file changed, 313 insertions(+), 191 deletions(-) diff --git a/target/ppc/translate.c b/target/ppc/translate.c index 93d77a2626..c280e0

[Qemu-devel] [PULL 28/36] spapr_pci: Get rid of duplicate code for node name creation

2019-04-25 Thread David Gibson
From: Greg Kurz According to the changelog of 298a971024534, SpaprPhbState::dtbusname was introduced to "make it easier to relate the guest and qemu views of memory to each other", hence its name. Use it when creating the PHB node to avoid code duplication. Signed-off-by: Greg Kurz Message-Id:

[Qemu-devel] [PULL 35/36] ppc/hash32: Rework R and C bit updates

2019-04-25 Thread David Gibson
From: Benjamin Herrenschmidt With MT-TCG, we are now running translation in a racy way, thus we need to mimic hardware when it comes to updating the R and C bits, by doing byte stores. Signed-off-by: Benjamin Herrenschmidt Signed-off-by: Cédric Le Goater Message-Id: <20190411080004.8690-5-...@

[Qemu-devel] [PULL 19/36] target/ppc: Style fixes for mmu-hash64.[ch]

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/mmu-hash64.c | 68 + 1 file changed, 42 insertions(+), 26 deletions(-) diff --git a/target/ppc/mmu-hash64.c b/target/ppc/mmu-hash64.c index 214149f65b..c74818

[Qemu-devel] [PULL 36/36] target/ppc: improve performance of large BAT invalidations

2019-04-25 Thread David Gibson
From: Artyom Tarasenko Performing a complete flush is ~ 100 times faster than flushing 256MiB of 4KiB pages. Set a limit of 1024 pages and perform a complete flush afterwards. This patch significantly speeds up AIX 5.1 and NetBSD-ofppc. Signed-off-by: Artyom Tarasenko Message-Id: <1555103178-2

[Qemu-devel] [PULL 14/36] target/ppc: Style fixes for machine.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/machine.c | 106 +-- 1 file changed, 63 insertions(+), 43 deletions(-) diff --git a/target/ppc/machine.c b/target/ppc/machine.c index a92d0ad3a3..25cdb9088b 1

[Qemu-devel] [PULL 26/36] target/ppc: Style fixes for translate/vmx-impl.inc.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/translate/vmx-impl.inc.c | 26 +++--- 1 file changed, 15 insertions(+), 11 deletions(-) diff --git a/target/ppc/translate/vmx-impl.inc.c b/target/ppc/translate/vmx-impl.inc.c in

[Qemu-devel] [PULL 27/36] target/ppc: Style fixes for translate/spe-impl.inc.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/translate/spe-impl.inc.c | 14 +- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/target/ppc/translate/spe-impl.inc.c b/target/ppc/translate/spe-impl.inc.c index 8c1c16c63e

[Qemu-devel] [PULL 15/36] target/ppc: Style fixes for mem_helper.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/mem_helper.c | 33 +++-- 1 file changed, 19 insertions(+), 14 deletions(-) diff --git a/target/ppc/mem_helper.c b/target/ppc/mem_helper.c index 9c5a68579e..5b0f9ee50d 100

[Qemu-devel] [PULL 10/36] target/ppc: Style fixes for excp_helper.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/excp_helper.c | 87 1 file changed, 53 insertions(+), 34 deletions(-) diff --git a/target/ppc/excp_helper.c b/target/ppc/excp_helper.c index beafcf1ebd..ec2c

[Qemu-devel] [PULL 21/36] target/ppc: Style fixes for monitor.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/monitor.c | 11 ++- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/target/ppc/monitor.c b/target/ppc/monitor.c index 42e58163fc..ee9d6e81d2 100644 --- a/target/ppc/monitor.c ++

[Qemu-devel] [PULL 06/36] target/ppc: Style fixes for cpu.[ch]

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/cpu.h | 237 ++- 1 file changed, 129 insertions(+), 108 deletions(-) diff --git a/target/ppc/cpu.h b/target/ppc/cpu.h index d5259f7dd3..8a79db0c43 100644

[Qemu-devel] [PULL 13/36] target/ppc: Style fixes for kvm_ppc.h and kvm.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/kvm.c | 178 +++ target/ppc/kvm_ppc.h | 3 +- 2 files changed, 115 insertions(+), 66 deletions(-) diff --git a/target/ppc/kvm.c b/target/ppc/kvm.c index

[Qemu-devel] [PULL 01/36] spapr: Support NVIDIA V100 GPU with NVLink2

2019-04-25 Thread David Gibson
From: Alexey Kardashevskiy NVIDIA V100 GPUs have on-board RAM which is mapped into the host memory space and accessible as normal RAM via an NVLink bus. The VFIO-PCI driver implements special regions for such GPUs and emulates an NVLink bridge. NVLink2-enabled POWER9 CPUs also provide address tra

[Qemu-devel] [PULL 07/36] target/ppc: Style fixes for int_helper.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/int_helper.c | 70 +++-- 1 file changed, 39 insertions(+), 31 deletions(-) diff --git a/target/ppc/int_helper.c b/target/ppc/int_helper.c index 162add561e..f6a088

[Qemu-devel] [PULL 18/36] target/ppc: Style fixes for mmu-hash32.[ch]

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/mmu-hash32.c | 22 ++ 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/target/ppc/mmu-hash32.c b/target/ppc/mmu-hash32.c index e8562a7c87..3f4dee835e 100644 --- a/ta

[Qemu-devel] [PULL 16/36] target/ppc: Style fixes for mfrom_table.inc.c & mfrom_table_gen.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/mfrom_table.inc.c | 3 +-- target/ppc/mfrom_table_gen.c | 8 +--- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/target/ppc/mfrom_table.inc.c b/target/ppc/mfrom_table.inc.c index

[Qemu-devel] [PULL 08/36] target/ppc: Style fixes for fpu_helper.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/fpu_helper.c | 134 +--- 1 file changed, 83 insertions(+), 51 deletions(-) diff --git a/target/ppc/fpu_helper.c b/target/ppc/fpu_helper.c index 2ed4f42275..0b7308

[Qemu-devel] [PULL 09/36] target/ppc: Style fixes for dfp_helper.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/dfp_helper.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/target/ppc/dfp_helper.c b/target/ppc/dfp_helper.c index 9164fe701b..f102177572 100644 --- a/target/ppc/

[Qemu-devel] [PULL 17/36] target/ppc: Style fixes for misc_helper.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/misc_helper.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/target/ppc/misc_helper.c b/target/ppc/misc_helper.c index c65d1ade15..0a81e98ee9 100644 --- a/target/ppc/mis

[Qemu-devel] [PULL 12/36] target/ppc: Style fixes for helper_regs.h

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/helper_regs.h | 10 ++ 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/target/ppc/helper_regs.h b/target/ppc/helper_regs.h index c863abc0bf..922da76c6c 100644 --- a/target/ppc/h

[Qemu-devel] [PULL 11/36] target/ppc: Style fixes for gdbstub.c

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/gdbstub.c | 34 +++--- 1 file changed, 19 insertions(+), 15 deletions(-) diff --git a/target/ppc/gdbstub.c b/target/ppc/gdbstub.c index fbf3821f4b..ce3625f44e 100644 ---

[Qemu-devel] [PULL 05/36] target/ppc: Style fixes for ppc-models.[ch]

2019-04-25 Thread David Gibson
Signed-off-by: David Gibson Reviewed-by: Cédric Le Goater Reviewed-by: Greg Kurz --- target/ppc/cpu-models.c | 2 +- target/ppc/cpu-models.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/target/ppc/cpu-models.c b/target/ppc/cpu-models.c index 7c75963e3c..9d7050b5fa 100

[Qemu-devel] [PULL 02/36] hw/ppc/prep: Drop useless inclusion of "hw/input/i8042.h"

2019-04-25 Thread David Gibson
From: Philippe Mathieu-Daudé In commit 47973a2dbf we split the last generic chipset out of the PC board, but missed to remove the i8042 keyboard controller. This omission was later fixed in commit 7cb00357c1, but here we forgot to remove the "i8042.h" include. Do it now. Signed-off-by: Philippe

[Qemu-devel] [PULL 03/36] spapr/rtas: modify spapr_rtas_register() to remove RTAS handlers

2019-04-25 Thread David Gibson
From: Cédric Le Goater Removing RTAS handlers will become necessary when the new pseries machine supporting multiple interrupt mode is introduced. Signed-off-by: Cédric Le Goater Message-Id: <20190321144914.19934-9-...@kaod.org> Signed-off-by: David Gibson --- hw/ppc/spapr_rtas.c| 2 +- i

[Qemu-devel] [PULL 00/36] ppc-for-4.1 queue 20190426

2019-04-25 Thread David Gibson
The following changes since commit 3284aa128153750f14a61e8a96fd085e6f2999b6: Merge remote-tracking branch 'remotes/lersek/tags/edk2-pull-2019-04-22' into staging (2019-04-24 13:19:41 +0100) are available in the Git repository at: git://github.com/dgibson/qemu.git tags/ppc-for-4.1-20190426

[Qemu-devel] [PULL 04/36] spapr/irq: remove spapr_ics_create()

2019-04-25 Thread David Gibson
From: Cédric Le Goater spapr_ics_create() is only called once. Merge it in spapr_irq_init_xics() and simplify a bit the error handling by using 'error_fatal' . Signed-off-by: Cédric Le Goater Message-Id: <20190321144914.19934-13-...@kaod.org> Signed-off-by: David Gibson --- hw/ppc/spapr_irq.c

Re: [Qemu-devel] [PATCH v2 for-4.1 0/2] Fix ohci_die() and move PCI code to separate file

2019-04-25 Thread Thomas Huth
On 26/04/2019 00.55, Philippe Mathieu-Daudé wrote: > Hi Thomas, > > On 4/19/19 9:56 AM, Thomas Huth wrote: >> First patch fixes a problem with ohci_die(), second patch moves PCI code into >> a separate file, so that the sysbus OHCI device can also be used without >> the dependency on the PCI code.

Re: [Qemu-devel] [PATCH v2 2/5] linux-user: Add support for the SIOCSPGRP ioctl

2019-04-25 Thread Max Filippov
On Wed, Apr 24, 2019 at 5:58 AM Aleksandar Markovic wrote: > > From: Aleksandar Markovic > > Add support for setting the process (or process group) to receive SIGIO > or SIGURG signals when I/O becomes possible or urgent data is available, > using SIOCSPGRP ioctl. > > The ioctl numeric values for

Re: [Qemu-devel] [PATCH v2 1/5] linux-user: Fix support for the SIOCATMARK and SIOCGPGRP ioctls for eXtensa

2019-04-25 Thread Max Filippov
On Wed, Apr 24, 2019 at 5:57 AM Aleksandar Markovic wrote: > From: Aleksandar Markovic > > Fix support for the SIOCATMARK and SIOCGPGRP ioctls for eXtensa by xtensa is the official name of this architecture, please fix the spelling here... > correcting corresponding macro definition. > > Values

[Qemu-devel] [PATCH v7 6/6] xfs: disable map_sync for async flush

2019-04-25 Thread Pankaj Gupta
Dont support 'MAP_SYNC' with non-DAX files and DAX files with asynchronous dax_device. Virtio pmem provides asynchronous host page cache flush mechanism. We don't support 'MAP_SYNC' with virtio pmem and xfs. Signed-off-by: Pankaj Gupta --- fs/xfs/xfs_file.c | 9 ++--- 1 file changed, 6 inser

[Qemu-devel] [PATCH v7 4/6] dax: check synchronous mapping is supported

2019-04-25 Thread Pankaj Gupta
This patch introduces 'daxdev_mapping_supported' helper which checks if 'MAP_SYNC' is supported with filesystem mapping. It also checks if corresponding dax_device is synchronous. Virtio pmem device is asynchronous and does not not support VM_SYNC. Suggested-by: Jan Kara Signed-off-by: Pankaj Gu

[Qemu-devel] [PATCH v7 2/6] virtio-pmem: Add virtio pmem driver

2019-04-25 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' driver can reserve this into sy

[Qemu-devel] [PATCH v7 0/6] virtio pmem driver

2019-04-25 Thread Pankaj Gupta
This patch series has implementation for "virtio pmem". "virtio pmem" is fake persistent memory(nvdimm) in guest which allows to bypass the guest page cache. This also implements a VIRTIO based asynchronous flush mechanism. Sharing guest kernel driver in this patchset with the changes

[Qemu-devel] [PATCH v7 04/21] gdbstub: Implement continue (c pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 25 +++-- 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index c47ef7dd9c..89f1ab6524 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1522,6 +1522,16 @@ static void handle_thread_alive(GdbCmdContext *gdb

[Qemu-devel] [PATCH v7 5/6] ext4: disable map_sync for async flush

2019-04-25 Thread Pankaj Gupta
Dont support 'MAP_SYNC' with non-DAX files and DAX files with asynchronous dax_device. Virtio pmem provides asynchronous host page cache flush mechanism. We don't support 'MAP_SYNC' with virtio pmem and ext4. Signed-off-by: Pankaj Gupta Reviewed-by: Jan Kara --- fs/ext4/file.c | 10 ++

[Qemu-devel] [PATCH v7 08/21] gdbstub: Implement remove breakpoint (z pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 49 - 1 file changed, 32 insertions(+), 17 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 36c7353a22..b42425b24c 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1611,6 +1611,29 @@ static void handle_insert

[Qemu-devel] [PATCH v7 3/6] libnvdimm: add dax_dev sync flag

2019-04-25 Thread Pankaj Gupta
This patch adds 'DAXDEV_SYNC' flag which is set for nd_region doing synchronous flush. This later is used to disable MAP_SYNC functionality for ext4 & xfs filesystem for devices don't support synchronous flush. Signed-off-by: Pankaj Gupta --- drivers/dax/bus.c| 2 +- drivers/dax/sup

[Qemu-devel] [PATCH v7 10/21] gdbstub: Implement get register (p pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 50 ++ 1 file changed, 38 insertions(+), 12 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 10e3f12a68..e9a3d0c2bc 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1655,6 +1655,36 @@ static void handle_set_r

[Qemu-devel] [PATCH v7 1/6] libnvdimm: nd_region flush callback support

2019-04-25 Thread Pankaj Gupta
This patch adds functionality to perform flush from guest to host over VIRTIO. We are registering a callback based on 'nd_region' type. virtio_pmem driver requires this special flush function. For rest of the region types we are registering existing flush function. Report error returned by host fsy

[Qemu-devel] [PATCH v7 15/21] gdbstub: Implement file io (F pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 62 +++ 1 file changed, 40 insertions(+), 22 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 3478ac778d..9fe130f30d 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1772,6 +1772,39 @@ static void handle_

[Qemu-devel] [PATCH v7 01/21] gdbstub: Add infrastructure to parse cmd packets

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 200 ++ 1 file changed, 200 insertions(+) diff --git a/gdbstub.c b/gdbstub.c index d54abd17cc..d5e0f3878a 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1268,6 +1268,206 @@ out: return res; } +typede

[Qemu-devel] [PATCH v7 00/21] gdbstub: Refactor command packets handler

2019-04-25 Thread Jon Doron
This patch series refactors the old gdbstub command packets handler with a new infrastructure which should ease extending and adding new and missing gdb command packets. version 7 changes: - Fixed few checkpatch complaints - Feedback from Alex Bennee version 4-6 changes: - mostly feedback from Ri

[Qemu-devel] [PATCH v7 02/21] gdbstub: Implement deatch (D pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 90 ++- 1 file changed, 50 insertions(+), 40 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index d5e0f3878a..621d689868 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1418,11 +1418,6 @@ static inline int s

[Qemu-devel] [PATCH v7 18/21] gdbstub: Implement generic query (q pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 327 ++ 1 file changed, 327 insertions(+) diff --git a/gdbstub.c b/gdbstub.c index d56d0fd235..83ae8738cc 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1915,6 +1915,323 @@ static void handle_v_commands(GdbC

[Qemu-devel] [PATCH v7 03/21] gdbstub: Implement thread_alive (T pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 43 --- 1 file changed, 32 insertions(+), 11 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 621d689868..c47ef7dd9c 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1498,6 +1498,30 @@ static void handle_detach(GdbCm

[Qemu-devel] [PATCH v7 07/21] gdbstub: Implement insert breakpoint (Z pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 33 + 1 file changed, 33 insertions(+) diff --git a/gdbstub.c b/gdbstub.c index 21cdaf4678..36c7353a22 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1588,6 +1588,29 @@ static void handle_set_thread(GdbCmdContext *gdb_ctx, voi

[Qemu-devel] [PATCH v7 09/21] gdbstub: Implement set register (P pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 39 ++- 1 file changed, 30 insertions(+), 9 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index b42425b24c..10e3f12a68 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1634,6 +1634,27 @@ static void handle_remove_bp(GdbCmdC

[Qemu-devel] [PATCH v7 05/21] gdbstub: Implement continue with signal (C pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 30 +- 1 file changed, 25 insertions(+), 5 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 89f1ab6524..469aaeb875 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1532,6 +1532,21 @@ static void handle_continue(GdbCmdContext *gd

[Qemu-devel] [PATCH v7 11/21] gdbstub: Implement write memory (M pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 51 +-- 1 file changed, 33 insertions(+), 18 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index e9a3d0c2bc..8dc2e1d507 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1685,6 +1685,31 @@ static void handle_get_

[Qemu-devel] [PATCH v7 19/21] gdbstub: Implement generic set (Q pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 213 +++--- 1 file changed, 25 insertions(+), 188 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 83ae8738cc..2fd0d66f4d 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1130,14 +1130,6 @@ static GDBThreadId

[Qemu-devel] [PATCH v7 21/21] gdbstub: Clear unused variables in gdb_handle_packet

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 11 ++- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index d678191705..8bdfae4b29 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -2259,17 +2259,11 @@ static void handle_target_halt(GdbCmdContext *gdb_ctx, void *us

[Qemu-devel] [PATCH v7 13/21] gdbstub: Implement write all registers (G pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 41 +++-- 1 file changed, 31 insertions(+), 10 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index daa602edc3..adfe39b3a3 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1734,6 +1734,29 @@ static void handle_read_mem(GdbCm

[Qemu-devel] [PATCH v7 12/21] gdbstub: Implement read memory (m pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 48 1 file changed, 32 insertions(+), 16 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 8dc2e1d507..daa602edc3 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1710,6 +1710,30 @@ static void handle_write_m

[Qemu-devel] [PATCH v7 06/21] gdbstub: Implement set_thread (H pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 79 ++- 1 file changed, 49 insertions(+), 30 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 469aaeb875..21cdaf4678 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1547,6 +1547,47 @@ static void handle_

[Qemu-devel] [PATCH v7 20/21] gdbstub: Implement target halted (? pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 36 ++-- 1 file changed, 26 insertions(+), 10 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 2fd0d66f4d..d678191705 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -2239,13 +2239,30 @@ static void handle_gen_set(GdbCmdCont

[Qemu-devel] [PATCH v7 17/21] gdbstub: Implement v commands with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 170 +++--- 1 file changed, 110 insertions(+), 60 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 9b0556f8be..d56d0fd235 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1815,6 +1815,106 @@ static void handl

[Qemu-devel] [PATCH v7 16/21] gdbstub: Implement step (s pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 25 +++-- 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 9fe130f30d..9b0556f8be 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1805,6 +1805,16 @@ static void handle_file_io(GdbCmdContext *gdb_ctx,

[Qemu-devel] [PATCH v7 14/21] gdbstub: Implement read all registers (g pkt) with new infra

2019-04-25 Thread Jon Doron
Signed-off-by: Jon Doron --- gdbstub.c | 31 +++ 1 file changed, 23 insertions(+), 8 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index adfe39b3a3..3478ac778d 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1757,6 +1757,21 @@ static void handle_write_all_regs(GdbCmdCont

Re: [Qemu-devel] [PATCH v3 01/20] gdbstub: Add infrastructure to parse cmd packets

2019-04-25 Thread Jon Doron
Hi Alex, Thank you for your comments I will add a cover-letter and update it with the review changes, as for what I'm was hoping to add later on is mostly custom query commands for KVM perhaps might apply to other architectures as well here are things i had mind: 1. Get VM nested state, this way y

Re: [Qemu-devel] [PATCH v3 01/20] gdbstub: Add infrastructure to parse cmd packets

2019-04-25 Thread Jon Doron
Thank you Alex I will publish v8 with fixes from your review :) please see my comments below On Thu, Apr 25, 2019 at 5:42 PM Alex Bennée wrote: > > > ari...@gmail.com writes: > > > From: Jon Doron > > > > Signed-off-by: Jon Doron > > --- > > gdbstub.c | 215

[Qemu-devel] [Bug 1826422] Re: Regression: QEMU 4.0 hangs the host (*bisect included*)

2019-04-25 Thread Alex Williamson
Not just NVIDIA, forcing a NIC to use INTx also fails and it's apparent from the host that the device is stuck with DisINTx+. Looks like the resampling mechanism that allows KVM to unmask the interrupt is broken with split irqchip. -- You received this bug notification because you are a member o

[Qemu-devel] [PATCH] migration/colo.h: Remove obsolete codes

2019-04-25 Thread Zhang Chen
From: Zhang Chen Signed-off-by: Zhang Chen --- include/migration/colo.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/include/migration/colo.h b/include/migration/colo.h index ddebe0ad27..f6fbe23ec9 100644 --- a/include/migration/colo.h +++ b/include/migration/colo.h @@ -22,8 +22,6 @@ en

[Qemu-devel] [PATCH] migration/colo.c: Remove redundant input parameter

2019-04-25 Thread Zhang Chen
From: Zhang Chen The colo_do_failover no need the input parameter. Signed-off-by: Zhang Chen --- include/migration/colo.h | 2 +- migration/colo-failover.c | 2 +- migration/colo.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/include/migration/colo.h b/inclu

[Qemu-devel] [Bug 1826422] Re: Regression: QEMU 4.0 hangs the host (*bisect included*)

2019-04-25 Thread Alex Williamson
This seems related to INTx (legacy) interrupt mode, which NVIDIA GeForce will use by default. Using regedit in a Windows VM or adjusting nvidia.ko module parameters of a Linux VM can enable the driver to use MSI, which seems unaffected. We also have the vfio-pci device option x -no-kvm-intx=on, w

[Qemu-devel] [PATCH] memory: correct the comment to DIRTY_MEMORY_MIGRATION

2019-04-25 Thread Wei Yang
The dirty bit is DIRTY_MEMORY_MIGRATION. Correct the comment. Signed-off-by: Wei Yang --- memory.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/memory.c b/memory.c index e49369d85d..9d015bfe4c 100644 --- a/memory.c +++ b/memory.c @@ -2576,7 +2576,7 @@ void memory_globa

Re: [Qemu-devel] [PATCH 1/2] vfio/mdev: add version field as mandatory attribute for mdev device

2019-04-25 Thread Yan Zhao
On Wed, Apr 24, 2019 at 05:10:43PM +0800, Christophe de Dinechin wrote: > > > > On 23 Apr 2019, at 12:39, Daniel P. Berrangé wrote: > > > > On Fri, Apr 19, 2019 at 04:35:04AM -0400, Yan Zhao wrote: > >> device version attribute in mdev sysfs is used by user space software > >> (e.g. libvirt) to

Re: [Qemu-devel] [PATCH 1/2] vfio/mdev: add version field as mandatory attribute for mdev device

2019-04-25 Thread Yan Zhao
On Wed, Apr 24, 2019 at 10:14:50PM +0800, Alex Williamson wrote: > On Tue, 23 Apr 2019 23:39:34 -0400 > Yan Zhao wrote: > > > On Tue, Apr 23, 2019 at 11:02:56PM +0800, Alex Williamson wrote: > > > On Tue, 23 Apr 2019 01:41:57 -0400 > > > Yan Zhao wrote: > > > > > > > On Tue, Apr 23, 2019 at 0

Re: [Qemu-devel] Booting from a Bootcamp partition

2019-04-25 Thread Programmingkid
> On Apr 15, 2019, at 2:35 PM, John Snow wrote: > > > > On 4/15/19 6:23 AM, Programmingkid wrote: >> >>> On Apr 15, 2019, at 5:54 AM, Stefan Hajnoczi wrote: >>> >>> On Sun, Apr 14, 2019 at 07:33:17PM -0400, Programmingkid wrote: Hi I was wondering if anyone has been able to boot from

Re: [Qemu-devel] [PATCH] target/riscv: Expose time CSRs when allowed by [m|s]counteren

2019-04-25 Thread Jonathan Behrens
No, I've still been meaning to send it. After thinking about this some more I realized that it didn't actually make sense for the CLINT to decide the timer frequency and that it should instead be a property of the board itself. I got a bit sidetracked in the process of making those changes, but I s

Re: [Qemu-devel] [PATCH 2/4] migration/savevm: use migration_is_blocked to validate

2019-04-25 Thread Wei Yang
On Thu, Apr 25, 2019 at 05:55:15PM -0300, Daniel Henrique Barboza wrote: > > >On 4/23/19 9:46 PM, Wei Yang wrote: >> migration_is_blocked() is used in migrate_prepare() and >> save_snapshot(), this is more proper to use this instead of >> qemu_savevm_state_blocked() in qemu_loadvm_state(). > > >mig

Re: [Qemu-devel] [PATCH 1/4] migration/savevm: remove duplicate check of migration_is_blocked

2019-04-25 Thread Wei Yang
On Thu, Apr 25, 2019 at 04:20:57PM -0300, Daniel Henrique Barboza wrote: > > >On 4/23/19 9:46 PM, Wei Yang wrote: >> Current call flow of save_snapshot is: >> >>save_snapshot >> migration_is_blocked >>qemu_savevm_state >> migration_is_blocked >> >> Since qemu_savevm_stat

[Qemu-devel] [PATCH v15 0/2] support MAP_SYNC for memory-backend-file

2019-04-25 Thread Wei Yang
Linux 4.15 introduces a new mmap flag MAP_SYNC, which can be used to guarantee the write persistence to mmap'ed files supporting DAX (e.g., files on ext4/xfs file system mounted with '-o dax'). A description of MAP_SYNC and MAP_SHARED_VALIDATE can be found at https://patchwork.kernel.org/patch

[Qemu-devel] [PATCH v15 1/2] util/mmap-alloc: support MAP_SYNC in qemu_ram_mmap()

2019-04-25 Thread Wei Yang
From: Zhang Yi When a file supporting DAX is used as vNVDIMM backend, mmap it with MAP_SYNC flag in addition which can ensure file system metadata synced in each guest writes to the backend file, without other QEMU actions (e.g., periodic fsync() by QEMU). Current, We have below different possib

[Qemu-devel] [PATCH v15 2/2] docs: Added MAP_SYNC documentation

2019-04-25 Thread Wei Yang
From: Zhang Yi Signed-off-by: Zhang Yi Signed-off-by: Wei Yang Reviewed-by: Stefan Hajnoczi Reviewed-by: Pankaj Gupta Reviewed-by: Michael S. Tsirkin --- docs/nvdimm.txt | 22 +++--- qemu-options.hx | 5 + 2 files changed, 24 insertions(+), 3 deletions(-) diff --git a/

Re: [Qemu-devel] [PATCH for-QEMU-4.1 v5 00/29] Kconfig dependencies for ARM machines

2019-04-25 Thread Philippe Mathieu-Daudé
Hi Thomas, On 4/18/19 8:00 PM, Thomas Huth wrote: > This series reworks the default-configs/arm-softmmu.mak and > default-configs/aarch64-softmmu.mak files to use the new Kconfig-style > dependencies instead. > > Some of the patches are slightly based on the work by Ákos Kovács: > > https://lis

Re: [Qemu-devel] [PATCH] ati-vga: Fix check for blt outside vram

2019-04-25 Thread BALATON Zoltan
On Sun, 14 Apr 2019, BALATON Zoltan wrote: On Tue, 9 Apr 2019, Philippe Mathieu-Daudé wrote: This patch looks 4.0 worthwhile. Now that it seems we'll have another rc, will this get in? Gerd, I think you have to send a pull request with it for that. Ping? This has missed two rc-s. This preve

Re: [Qemu-devel] [PATCH v2 for-4.1 0/2] Fix ohci_die() and move PCI code to separate file

2019-04-25 Thread Philippe Mathieu-Daudé
Hi Thomas, On 4/19/19 9:56 AM, Thomas Huth wrote: > First patch fixes a problem with ohci_die(), second patch moves PCI code into > a separate file, so that the sysbus OHCI device can also be used without > the dependency on the PCI code. > > v2: Split the patch into two patches, one for the ohci

Re: [Qemu-devel] [PATCH for-QEMU-4.1 v5 09/29] hw/arm: Express dependencies of the OMAP machines with Kconfig

2019-04-25 Thread Philippe Mathieu-Daudé
On 4/18/19 8:00 PM, Thomas Huth wrote: > Add Kconfig dependencies for the OMAP machines (cheetah, n800, n810, > sx1 and sx1-v1). > This patch is slightly based on earlier work by Ákos Kovács (i.e. > his "hw/arm/Kconfig: Add ARM Kconfig" patch). > > Signed-off-by: Thomas Huth > --- > default-conf

Re: [Qemu-devel] [PATCH v3 11/13] tests: acpi: add simple arm/virt testcase

2019-04-25 Thread x00249684
Hi Igor, +static void test_acpi_virt_tcg(void) +{ +test_data data = { +.machine = "virt", +.uefi_fl1 = "pc-bios/edk2-aarch64-code.fd", +.uefi_fl2 = "pc-bios/edk2-arm-vars.fd", +.cd = "tests/data/uefi-boot-images/bios-tables-test.aarch64.iso.qcow2", +.ram

Re: [Qemu-devel] [PATCH for-QEMU-4.1 v5 11/29] hw/arm: Express dependencies of realview, versatile and vexpress with Kconfig

2019-04-25 Thread Philippe Mathieu-Daudé
Hi Thomas, On 4/18/19 8:00 PM, Thomas Huth wrote: > This patch is slightly based on earlier work by Ákos Kovács (i.e. > his "hw/arm/Kconfig: Add ARM Kconfig" patch). > > Signed-off-by: Thomas Huth > --- > default-configs/arm-softmmu.mak | 24 - > hw/arm/Kconfig

Re: [Qemu-devel] [PATCH for-QEMU-4.1 v5 19/29] hw/arm: Express dependencies of the MPS2 boards with Kconfig

2019-04-25 Thread Philippe Mathieu-Daudé
On 4/18/19 8:00 PM, Thomas Huth wrote: > Add Kconfig dependencies for the mps2-an* machines. > > Signed-off-by: Thomas Huth > --- > default-configs/arm-softmmu.mak | 20 +--- > hw/arm/Kconfig | 18 ++ > 2 files changed, 19 insertions(+), 19 deleti

Re: [Qemu-devel] [PATCH 4/4] migration/savevm: wrap into qemu_loadvm_state_header()

2019-04-25 Thread Daniel Henrique Barboza
On 4/23/19 9:47 PM, Wei Yang wrote: On source side, we have qemu_savevm_state_header() to send related data, while on the receiving side those steps are scattered in qemu_loadvm_state(). This patch wrap those related steps into qemu_loadvm_state_header() to make it friendly to read. Signed-o

[Qemu-devel] [Bug 1701835] Re: floating-point operation bugs in qemu-alpha

2019-04-25 Thread Stefan Ring
There seems to be more confusion of the sort. This fixes it for me: --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -10226,7 +10226,7 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1, return -TARGET_EFAULT; } orig

Re: [Qemu-devel] [PATCH for-QEMU-4.1 v5 28/29] hw/arm: Express dependencies of the musca machines with Kconfig

2019-04-25 Thread Philippe Mathieu-Daudé
On 4/18/19 8:00 PM, Thomas Huth wrote: > Dependencies have been determined with trial-and-error and by > looking at the musca.c source file. > > Signed-off-by: Thomas Huth Reviewed-by: Philippe Mathieu-Daudé > --- > hw/arm/Kconfig | 9 ++--- > 1 file changed, 6 insertions(+), 3 deletions(

Re: [Qemu-devel] [PATCH] Revert "armv7m: Guard against no -kernel argument"

2019-04-25 Thread Philippe Mathieu-Daudé
On 4/25/19 8:07 PM, Philippe Mathieu-Daudé wrote: > Hi Peter, Stefan, > > On 1/4/19 4:16 PM, Peter Maydell wrote: >> On Thu, 3 Jan 2019 at 14:41, Stefan Hajnoczi wrote: >>> >>> This reverts commit 01fd41ab3fb69971c24a69ed49cde96086d81278. >>> >>> The generic loader device (-device loader,file=ker

Re: [Qemu-devel] [PATCH] target/riscv: Expose time CSRs when allowed by [m|s]counteren

2019-04-25 Thread Palmer Dabbelt
On Fri, 19 Apr 2019 16:05:35 PDT (-0700), alistai...@gmail.com wrote: On Mon, Apr 15, 2019 at 5:46 PM Jonathan Behrens wrote: For any chip that has a CLINT, we want the frequency of the time register and the frequency of the CLINT to match. That frequency, SIFIVE_CLINT_TIMEBASE_FREQ (=10MHz)

  1   2   3   >