Re: [PATCH v5 07/10] block: introduce preallocate filter

2020-08-25 Thread Vladimir Sementsov-Ogievskiy
25.08.2020 18:11, Max Reitz wrote: On 21.08.20 16:11, Vladimir Sementsov-Ogievskiy wrote: It's intended to be inserted between format and protocol nodes to preallocate additional space (expanding protocol file) on writes crossing EOF. It improves performance for file-systems with slow allocation

Re: [PATCH 3/4] meson: Mingw64 gcc doesn't recognize system include_type for sdl2

2020-08-25 Thread Paolo Bonzini
On Tue, Aug 25, 2020 at 11:38 PM Mark Cave-Ayland wrote: > Marc-André had a query about why this is marked as a system include, however > I can > confirm that it fixes the missing "SDL.h" issue during build. It was marked as a system include in an attempt to work around the SDL 2.0.8 bug that re

Re: [PATCH 2/4] meson: fixes relpath may fail on win32.

2020-08-25 Thread Paolo Bonzini
On Tue, Aug 25, 2020 at 11:31 PM Mark Cave-Ayland wrote: > On 25/08/2020 17:53, luoyongg...@gmail.com wrote: > > > From: Yonggang Luo > > > > On win32, os.path.relpath would raise exception when do the following > > relpath: > > C:/msys64/mingw64/x.exe relative to E:/path/qemu-build would fail.

Re: [PATCH 1/4] meson: Fixes the ninjatool issue that E$$: are generated in Makefile.ninja

2020-08-25 Thread Paolo Bonzini
On Tue, Aug 25, 2020 at 11:26 PM Mark Cave-Ayland wrote: > I've tested this and it changes build.ninja so instead of Windows paths > beginning C$$ > they now begin C$ instead e.g.: > > build qemu-version.h: CUSTOM_COMMAND | > C$:/msys64/home/Mark/qemu/scripts/qemu-version.sh PHONY The patch sho

Re: device compatibility interface for live migration with assigned devices

