[PATCH v5 00/15] cpu: Introduce SysemuCPUOps structure

2021-04-22 Thread Philippe Mathieu-Daudé
Missing review: patch #7 Hi, This series is inspired on Claudio TCG work. Instead of separate TCG from other accelerators, here we separate sysemu operations (system VS user). Patches 1-5 are generic cleanups. Patches 6-14 move from CPUClass to SysemuCPUOps Patch 15 restricts SysemuCPUOps to

[PATCH v5 02/15] cpu: Introduce cpu_virtio_is_big_endian()

2021-04-22 Thread Philippe Mathieu-Daudé
Introduce the cpu_virtio_is_big_endian() generic helper to avoid calling CPUClass internal virtio_is_big_endian() one. Similarly to commit bf7663c4bd8 ("cpu: introduce CPUClass::virtio_is_big_endian()"), we keep 'virtio' in the method name to hint this handler shouldn't be called anywhere but from

[PATCH v5 01/15] cpu: Un-inline cpu_get_phys_page_debug and cpu_asidx_from_attrs

2021-04-22 Thread Philippe Mathieu-Daudé
To be able to later extract the cpu_get_phys_page_debug() and cpu_asidx_from_attrs() handlers from CPUClass, un-inline them from "hw/core/cpu.h". Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- include/hw/core/cpu.h | 33 - hw/core/cpu.c

[PATCH v5 11/15] cpu: Move CPUClass::asidx_from_attrs to SysemuCPUOps

2021-04-22 Thread Philippe Mathieu-Daudé
Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- include/hw/core/cpu.h| 3 --- include/hw/core/sysemu-cpu-ops.h | 5 + hw/core/cpu.c| 4 ++-- target/arm/cpu.c | 2 +- target/i386/cpu.c| 2 +- 5 files chan

[PATCH v5 04/15] cpu: Directly use get_paging_enabled() fallback handlers in place

2021-04-22 Thread Philippe Mathieu-Daudé
No code uses CPUClass::get_paging_enabled() outside of hw/core/cpu.c: $ git grep -F -- '->get_paging_enabled' hw/core/cpu.c:74:return cc->get_paging_enabled(cpu); hw/core/cpu.c:438:k->get_paging_enabled = cpu_common_get_paging_enabled; target/i386/cpu.c:7418:cc->get_paging_enab

[PATCH v5 10/15] cpu: Move CPUClass::write_elf* to SysemuCPUOps

2021-04-22 Thread Philippe Mathieu-Daudé
The write_elf*() handlers are used to dump vmcore images. This feature is only meaningful for system emulation. Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- v4: Added target/riscv/cpu.c after rebasing --- include/hw/core/cpu.h| 17 - inclu

[PATCH v5 03/15] cpu: Directly use cpu_write_elf*() fallback handlers in place

