[PATCH v2] target/ppc: Fix ISA v3.0 (POWER9) slbia implementation

2020-03-18 Thread Nicholas Piggin
The new ISA v3.0 slbia variants have not been implemented for TCG, which can lead to crashing when a POWER9 machine boots Linux using the hash MMU, for example ("disable_radix" kernel command line). Add them. Signed-off-by: Nicholas Piggin --- Changes in v2: - Rewrite changelog. - Remove stray s

Re: [PATCH v14 Kernel 7/7] vfio: Selective dirty page tracking if IOMMU backed device pins pages

2020-03-18 Thread Yan Zhao
On Thu, Mar 19, 2020 at 03:41:14AM +0800, Kirti Wankhede wrote: > Added a check such that only singleton IOMMU groups can pin pages. > From the point when vendor driver pins any pages, consider IOMMU group > dirty page scope to be limited to pinned pages. > > To optimize to avoid walking list ofte

Re: [PATCH v14 Kernel 4/7] vfio iommu: Implementation of ioctl for dirty pages tracking.

2020-03-18 Thread Yan Zhao
On Thu, Mar 19, 2020 at 12:40:53PM +0800, Alex Williamson wrote: > On Thu, 19 Mar 2020 00:15:33 -0400 > Yan Zhao wrote: > > > On Thu, Mar 19, 2020 at 12:01:00PM +0800, Alex Williamson wrote: > > > On Wed, 18 Mar 2020 23:06:39 -0400 > > > Yan Zhao wrote: > > > > > > > On Thu, Mar 19, 2020 at 0

Re: [PATCH v3 2/2] target/ppc: Add support for scv and rfscv instructions

2020-03-18 Thread David Gibson
On Tue, Mar 17, 2020 at 03:49:18PM +1000, Nicholas Piggin wrote: > POWER9 adds scv and rfscv instructions and the system call vectored > interrupt. Linux does not support this instruction yet but it has > been tested with a modified kernel that runs on real hardware. > > Signed-off-by: Nicholas Pi

Re: [PATCH v3 1/2] target/ppc: Improve syscall exception logging

2020-03-18 Thread David Gibson
On Tue, Mar 17, 2020 at 03:49:17PM +1000, Nicholas Piggin wrote: > system calls (at least in Linux) use registers r3-r8 for inputs, so > include those registers in the dump. > > This also adds a mode for PAPR hcalls, which have a different calling > convention. > > Signed-off-by: Nicholas Piggin

Re: [PATCH v2 1/1] target/ppc: don't byte swap ELFv2 signal handler

2020-03-18 Thread David Gibson
On Wed, Mar 18, 2020 at 12:01:16PM -0500, Vincent Fazio wrote: > From: Vincent Fazio > > Previously, the signal handler would be byte swapped if the target and > host CPU used different endianness. This would cause a SIGSEGV when > attempting to translate the opcode pointed to by the swapped addr

[Bug 1866962] Re: [Regression]Powerpc kvm guest unable to start with hugepage backed memory

2020-03-18 Thread Satheesh Rajendran
Any updates? -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1866962 Title: [Regression]Powerpc kvm guest unable to start with hugepage backed memory Status in QEMU: New Bug description: Curr

Re: [PATCH 1/1] target/ppc: fix ELFv2 signal handler endianness

2020-03-18 Thread David Gibson
On Wed, Mar 18, 2020 at 10:00:20AM -0500, Vincent Fazio wrote: > David, Laurent, > > On 3/15/20 9:21 PM, David Gibson wrote: > > On Sun, Mar 15, 2020 at 07:29:04PM -0500, Vincent Fazio wrote: > > > Laurent, > > > > > > On Sun, Mar 15, 2020 at 1:10 PM Laurent Vivier wrote: > > > > Le 15/03/2020 à

Re: [PATCH 1/2] target/ppc: Fix slbia TLB invalidation gap

2020-03-18 Thread David Gibson
On Wed, Mar 18, 2020 at 02:41:34PM +1000, Nicholas Piggin wrote: > slbia must invalidate TLBs even if it does not remove a valid SLB > entry, because slbmte can overwrite valid entries without removing > their TLBs. > > As the architecture says, slbia invalidates all lookaside information, > not c

Re: [EXTERNAL] [PATCH 2/2] target/ppc: Fix ISA v3.0 (POWER9) slbia implementation

2020-03-18 Thread David Gibson
On Thu, Mar 19, 2020 at 07:46:54AM +1100, Benjamin Herrenschmidt wrote: > On Wed, 2020-03-18 at 18:08 +0100, Cédric Le Goater wrote: > > On 3/18/20 5:41 AM, Nicholas Piggin wrote: > > > Linux using the hash MMU ("disable_radix" command line) on a POWER9 > > > machine quickly hits translation bugs d

Re: [PATCH v2] ppc/spapr: Set the effective address provided flag in mc error log.

2020-03-18 Thread David Gibson
On Wed, Mar 18, 2020 at 01:04:20PM +0530, Mahesh Salgaonkar wrote: > Per PAPR, it is expected to set effective address provided flag in > sub_err_type member of mc extended error log (i.e > rtas_event_log_v6_mc.sub_err_type). This somehow got missed in original > fwnmi-mce patch series. The current

Re: [PATCH 1/2] target/ppc: Fix slbia TLB invalidation gap