2020-08-25 Thread Yan Zhao
On Tue, Aug 25, 2020 at 04:39:25PM +0200, Cornelia Huck wrote: <...> > > do you think the bin_attribute I proposed yesterday good? > > Then we can have a single compatible with a variable in the mdev_type and > > aggregator. > > > >mdev_type=i915-GVTg_V5_{val1:int:2,4,8} > >aggregator={val

Re: [PATCH 00/12] fix some error memleaks

2020-08-25 Thread Pan Nengyuan
ping! On 2020/8/15 0:02, Pan Nengyuan wrote: > This series fix some Error/GError memleaks. > > Pan Nengyuan (12): > qga/channel-posix: Plug memory leak in ga_channel_write_all() > hw/vfio/ap: Plug memleak in vfio_ap_get_group() > elf2dmp/qemu_elf: Plug memleak in QEMU_Elf_init > elf2dmp/p

Re: [PATCH v5 06/10] block: introduce BDRV_REQ_NO_WAIT flag

2020-08-25 Thread Vladimir Sementsov-Ogievskiy
25.08.2020 16:10, Max Reitz wrote: On 21.08.20 16:11, Vladimir Sementsov-Ogievskiy wrote: Add flag to make serialising request no wait: if there are conflicting requests, just return error immediately. It's will be used in upcoming preallocate filter. Signed-off-by: Vladimir Sementsov-Ogievskiy

Re: [PATCH] disas/libvixl: Fix fall-through annotation for GCC >= 7

2020-08-25 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200824130114.41368-1-th...@redhat.com/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20200824130114.41368-1-th...@redhat.com Subject: [PATCH] disas/libvixl: Fix fall-through anno

Re: [External] Re: [PATCH 2/2] coroutine: take exactly one batch from global pool at a time

2020-08-25 Thread 王洪浩
The purpose of this patch is to improve performance without increasing memory consumption. My test case: QEMU command line arguments -drive file=/dev/nvme2n1p1,format=raw,if=none,id=local0,cache=none,aio=native \ -device virtio-blk,id=blk0,drive=local0,iothread=iothread0,num-queues=4 \ -drive

[PATCH v7 8/8] target/s390x: Use start-powered-off CPUState property

2020-08-25 Thread Thiago Jung Bauermann
Instead of setting CPUState::halted to 1 in s390_cpu_initfn(), use the start-powered-off property which makes cpu_common_reset() initialize it to 1 in common code. Note that this changes behavior by setting cs->halted to 1 on reset, which didn't happen before. Acked-by: Cornelia Huck Reviewed-by

[PATCH v7 5/8] mips/cps: Use start-powered-off CPUState property

2020-08-25 Thread Thiago Jung Bauermann
Instead of setting CPUState::halted to 1 in main_cpu_reset(), use the start-powered-off property which makes cpu_common_reset() initialize it to 1 in common code. Also change creation of CPU object from cpu_create() to object_new() and qdev_realize_and_unref() because cpu_create() realizes the CPU

[PATCH v7 7/8] sparc/sun4m: Use start-powered-off CPUState property

2020-08-25 Thread Thiago Jung Bauermann
Instead of setting CPUState::halted to 1 in secondary_cpu_reset(), use the start-powered-off property which makes cpu_common_reset() initialize it to 1 in common code. Now secondary_cpu_reset() becomes equivalent to main_cpu_reset() so rename the function to sun4m_cpu_reset(). Also remove setting

[PATCH v7 6/8] sparc/sun4m: Don't set cs->halted = 0 in main_cpu_reset()

2020-08-25 Thread Thiago Jung Bauermann
We rely on cpu_common_reset() to set cs->halted to 0, it's redundant to do it in main_cpu_reset(). Signed-off-by: Thiago Jung Bauermann --- hw/sparc/sun4m.c | 1 - 1 file changed, 1 deletion(-) diff --git a/hw/sparc/sun4m.c b/hw/sparc/sun4m.c index cf7dfa4af5..7484aa4438 100644 --- a/hw/sparc/s

[PATCH v7 2/8] target/arm: Move setting of CPU halted state to generic code

2020-08-25 Thread Thiago Jung Bauermann
This change is in a separate patch because it's not so obvious that it won't cause a regression. Suggested-by: Eduardo Habkost Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: David Gibson Reviewed-by: Greg Kurz Signed-off-by: Thiago Jung Bauermann --- hw/core/cpu.c| 2 +- target/arm/cpu

[PATCH v7 4/8] ppc/e500: Use start-powered-off CPUState property

2020-08-25 Thread Thiago Jung Bauermann
Instead of setting CPUState::halted to 1 in ppce500_cpu_reset_sec(), use the start-powered-off property which makes cpu_common_reset() initialize it to 1 in common code. Also change creation of CPU object from cpu_create() to object_new() and qdev_realize_and_unref() because cpu_create() realizes

[PATCH v7 0/8] Generalize start-powered-off property from ARM

2020-08-25 Thread Thiago Jung Bauermann
This version fixes `make check` failures in ppc/e500.c, mips/cps.c and sparc/sun4m.c. This was done by moving the qdev_realize_and_unref() call as close as possible to the object_new() call, in order to keep the CPU object construction as similar as possible to the earlier version which used cpu_cr

[PATCH v7 1/8] target/arm: Move start-powered-off property to generic CPUState

2020-08-25 Thread Thiago Jung Bauermann
There are other platforms which also have CPUs that start powered off, so generalize the start-powered-off property so that it can be used by them. Note that ARMv7MState also has a property of the same name but this patch doesn't change it because that class isn't a subclass of CPUState so it woul

[PATCH v7 3/8] ppc/spapr: Use start-powered-off CPUState property

2020-08-25 Thread Thiago Jung Bauermann
PowerPC sPAPR CPUs start in the halted state, and spapr_reset_vcpu() attempts to implement this by setting CPUState::halted to 1. But that's too late for the case of hotplugged CPUs in a machine configure with 2 or more threads per core. By then, other parts of QEMU have already caused the vCPU to

Re: [PULL] nvme updates

2020-08-25 Thread Klaus Jensen
On Aug 26 07:28, Keith Busch wrote: > On Tue, Aug 25, 2020 at 10:43:23PM +0100, Peter Maydell wrote: > > On Tue, 25 Aug 2020 at 21:12, Keith Busch wrote: > > > > > > On Sun, Aug 23, 2020 at 02:56:12PM +0100, Peter Maydell wrote: > > > > Hi; it looks like this isn't a gpg-signed tag? > > > > > > >

Re: [PATCH v6 4/8] ppc/e500: Use start-powered-off CPUState property

2020-08-25 Thread Thiago Jung Bauermann
Philippe Mathieu-Daudé writes: > On 8/22/20 10:59 AM, Cédric Le Goater wrote: >> Hello, >> >> On 8/19/20 6:43 PM, Thiago Jung Bauermann wrote: >>> Instead of setting CPUState::halted to 1 in ppce500_cpu_reset_sec(), use >>> the start-powered-off property which makes cpu_common_reset() initiali

Re: [PATCH] meson: don't require CONFIG_VTE for the GTK UI

2020-08-25 Thread Gerd Hoffmann
On Tue, Aug 25, 2020 at 11:23:10PM +0100, Mark Cave-Ayland wrote: > Prevously CONFIG_VTE was not required to build QEMU with GTK UI support as not > all platforms have VTE available (in particular Windows). > > Remove this requirement from the meson build system to enable QEMU to be built > with G

Re: [PATCH v3 14/74] hcd-dwc2: Rename USB_*CLASS macros for consistency

2020-08-25 Thread Gerd Hoffmann
On Tue, Aug 25, 2020 at 03:20:10PM -0400, Eduardo Habkost wrote: > Rename the DWC2_CLASS to DWC2_USB_CLASS and DWC2_GET_CLASS to > DWC2_USB_GET_CLASS, for consistency with the DWC2_USB macro. > > Reviewed-by: Philippe Mathieu-Daudé > Reviewed-by: Daniel P. Berrangé > Signed-off-by: Eduardo Hab

Re: [PATCH] meson: set colorout to auto

2020-08-25 Thread Gerd Hoffmann
On Tue, Aug 25, 2020 at 06:26:33AM -0700, Richard Henderson wrote: > On 8/24/20 11:43 PM, Gerd Hoffmann wrote: > > Dunno why the default is set to "always". IMHO it should be "auto", > > i.e. only colorize in case stdout goes to a terminal. Cluttering > > logfiles and confusing compiler message p

[Bug 1892978] [NEW] Heap-use-after-free in e1000e_write_packet_to_guest

2020-08-25 Thread Alexander Bulekov
Public bug reported: Hello, Reproducer: cat << EOF | ./qemu-system-i386 \ -display none -m 64 -netdev user,id=qtest-bn0 \ -device e1000e,netdev=qtest-bn0 -display none \ -nodefaults -accel qtest -qtest stdio outl 0xcf8 0x80001004 outl 0xcfc 0x3b2e84ce outl 0xcf8 0x80001013 outw 0xcfc 0x2499 writew

Re: [PULL 00/18] riscv-to-apply queue

2020-08-25 Thread Bin Meng
On Wed, Aug 26, 2020 at 6:41 AM Alistair Francis wrote: > > On Tue, Aug 25, 2020 at 2:50 PM Peter Maydell > wrote: > > > > On Tue, 25 Aug 2020 at 22:32, Alistair Francis wrote: > > > > > > On Tue, Aug 25, 2020 at 2:24 PM Peter Maydell > > > wrote: > > > > The hypervisor related patches don't

Re: [PATCH v6 6/8] sparc/sun4m: Remove main_cpu_reset()

2020-08-25 Thread Thiago Jung Bauermann
Thiago Jung Bauermann writes: > We rely on cpu_common_reset() to set cs->halted to 0, so main_cpu_reset() > is pointless. > > Suggested-by: Philippe Mathieu-Daudé > Reviewed-by: Philippe Mathieu-Daudé > Reviewed-by: David Gibson > Signed-off-by: Thiago Jung Bauermann > --- > hw/sparc/sun4m

[Bug 1892966] [NEW] Null-pointer dereference in blk_bs through ide_cancel_dma_sync

2020-08-25 Thread Alexander Bulekov
Public bug reported: Hello, Reproducer: cat << EOF | ./qemu-system-i386 -M pc \ -drive file=null-co://,if=none,format=raw,id=disk0 \ -device ide-hd,drive=disk0,bus=ide.1,unit=1 \ -display none -nodefaults -display none -qtest stdio -accel qtest outw 0x176 0x35b3 outb 0x376 0x5f outb 0x376 0x40 out

Re: [PATCH 2/2] target/i386: Add missed features to Cooperlake CPU model

2020-08-25 Thread Xiaoyao Li
On 8/25/2020 10:01 PM, Eduardo Habkost wrote: On Tue, Aug 25, 2020 at 08:20:35AM +0800, Xiaoyao Li wrote: On 8/25/2020 6:07 AM, Eduardo Habkost wrote: On Wed, Dec 25, 2019 at 02:30:18PM +0800, Xiaoyao Li wrote: It lacks VMX features and two security feature bits (disclosed recently) in MSR_IA3

RE: [PATCH v2 03/10] target/arm/translate-a64:Remove dead assignment in handle_scalar_simd_shli()

2020-08-25 Thread Chenqun (kuhn)
> On Tue, 25 Aug 2020 at 12:26, Chen Qun wrote: > > > > Clang static code analyzer show warning: > > target/arm/translate-a64.c:8635:14: warning: Value stored to 'tcg_rn' > > during its initialization is never read > > TCGv_i64 tcg_rn = new_tmp_a64(s); > > ^~ ~~

RE: [PATCH v2 08/10] usb/bus: Remove dead assignment in usb_get_fw_dev_path()

2020-08-25 Thread Chenqun (kuhn)
> > > hw/usb/bus.c | 4 ++-- > > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > > > diff --git a/hw/usb/bus.c b/hw/usb/bus.c index > > > b17bda3b29..7bab0499ad > > > 100644 > > > --- a/hw/usb/bus.c > > > +++ b/hw/usb/bus.c > > > @@ -612,8 +612,8 @@ static char *usb_get_fw_dev_path(Dev

[Bug 1892963] [NEW] Heap-use-after-free in put_dwords through ehci_flush_qh

2020-08-25 Thread Alexander Bulekov
Public bug reported: Hello, Reproducer: cat << EOF | ./qemu-system-i386 -machine q35 \ -device ich9-usb-ehci1,bus=pcie.0,addr=1d.7,\ multifunction=on,id=ich9-ehci-1 \ -drive if=none,id=usbcdrom,media=cdrom \ -device usb-storage,bus=ich9-ehci-1.0,\ port=2,drive=usbcdrom \ -display none -nodefaults

Re: [RFC PATCH v3 02/34] Hexagon (target/hexagon) README

2020-08-25 Thread Richard Henderson
On 8/18/20 8:50 AM, Taylor Simpson wrote: > +#ifdef fGEN_TCG_A2_add > +fGEN_TCG_A2_add({ RdV=RsV+RtV;}); > +#else > +do { > +gen_helper_A2_add(RdV, cpu_env, RsV, RtV); > +} while (0); I don't understand the benefit of passing the SHORTCODE to fGEN_TCG_*. Is this file inclu

Re: [RFC PATCH v3 03/34] Hexagon (include/elf.h) ELF machine definition

2020-08-25 Thread Richard Henderson
On 8/18/20 8:50 AM, Taylor Simpson wrote: > Define EM_HEXAGON 164 > > Signed-off-by: Taylor Simpson > Reviewed-by: Philippe Mathieu-Daudé > Tested-by: Philippe Mathieu-Daudé > --- > include/elf.h | 2 ++ > 1 file changed, 2 insertions(+) Reviewed-by: Richard Henderson r~

[Bug 1892962] [NEW] Segfault in usb_bus_from_device

2020-08-25 Thread Alexander Bulekov
Public bug reported: Hello, Reproducer: cat << EOF | ./qemu-system-i386 -machine q35 \ -device ich9-usb-ehci1,bus=pcie.0,addr=1d.7,\ multifunction=on,id=ich9-ehci-1 \ -device ich9-usb-uhci1,bus=pcie.0,addr=1d.0,\ multifunction=on,masterbus=ich9-ehci-1.0,firstport=0 \ -device usb-tablet,bus=ich9-e

RE: [PATCH v2 08/10] usb/bus: Remove dead assignment in usb_get_fw_dev_path()

2020-08-25 Thread Chenqun (kuhn)
> > hw/usb/bus.c | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/hw/usb/bus.c b/hw/usb/bus.c index b17bda3b29..7bab0499ad > > 100644 > > --- a/hw/usb/bus.c > > +++ b/hw/usb/bus.c > > @@ -612,8 +612,8 @@ static char *usb_get_fw_dev_path(DeviceState > > *qdev) >

Re: [RFC PATCH v3 01/34] Hexagon Update MAINTAINERS file

2020-08-25 Thread Richard Henderson
On 8/18/20 8:50 AM, Taylor Simpson wrote: > Add Taylor Simpson as the Hexagon target maintainer > > Signed-off-by: Taylor Simpson > --- > MAINTAINERS | 8 > 1 file changed, 8 insertions(+) Reviewed-by: Richard Henderson r~

Re: [PATCH v2 10/10] hw/display/vga:Remove redundant statement in vga_draw_graphic()

2020-08-25 Thread Li Qiang
Chen Qun 于2020年8月25日周二 下午7:33写道: > > Clang static code analyzer show warning: > hw/display/vga.c:1677:9: warning: Value stored to 'update' is never read > update = full_update; > ^~~~ > > Reported-by: Euler Robot > Signed-off-by: Chen Qun > Reviewed-by: Gerd Hoffm

RE: [PATCH v2 07/10] vfio/platform: Remove dead assignment in vfio_intp_interrupt()

2020-08-25 Thread Chenqun (kuhn)
> > Clang static code analyzer show warning: > > hw/vfio/platform.c:239:9: warning: Value stored to 'ret' is never read > > ret = event_notifier_test_and_clear(intp->interrupt); > > ^ ~~ > > > > Reported-by: Euler Robot > > Signed-of

Re: [PATCH v2 07/10] vfio/platform: Remove dead assignment in vfio_intp_interrupt()

2020-08-25 Thread Li Qiang
Chen Qun 于2020年8月25日周二 下午7:31写道: > > Clang static code analyzer show warning: > hw/vfio/platform.c:239:9: warning: Value stored to 'ret' is never read > ret = event_notifier_test_and_clear(intp->interrupt); > ^ ~~ > > Reported-by: Eul

Re: [PATCH v2 06/10] hw/net/virtio-net:Remove redundant statement in virtio_net_rsc_tcp_ctrl_check()

2020-08-25 Thread Li Qiang
Chen Qun 于2020年8月25日周二 下午7:32写道: > > Clang static code analyzer show warning: > hw/net/virtio-net.c:2077:5: warning: Value stored to 'tcp_flag' is never read > tcp_flag &= VIRTIO_NET_TCP_FLAG; > ^ ~~~ > > The 'VIRTIO_NET_TCP_FLAG' is '0x3F'. The last ‘tcp_flag’ as

[Bug 1892960] [NEW] Heap-overflow in flatview_read through sdhci_data_transfer

2020-08-25 Thread Alexander Bulekov
Public bug reported: Hello, Reproducer: cat << EOF | ./qemu-system-i386 -nodefaults \ -device sdhci-pci,sd-spec-version=3 \ -device sd-card,drive=mydrive \ -drive if=sd,index=0,file=null-co://,format=raw,id=mydrive \ -nographic -qtest stdio -accel qtest outl 0xcf8 0x80001010 outl 0xcfc 0xd7055dba

Re: [PATCH v2 02/10] hw/arm/omap1:Remove redundant statement in omap_clkdsp_read()

2020-08-25 Thread Li Qiang
Chen Qun 于2020年8月25日周二 下午7:30写道: > > Clang static code analyzer show warning: > hw/arm/omap1.c:1760:15: warning: Value stored to 'cpu' during its > initialization is never read > CPUState *cpu = CPU(s->cpu); > ^~~ ~~~ > > Reported-by: Euler Robot > Signed-off-by: Chen

Re: [PATCH v2 01/10] hw/arm/virt-acpi-build:Remove dead assignment in build_madt()

2020-08-25 Thread Li Qiang
Chen Qun 于2020年8月25日周二 下午7:26写道: > > Clang static code analyzer show warning: > hw/arm/virt-acpi-build.c:641:5: warning: Value stored to 'madt' is never read > madt = acpi_data_push(table_data, sizeof *madt); > ^ > > Reported-by: Euler Robot >

[Bug 1892604] Re: qemu-system-arm: ../hw/usb/hcd-dwc2.c:666: dwc2_glbreg_read: Assertion `addr <= GINTSTS2' failed.

2020-08-25 Thread Brendan Dolan-Gavitt
Yep, it looks like that works! Sorry for the bogus report, I didn't think to check the Changelog. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1892604 Title: qemu-system-arm: ../hw/usb/hcd-dwc2.c:

Re: [PATCH v2 1/4] Define ePMP mseccfg

2020-08-25 Thread Alistair Francis
On Mon, Aug 10, 2020 at 5:25 PM Hou Weiying wrote: > > Currently using 0x390 and 0x391 for x-epmp (experimental). This may change in > the future spec. > > Signed-off-by: Hongzheng-Li > Signed-off-by: Hou Weiying > Signed-off-by: Myriad-Dreamin > --- > target/riscv/cpu_bits.h | 3 +++ > targe

Re: [PULL 00/18] riscv-to-apply queue

2020-08-25 Thread Alistair Francis
On Tue, Aug 25, 2020 at 2:50 PM Peter Maydell wrote: > > On Tue, 25 Aug 2020 at 22:32, Alistair Francis wrote: > > > > On Tue, Aug 25, 2020 at 2:24 PM Peter Maydell > > wrote: > > > The hypervisor related patches don't seem to have any > > > reviewed-by tags, which seems a shame for a fairly si

Re: [PULL] nvme updates

2020-08-25 Thread Keith Busch
On Tue, Aug 25, 2020 at 10:43:23PM +0100, Peter Maydell wrote: > On Tue, 25 Aug 2020 at 21:12, Keith Busch wrote: > > > > On Sun, Aug 23, 2020 at 02:56:12PM +0100, Peter Maydell wrote: > > > Hi; it looks like this isn't a gpg-signed tag? > > > > > > error: remotes/nvme/nvme-next: cannot verify a n

[PATCH] meson: don't require CONFIG_VTE for the GTK UI

2020-08-25 Thread Mark Cave-Ayland
Prevously CONFIG_VTE was not required to build QEMU with GTK UI support as not all platforms have VTE available (in particular Windows). Remove this requirement from the meson build system to enable QEMU to be built with GTK UI support for Windows once again. Signed-off-by: Mark Cave-Ayland ---

Re: meson: problems building under msys2/mingw-w64 native

2020-08-25 Thread Mark Cave-Ayland
On 25/08/2020 09:34, Paolo Bonzini wrote: > I saw it, thanks. I would like to have someone else (like Mark) test it and > then I > will include it. > > Paolo Yonggang Luo, thank you for this patchset which helped enable me to build QEMU on Windows with the new meson build. I've replied to ind

[Bug 1882851] [PATCH] drm/virtio: fix unblank

2020-08-25 Thread Diego Viola
From: Gerd Hoffmann When going through a disable/enable cycle without changing the framebuffer the optimization added by commit 3954ff10e06e ("drm/virtio: skip set_scanout if framebuffer didn't change") causes the screen stay blank. Add a bool to force an update to fix that. v2: use drm_atomic_

[REPORT] Nightly Performance Tests - Tuesday, August 25, 2020

2020-08-25 Thread Ahmed Karaman
Host CPU : Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz Host Memory : 15.49 GB Start Time (UTC) : 2020-08-25 21:30:01 End Time (UTC) : 2020-08-25 22:02:37 Execution Time : 0:32:35.896990 Status : SUCCESS Note: Changes denoted by '-' are less than 0.01%. -

[PATCH 3/3] ppc/spapr_nvdimm: do not enable support with 'nvdimm=off'

2020-08-25 Thread Daniel Henrique Barboza
The NVDIMM support for pSeries was introduced in 5.1, but it didn't contemplate the 'nvdimm' machine option that other archs uses. For every other arch, if no '-machine nvdimm(=on)' is present, it is assumed that the NVDIMM support is disabled. The user must explictly inform that the machine suppor

[PATCH 2/3] spapr, spapr_nvdimm: fold NVDIMM validation in the same place

2020-08-25 Thread Daniel Henrique Barboza
NVDIMM has different contraints and conditions than the regular DIMM and we'll need to add at least one more. Instead of relying on 'if (nvdimm)' conditionals in the body of spapr_memory_pre_plug(), use the existing spapr_nvdimm_validate_opts() and put all NVDIMM handling code there. Rename it to

[PATCH 1/3] ppc/spapr_nvdimm: use g_autofree in spapr_nvdimm_validate_opts()

2020-08-25 Thread Daniel Henrique Barboza
Since we're using the string just once, just use g_autofree and avoid leaking it without calling g_free(). Signed-off-by: Daniel Henrique Barboza --- hw/ppc/spapr_nvdimm.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/hw/ppc/spapr_nvdimm.c b/hw/ppc/spapr_nvdimm.c index 81

Re: [PATCH v3] block: Raise an error when backing file parameter is an empty string

2020-08-25 Thread Connor Kuehl
On 8/13/20 8:47 AM, Connor Kuehl wrote: Providing an empty string for the backing file parameter like so: qemu-img create -f qcow2 -b '' /tmp/foo allows the flow of control to reach and subsequently fail an assert statement because passing an empty string to bdrv_get_full_backi

[PATCH 0/3] spapr NVDIMM: consider 'nvdimm' machine option

2020-08-25 Thread Daniel Henrique Barboza
This series aims to solve bug [1]. First patch is a trivial cleanup, feel free to squash into patch 02. Patch 02 attempts a code simplification to put all NVDIMM related logic in the same function. Patch 03 is where the actual fix is implemented. My initial approach here was to make the handling

Re: [PATCH 4/4] configure: Fix include and linkage issue on msys2

2020-08-25 Thread Mark Cave-Ayland
On 25/08/2020 17:53, luoyongg...@gmail.com wrote: > From: Yonggang Luo > > On msys2, the -I/e/path/to/qemu -L/e/path/to/qemu are not recognized by the > compiler > Cause $PWD are result posix style path such as /e/path/to/qemu that can not > be recognized > by mingw gcc, and `pwd -W` are resul

[PATCH 77/77] target/microblaze: Reduce linux-user address space to 32-bit

2020-08-25 Thread Richard Henderson
User-space programs cannot use the 64-bit lwea/swea instructions. We can improve code generation and runtime by restricting the user-only address space to 32-bit. Signed-off-by: Richard Henderson --- target/microblaze/cpu-param.h | 15 +++ target/microblaze/cpu.h | 2 +- targe

Re: [PULL 00/18] riscv-to-apply queue

2020-08-25 Thread Peter Maydell
On Tue, 25 Aug 2020 at 22:32, Alistair Francis wrote: > > On Tue, Aug 25, 2020 at 2:24 PM Peter Maydell > wrote: > > The hypervisor related patches don't seem to have any > > reviewed-by tags, which seems a shame for a fairly significant > > chunk of work. Is there really nobody who can review t

better file/line info for format string errors in trace events

2020-08-25 Thread Peter Maydell
If you have a format string error in a trace event it fails like this: In file included from ../../hw/block/trace.h:1:0, from ../../hw/block/fdc.c:48: ./trace/trace-hw_block.h: In function '_nocheck__trace_pci_nvme_err_mdts': ./trace/trace-hw_block.h:2162:18: error: format '%llu'

[PATCH 75/77] target/microblaze: Remove cpu_R[0]

2020-08-25 Thread Richard Henderson
Do not initialize cpu_R[0], as this should be totally unused. The cpu_for_read and cpu_for_write functions use a local temp. Signed-off-by: Richard Henderson --- target/microblaze/translate.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/target/microblaze/translate.c

Re: linux-user static build broken

2020-08-25 Thread Peter Maydell
On Tue, 25 Aug 2020 at 21:37, Laurent Vivier wrote: > > Hi, > > since we have switched to meson, the statically linked binaries of qemu > linux-user are broken: > > cd $OBJ > $SRC/configure --static --target-list=m68k-linux-user > make > ./qemu-m68k > Segmentation fault (core dumped) It can't be

[PATCH 73/77] target/microblaze: Convert dec_stream to decodetree

2020-08-25 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 6 target/microblaze/translate.c | 64 ++ 2 files changed, 55 insertions(+), 15 deletions(-) diff --git a/target/microblaze/insns.decode b/target/microblaze/insns.decode index 48c60082e0.

ANNOUNCE: libnbd 1.4 - high performance NBD client library

2020-08-25 Thread Richard W.M. Jones
I'm pleased to announce the release of libnbd 1.4.0, a high performance Network Block Device (NBD) client library. Key features of libnbd: * Synchronous API for ease of use. * Asynchronous API for writing non-blocking, multithreaded clients. You can mix both APIs freely. * High performan

[PATCH 67/77] target/microblaze: Convert dec_br to decodetree

2020-08-25 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 14 + target/microblaze/translate.c | 98 +++--- 2 files changed, 68 insertions(+), 44 deletions(-) diff --git a/target/microblaze/insns.decode b/target/microblaze/insns.decode index 77b073be9e

[PATCH 65/77] target/microblaze: Reorganize branching

2020-08-25 Thread Richard Henderson
Remove the btaken variable, and simplify things by always computing the full branch destination into btarget. This avoids all need for sync_jmpstate(). Retain the direct branch behaviour by remembering the jump destination in jmp_dest, discarding btarget. In the normal case, where the branch del

Re: [PULL] nvme updates

2020-08-25 Thread Peter Maydell
On Tue, 25 Aug 2020 at 21:12, Keith Busch wrote: > > On Sun, Aug 23, 2020 at 02:56:12PM +0100, Peter Maydell wrote: > > Hi; it looks like this isn't a gpg-signed tag? > > > > error: remotes/nvme/nvme-next: cannot verify a non-tag object of type > > commit. > > Oops, sorry I forgot about that part

[PATCH 64/77] target/microblaze: Convert mbar to decodetree

2020-08-25 Thread Richard Henderson
Split this out of the normal branch instructions, as it requires special handling. End the TB only for an instruction barrier. Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 2 + target/microblaze/translate.c | 81 ++ 2 files changed, 45

Re: [PATCH 1/4] meson: Fixes the ninjatool issue that E$$: are generated in Makefile.ninja

2020-08-25 Thread Eric Blake
On 8/25/20 11:53 AM, luoyongg...@gmail.com wrote: From: Yonggang Luo SIMPLE_PATH_RE should match the full path token. Or the $ and : contained in path would not matched if the path are start with C:/ and E:/ --- Missing a Signed-off-by tag. Without that, we cannot apply it. Also missing a

[PATCH 61/77] target/microblaze: Tidy mb_cpu_dump_state

2020-08-25 Thread Richard Henderson
Using lookup_symbol is quite slow; remove that. Decode the various bits of iflags; only show imm, btaken, btarget when they are relevant to iflags. Improve formatting. Signed-off-by: Richard Henderson --- target/microblaze/translate.c | 67 +-- 1 file changed, 4

[PATCH 76/77] target/microblaze: Add flags markup to some helpers

2020-08-25 Thread Richard Henderson
The mmu_read, mmu_write, get, and put helpers do not touch the general registers, or any of the other variables managed by tcg. Signed-off-by: Richard Henderson --- target/microblaze/helper.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/target/microblaze/helper.h b

[PATCH 56/77] target/microblaze: Store "current" iflags in insn_start

2020-08-25 Thread Richard Henderson
This data is available during exception unwinding, thus we can restore it from there directly, rather than saving it during the TB. Thus we may remove the t_sync_flags() calls in the load/store operations. Note that these calls were missing from the other places where runtime exceptions may be ra

[PATCH 71/77] target/microblaze: Convert msrclr, msrset to decodetree

2020-08-25 Thread Richard Henderson
Split this out of dec_msr. Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 6 +++ target/microblaze/translate.c | 85 +++--- 2 files changed, 54 insertions(+), 37 deletions(-) diff --git a/target/microblaze/insns.decode b/target/microblaze/ins

[PATCH 53/77] target/microblaze: Convert dec_load and dec_store to decodetree

2020-08-25 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 32 ++ target/microblaze/translate.c | 723 +++-- 2 files changed, 456 insertions(+), 299 deletions(-) diff --git a/target/microblaze/insns.decode b/target/microblaze/insns.decode index ea6743c7e5

[PATCH 66/77] target/microblaze: Use tcg_gen_lookup_and_goto_ptr

2020-08-25 Thread Richard Henderson
When goto_tb cannot be used due to branch page crossing, or due to indirect jumping, tcg_gen_lookup_and_goto_ptr can be used instead. Signed-off-by: Richard Henderson --- target/microblaze/translate.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target/microblaze/trans

Re: [PATCH 3/4] meson: Mingw64 gcc doesn't recognize system include_type for sdl2

2020-08-25 Thread Mark Cave-Ayland
On 25/08/2020 17:53, luoyongg...@gmail.com wrote: > From: Yonggang Luo > > Fixes this for msys2/mingw64 by remove the include_type for sdl2 discovery in > meson > --- > meson.build | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/meson.build b/meson.build > index f0f

[PATCH 51/77] target/microblaze: Cache mem_index in DisasContext

2020-08-25 Thread Richard Henderson
Ideally, nothing outside the top-level of translation even has access to env. Cache the value in init_disas_context. Signed-off-by: Richard Henderson --- target/microblaze/translate.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/target/microblaze/translate.c b/ta

[PATCH 60/77] target/microblaze: Replace delayed_branch with tb_flags_to_set

2020-08-25 Thread Richard Henderson
The multi-stage counter can be replaced by clearing D_FLAG, the or'ing in tb_flags_to_set. The jump then happens when D_FLAG is finally cleared. Signed-off-by: Richard Henderson --- target/microblaze/translate.c | 17 + 1 file changed, 5 insertions(+), 12 deletions(-) diff --gi

Re: [PULL 00/18] riscv-to-apply queue

2020-08-25 Thread Alistair Francis
On Tue, Aug 25, 2020 at 2:24 PM Peter Maydell wrote: > > On Tue, 25 Aug 2020 at 20:01, Alistair Francis > wrote: > > > > The following changes since commit 7774e403f2ac58b3e87bfe8d2f77676501ba893e: > > > > Merge remote-tracking branch > > 'rem

Re: [PATCH 1/4] meson: Fixes the ninjatool issue that E$$: are generated in Makefile.ninja

2020-08-25 Thread Mark Cave-Ayland
On 25/08/2020 17:53, luoyongg...@gmail.com wrote: > From: Yonggang Luo > > SIMPLE_PATH_RE should match the full path token. > Or the $ and : contained in path would not matched if the path are start with > C:/ and E:/ > --- > scripts/ninjatool.py | 2 +- > 1 file changed, 1 insertion(+), 1 del

Re: [PATCH 2/4] meson: fixes relpath may fail on win32.

2020-08-25 Thread Mark Cave-Ayland
On 25/08/2020 17:53, luoyongg...@gmail.com wrote: > From: Yonggang Luo > > On win32, os.path.relpath would raise exception when do the following relpath: > C:/msys64/mingw64/x.exe relative to E:/path/qemu-build would fail. > So we try catch it for stopping it from raise exception on msys2 > ---

[PATCH 59/77] target/microblaze: Replace clear_imm with tb_flags_to_set

2020-08-25 Thread Richard Henderson
This more general update variable will be able to handle delay slots as well. Signed-off-by: Richard Henderson --- target/microblaze/translate.c | 15 +-- 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/target/microblaze/translate.c b/target/microblaze/translate.c index

Re: [PULL 00/18] riscv-to-apply queue

2020-08-25 Thread Peter Maydell
On Tue, 25 Aug 2020 at 20:01, Alistair Francis wrote: > > The following changes since commit 7774e403f2ac58b3e87bfe8d2f77676501ba893e: > > Merge remote-tracking branch > 'remotes/kraxel/tags/fixes-20200825-pull-request' into staging (2020-08-25 > 10:54:51 +0100)

[PATCH 49/77] target/microblaze: Mark fpu helpers TCG_CALL_NO_WG

2020-08-25 Thread Richard Henderson
Now that FSR is no longer a tcg global temp, we can say that the fpu helpers do not write to tcg temps. All temps are read implicitly by the fpu exception path. Signed-off-by: Richard Henderson --- target/microblaze/helper.h | 28 ++-- 1 file changed, 14 insertions(+), 1

[PATCH v2 1/2] linux-user: Modify 'recvmmsg()' implementation

2020-08-25 Thread Filip Bozuta
Implementation of syscall 'recvmmsg()' in file 'syscall.c' uses a loop over 'recvmsg()' to receive each individual message from a socket. However, the implementation ignores the timeout argument. This patch changes that by introducing a timeout check after each received message. Implementation not

[PATCH 58/77] target/microblaze: Use cc->do_unaligned_access

2020-08-25 Thread Richard Henderson
This fixes the problem in which unaligned stores succeeded, but then we raised the exception after modifying memory. Store the ESS for the unaligned data access in the iflags for the insn, so that it can be found during unwind. Signed-off-by: Richard Henderson --- target/microblaze/cpu.h |

[PATCH v2 2/2] linux-user: Add support for 'recvmmsg_time64()'

2020-08-25 Thread Filip Bozuta
This patch introduces functionality for syscall: *recvmmsg_time64 This syscall is a 2038 safe variant for syscall: int recvmmsg(int sockfd, struct mmsghdr *msgvec, unsigned int vlen, int flags, struct timespec *timeout) --receive multiple messages on a socket--

[PATCH 48/77] target/microblaze: Fix cpu unwind for fpu exceptions

2020-08-25 Thread Richard Henderson
Restore the correct PC when an exception must be raised. Signed-off-by: Richard Henderson --- target/microblaze/op_helper.c | 37 +++ 1 file changed, 20 insertions(+), 17 deletions(-) diff --git a/target/microblaze/op_helper.c b/target/microblaze/op_helper.c inde

[PATCH 46/77] target/microblaze: Convert dec_imm to decodetree

2020-08-25 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 2 ++ target/microblaze/translate.c | 18 +- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/target/microblaze/insns.decode b/target/microblaze/insns.decode index 31e50549ea..a7eb7d4e6f 100644

[PATCH v2 0/2] linux-user: Introducing support for 'recvmmsg_time64()'

2020-08-25 Thread Filip Bozuta
This patch introduces functionality for 'recvmmsg_time64()' which is a year 2038 safe variant of 'recvmmsg()'. This new time64 syscall is introduced in series of two patches rather than in one patch because a little modification was needed before the syscall could be introduced properly. The first

[PATCH 57/77] tcg: Add tcg_get_insn_start_param

2020-08-25 Thread Richard Henderson
MicroBlaze will shortly need to update a parameter in place. Add an interface to read to match that for write. Signed-off-by: Richard Henderson --- include/tcg/tcg.h | 15 +++ 1 file changed, 15 insertions(+) diff --git a/include/tcg/tcg.h b/include/tcg/tcg.h index d40c925d04..15da4

[PATCH 74/77] target/microblaze: Remove last of old decoder

2020-08-25 Thread Richard Henderson
All instructions have been convered. Issue sigill if decodetree does not match. Remove argument decode from DisasContext. Signed-off-by: Richard Henderson --- target/microblaze/translate.c | 75 +-- 1 file changed, 2 insertions(+), 73 deletions(-) diff --git a/

[PATCH 45/77] target/microblaze: Convert dec_barrel to decodetree

2020-08-25 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 20 ++ target/microblaze/translate.c | 125 + 2 files changed, 86 insertions(+), 59 deletions(-) diff --git a/target/microblaze/insns.decode b/target/microblaze/insns.decode index 5666b381

[PATCH 42/77] target/microblaze: Convert dec_div to decodetree

2020-08-25 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 3 +++ target/microblaze/translate.c | 35 +- 2 files changed, 16 insertions(+), 22 deletions(-) diff --git a/target/microblaze/insns.decode b/target/microblaze/insns.decode index 65a8a53b54..

[PATCH 68/77] target/microblaze: Convert dec_bcc to decodetree

2020-08-25 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 36 + target/microblaze/translate.c | 99 ++ 2 files changed, 88 insertions(+), 47 deletions(-) diff --git a/target/microblaze/insns.decode b/target/microblaze/insns.decode index 94

[PATCH 40/77] target/microblaze: Convert dec_and, dec_or, dec_xor to decodetree

2020-08-25 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 12 ++ target/microblaze/translate.c | 44 -- 2 files changed, 27 insertions(+), 29 deletions(-) diff --git a/target/microblaze/insns.decode b/target/microblaze/insns.decode index 8d3de

[PATCH 39/77] target/microblaze: Convert dec_pattern to decodetree

2020-08-25 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 4 ++ target/microblaze/translate.c | 67 +- 2 files changed, 22 insertions(+), 49 deletions(-) diff --git a/target/microblaze/insns.decode b/target/microblaze/insns.decode index 3f5f7b1852..8

[PATCH 72/77] target/microblaze: Convert dec_msr to decodetree

2020-08-25 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/microblaze/insns.decode | 3 + target/microblaze/translate.c | 270 + 2 files changed, 139 insertions(+), 134 deletions(-) diff --git a/target/microblaze/insns.decode b/target/microblaze/insns.decode index e80283cce6.

[PATCH 63/77] target/microblaze: Convert brk and brki to decodetree

2020-08-25 Thread Richard Henderson
Split these out of the normal branch instructions, as they require special handling. Perform the entire operation inline, instead of raising EXCP_BREAK to do the work in mb_cpu_do_interrupt. This fixes a bug in that brki rd, imm, for imm != 0x18 is not supposed to set MSR_BIP. This fixes a bug i

[PATCH 38/77] target/microblaze: Implement cmp and cmpu inline

2020-08-25 Thread Richard Henderson
These are simple enough operations; we do not need to call an out-of-line helper. Signed-off-by: Richard Henderson --- target/microblaze/helper.h| 2 -- target/microblaze/op_helper.c | 20 target/microblaze/translate.c | 24 ++-- 3 files changed, 22

  1   2   3   4   5   6   >