2021-04-22 Thread Philippe Mathieu-Daudé
No code directly accesses CPUClass::write_elf*() handlers out of hw/core/cpu.c (the rest are assignation in target/ code): $ git grep -F -- '->write_elf' hw/core/cpu.c:157:return (*cc->write_elf32_qemunote)(f, cpu, opaque); hw/core/cpu.c:171:return (*cc->write_elf32_note)(f, cpu, cpu

[PATCH v5 13/15] cpu: Move CPUClass::get_memory_mapping to SysemuCPUOps

2021-04-22 Thread Philippe Mathieu-Daudé
Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- include/hw/core/cpu.h| 3 --- include/hw/core/sysemu-cpu-ops.h | 5 + hw/core/cpu.c| 4 ++-- target/i386/cpu.c| 2 +- 4 files changed, 8 insertions(+), 6 deletions(-) dif

[PATCH v5 07/15] cpu: Move CPUClass::vmsd to SysemuCPUOps

2021-04-22 Thread Philippe Mathieu-Daudé
Migration is specific to system emulation. - Move the CPUClass::vmsd field to SysemuCPUOps, - restrict VMSTATE_CPU() macro to sysemu, - vmstate_dummy is now unused, remove it. Signed-off-by: Philippe Mathieu-Daudé --- Since v3: Merged in patch 1 (Eduardo) therefore removed Richard R-b. 'vmsd' i

[PATCH v5 05/15] cpu: Directly use get_memory_mapping() fallback handlers in place

2021-04-22 Thread Philippe Mathieu-Daudé
No code uses CPUClass::get_memory_mapping() outside of hw/core/cpu.c: $ git grep -F -- '->get_memory_mapping' hw/core/cpu.c:87:cc->get_memory_mapping(cpu, list, errp); hw/core/cpu.c:439:k->get_memory_mapping = cpu_common_get_memory_mapping; target/i386/cpu.c:7422:cc->get_memory

[PATCH v5 14/15] cpu: Move CPUClass::get_paging_enabled to SysemuCPUOps

2021-04-22 Thread Philippe Mathieu-Daudé
Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- include/hw/core/cpu.h| 2 -- include/hw/core/sysemu-cpu-ops.h | 4 hw/core/cpu.c| 4 ++-- target/i386/cpu.c| 4 +++- 4 files changed, 9 insertions(+), 5 deletions(-) dif

[PATCH v5 08/15] cpu: Move CPUClass::virtio_is_big_endian to SysemuCPUOps

2021-04-22 Thread Philippe Mathieu-Daudé
VirtIO devices are only meaningful with system emulation. Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- include/hw/core/cpu.h| 5 - include/hw/core/sysemu-cpu-ops.h | 8 hw/core/cpu.c| 4 ++-- target/arm/cpu.c

[PATCH v5 06/15] cpu: Introduce SysemuCPUOps structure

2021-04-22 Thread Philippe Mathieu-Daudé
Introduce a structure to hold handler specific to sysemu. Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- include/hw/core/cpu.h| 5 + include/hw/core/sysemu-cpu-ops.h | 21 + target/alpha/cpu.c | 6 ++ target/arm/c

[PATCH v5 15/15] cpu: Restrict "hw/core/sysemu-cpu-ops.h" to target/cpu.c

2021-04-22 Thread Philippe Mathieu-Daudé
Somehow similar to commit 78271684719 ("cpu: tcg_ops: move to tcg-cpu-ops.h, keep a pointer in CPUClass"): We cannot in principle make the SysEmu Operations field definitions conditional on CONFIG_SOFTMMU in code that is included by both common_ss and specific_ss modules. Therefore, what we can d

[PATCH v5 09/15] cpu: Move CPUClass::get_crash_info to SysemuCPUOps

2021-04-22 Thread Philippe Mathieu-Daudé
cpu_get_crash_info() is called on GUEST_PANICKED events, which only occur in system emulation. Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- include/hw/core/cpu.h| 1 - include/hw/core/sysemu-cpu-ops.h | 5 + hw/core/cpu.c| 4 ++--

[Bug 1916269] Re: TCG: QEMU raises exception on SSE4.2 CRC32 instruction in kernel

2021-04-22 Thread Alexander Richardson
Could someone familiar with the target/i386 decode logic could have a look at this? It should be a rather simple change to avoid the exception for the crc32 encoding. However, I am not familiar with x86 instruction encodings so it would take me a long time to come up with a correct patch. Thanks

[PATCH v5 12/15] cpu: Move CPUClass::get_phys_page_debug to SysemuCPUOps

2021-04-22 Thread Philippe Mathieu-Daudé
Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- include/hw/core/cpu.h| 8 include/hw/core/sysemu-cpu-ops.h | 13 + hw/core/cpu.c| 6 +++--- target/alpha/cpu.c | 2 +- target/arm/cpu.c |

Re: [PATCH v3 01/27] target: Set CPUClass::vmsd instead of DeviceClass::vmsd

2021-04-22 Thread Philippe Mathieu-Daudé
On 4/22/21 12:28 PM, Peter Maydell wrote: > On Thu, 22 Apr 2021 at 10:55, Philippe Mathieu-Daudé wrote: >> My guess is CPUState is the only device used in user emulation, >> so it would be a way to restrict the vmstate_dummy to CPU and >> not to any DeviceState? >> >> But looking at the introducto

Re: [PATCH v5 07/15] cpu: Move CPUClass::vmsd to SysemuCPUOps

2021-04-22 Thread Philippe Mathieu-Daudé
On 4/22/21 12:46 PM, Philippe Mathieu-Daudé wrote: > Migration is specific to system emulation. > > - Move the CPUClass::vmsd field to SysemuCPUOps, > - restrict VMSTATE_CPU() macro to sysemu, > - vmstate_dummy is now unused, remove it. > > Signed-off-by: Philippe Mathieu-Daudé > --- > Since v3:

[Bug 1920752] Re: USB SoundCard Passthrough not working on arm64

2021-04-22 Thread Ravishankar
Hello, You can close this bug as as a simple usb-audio switch is working fine for me: I just added -device usb-audio and set the -device nec-usb-xhci and sound within the qemu is working fine.. qemu-system-aarch64 -M virt -m 2048 -smp 2 -cpu host,aarch64=off -enable-kvm -kernel vmlinuz-4.19.0-14

[Bug 1721788] Re: Failed to get shared "write" lock with 'qemu-img info'

2021-04-22 Thread Max Reitz
Hi, What exactly is the problem now? As Eric explained in comment 3, "qemu- img info -U" is what needs to be used here. Daniel raised the problem of --force-share/-U being undocumented, but that’s no longer the case as of commit a7e326df1c116e99e, which was first included in the 2.12.0 release.

[Bug 1833661] Re: Linux kernel oops on Malta board while accessing pflash

2021-04-22 Thread Philippe Mathieu-Daudé
** Changed in: qemu Status: Incomplete => Confirmed -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1833661 Title: Linux kernel oops on Malta board while accessing pflash Status in QEMU: Co

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

2021-04-22 Thread Philippe Mathieu-Daudé
** Changed in: qemu Status: Incomplete => New ** Changed in: qemu Status: New => Confirmed -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1835865 Title: piix crashes on mips when acce

Re: s390-ccw: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]