2020-03-18 Thread David Gibson
On Wed, Mar 18, 2020 at 05:52:32PM +0100, Greg Kurz wrote: 65;5803;1c> On Wed, 18 Mar 2020 14:41:34 +1000 > Nicholas Piggin wrote: > > > slbia must invalidate TLBs even if it does not remove a valid SLB > > entry, because slbmte can overwrite valid entries without removing > > their TLBs. > > >

Re: [PATCH v14 Kernel 1/7] vfio: KABI for migration interface for device state

2020-03-18 Thread Yan Zhao
On Thu, Mar 19, 2020 at 11:49:26AM +0800, Alex Williamson wrote: > On Wed, 18 Mar 2020 21:17:03 -0400 > Yan Zhao wrote: > > > On Thu, Mar 19, 2020 at 03:41:08AM +0800, Kirti Wankhede wrote: > > > - Defined MIGRATION region type and sub-type. > > > > > > - Defined vfio_device_migration_info struc

Re: [PATCH v1 1/1] target/riscv: Don't set write permissions on dirty PTEs

2020-03-18 Thread Palmer Dabbelt
On Tue, 03 Mar 2020 17:16:59 PST (-0800), Alistair Francis wrote: The RISC-V spec specifies that when a write happens and the D bit is clear the implementation will set the bit in the PTE. It does not describe that the PTE being dirty means that we should provide write access. This patch removes

Re: [PATCH v14 Kernel 4/7] vfio iommu: Implementation of ioctl for dirty pages tracking.

2020-03-18 Thread Alex Williamson
On Thu, 19 Mar 2020 00:15:33 -0400 Yan Zhao wrote: > On Thu, Mar 19, 2020 at 12:01:00PM +0800, Alex Williamson wrote: > > On Wed, 18 Mar 2020 23:06:39 -0400 > > Yan Zhao wrote: > > > > > On Thu, Mar 19, 2020 at 03:41:11AM +0800, Kirti Wankhede wrote: > > > > VFIO_IOMMU_DIRTY_PAGES ioctl per

Re: [PATCH v14 Kernel 4/7] vfio iommu: Implementation of ioctl for dirty pages tracking.

2020-03-18 Thread Yan Zhao
On Thu, Mar 19, 2020 at 12:01:00PM +0800, Alex Williamson wrote: > On Wed, 18 Mar 2020 23:06:39 -0400 > Yan Zhao wrote: > > > On Thu, Mar 19, 2020 at 03:41:11AM +0800, Kirti Wankhede wrote: > > > VFIO_IOMMU_DIRTY_PAGES ioctl performs three operations: > > > - Start dirty pages tracking while migr

[PATCH v2 1/1] device_tree: Add info message when dumping dtb to file

2020-03-18 Thread Leonardo Bras
When dumping dtb to a file, qemu exits silently before starting the VM. Add info message so user can easily track why the proccess exits. Add error message if dtb dump failed. Signed-off-by: Leonardo Bras --- device_tree.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git

Re: [PATCH v14 Kernel 4/7] vfio iommu: Implementation of ioctl for dirty pages tracking.

2020-03-18 Thread Alex Williamson
On Wed, 18 Mar 2020 23:06:39 -0400 Yan Zhao wrote: > On Thu, Mar 19, 2020 at 03:41:11AM +0800, Kirti Wankhede wrote: > > VFIO_IOMMU_DIRTY_PAGES ioctl performs three operations: > > - Start dirty pages tracking while migration is active > > - Stop dirty pages tracking. > > - Get dirty pages bitmap

Re: [PATCH v14 Kernel 1/7] vfio: KABI for migration interface for device state

2020-03-18 Thread Alex Williamson
On Wed, 18 Mar 2020 21:17:03 -0400 Yan Zhao wrote: > On Thu, Mar 19, 2020 at 03:41:08AM +0800, Kirti Wankhede wrote: > > - Defined MIGRATION region type and sub-type. > > > > - Defined vfio_device_migration_info structure which will be placed at the > > 0th offset of migration region to get/se

Re: [PATCH 1/1] device_tree: Add info message when dumping dtb to file

2020-03-18 Thread Leonardo Bras
On Thu, 2020-03-19 at 00:32 -0300, Leonardo Bras wrote: > error_report("%s: Failed dumping dtb to %s", __func__, dumpdtb) Sorry, missed ending ';'. I will send a v2. signature.asc Description: This is a digitally signed message part

Re: [PATCH v14 Kernel 5/7] vfio iommu: Update UNMAP_DMA ioctl to get dirty bitmap before unmap

2020-03-18 Thread Alex Williamson
On Thu, 19 Mar 2020 01:11:12 +0530 Kirti Wankhede wrote: > DMA mapped pages, including those pinned by mdev vendor drivers, might > get unpinned and unmapped while migration is active and device is still > running. For example, in pre-copy phase while guest driver could access > those pages, host

Re: [PATCH v6 25/61] target/riscv: vector single-width averaging add and subtract

2020-03-18 Thread LIU Zhiwei
On 2020/3/17 23:06, LIU Zhiwei wrote: Signed-off-by: LIU Zhiwei --- target/riscv/helper.h | 17 target/riscv/insn32.decode | 5 ++ target/riscv/insn_trans/trans_rvv.inc.c | 7 ++ target/riscv/vector_helper.c| 100 4

Re: [PATCH v14 Kernel 4/7] vfio iommu: Implementation of ioctl for dirty pages tracking.

2020-03-18 Thread Alex Williamson
On Thu, 19 Mar 2020 01:11:11 +0530 Kirti Wankhede wrote: > VFIO_IOMMU_DIRTY_PAGES ioctl performs three operations: > - Start dirty pages tracking while migration is active > - Stop dirty pages tracking. > - Get dirty pages bitmap. Its user space application's responsibility to > copy content of

Re: [PATCH v14 Kernel 7/7] vfio: Selective dirty page tracking if IOMMU backed device pins pages

2020-03-18 Thread Alex Williamson
On Thu, 19 Mar 2020 01:11:14 +0530 Kirti Wankhede wrote: > Added a check such that only singleton IOMMU groups can pin pages. > From the point when vendor driver pins any pages, consider IOMMU group > dirty page scope to be limited to pinned pages. > > To optimize to avoid walking list often, ad

Re: [PATCH v14 Kernel 3/7] vfio iommu: Add ioctl definition for dirty pages tracking.

2020-03-18 Thread Alex Williamson
On Thu, 19 Mar 2020 01:11:10 +0530 Kirti Wankhede wrote: > IOMMU container maintains a list of all pages pinned by vfio_pin_pages API. > All pages pinned by vendor driver through this API should be considered as > dirty during migration. When container consists of IOMMU capable device and > all p

[PATCH 1/1] device_tree: Add info message when dumping dtb to file

2020-03-18 Thread Leonardo Bras
When dumping dtb to a file, qemu exits silently before starting the VM. Add info message so user can easily track why the proccess exits. Add error message if dtb dump failed. Signed-off-by: Leonardo Bras --- device_tree.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git

Re: [PATCH v2] ppc/spapr: Set the effective address provided flag in mc error log.

2020-03-18 Thread Nicholas Piggin
Mahesh Salgaonkar's on March 18, 2020 5:34 pm: > Per PAPR, it is expected to set effective address provided flag in > sub_err_type member of mc extended error log (i.e > rtas_event_log_v6_mc.sub_err_type). This somehow got missed in original > fwnmi-mce patch series. The current code just updates t

Re: [PATCH v14 Kernel 4/7] vfio iommu: Implementation of ioctl for dirty pages tracking.

2020-03-18 Thread Yan Zhao
On Thu, Mar 19, 2020 at 03:41:11AM +0800, Kirti Wankhede wrote: > VFIO_IOMMU_DIRTY_PAGES ioctl performs three operations: > - Start dirty pages tracking while migration is active > - Stop dirty pages tracking. > - Get dirty pages bitmap. Its user space application's responsibility to > copy conte

Re: [EXTERNAL] [PATCH 2/2] target/ppc: Fix ISA v3.0 (POWER9) slbia implementation

2020-03-18 Thread Nicholas Piggin
Benjamin Herrenschmidt's on March 19, 2020 6:46 am: > On Wed, 2020-03-18 at 18:08 +0100, Cédric Le Goater wrote: >> On 3/18/20 5:41 AM, Nicholas Piggin wrote: >> > Linux using the hash MMU ("disable_radix" command line) on a POWER9 >> > machine quickly hits translation bugs due to using v3.0 slbia

Re: [PATCH 4/5] ppc/spapr: Don't kill the guest if a recovered FWNMI machine check delivery fails

2020-03-18 Thread Nicholas Piggin
Greg Kurz's on March 18, 2020 2:57 am: > On Tue, 17 Mar 2020 15:02:14 +1000 > Nicholas Piggin wrote: > >> Try to be tolerant of errors if the machine check had been recovered >> by the host. >> >> Signed-off-by: Nicholas Piggin >> --- > > Same comment as previous patch on multi-line error stri

Re: [PATCH 3/5] ppc/spapr: Add FWNMI machine check delivery warnings

2020-03-18 Thread Nicholas Piggin
Greg Kurz's on March 17, 2020 10:20 pm: > On Tue, 17 Mar 2020 15:02:13 +1000 > Nicholas Piggin wrote: > >> Add some messages which explain problems and guest misbehaviour that >> may be difficult to diagnose in rare cases of machine checks. >> >> Signed-off-by: Nicholas Piggin >> --- >> hw/ppc

Re: [PATCH 1/5] ppc/spapr: KVM FWNMI should not be enabled until guest requests it

2020-03-18 Thread Nicholas Piggin
Greg Kurz's on March 17, 2020 9:02 pm: > On Tue, 17 Mar 2020 15:02:11 +1000 > Nicholas Piggin wrote: > >> The KVM FWNMI capability should be enabled with the "ibm,nmi-register" >> rtas call. Although MCEs from KVM will be delivered as architected >> interrupts to the guest before "ibm,nmi-registe

Re: [EXTERNAL] [PATCH 1/2] target/ppc: Fix slbia TLB invalidation gap

2020-03-18 Thread Nicholas Piggin
Cédric Le Goater's on March 19, 2020 2:45 am: > On 3/18/20 5:41 AM, Nicholas Piggin wrote: >> slbia must invalidate TLBs even if it does not remove a valid SLB >> entry, because slbmte can overwrite valid entries without removing >> their TLBs. >> >> As the architecture says, slbia invalidates all

[PATCH v4 2/2] virtio-gpu: add the ability to export resources