2021-04-22 Thread Philippe Mathieu-Daudé
On 4/22/21 12:30 PM, Peter Maydell wrote: > On Thu, 22 Apr 2021 at 11:18, Daniel P. Berrangé wrote: >> >> On Thu, Apr 22, 2021 at 06:47:30AM +0200, Thomas Huth wrote: >>> On 22/04/2021 06.18, Philippe Mathieu-Daudé wrote: Hi Thomas, Daniel, Stefano, Regarding the following warning (

[Bug 1563931] Re: qemu-img should allow resizing image with snapshots

2021-04-22 Thread Max Reitz
Implemented in 7fa140abf69675b7b83af32de. Note that every internal snapshot has a disk size associated with it, though, so applying a snapshot from when the image had a different size means the image size will be reverted to what it was as the time of the snapshot. ** Changed in: qemu Stat

[PATCH 0/2] tests/docker: tests/tcg/ppc64le: Newer toolchain to build tests for PowerISA v3.1 instructions

2021-04-22 Thread matheus . ferst
From: Matheus Ferst This series adds gcc-10 based images to enable the build of tests with Power10 instructions. Then, to put it to good use, a tests for the byte-reverse instructions (implemented in 9d69cfa2faa7) is introduced. v2: - Unused images removed from tests/docker/Makefile.include, t

[PATCH v2 1/2] tests/docker: gcc-10 based images for ppc64{, le} tests

2021-04-22 Thread matheus . ferst
From: Matheus Ferst A newer compiler is needed to build tests for Power10 instructions. As done for arm64 on c729a99d2701, a new '-test-cross' image is created for ppc64 and ppc64le. As done on 936fda4d771f, a test for compiler support is added to verify that the toolchain in use has '-mpower10'.

[PATCH v2 2/2] tests/tcg/ppc64le: tests for brh/brw/brd

2021-04-22 Thread matheus . ferst
From: Matheus Ferst Tests for Byte-Reverse Halfword, Word and Doubleword Signed-off-by: Matheus Ferst --- tests/tcg/ppc64/Makefile.target | 7 +++ tests/tcg/ppc64le/Makefile.target | 7 +++ tests/tcg/ppc64le/byte_reverse.c | 21 + 3 files changed, 35 insertions

Re: s390-ccw: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]

2021-04-22 Thread Thomas Huth
On 22/04/2021 13.24, Philippe Mathieu-Daudé wrote: On 4/22/21 12:30 PM, Peter Maydell wrote: On Thu, 22 Apr 2021 at 11:18, Daniel P. Berrangé wrote: On Thu, Apr 22, 2021 at 06:47:30AM +0200, Thomas Huth wrote: On 22/04/2021 06.18, Philippe Mathieu-Daudé wrote: Hi Thomas, Daniel, Stefano, R

Re: s390-ccw: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]

2021-04-22 Thread Daniel P . Berrangé
On Thu, Apr 22, 2021 at 01:24:30PM +0200, Philippe Mathieu-Daudé wrote: > This silents the warning however: > > -- >8 -- > diff --git a/pc-bios/s390-ccw/libc.h b/pc-bios/s390-ccw/libc.h > index bcdc45732d..2dea399904 100644 > --- a/pc-bios/s390-ccw/libc.h > +++ b/pc-bios/s390-ccw/libc.h > @@ -19,6

[RFC v3 02/13] hw/s390x: only build tod-tcg from the CONFIG_TCG build

2021-04-22 Thread Claudio Fontana
this will allow in later patches to remove unneeded stubs in target/s390x. Signed-off-by: Claudio Fontana Reviewed-by: David Hildenbrand --- hw/s390x/meson.build | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/hw/s390x/meson.build b/hw/s390x/meson.build index 02e81a9467..

[RFC v3 01/13] hw/s390x: rename tod-qemu.c to tod-tcg.c