2020-03-18 Thread David Stevens
Signed-off-by: David Stevens --- virtio-gpu.tex | 30 ++ 1 file changed, 30 insertions(+) diff --git a/virtio-gpu.tex b/virtio-gpu.tex index af4ca61..e75aafa 100644 --- a/virtio-gpu.tex +++ b/virtio-gpu.tex @@ -35,6 +35,8 @@ \subsection{Feature bits}\label{sec:Device

[PATCH v4 1/2] content: define what an exported object is

2020-03-18 Thread David Stevens
Define a mechanism for sharing objects between different virtio devices. Signed-off-by: David Stevens --- content.tex | 12 introduction.tex | 4 2 files changed, 16 insertions(+) diff --git a/content.tex b/content.tex index b1ea9b9..c8a367b 100644 --- a/content.tex +++

[PATCH v4 0/2] Cross-device resource sharing

2020-03-18 Thread David Stevens
Hi all, This is the next iteration of patches for adding support for sharing resources between different virtio devices. The corresponding Linux implementation is [1]. In addition to these patches, the most recent virtio-video patchset includes a patch for importing objects into that device [2].

Re: [PATCH v14 Kernel 1/7] vfio: KABI for migration interface for device state

2020-03-18 Thread Yan Zhao
On Thu, Mar 19, 2020 at 03:41:08AM +0800, Kirti Wankhede wrote: > - Defined MIGRATION region type and sub-type. > > - Defined vfio_device_migration_info structure which will be placed at the > 0th offset of migration region to get/set VFIO device related > information. Defined members of struc

Re: [PATCH v9 0/4] linux-user: generate syscall_nr.sh for RISC-V

2020-03-18 Thread no-reply
Patchew URL: https://patchew.org/QEMU/cover.1584571250.git.alistair.fran...@wdc.com/ Hi, This series seems to have some coding style problems. See output below for more information: Subject: [PATCH v9 0/4] linux-user: generate syscall_nr.sh for RISC-V Message-id: cover.1584571250.git.alistai

Re: [PATCH v9 0/4] linux-user: generate syscall_nr.sh for RISC-V

2020-03-18 Thread no-reply
Patchew URL: https://patchew.org/QEMU/cover.1584571250.git.alistair.fran...@wdc.com/ Hi, This series seems to have some coding style problems. See output below for more information: Subject: [PATCH v9 0/4] linux-user: generate syscall_nr.sh for RISC-V Message-id: cover.1584571250.git.alistai

Re: [PATCH v2 0/4] travis-ci: Add a KVM-only s390x job

2020-03-18 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200318222717.24676-1-phi...@redhat.com/ Hi, This series failed the docker-quick@centos7 build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. === TEST SCRIPT BEGIN === #

Re: [PATCH v6 06/61] target/riscv: add vector stride load and store instructions

2020-03-18 Thread Alistair Francis
On Tue, Mar 17, 2020 at 8:19 AM LIU Zhiwei wrote: > > Vector strided operations access the first memory element at the base address, > and then access subsequent elements at address increments given by the byte > offset contained in the x register specified by rs2. > > Vector unit-stride operation

Re: [PATCH v6 05/61] target/riscv: add an internals.h header

2020-03-18 Thread Alistair Francis
On Tue, Mar 17, 2020 at 8:17 AM LIU Zhiwei wrote: > > The internals.h keeps things that are not relevant to the actual architecture, > only to the implementation, separate. > > Signed-off-by: LIU Zhiwei Reviewed-by: Alistair Francis Alistair > --- > target/riscv/internals.h | 24

Re: [PATCH v9 2/4] linux-user/syscall: Add support for clock_gettime64/clock_settime64

2020-03-18 Thread Philippe Mathieu-Daudé
On 3/18/20 11:46 PM, Alistair Francis wrote: Add support for the clock_gettime64/clock_settime64 syscalls. If your host is 64-bit or is 32-bit with the *_time64 syscall then the timespec will correctly be a 64-bit time_t. Otherwise the host will return a 32-bit time_t which will be rounded to 64

Re: [PATCH v9 1/4] linux-user: Protect more syscalls

2020-03-18 Thread Philippe Mathieu-Daudé
On 3/18/20 11:46 PM, Alistair Francis wrote: New y2038 safe 32-bit architectures (like RISC-V) don't support old syscalls with a 32-bit time_t. The kernel defines new *_time64 versions of these syscalls. Add some more #ifdefs to syscall.c in linux-user to allow us to compile without these old sys

Re: [PATCH] gdbstub: add support to Xfer:auxv:read: packet

2020-03-18 Thread Lirong Yuan
On Fri, Mar 6, 2020 at 5:01 PM Lirong Yuan wrote: > This allows gdb to access the target’s auxiliary vector, > which can be helpful for telling system libraries important details > about the hardware, operating system, and process. > > Signed-off-by: Lirong Yuan > --- > gdbstub.c | 55 +

Re: [PATCH v2] slirp: update submodule to v4.2.0 + mingw-fix

2020-03-18 Thread Samuel Thibault
Marc-André Lureau, le mar. 17 mars 2020 19:13:36 +0100, a ecrit: > git shortlog > 126c04acbabd7ad32c2b018fe10dfac2a3bc1210..7012a2c62e5b54eab88c119383022ec7ce86e9b2 > > 5eraph (1): > Use specific outbound IP address > > Akihiro Suda (8): > remove confusing comment that exists from anc

[PATCH v9 3/4] linux-user: Support futex_time64

2020-03-18 Thread Alistair Francis
Add support for host and target futex_time64. If futex_time64 exists on the host we try that first before falling back to the standard futux syscall. Signed-off-by: Alistair Francis --- linux-user/syscall.c | 144 +++ 1 file changed, 131 insertions(+), 13

[PATCH v9 0/4] linux-user: generate syscall_nr.sh for RISC-V

2020-03-18 Thread Alistair Francis
This series updates the RISC-V syscall_nr.sh based on the 5.5 kernel. There are two parts to this. One is just adding the new syscalls, the other part is updating the RV32 syscalls to match the fact that RV32 is a 64-bit time_t architectures (y2038) safe. We need to make some changes to syscall.c

[PATCH v9 4/4] linux-user/riscv: Update the syscall_nr's to the 5.5 kernel

2020-03-18 Thread Alistair Francis
Signed-off-by: Alistair Francis Reviewed-by: Laurent Vivier --- linux-user/riscv/syscall32_nr.h | 295 +++ linux-user/riscv/syscall64_nr.h | 301 linux-user/riscv/syscall_nr.h | 294 +-- 3 files changed, 5

[PATCH v9 2/4] linux-user/syscall: Add support for clock_gettime64/clock_settime64

2020-03-18 Thread Alistair Francis
Add support for the clock_gettime64/clock_settime64 syscalls. If your host is 64-bit or is 32-bit with the *_time64 syscall then the timespec will correctly be a 64-bit time_t. Otherwise the host will return a 32-bit time_t which will be rounded to 64-bits. This will be incorrect after y2038. Sig

[PATCH v9 1/4] linux-user: Protect more syscalls

2020-03-18 Thread Alistair Francis
New y2038 safe 32-bit architectures (like RISC-V) don't support old syscalls with a 32-bit time_t. The kernel defines new *_time64 versions of these syscalls. Add some more #ifdefs to syscall.c in linux-user to allow us to compile without these old syscalls. Signed-off-by: Alistair Francis Review

[Bug 1835865] Re: piix crashes on mips when accessing acpi-pci-hotplug

2020-03-18 Thread Philippe Mathieu-Daudé
Proposed fix: https://lists.gnu.org/archive/html/qemu-devel/2020-03/msg06080.html ** Changed in: qemu Status: New => In Progress ** Changed in: qemu Assignee: (unassigned) => Philippe Mathieu-Daudé (philmd) -- You received this bug notification because you are a member of qemu- deve

Re: [PATCH 5/4] scripts/simplebench: fix python script ! headers

2020-03-18 Thread Philippe Mathieu-Daudé
On 3/18/20 6:02 PM, Vladimir Sementsov-Ogievskiy wrote: - simplebench.py is not for executing by itself, so drop the header - in bench_block_job.py fix python to python3 Signed-off-by: Vladimir Sementsov-Ogievskiy --- scripts/simplebench/bench_block_job.py | 2 +- scripts/simplebench/simpleb

Re: [PATCH v3] fdc/i8257: implement verify transfer mode

2020-03-18 Thread John Snow
On 11/1/19 12:55 PM, Sven Schnelle wrote: > While working on the Tulip driver i tried to write some Teledisk images to > a floppy image which didn't work. Turned out that Teledisk checks the written > data by issuing a READ command to the FDC but running the DMA controller > in VERIFY mode. As w

[PATCH v2 4/4] .travis.yml: Add a KVM-only s390x job

2020-03-18 Thread Philippe Mathieu-Daudé
Add a job to build QEMU on s390x with TCG disabled, so this configuration won't bitrot over time. This job is quick, running check-unit: Ran for 4 min 48 sec https://travis-ci.org/github/philmd/qemu/jobs/663659486 Signed-off-by: Philippe Mathieu-Daudé --- .travis.yml | 42 ++

[PATCH-for-5.0 v2 3/4] tests/migration: Reduce autoconverge initial bandwidth

2020-03-18 Thread Philippe Mathieu-Daudé
When using max-bandwidth=~100Mb/s, this test fails on Travis-CI s390x when configured with --disable-tcg: $ make check-qtest TESTcheck-qtest-s390x: tests/qtest/boot-serial-test qemu-system-s390x: -accel tcg: invalid accelerator tcg qemu-system-s390x: falling back to KVM TESTc

[PATCH-for-5.0 v2 2/4] tests/test-util-sockets: Skip test on non-x86 Travis containers

2020-03-18 Thread Philippe Mathieu-Daudé
Similarly to commit 4f370b1098, test-util-sockets fails in restricted non-x86 Travis containers since they apparently blacklisted some required system calls there. Let's simply skip the test if we detect such an environment. Reviewed-by: Daniel P. Berrangé Signed-off-by: Philippe Mathieu-Daudé -

[PATCH v2 0/4] travis-ci: Add a KVM-only s390x job

2020-03-18 Thread Philippe Mathieu-Daudé
Add a Travis job to build a KVM-only QEMU on s390x. This series also contains few fixes for Travis/s390x. Since v1: - Do not disable autoconverge on s390x, but reduce the test initial bandwidth (dgilbert) - Added danpb R-b tags Philippe Mathieu-Daudé (4): tests/test-util-filemonitor: Fix Tra

[PATCH-for-5.0 v2 1/4] tests/test-util-filemonitor: Fix Travis-CI $ARCH env variable name

2020-03-18 Thread Philippe Mathieu-Daudé
While we can find reference of a 'TRAVIS_ARCH' variable in the environment and source [1], per the Travis-CI multi-arch documentation [2] the variable is named TRAVIS_CPU_ARCH. [1] https://github.com/travis-ci/travis-build/blob/v10.0.0/lib/travis/build/bash/travis_setup_env.bash#L39 [2] https://

[PATCH-for-5.0] block: Assert BlockDriver::format_name is not NULL

2020-03-18 Thread Philippe Mathieu-Daudé
bdrv_do_find_format() calls strcmp() using BlockDriver::format_name as argument, which must not be NULL. Assert this field is not null when we register a block driver in bdrv_register(). Reported-by: Mansour Ahmadi Signed-off-by: Philippe Mathieu-Daudé --- block.c | 1 + 1 file changed, 1 inser

[PATCH-for-5.0 2/2] hw/acpi/piix4: Restrict system-hotplug-support to x86 i440fx PC machine

2020-03-18 Thread Philippe Mathieu-Daudé
The PC (i440fx) machine is the only one using the PIIX4 PM specific system-hotplug-support feature. Enable this feature in pc_init1(), and let the callers of piix4_create() get a simple PIIX4 device. This is the case of the MIPS Malta board. Doing so we fix a bug on the Malta where a guest writin

[PATCH-for-5.0 0/2] hw/acpi/piix4: Restrict 'system hotplug' feature to i440fx PC machine

2020-03-18 Thread Philippe Mathieu-Daudé
This feature is not documented in the PIIX4 datasheet. It appears to be only used on the i440fx PC machine. Add a property to the PIIX4_PM device to restrict its use. This fixes MIPS guest crashing QEMU when accessing ioport 0xaf00. Philippe Mathieu-Daudé (2): hw/acpi/piix4: Add 'system-hotplug-

[PATCH-for-5.0 1/2] hw/acpi/piix4: Add 'system-hotplug-support' property

2020-03-18 Thread Philippe Mathieu-Daudé
The I/O ranges registered by the piix4_acpi_system_hot_add_init() function are not documented in the PIIX4 datasheet. This appears to be a PC-only feature added in commit 5e3cb5347e ("initialize hot add system / acpi gpe") which was then moved to the PIIX4 device model in commit 9d5e77a22f ("make q

Re: [PULL 00/28 for 5.0] testing and gdbstub updates

2020-03-18 Thread Peter Maydell
On Tue, 17 Mar 2020 at 17:50, Alex Bennée wrote: > > The following changes since commit 6fb1603aa24d9212493e4819d7b685be9c9aad7a: > > Merge remote-tracking branch > 'remotes/pmaydell/tags/pull-target-arm-20200317' into staging (2020-03-17 > 14:44:50 +) > > are available in the Git reposito

Re: [EXTERNAL] [PATCH 2/2] target/ppc: Fix ISA v3.0 (POWER9) slbia implementation

2020-03-18 Thread Benjamin Herrenschmidt
On Wed, 2020-03-18 at 18:08 +0100, Cédric Le Goater wrote: > On 3/18/20 5:41 AM, Nicholas Piggin wrote: > > Linux using the hash MMU ("disable_radix" command line) on a POWER9 > > machine quickly hits translation bugs due to using v3.0 slbia > > features that are not implemented in TCG. Add them. >

Re: [PULL v2 00/37] Linux user for 5.0 patches

2020-03-18 Thread Richard Henderson
On 3/18/20 1:23 PM, Laurent Vivier wrote: > Le 18/03/2020 à 21:17, Richard Henderson a écrit : >> On 3/18/20 12:58 PM, Laurent Vivier wrote: However, from the error message above, it's clear that cpu_loop.o has not been rebuilt properly. >>> >>> In the series merged here syscal

[PULL v2 10/11] nbd/server: use bdrv_dirty_bitmap_next_dirty_area

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Use bdrv_dirty_bitmap_next_dirty_area for bitmap_to_extents. Since bdrv_dirty_bitmap_next_dirty_area is very accurate in its interface, we'll never exceed requested region with last chunk. So, we don't need dont_fragment, and bitmap_to_extents() interface become

[PULL v2 09/11] nbd/server: introduce NBDExtentArray

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Introduce NBDExtentArray class, to handle extents list creation in more controlled way and with fewer OUT parameters in functions. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Eric Blake Message-id: 20200205112041.6003-9-vsement...@virtuozzo.com S

[PULL v2 11/11] block/qcow2-bitmap: use bdrv_dirty_bitmap_next_dirty

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy store_bitmap_data() loop does bdrv_set_dirty_iter() on each iteration, which means that we actually don't need iterator itself and we can use simpler bitmap API. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow Messag

[PULL v2 08/11] block/dirty-bitmap: improve _next_dirty_area API

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Firstly, _next_dirty_area is for scenarios when we may contiguously search for next dirty area inside some limited region, so it is more comfortable to specify "end" which should not be recalculated on each iteration. Secondly, let's add a possibility to limit

Re: [PATCH v10 01/16] s390x: Move diagnose 308 subcodes and rcs into ipl.h

2020-03-18 Thread Christian Borntraeger
On 18.03.20 15:30, Janosch Frank wrote: > They are part of the IPL process, so let's put them into the ipl > header. > > Signed-off-by: Janosch Frank Reviewed-by: Christian Borntraeger > --- > hw/s390x/ipl.h | 11 +++ > target/s390x/diag.c | 11 --- > 2 files changed, 1

[PULL v2 04/11] hbitmap: unpublish hbitmap_iter_skip_words

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Function is internal and even commented as internal. Drop its definition from .h file. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow Message-id: 20200205112041.6003-4-vsement...@virtuozzo.com Signed-off-by: John Sn

[PULL v2 06/11] block/dirty-bitmap: switch _next_dirty_area and _next_zero to int64_t

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy We are going to introduce bdrv_dirty_bitmap_next_dirty so that same variable may be used to store its return value and to be its parameter, so it would int64_t. Similarly, we are going to refactor hbitmap_next_dirty_area to use hbitmap_next_dirty together with

[PULL v2 01/11] build: Silence clang warning on older glib autoptr usage

2020-03-18 Thread John Snow
From: Eric Blake glib's G_DEFINE_AUTOPTR_CLEANUP_FUNC() macro defines several static inline functions, often with some of them unused, but prior to 2.57.2 did not mark the functions as such. As a result, clang (but not gcc) fails to build with older glib unless -Wno-unused-function is enabled.

[PULL v2 05/11] hbitmap: drop meta bitmaps as they are unused

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow Message-id: 20200205112041.6003-5-vsement...@virtuozzo.com Signed-off-by: John Snow --- include/qemu/hbitmap.h | 21 tests/test-hbitmap.c | 115 ---

[PULL v2 02/11] hbitmap: assert that we don't create bitmap larger than INT64_MAX

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy We have APIs which returns signed int64_t, to be able to return error. Therefore we can't handle bitmaps with absolute size larger than (INT64_MAX+1). Still, keep maximum to be INT64_MAX which is a bit safer. Note, that bitmaps are used to represent disk images

[PULL v2 07/11] block/dirty-bitmap: add _next_dirty API

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy We have bdrv_dirty_bitmap_next_zero, let's add corresponding bdrv_dirty_bitmap_next_dirty, which is more comfortable to use than bitmap iterators in some cases. For test modify test_hbitmap_next_zero_check_range to check both next_zero and next_dirty and add so

[PULL v2 03/11] hbitmap: move hbitmap_iter_next_word to hbitmap.c

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy The function is definitely internal (it's not used by third party and it has complicated interface). Move it to .c file. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow Message-id: 20200205112041.6003-3-vsement...@vi

Re: [PULL 0/4] Error reporting patches for 2020-03-17

2020-03-18 Thread Peter Maydell
On Tue, 17 Mar 2020 at 16:38, Markus Armbruster wrote: > > The following changes since commit 40c67636f67c2a89745f2e698522fe917326a952: > > Merge remote-tracking branch > 'remotes/kraxel/tags/usb-20200317-pull-request' into staging (2020-03-17 > 14:00:56 +) > > are available in the Git rep

[PULL v2 00/11] Bitmaps patches

2020-03-18 Thread John Snow
The following changes since commit d649689a8ecb2e276cc20d3af6d416e3c299cb17: Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging (2020-03-17 18:33:05 +) are available in the Git repository at: https://github.com/jnsnow/qemu.git tags/bitmaps-pull-request for yo

Re: [PULL v2 00/37] Linux user for 5.0 patches

2020-03-18 Thread Laurent Vivier
Le 18/03/2020 à 21:17, Richard Henderson a écrit : > On 3/18/20 12:58 PM, Laurent Vivier wrote: >>> However, from the error message above, it's clear that cpu_loop.o has not >>> been >>> rebuilt properly. >>> >> >> In the series merged here syscall_nr.h are moved from source directory >> to build

Re: [Bug 1743191] Re: Interacting with NetBSD serial console boot blocks no longer works

2020-03-18 Thread Ottavio Caruso
On Fri, 6 Mar 2020 at 13:24, Gerd Hoffmann <1743...@bugs.launchpad.net> wrote: > So one option is to turn off seabios sercon: "qemu -nographic -machine > graphics=on". This works for me, but only if I turn off "q35", therefore changing from a sata disk to a plain ide: qemu-system-x86_64 \ -drive

[PATCH v14 Kernel 5/7] vfio iommu: Update UNMAP_DMA ioctl to get dirty bitmap before unmap

2020-03-18 Thread Kirti Wankhede
DMA mapped pages, including those pinned by mdev vendor drivers, might get unpinned and unmapped while migration is active and device is still running. For example, in pre-copy phase while guest driver could access those pages, host device or vendor driver can dirty these mapped pages. Such pages s

[PATCH v14 Kernel 7/7] vfio: Selective dirty page tracking if IOMMU backed device pins pages

2020-03-18 Thread Kirti Wankhede
Added a check such that only singleton IOMMU groups can pin pages. >From the point when vendor driver pins any pages, consider IOMMU group dirty page scope to be limited to pinned pages. To optimize to avoid walking list often, added flag pinned_page_dirty_scope to indicate if all of the vfio_grou

Re: [PULL v2 00/37] Linux user for 5.0 patches

2020-03-18 Thread Richard Henderson
On 3/18/20 12:58 PM, Laurent Vivier wrote: >> However, from the error message above, it's clear that cpu_loop.o has not >> been >> rebuilt properly. >> > > In the series merged here syscall_nr.h are moved from source directory > to build directory. > > The include path of the files is based on t

[PATCH v14 Kernel 2/7] vfio iommu: Remove atomicity of ref_count of pinned pages

2020-03-18 Thread Kirti Wankhede
vfio_pfn.ref_count is always updated by holding iommu->lock, using atomic variable is overkill. Signed-off-by: Kirti Wankhede Reviewed-by: Neo Jia --- drivers/vfio/vfio_iommu_type1.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/vfio/vfio_iommu_type1.c b/d

[PATCH v14 Kernel 6/7] vfio iommu: Adds flag to indicate dirty pages tracking capability support

2020-03-18 Thread Kirti Wankhede
Flag VFIO_IOMMU_INFO_DIRTY_PGS in VFIO_IOMMU_GET_INFO indicates that driver support dirty pages tracking. Signed-off-by: Kirti Wankhede Reviewed-by: Neo Jia --- drivers/vfio/vfio_iommu_type1.c | 3 ++- include/uapi/linux/vfio.h | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-)

[PATCH v14 Kernel 4/7] vfio iommu: Implementation of ioctl for dirty pages tracking.

2020-03-18 Thread Kirti Wankhede
VFIO_IOMMU_DIRTY_PAGES ioctl performs three operations: - Start dirty pages tracking while migration is active - Stop dirty pages tracking. - Get dirty pages bitmap. Its user space application's responsibility to copy content of dirty pages from source to destination during migration. To prevent

[PATCH v14 Kernel 1/7] vfio: KABI for migration interface for device state

2020-03-18 Thread Kirti Wankhede
- Defined MIGRATION region type and sub-type. - Defined vfio_device_migration_info structure which will be placed at the 0th offset of migration region to get/set VFIO device related information. Defined members of structure and usage on read/write access. - Defined device states and state tr

[PATCH v14 Kernel 3/7] vfio iommu: Add ioctl definition for dirty pages tracking.

2020-03-18 Thread Kirti Wankhede
IOMMU container maintains a list of all pages pinned by vfio_pin_pages API. All pages pinned by vendor driver through this API should be considered as dirty during migration. When container consists of IOMMU capable device and all pages are pinned and mapped, then all pages are marked dirty. Added

[PATCH v14 Kernel 0/7] KABIs to support migration for VFIO devices

2020-03-18 Thread Kirti Wankhede
QEMU patch set to understand KABI changes done till now v13 -> v14 - Added struct vfio_bitmap to kabi. updated structure vfio_iommu_type1_dirty_bitmap_get and vfio_iommu_type1_dma_unmap. - All small changes suggested by Alex. - Patches are on tag: next-20200318 and 1-3 patches from Yan'

[PATCH v3] block/nvme: introduce PMR support from NVMe 1.4 spec

2020-03-18 Thread Andrzej Jakowski
This patch introduces support for PMR that has been defined as part of NVMe 1.4 spec. User can now specify a pmrdev option that should point to HostMemoryBackend. pmrdev memory region will subsequently be exposed as PCI BAR 2 in emulated NVMe device. Guest OS can perform mmio read and writes to th

Re: [PULL v2 00/37] Linux user for 5.0 patches

2020-03-18 Thread Laurent Vivier
Le 18/03/2020 à 20:46, Richard Henderson a écrit : > On 3/18/20 6:57 AM, Peter Maydell wrote: >> My set of "run ls for various architectures" linux-user tests >> https://people.linaro.org/~peter.maydell/linux-user-test-pmm-20200114.tgz >> fails with this pullreq: >> >> e104462:bionic:linux-user-tes

Re: [PATCH v2 1/1] target/ppc: don't byte swap ELFv2 signal handler

2020-03-18 Thread Richard Henderson
On 3/18/20 10:01 AM, Vincent Fazio wrote: > From: Vincent Fazio > > Previously, the signal handler would be byte swapped if the target and > host CPU used different endianness. This would cause a SIGSEGV when > attempting to translate the opcode pointed to by the swapped address. > > Thread 1 "

Re: Qemu API documentation

2020-03-18 Thread John Snow
On 3/18/20 7:09 AM, Peter Maydell wrote: > On Wed, 18 Mar 2020 at 09:55, Priyamvad Acharya > wrote: >> >> Hello developer community, >> >> I am working on implementing a custom device in Qemu, so to implement it I >> need documentation of functions which are used to emulate a hardware model >

Re: Missing Null check

2020-03-18 Thread Mansour Ahmadi
Thanks for the fix! Best, Mansour On Wed, Mar 18, 2020 at 4:14 AM Philippe Mathieu-Daudé wrote: > On 3/17/20 9:40 PM, Mansour Ahmadi wrote: > > Is a NULL check on 'drv1->format_name' missing here? > > > https://github.com/qemu/qemu/blob/cc818a2148c5f321bdeb8e5564bdb2914e824600/block.c#L400-L40

Re: [PULL v2 00/37] Linux user for 5.0 patches

2020-03-18 Thread Richard Henderson
On 3/18/20 6:57 AM, Peter Maydell wrote: > My set of "run ls for various architectures" linux-user tests > https://people.linaro.org/~peter.maydell/linux-user-test-pmm-20200114.tgz > fails with this pullreq: > > e104462:bionic:linux-user-test-0.3$ > /home/petmay01/linaro/qemu-for-merges/build/all-

[Bug 1866870] Re: KVM Guest pauses after upgrade to Ubuntu 20.04

2020-03-18 Thread Christian Ehrhardt 
I've tested smoe more cmbinations and found that I van have v4.2 work on focal. Eventually I have realized that when I install start the qemu from Ubuntu not only that but also the formerly working build of v4.2.0 from git start to fail (without rebuilding). A bit of package bisect later I found

[Bug 1867786] Re: Qemu PPC64 freezes with multi-core CPU

2020-03-18 Thread carlosedp
Hi Laurent, I'm on a MacOS Mojave running Qemu installed by homebrew from master branch on the day I've opened the bug. The option to install was: `brew install --HEAD qemu -s --verbose`. Maybe it's a Mac related problem? -- You received this bug notification because you are a member of qemu- d

Re: [PATCH 04/11] MAINTAINERS: Add an entry for the HVF accelerator

2020-03-18 Thread Cameron Esfahani via
Please add me to the HVF maintainers as well. Cameron Esfahani di...@apple.com "In the elder days of Art, Builders wrought with greatest care each minute and unseen part; For the gods see everywhere." "The Builders", H. W. Longfellow > On Mar 16, 2020, at 5:00 AM, Philippe Mathieu-Daudé wro

  1   2   3   >