2021-04-22 Thread Claudio Fontana
we stop short of renaming the actual qom object though, so type remains TYPE_QEMU_S390_TOD, ie "s390-tod-qemu". Signed-off-by: Claudio Fontana --- hw/s390x/{tod-qemu.c => tod-tcg.c} | 0 hw/s390x/meson.build | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) rename hw/s390x/{t

[RFC v3 04/13] target/s390x: remove tcg-stub.c

2021-04-22 Thread Claudio Fontana
now that we protect all calls to the tcg-specific functions with if (tcg_enabled()), we do not need the TCG stub anymore. Signed-off-by: Claudio Fontana Reviewed-by: David Hildenbrand --- target/s390x/tcg-stub.c | 30 -- target/s390x/meson.build | 2 +- 2 files cha

[RFC v3 07/13] target/s390x: split cpu-dump from helper.c

2021-04-22 Thread Claudio Fontana
Signed-off-by: Claudio Fontana --- target/s390x/cpu-dump.c | 131 +++ target/s390x/helper.c| 107 target/s390x/meson.build | 1 + 3 files changed, 132 insertions(+), 107 deletions(-) create mode 100644 target/s390x/cpu-d

[RFC v3 03/13] hw/s390x: tod: make explicit checks for accelerators when initializing

2021-04-22 Thread Claudio Fontana
replace general "else" with specific checks for each possible accelerator. Handle qtest as a NOP, and error out for an unknown accelerator used in combination with tod. Signed-off-by: Claudio Fontana Reviewed-by: David Hildenbrand --- hw/s390x/tod.c | 9 - 1 file changed, 8 insertions(

[RFC v3 08/13] target/s390x: make helper.c sysemu-only

2021-04-22 Thread Claudio Fontana
Now that we have moved cpu-dump functionality out of helper.c, we can make the module sysemu-only. Signed-off-by: Claudio Fontana --- target/s390x/helper.c| 4 target/s390x/meson.build | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/target/s390x/helper.c b/target/s

[RFC v3 05/13] target/s390x: start moving TCG-only code to tcg/

2021-04-22 Thread Claudio Fontana
move everything related to translate, as well as HELPER code in tcg/ mmu_helper.c stays put for now, as it contains both TCG and KVM code. The internal.h file is renamed to s390x-internal.h, because of the risk of collision with other files with the same name. Signed-off-by: Claudio Fontana ---

[RFC v3 00/13] s390x cleanup

2021-04-22 Thread Claudio Fontana
Hi, this is the next version of a cleanup series for s390x. v2 -> v3: minor changes * "hw/s390x: rename tod-qemu.c to tod-tcg.c": move to the front (David) * "hw/s390x: only build tod-qemu from the CONFIG_TCG build" - move just after, use "tod-tcg" instead * "hw/s390x: tod: make explicit che

[RFC v3 06/13] target/s390x: move sysemu-only code out to cpu-sysemu.c

2021-04-22 Thread Claudio Fontana
Signed-off-by: Claudio Fontana --- target/s390x/s390x-internal.h | 6 + target/s390x/cpu-sysemu.c | 304 ++ target/s390x/cpu.c| 283 ++- target/s390x/meson.build | 1 + target/s390x/trace-events | 2 +- 5 f

[RFC v3 11/13] target/s390x: move kvm files into kvm/

2021-04-22 Thread Claudio Fontana
Signed-off-by: Claudio Fontana --- meson.build| 1 + target/s390x/{ => kvm}/kvm_s390x.h | 0 target/s390x/kvm/trace.h | 1 + hw/intc/s390_flic_kvm.c| 2 +- hw/s390x/s390-stattrib-kvm.c | 2 +- hw/s390x/tod-kvm.c | 2 +- hw/

[RFC v3 09/13] target/s390x: use kvm_enabled() to wrap call to kvm_s390_get_hpage_1m

2021-04-22 Thread Claudio Fontana
this will allow to remove the kvm stubs. Signed-off-by: Claudio Fontana --- target/s390x/diag.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/target/s390x/diag.c b/target/s390x/diag.c index 86b7032b5b..311e22b4ea 100644 --- a/target/s390x/diag.c +++ b/target/s390x/diag.c

[RFC v3 10/13] target/s390x: remove kvm-stub.c

2021-04-22 Thread Claudio Fontana
all function calls are protected by kvm_enabled(), so we should not need the stubs. Signed-off-by: Claudio Fontana --- target/s390x/kvm-stub.c | 126 --- target/s390x/meson.build | 2 +- 2 files changed, 1 insertion(+), 127 deletions(-) delete mode 100644

[RFC v3 13/13] MAINTAINERS: update s390x directories

2021-04-22 Thread Claudio Fontana
After the reshuffling, update MAINTAINERS accordingly. Make use of the new directories: target/s390x/kvm/ target/s390x/tcg/ Signed-off-by: Claudio Fontana --- MAINTAINERS | 8 +++- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index 7de873c9f5..3d73

[RFC v3 12/13] target/s390x: split sysemu part of cpu models

2021-04-22 Thread Claudio Fontana
also create a tiny _user.c with just the (at least for now), empty implementation of apply_cpu_model. Signed-off-by: Claudio Fontana --- target/s390x/s390x-internal.h| 2 + target/s390x/cpu_models.c| 417 +- target/s390x/cpu_models_sysemu.c | 426 +++

Re: [PATCH v2 1/7] tests/acceptance: Automatic set -cpu to the test vm

2021-04-22 Thread Cleber Rosa
On Thu, Apr 08, 2021 at 04:52:31PM -0300, Wainer dos Santos Moschetta wrote: > This introduces a new feature to the functional tests: automatic setting of > the '-cpu VALUE' option to the created vm if the test is tagged with > 'cpu:VALUE'. The 'cpu' property is made available to the test object as

Re: [PATCH v2 0/7] tests/acceptance: Handle tests with "cpu" tag

2021-04-22 Thread Cleber Rosa
On Thu, Apr 08, 2021 at 04:52:30PM -0300, Wainer dos Santos Moschetta wrote: > Currently the acceptance tests tagged with "machine" have the "-M TYPE" > automatically added to the list of arguments of the QEMUMachine object. > In other words, that option is passed to the launched QEMU. On this > se

Re: [PATCH v2 2/7] tests/acceptance: Fix mismatch on cpu tagged tests

2021-04-22 Thread Cleber Rosa
On Thu, Apr 08, 2021 at 04:52:32PM -0300, Wainer dos Santos Moschetta wrote: > There are test cases on machine_mips_malta.py and tcg_plugins.py files > where the cpu tag does not correspond to the value actually given to the QEMU > binary. This fixed those tests tags. > > Signed-off-by: Wainer dos

Re: [PATCH v2 3/7] tests/acceptance: Let the framework handle "cpu:VALUE" tagged tests

2021-04-22 Thread Cleber Rosa
On Thu, Apr 08, 2021 at 04:52:33PM -0300, Wainer dos Santos Moschetta wrote: > The tests that are already tagged with "cpu:VALUE" don't need to add > "-cpu VALUE" to the list of arguments of the vm object because the > avocado_qemu > framework is able to handle it automatically. > > Signed-off-by

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

2021-04-22 Thread Paul Goyette
This bug was fixed long ago, so long ago that I have no idea when! Please close wiwth an appropriate status. On Thu, 22 Apr 2021, Thomas Huth wrote: > The QEMU project is currently considering to move its bug tracking to > another system. For this we need to know which bugs are still valid > an

Re: [PATCH v2 6/7] tests/acceptance: Add set_vm_arg() to the Test class

2021-04-22 Thread Cleber Rosa
On Thu, Apr 08, 2021 at 04:52:36PM -0300, Wainer dos Santos Moschetta wrote: > The set_vm_arg method is added to avocado_qemu.Test class on this > change. Use that method to set (or replace) an argument to the list of > arguments given to the QEMU binary. > > Suggested-by: Cleber Rosa > Signed-of

Re: [PATCH v2 7/7] tests/acceptance: Handle cpu tag on x86_cpu_model_versions tests

2021-04-22 Thread Cleber Rosa
On Thu, Apr 08, 2021 at 04:52:37PM -0300, Wainer dos Santos Moschetta wrote: > Some test cases on x86_cpu_model_versions.py are corner cases because they > need to pass extra options to the -cpu argument. Once the avocado_qemu > framework will set -cpu automatically, the value should be reset. This

Re: [PATCH v2 4/7] tests/acceptance: Tagging tests with "cpu:VALUE"

2021-04-22 Thread Cleber Rosa
On Thu, Apr 08, 2021 at 04:52:34PM -0300, Wainer dos Santos Moschetta wrote: > The existing tests which are passing "-cpu VALUE" argument to the vm object > are now properly "cpu:VALUE" tagged, so letting the avocado_qemu framework to > handle that automatically. > > Signed-off-by: Wainer dos Sant

Re: [PATCH v2 5/7] python/qemu: Add args property to the QEMUMachine class

2021-04-22 Thread Cleber Rosa
On Thu, Apr 08, 2021 at 04:52:35PM -0300, Wainer dos Santos Moschetta wrote: > This added the args property to QEMUMachine so that users of the class > can access and handle the list of arguments to be given to the QEMU > binary. > > Signed-off-by: Wainer dos Santos Moschetta > --- > python/qemu

[Bug 1580459] Re: Windows (10?) guest freezes entire host on shutdown if using PCI passthrough

2021-04-22 Thread Jimi
My hardware and the way I run my VM are both now very different from back then, and I haven't had the issue described here for years. So either it was fixed or I'm no longer an accurate test subject. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscr

Re: [PATCH v4 0/2] Fix segfault in qemu_rbd_parse_filename

2021-04-22 Thread Max Reitz
On 21.04.21 23:23, Connor Kuehl wrote: Connor Kuehl (2): iotests/231: Update expected deprecation message block/rbd: Add an escape-aware strchr helper block/rbd.c| 32 +--- tests/qemu-iotests/231 | 4 tests/qemu-iotests/231.out | 7

RE: [PATCH 1/4] target/ppc: Code motion required to build disabling tcg

2021-04-22 Thread Bruno Piazera Larsen
> > You are correct! I've just tweaked the code that defines spr_register and > > it should be working now. I'm still working in splitting the SPR functions > > from translate_init, since I think it would make it easier to prepare the > > !TCG case and for adding new architectures in the future, an

[Bug 1925496] [NEW] nvme disk cannot be hotplugged after removal

2021-04-22 Thread Oguz Bektas
Public bug reported: Hello, When I try to re-add an nvme disk shortly after removing it, I get an error about duplicate ID. See the following commands to reproduce. This happens consistently on all VMs that I tested: attach == $VAR1 = { 'arguments' => {

Re: s390-ccw: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]

2021-04-22 Thread Christian Borntraeger
On 22.04.21 13:47, Thomas Huth wrote: On 22/04/2021 13.24, Philippe Mathieu-Daudé wrote: On 4/22/21 12:30 PM, Peter Maydell wrote: On Thu, 22 Apr 2021 at 11:18, Daniel P. Berrangé wrote: On Thu, Apr 22, 2021 at 06:47:30AM +0200, Thomas Huth wrote: On 22/04/2021 06.18, Philippe Mathieu-Da

[Bug 1925496] Re: nvme disk cannot be hotplugged after removal

2021-04-22 Thread Klaus Jensen
Hi, What QEMU version is this happening on? Is this the -rc4, is it a regression? -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1925496 Title: nvme disk cannot be hotplugged after removal Status

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

2021-04-22 Thread Andreas Gustafsson
Paul Goyette wrote: > This bug was fixed long ago, so long ago that I have no idea when! No, it is not fixed, and I did actually check before I switched the bug state back to "new". Perhaps you are specifying "-machine graphics=on" as suggested in one of the comments? If so, that's a work-around

[PATCH qemu v19] spapr: Implement Open Firmware client interface

2021-04-22 Thread Alexey Kardashevskiy
The PAPR platform describes an OS environment that's presented by a combination of a hypervisor and firmware. The features it specifies require collaboration between the firmware and the hypervisor. Since the beginning, the runtime component of the firmware (RTAS) has been implemented as a 20 byte

Re: [PATCH] monitor: hmp_qemu_io: acquire aio contex, fix crash

2021-04-22 Thread Max Reitz
On 21.04.21 10:32, Vladimir Sementsov-Ogievskiy wrote: Max reported the following bug: $ ./qemu-img create -f raw src.img 1G $ ./qemu-img create -f raw dst.img 1G $ (echo ' {"execute":"qmp_capabilities"} {"execute":"blockdev-mirror", "arguments":{"job-id":"mirror",

Re: Resetting non-qdev children in a 3-phase reset device

2021-04-22 Thread Markus Armbruster
Peter Maydell writes: > On Sun, 18 Apr 2021 at 21:16, Philippe Mathieu-Daudé wrote: >> >> +Markus >> >> On 4/9/21 8:13 PM, Peter Maydell wrote: >> > Maybe some mechanism for marking "these things which are my >> > QOM children I want to be reset when I am reset (so make them >> > reset children

[Bug 1925496] Re: nvme disk cannot be hotplugged after removal

2021-04-22 Thread Oguz Bektas
Hi, this is happening on qemu 5.2.0 -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1925496 Title: nvme disk cannot be hotplugged after removal Status in QEMU: New Bug description: Hello, W

[PATCH for-6.0? 1/1] hw/block/nvme: fix invalid msix exclusive uninit

2021-04-22 Thread Klaus Jensen
From: Klaus Jensen Commit 1901b4967c3f changed the nvme device from using a bar exclusive for MSI-x to sharing it on bar0. Unfortunately, the msix_uninit_exclusive_bar() call remains in nvme_exit() which causes havoc when the device is removed with, say, device_del. Fix this. Fixes: 1901b4967c

[PATCH for-6.0? 0/1] hw/block/nvme: fix msix uninit

2021-04-22 Thread Klaus Jensen
From: Klaus Jensen Hi Peter, The commit message on the patch describes the issue. This is a QEMU crashing bug in -rc4 that I introduced early in the cycle and never found in time. Lack of testing device hotplugging is the cause for that. I'm not sure what to say other than I'm terribly sorry fo

[Bug 1925512] [NEW] UNDEFINED case for instruction BLX

2021-04-22 Thread JIANG Muhui
Public bug reported: Hi I refer to the instruction BLX imm (T2 encoding) in ARMv7 (Thumb mode). 0 S imm10H 11 J1 0 J2 imm10L H if H == '1' then UNDEFINED; I1 = NOT(J1 EOR S); I2 = NOT(J2 EOR S); imm32 = SignExtend(S:I1:I2:imm10H:imm10L:'00', 32); targetInstrSet = InstrSet_A32; if InITB

Re: [PATCH] monitor: hmp_qemu_io: acquire aio contex, fix crash

2021-04-22 Thread Vladimir Sementsov-Ogievskiy
22.04.2021 16:01, Max Reitz wrote: On 21.04.21 10:32, Vladimir Sementsov-Ogievskiy wrote: Max reported the following bug: $ ./qemu-img create -f raw src.img 1G $ ./qemu-img create -f raw dst.img 1G $ (echo '     {"execute":"qmp_capabilities"}     {"execute":"blockdev-mirror", "arguments":

Re: [PATCH for-6.0? 0/1] hw/block/nvme: fix msix uninit

2021-04-22 Thread Klaus Jensen
On Apr 22 15:58, Klaus Jensen wrote: From: Klaus Jensen Hi Peter, The commit message on the patch describes the issue. This is a QEMU crashing bug in -rc4 that I introduced early in the cycle and never found in time. Lack of testing device hotplugging is the cause for that. I'm not sure what

Re: [PATCH] docs: Add SEV-ES documentation to amd-memory-encryption.txt

2021-04-22 Thread Laszlo Ersek
On 04/21/21 21:31, Tom Lendacky wrote: > On 4/21/21 2:12 PM, Tom Lendacky wrote: >> From: Tom Lendacky >> >> Update the amd-memory-encryption.txt file with information about SEV-ES, >> including how to launch an SEV-ES guest and some of the differences >> between SEV and SEV-ES guests in regards t

Re: firmware selection for SEV-ES

2021-04-22 Thread Laszlo Ersek
On 04/21/21 13:51, Pavel Hrdina wrote: > On Wed, Apr 21, 2021 at 11:54:24AM +0200, Laszlo Ersek wrote: >> Hi Brijesh, Tom, >> >> in QEMU's "docs/interop/firmware.json", the @FirmwareFeature enumeration >> has a constant called @amd-sev. We should introduce an @amd-sev-es >> constant as well, minima

Re: firmware selection for SEV-ES

2021-04-22 Thread Laszlo Ersek
On 04/21/21 17:25, Tom Lendacky wrote: > On 4/21/21 4:54 AM, Laszlo Ersek wrote: >> Hi Brijesh, Tom, > > Hi Laszlo, > >> >> in QEMU's "docs/interop/firmware.json", the @FirmwareFeature enumeration >> has a constant called @amd-sev. We should introduce an @amd-sev-es >> constant as well, minimally

Re: Resetting non-qdev children in a 3-phase reset device

2021-04-22 Thread Philippe Mathieu-Daudé
On 4/22/21 3:21 PM, Markus Armbruster wrote: > Peter Maydell writes: > >> On Sun, 18 Apr 2021 at 21:16, Philippe Mathieu-Daudé wrote: >>> >>> +Markus >>> >>> On 4/9/21 8:13 PM, Peter Maydell wrote: Maybe some mechanism for marking "these things which are my QOM children I want to be re

[Bug 1925496] Re: nvme disk cannot be hotplugged after removal

2021-04-22 Thread Klaus Jensen
** Changed in: qemu Assignee: (unassigned) => Klaus Jensen (birkelund) ** Changed in: qemu Status: New => Confirmed -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1925496 Title: nvme di

Re: s390-ccw: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]

2021-04-22 Thread Philippe Mathieu-Daudé
On 4/22/21 2:41 PM, Christian Borntraeger wrote: > On 22.04.21 13:47, Thomas Huth wrote: >> On 22/04/2021 13.24, Philippe Mathieu-Daudé wrote: >>> On 4/22/21 12:30 PM, Peter Maydell wrote: On Thu, 22 Apr 2021 at 11:18, Daniel P. Berrangé wrote: >>> This silents the warning however: >>>

Re: s390-ccw: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]

2021-04-22 Thread Philippe Mathieu-Daudé
On 4/22/21 1:48 PM, Daniel P. Berrangé wrote: > On Thu, Apr 22, 2021 at 01:24:30PM +0200, Philippe Mathieu-Daudé wrote: >> This silents the warning however: >> >> -- >8 -- >> diff --git a/pc-bios/s390-ccw/libc.h b/pc-bios/s390-ccw/libc.h >> index bcdc45732d..2dea399904 100644 >> --- a/pc-bios/s390-

Re: [PATCH v3 0/8] qapi: static typing conversion, pt4

2021-04-22 Thread John Snow
On 4/22/21 4:09 AM, Markus Armbruster wrote: John Snow writes: Hi, this series adds static type hints to the QAPI module. This is part four, and focuses on error.py. Part 4: https://gitlab.com/jsnow/qemu/-/tree/python-qapi-cleanup-pt4 CI: https://gitlab.com/jsnow/qemu/-/pipelines/290152364 R

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

2021-04-22 Thread Ottavio Caruso
On Thu, 22 Apr 2021 at 13:46, Andreas Gustafsson <1743...@bugs.launchpad.net> wrote: > > Paul Goyette wrote: > > This bug was fixed long ago, so long ago that I have no idea when! > > No, it is not fixed, and I did actually check before I switched the > bug state back to "new". > > Perhaps you are

[Bug 1874676] Re: [Feature request] MDIO bus

2021-04-22 Thread Philippe Mathieu-Daudé
OK. Feel free to change the status to Won't Fix. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1874676 Title: [Feature request] MDIO bus Status in QEMU: Incomplete Bug description: Various ne

[PATCH 1/2] block/export: Free ignored Error

2021-04-22 Thread Max Reitz
When invoking block-export-add with some iothread and fixed-iothread=false, and changing the node's iothread fails, the error is supposed to be ignored. However, it is still stored in *errp, which is wrong. If a second error occurs, the "*errp must be NULL" assertion in error_setv() fails: qem

[PATCH 2/2] iotests/307: Test iothread conflict for exports

2021-04-22 Thread Max Reitz
Passing fixed-iothread=true should make iothread conflicts fatal, whereas fixed-iothread=false should not. Combine the second case with an error condition that is checked after the iothread is handled, to verify that qemu does not crash if there is such an error after changing the iothread failed.

[PATCH 0/2] block/export: Fix crash on error after iothread conflict

2021-04-22 Thread Max Reitz
Hi, By passing the @iothread option to block-export-add, the new export can be moved to the given iothread. This may conflict with an existing parent of the node in question. How this conflict is resolved, depends on @fixed-iothread: If that option is true, the error is fatal and block-export-ad

[PATCH] pc-bios/s390-ccw: Silence GCC 11 stringop-overflow warning

2021-04-22 Thread Philippe Mathieu-Daudé
When building on Fedora 34 (gcc version 11.0.0 20210210) we get: In file included from pc-bios/s390-ccw/main.c:11: In function ‘memset’, inlined from ‘boot_setup’ at pc-bios/s390-ccw/main.c:185:5, inlined from ‘main’ at pc-bios/s390-ccw/main.c:288:5: pc-bios/s390-ccw/libc.h:28:14

[Bug 1893040] Re: External modules retreval using Go1.15 on s390x appears to have checksum and ECDSA verification issues

2021-04-22 Thread Matt K
It's still an issue using qemu-6.0.0-rc4. If you remove the environment variable ENV GOPROXY="https://proxy.golang.org|direct" you get a different error: => ERROR [6/6] RUN go build .

Re: [PATCH] pc-bios/s390-ccw: Silence GCC 11 stringop-overflow warning

2021-04-22 Thread Christian Borntraeger
On 22.04.21 16:59, Philippe Mathieu-Daudé wrote: When building on Fedora 34 (gcc version 11.0.0 20210210) we get: In file included from pc-bios/s390-ccw/main.c:11: In function ‘memset’, inlined from ‘boot_setup’ at pc-bios/s390-ccw/main.c:185:5, inlined from ‘main’ at pc-bios

[Bug 1925512] Re: UNDEFINED case for instruction BLX

2021-04-22 Thread Philippe Mathieu-Daudé
** Tags added: arm tcg -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1925512 Title: UNDEFINED case for instruction BLX Status in QEMU: New Bug description: Hi I refer to the instruction BL

Re: s390-ccw: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]

2021-04-22 Thread Thomas Huth
On 22/04/2021 16.31, Philippe Mathieu-Daudé wrote: On 4/22/21 2:41 PM, Christian Borntraeger wrote: On 22.04.21 13:47, Thomas Huth wrote: On 22/04/2021 13.24, Philippe Mathieu-Daudé wrote: On 4/22/21 12:30 PM, Peter Maydell wrote: On Thu, 22 Apr 2021 at 11:18, Daniel P. Berrangé wrote: Th

Re: [PATCH] tcg/ppc: Fix building with Clang

2021-04-22 Thread Richard Henderson
On 4/22/21 2:20 AM, Peter Maydell wrote: On Thu, 22 Apr 2021 at 06:18, Richard Henderson I'm thinking something like #if !defined(_CALL_SYSV) && \ !defined(_CALL_DARWIN) && \ !defined(_CALL_AIX) && \ !defined(_CALL_ELF) # if defined(__APPLE__) # define _CALL_DARWIN # elif def

Re: [Virtio-fs] [PATCH v2 17/25] DAX/unmap: virtiofsd: Add VHOST_USER_SLAVE_FS_IO

2021-04-22 Thread Vivek Goyal
On Thu, Apr 22, 2021 at 10:29:08AM +0100, Dr. David Alan Gilbert wrote: > * Vivek Goyal (vgo...@redhat.com) wrote: > > On Wed, Apr 14, 2021 at 04:51:29PM +0100, Dr. David Alan Gilbert (git) > > wrote: > > > From: "Dr. David Alan Gilbert" > > > > > > Define a new slave command 'VHOST_USER_SLAVE_F

[Bug 1843795] Re: 'mtfsf' instruction can clear FI incorrectly

2021-04-22 Thread Paul Clarke
** Changed in: qemu Status: Incomplete => New -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1843795 Title: 'mtfsf' instruction can clear FI incorrectly Status in QEMU: New Bug descriptio

Re: [PATCH v3 01/27] target: Set CPUClass::vmsd instead of DeviceClass::vmsd

2021-04-22 Thread Philippe Mathieu-Daudé
On 4/22/21 1:01 PM, Philippe Mathieu-Daudé wrote: > On 4/22/21 12:28 PM, Peter Maydell wrote: >> On Thu, 22 Apr 2021 at 10:55, Philippe Mathieu-Daudé wrote: >>> My guess is CPUState is the only device used in user emulation, >>> so it would be a way to restrict the vmstate_dummy to CPU and >>> not

[PATCH] target/s390x: fix s390_probe_access to check PAGE_WRITE_ORG for writeability

2021-04-22 Thread Alex Bennée
We can remove PAGE_WRITE when (internally) marking a page read-only because it contains translated code. This can get confused when we are executing signal return code on signal stacks. Fixes: e56552cf07 ("target/s390x: Implement the MVPG condition-code-option bit") Found-by: Richard Henderson Si

Re: [PATCH for-6.0? 1/1] hw/block/nvme: fix invalid msix exclusive uninit

2021-04-22 Thread Klaus Jensen
On Apr 22 15:58, Klaus Jensen wrote: From: Klaus Jensen Commit 1901b4967c3f changed the nvme device from using a bar exclusive for MSI-x to sharing it on bar0. Unfortunately, the msix_uninit_exclusive_bar() call remains in nvme_exit() which causes havoc when the device is removed with, say, de

Re: s390-ccw: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]

2021-04-22 Thread Philippe Mathieu-Daudé
On 4/22/21 5:38 PM, Thomas Huth wrote: > On 22/04/2021 16.31, Philippe Mathieu-Daudé wrote: >> On 4/22/21 2:41 PM, Christian Borntraeger wrote: >>> On 22.04.21 13:47, Thomas Huth wrote: On 22/04/2021 13.24, Philippe Mathieu-Daudé wrote: > On 4/22/21 12:30 PM, Peter Maydell wrote: >> On

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

2021-04-22 Thread Paul Goyette
On Thu, 22 Apr 2021, Ottavio Caruso wrote: > On Thu, 22 Apr 2021 at 13:46, Andreas Gustafsson > <1743...@bugs.launchpad.net> wrote: >> >> Paul Goyette wrote: >>> This bug was fixed long ago, so long ago that I have no idea when! >> >> No, it is not fixed, and I did actually check before I switched

Re: [PATCH] target/mips: Remove spurious LOG_UNIMP of MTHC0 opcode

2021-04-22 Thread Richard Henderson
On 4/22/21 1:10 AM, Philippe Mathieu-Daudé wrote: When running with '-d unimp' all MTHC0 opcode executed are logged as unimplemented... Add the proper 'return' statement missed from commit 5204ea79ea7. Signed-off-by: Philippe Mathieu-Daudé --- target/mips/translate.c | 1 + 1 file changed, 1

Re: [Virtio-fs] [PATCH v2 17/25] DAX/unmap: virtiofsd: Add VHOST_USER_SLAVE_FS_IO

2021-04-22 Thread Dr. David Alan Gilbert
* Vivek Goyal (vgo...@redhat.com) wrote: > On Thu, Apr 22, 2021 at 10:29:08AM +0100, Dr. David Alan Gilbert wrote: > > * Vivek Goyal (vgo...@redhat.com) wrote: > > > On Wed, Apr 14, 2021 at 04:51:29PM +0100, Dr. David Alan Gilbert (git) > > > wrote: > > > > From: "Dr. David Alan Gilbert" > > > >

Re: s390-ccw: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]

2021-04-22 Thread Stefano Garzarella
On Thu, Apr 22, 2021 at 05:38:26PM +0200, Thomas Huth wrote: On 22/04/2021 16.31, Philippe Mathieu-Daudé wrote: On 4/22/21 2:41 PM, Christian Borntraeger wrote: On 22.04.21 13:47, Thomas Huth wrote: On 22/04/2021 13.24, Philippe Mathieu-Daudé wrote: On 4/22/21 12:30 PM, Peter Maydell wrote:

Re: [PATCH v3 01/27] target: Set CPUClass::vmsd instead of DeviceClass::vmsd

2021-04-22 Thread Peter Maydell
On Thu, 22 Apr 2021 at 16:41, Philippe Mathieu-Daudé wrote: > IOW new targets should use type 1. > > > Looking at type 2: > > a) targets added 'recently' with the incorrect type 2: > > target/avr/cpu.c:216:cc->vmsd = &vms_avr_cpu; > target/riscv/cpu.c:627:cc->vmsd = &vmstate_riscv_cpu; > >

Re: [PATCH v3 01/27] target: Set CPUClass::vmsd instead of DeviceClass::vmsd

2021-04-22 Thread Philippe Mathieu-Daudé
On 4/22/21 5:53 PM, Peter Maydell wrote: > On Thu, 22 Apr 2021 at 16:41, Philippe Mathieu-Daudé wrote: >> IOW new targets should use type 1. >> >> >> Looking at type 2: >> >> a) targets added 'recently' with the incorrect type 2: >> >> target/avr/cpu.c:216:cc->vmsd = &vms_avr_cpu; >> target/ri

<    1   2   3   4   >