Re: [PATCH for-5.0 v2 3/3] block: Fix blk->in_flight during blk_wait_while_drained()

2020-04-06 Thread Vladimir Sementsov-Ogievskiy
06.04.2020 20:14, Kevin Wolf wrote: Waiting in blk_wait_while_drained() while blk->in_flight is increased for the current request is wrong because it will cause the drain operation to deadlock. This patch makes sure that blk_wait_while_drained() is called with blk->in_flight increased exactly on

Re: [PATCH-for-5.1 v2 49/54] various: Use &error_abort in instance_init()

2020-04-06 Thread Cédric Le Goater
On 4/6/20 7:47 PM, Philippe Mathieu-Daudé wrote: > Patch created mechanically by running: > > $ spatch \ > --macro-file scripts/cocci-macro-file.h \ > --include-headers --keep-comments --in-place \ > --sp-file \ > scripts/coccinelle/use-error_abort-in-instance_init.cocci > > S

Re: [PATCH v1] nrf51: Fix last GPIO CNF address

2020-04-06 Thread Cédric Le Goater
On 4/7/20 12:55 AM, Cameron Esfahani wrote: > NRF51_GPIO_REG_CNF_END doesn't actually refer to the start of the last > valid CNF register: it's referring to the last byte of the last valid > CNF register. > > This hasn't been a problem up to now, as current implementation in > memory.c turns an un

Re: [PATCH-for-5.1 v2 07/54] hw/arm/aspeed_soc: Simplify use of Error*

2020-04-06 Thread Cédric Le Goater
On 4/6/20 7:46 PM, Philippe Mathieu-Daudé wrote: > In the previous commit we noticed we don't need two different > Error*, drop the one less used. > > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Cédric Le Goater It seems that the 'return' are badly aligned ? Thanks, C. > --- > hw/

Re: [PATCH-for-5.1 v2 28/54] hw/arm/aspeed: Add missing error-propagation code

2020-04-06 Thread Cédric Le Goater
On 4/6/20 7:47 PM, Philippe Mathieu-Daudé wrote: > Patch created mechanically by running: > > $ spatch \ > --macro-file scripts/cocci-macro-file.h --include-headers \ > --sp-file scripts/coccinelle/use-error_propagate-in-realize.cocci \ > --keep-comments --smpl-spacing --in-place --d

Re: [PATCH-for-5.1 v2 06/54] hw/arm/aspeed_soc: Move some code from realize() to init()

2020-04-06 Thread Cédric Le Goater
On 4/6/20 7:46 PM, Philippe Mathieu-Daudé wrote: > Coccinelle reported: > > $ spatch ... --timeout 60 --sp-file \ > scripts/coccinelle/simplify-init-realize-error_propagate.cocci > HANDLING: ./hw/arm/aspeed_soc.c > >>> possible moves from aspeed_soc_init() to aspeed_soc_realize() in > .

Re: [PATCH-for-5.1 v2 04/54] hw/arm/aspeed_ast2600: Simplify use of Error*

2020-04-06 Thread Cédric Le Goater
On 4/6/20 7:46 PM, Philippe Mathieu-Daudé wrote: > Coccinelle reported: > > $ spatch ... --timeout 60 --sp-file \ > scripts/coccinelle/simplify-init-realize-error_propagate.cocci > HANDLING: ./hw/arm/aspeed_ast2600.c > >>> possible moves from aspeed_soc_ast2600_init() to > aspeed_soc_as

Re: [PATCH for-5.0 v2 2/3] block: Increase BB.in_flight for coroutine interfaces

2020-04-06 Thread Vladimir Sementsov-Ogievskiy
06.04.2020 20:14, Kevin Wolf wrote: External callers of blk_co_*() don't currently increase the BlockBackend.in_flight counter, but calls from blk_aio_*() do, so there is an inconsistency whether the counter has been increased or not. This patch moves the actual operations to static functions th

Re: [RFC PATCH v2 7/7] vfio-ccw: Add support for the CRW irq

2020-04-06 Thread Cornelia Huck
On Mon, 6 Apr 2020 17:37:18 -0400 Eric Farman wrote: > On 4/6/20 12:22 PM, Cornelia Huck wrote: > > On Thu, 6 Feb 2020 22:45:09 +0100 > > Eric Farman wrote: > > > >> From: Farhan Ali > >> > >> The CRW irq will be used by vfio-ccw to notify the userspace > >> about any CRWs the userspace nee

Re: [RFC PATCH v2 1/7] vfio-ccw: Return IOINST_CC_NOT_OPERATIONAL for EIO

2020-04-06 Thread Cornelia Huck
On Mon, 6 Apr 2020 14:21:17 -0400 Eric Farman wrote: > On 4/1/20 4:52 AM, Cornelia Huck wrote: > > On Wed, 25 Mar 2020 03:24:28 +0100 > > Halil Pasic wrote: > > > >> On Tue, 24 Mar 2020 18:04:30 +0100 > >> Cornelia Huck wrote: > >> > >>> On Thu, 6 Feb 2020 22:45:03 +0100 > >>> Eric Farman

Re: [PATCH v2] qcow2: Check request size in qcow2_co_pwritev_compressed_part()

2020-04-06 Thread Andrey Shinkevich
I wouldn't mind either. Andrey From: Alberto Garcia Sent: Monday, April 6, 2020 7:08 PM To: qemu-devel@nongnu.org Cc: qemu-bl...@nongnu.org ; Andrey Shinkevich ; Max Reitz ; Kevin Wolf ; Vladimir Sementsov-Ogievskiy ; Pavel Butsykin Subject: Re: [PATCH v2] q

[PATCH v3 4/7] vmbus: vmbus implementation

2020-04-06 Thread Jon Doron
Add the VMBus infrastructure -- bus, devices, root bridge, vmbus state machine, vmbus channel interactions, etc. VMBus is a collection of technologies. At its lowest layer, it's a message passing and signaling mechanism, allowing efficient passing of messages to and from guest VMs. A layer highe

[PATCH v3 6/7] i386: Hyper-V VMBus ACPI DSDT entry

2020-04-06 Thread Jon Doron
Guest OS uses ACPI to discover VMBus presence. Add a corresponding entry to DSDT in case VMBus has been enabled. Experimentally Windows guests were found to require this entry to include two IRQ resources. They seem to never be used but they still have to be there. Make IRQ numbers user-configur

[PATCH v3 5/7] i386:pc: whitelist dynamic vmbus-bridge

2020-04-06 Thread Jon Doron
As vmbus-bridge is derived from sysbus device, it has to be whitelisted to be allowed to be created with -device. Signed-off-by: Roman Kagan Signed-off-by: Maciej S. Szmigiero Signed-off-by: Jon Doron --- hw/i386/pc_piix.c | 2 ++ hw/i386/pc_q35.c | 2 ++ 2 files changed, 4 insertions(+) dif

[PATCH v3 2/7] hyperv: SControl is optional to enable SynIc

2020-04-06 Thread Jon Doron
SynIc can be enabled regardless of the SControl mechanisim which can register a GSI for a given SintRoute. This behaviour can achived by setting enabling SIMP and then the guest will poll on the message slot. Once there is another message pending the host will set the message slot with the pendin

[PATCH v3 7/7] vmbus: add infrastructure to save/load vmbus requests

2020-04-06 Thread Jon Doron
This can be allow to include controller-specific data while saving/loading in-flight scsi requests of the vmbus scsi controller. Signed-off-by: Roman Kagan Signed-off-by: Maciej S. Szmigiero Signed-off-by: Jon Doron --- hw/hyperv/vmbus.c | 99 +++ in

[PATCH v3 3/7] vmbus: add vmbus protocol definitions

2020-04-06 Thread Jon Doron
Add a header with data structures and constants used in Hyper-V VMBus hypervisor <-> guest interactions. Based on the respective stuff from Linux kernel. Signed-off-by: Roman Kagan Signed-off-by: Maciej S. Szmigiero Signed-off-by: Jon Doron --- include/hw/hyperv/vmbus-proto.h | 222 ++

[PATCH v3 1/7] hyperv: expose API to determine if synic is enabled

2020-04-06 Thread Jon Doron
Signed-off-by: Jon Doron --- hw/hyperv/hyperv.c | 8 include/hw/hyperv/hyperv.h | 1 + 2 files changed, 9 insertions(+) diff --git a/hw/hyperv/hyperv.c b/hw/hyperv/hyperv.c index 8ca3706f5b..ddf4f32c60 100644 --- a/hw/hyperv/hyperv.c +++ b/hw/hyperv/hyperv.c @@ -37,6 +37,13 @@ t

[PATCH v3 0/7] hyperv: VMBus implementation

2020-04-06 Thread Jon Doron
This is a rebase of the old patchset from Roman for HyperV VMBus implementation. How to use: -device vmbus-bridge Later on new paravirtualized devices can be implemented on top of it (Network/SCSI/etc.) VMBus is a collection of technologies. At its lowest layer, it's a message passing and signa

Re: [PATCH for-5.0 v2 1/3] block-backend: Reorder flush/pdiscard function definitions

2020-04-06 Thread Vladimir Sementsov-Ogievskiy
06.04.2020 20:14, Kevin Wolf wrote: Move all variants of the flush/pdiscard functions to a single place and put the blk_co_*() version first because it is called by all other variants (and will become static in the next patch). Signed-off-by: Kevin Wolf Reviewed-by: Vladimir Sementsov-Ogievski

Re: [PATCH for-5.0] xen-block: Fix uninitialized variable

2020-04-06 Thread Markus Armbruster
Anthony PERARD writes: > On Mon, Apr 06, 2020 at 06:50:41PM +0200, Philippe Mathieu-Daudé wrote: >> On 4/6/20 6:42 PM, Anthony PERARD wrote: >> > Since 7f5d9b206d1e ("object-add: don't create return value if >> > failed"), qmp_object_add() don't write any value in 'ret_data', thus >> > has random

Re: [PATCH v9 5/9] docs/clocks: add device's clock documentation

2020-04-06 Thread Markus Armbruster
Damien Hedde writes: > Add the documentation about the clock inputs and outputs in devices. > > This is based on the original work of Frederic Konrad. > > Signed-off-by: Damien Hedde > Reviewed-by: Alistair Francis > Reviewed-by: Edgar E. Iglesias > --- > v9: > + fix a few typos (Alistair) >

Re: [PATCH for-5.0?] target/xtensa: Statically allocate xtensa_insnbufs

2020-04-06 Thread Richard Henderson
On 4/6/20 9:04 PM, Max Filippov wrote: > On Mon, Apr 6, 2020 at 8:09 PM Richard Henderson > wrote: >> >> Rather than dynamically allocate, and risk failing to free >> when we longjmp out of the translator, allocate the maximum >> buffer size from any of the supported cpus, which is 8: > > There's

[PULL 09/10] pseries: Update SLOF firmware image

2020-04-06 Thread David Gibson
From: Alexey Kardashevskiy This is a single regression fix for for 5.0: Greg Kurz (1): slof: Only close stdout for virtio-serial devices Signed-off-by: Alexey Kardashevskiy Signed-off-by: David Gibson --- pc-bios/README | 2 +- pc-bios/slof.bin | Bin 965008 -> 965112 bytes roms/SL

[PULL 10/10] ppc/pnv: Create BMC devices only when defaults are enabled

2020-04-06 Thread David Gibson
From: Cédric Le Goater Commit e2392d4395dd ("ppc/pnv: Create BMC devices at machine init") introduced default BMC devices which can be a problem when the same devices are defined on the command line with : -device ipmi-bmc-sim,id=bmc0 -device isa-ipmi-bt,bmc=bmc0,irq=10 QEMU fails with : q

[PULL 05/10] ppc/spapr: Add FWNMI machine check delivery warnings

2020-04-06 Thread David Gibson
From: Nicholas Piggin 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 Message-Id: <20200325142906.221248-4-npig...@gmail.com> Reviewed-by: Greg Kurz Signed-off-by: David Gibson --

[PULL 06/10] ppc/spapr: Don't kill the guest if a recovered FWNMI machine check delivery fails

2020-04-06 Thread David Gibson
From: Nicholas Piggin Try to be tolerant of FWNMI delivery errors if the machine check had been recovered by the host. Signed-off-by: Nicholas Piggin Message-Id: <20200325142906.221248-5-npig...@gmail.com> Reviewed-by: Greg Kurz [dwg: Updated comment at Greg's suggestion] Signed-off-by: David

[PULL 08/10] hw/ppc/ppc440_uc.c: Remove incorrect iothread locking from dcr_write_pcie()

2020-04-06 Thread David Gibson
From: Peter Maydell In dcr_write_pcie() we take the iothread lock around a call to pcie_host_mmcfg_udpate(). This is an incorrect attempt to deal with the bug fixed in commit 235352ee6e73d7716, where we were not taking the iothread lock before calling device dcr read/write functions. (It's not s

[PULL 04/10] ppc/spapr: Improve FWNMI machine check delivery corner case comments

2020-04-06 Thread David Gibson
From: Nicholas Piggin Some of the conditions are not as clearly documented as they could be. Also the non-FWNMI case does not need a large comment. Reviewed-by: Greg Kurz Signed-off-by: Nicholas Piggin Message-Id: <20200325142906.221248-3-npig...@gmail.com> Signed-off-by: David Gibson --- hw

[PULL 03/10] ppc/spapr: KVM FWNMI should not be enabled until guest requests it

2020-04-06 Thread David Gibson
From: Nicholas Piggin 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-register" is called, KVM has different behaviour depending on whether the guest has enabled FWNMI

[PULL 02/10] vfio/spapr: Fix page size calculation

2020-04-06 Thread David Gibson
From: Alexey Kardashevskiy Coverity detected an issue (CID 1421903) with potential call of clz64(0) which returns 64 which make it do "<<" with a negative number. This checks the mask and avoids undefined behaviour. In practice pgsizes and memory_region_iommu_get_min_page_size() always have som

[PULL 00/10] ppc-for-5.0 queue 20200407

2020-04-06 Thread David Gibson
The following changes since commit 53ef8a92eb04ee19640f5aad3bff36cd4a36c250: Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20200406' into staging (2020-04-06 12:36:45 +0100) are available in the Git repository at: git://github.com/dgibson/qemu.git tags/p

[PULL 01/10] hw/ppc/e500.c: Handle qemu_find_file() failure

2020-04-06 Thread David Gibson
From: Peter Maydell If qemu_find_file() doesn't find the BIOS it returns NULL; we were passing that unchecked through to load_elf(), which assumes a non-NULL pointer and may misbehave. In practice it fails with a weird message: $ qemu-system-ppc -M ppce500 -display none -kernel nonesuch Bad

[PULL 07/10] spapr: Fix failure path for attempting to hot unplug PCI bridges

2020-04-06 Thread David Gibson
For various technical reasons we can't currently allow unplug a PCI to PCI bridge on the pseries machine. spapr_pci_unplug_request() correctly generates an error message if that's attempted. But.. if the given errp is not error_abort or error_fatal, it doesn't actually stop trying to unplug the b

Re: [PATCH v16 QEMU 04/16] vfio: Add save and load functions for VFIO PCI devices

2020-04-06 Thread Longpeng (Mike, Cloud Infrastructure Service Product Dept.)
On 2020/3/25 5:09, Kirti Wankhede wrote: > These functions save and restore PCI device specific data - config > space of PCI device. > Tested save and restore with MSI and MSIX type. > > Signed-off-by: Kirti Wankhede > Reviewed-by: Neo Jia > --- > hw/vfio/pci.c | 163 > +

Re: [PATCH for-5.0?] target/xtensa: Statically allocate xtensa_insnbufs

2020-04-06 Thread Max Filippov
On Mon, Apr 6, 2020 at 9:04 PM Max Filippov wrote: > diff --git a/target/xtensa/helper.c b/target/xtensa/helper.c > index 376a61f3397c..278415ae0e06 100644 > --- a/target/xtensa/helper.c > +++ b/target/xtensa/helper.c > @@ -96,6 +96,7 @@ static void init_libisa(XtensaConfig *config) > > confi

Re: [PATCH for-5.0?] target/xtensa: Statically allocate xtensa_insnbufs

2020-04-06 Thread Max Filippov
On Mon, Apr 6, 2020 at 8:09 PM Richard Henderson wrote: > > Rather than dynamically allocate, and risk failing to free > when we longjmp out of the translator, allocate the maximum > buffer size from any of the supported cpus, which is 8: There's macro MAX_INSN_LENGTH that defines maximal support

Re: [PATCH v2 0/3] drop writes to read-only ram device & vfio regions

2020-04-06 Thread Yan Zhao
On Fri, Apr 03, 2020 at 08:53:12PM +0800, Peter Maydell wrote: > On Fri, 3 Apr 2020 at 09:13, Yan Zhao wrote: > > > > patch 1 modifies handler of ram device memory regions to drop guest writes > > to read-only ram device memory regions > > > > patch 2 modifies handler of non-mmap'd read-only vfio

[PATCH for-5.0?] linux-user/ppc: Fix padding in mcontext_t for ppc64

2020-04-06 Thread Richard Henderson
The padding that was added in 95cda4c44ee was added to a union, and so it had no effect. This fixes misalignment errors detected by clang sanitizers for ppc64 and ppc64le. In addition, only ppc64 allocates space for VSX registers, so do not save them for ppc32. The kernel only has references to

[PATCH for-5.0?] target/xtensa: Statically allocate xtensa_insnbufs

2020-04-06 Thread Richard Henderson
Rather than dynamically allocate, and risk failing to free when we longjmp out of the translator, allocate the maximum buffer size from any of the supported cpus, which is 8: core-dc232b/xtensa-modules.inc.c: 3 /* insn_size */, 0, core-dc233c/xtensa-modules.inc.c: 3 /* insn_size */, 0, core-de21

[Bug 1863441] Re: cmd_mode_sense always reports 0x70, no CDROM present

2020-04-06 Thread Benjamin David Lunt
Since I posted this bug report, I have done a little more research and this specific part of this command is actually quite obsolete. It use to be documented (MMC v1.2 Draft), but later versions have actually removed this part of the command, even stating "obsolete" in some of the documentation.

[Bug 1871267] Re: Multiple (Repeating) Keystrokes in macOS

2020-04-06 Thread Russell Morris
BTW, it does make the guest unusable ... can't even enter a password (if I could get that far, having issues even running setup). Thanks! -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1871267 Title:

[Bug 1871267] [NEW] Multiple (Repeating) Keystrokes in macOS

2020-04-06 Thread Russell Morris
Public bug reported: Hi, I am finding this issue with v4.2.0, or the latest master - on a Windows host, with macOS guest. It happens using gtk (SPICE?) or VNC. When I get to a place to enter a keystroke, I quite reliably get multiple of the same key (i.e. press A, get ). Thinking there may b

[Bug 1871270] [NEW] [Feature Request] add usbredir device reset blacklist options support to allow macOS guest to iOS device usbredir

2020-04-06 Thread Michael Lee
Public bug reported: Description of problem: Currently, when a iOS device is redirected to a macOS VM, it falls into a reset-not-found loop. Version-Release number of selected component (if applicable): latest How reproducible: 100% Steps to Reproduce: Connect an iOS device to Ubuntu 18.04.2 LT

Re: [RFC PATCH-for-5.0?] target/mips/translate: Report exception in delay slot as UNPREDICTABLE

2020-04-06 Thread Philippe Mathieu-Daudé
On 4/7/20 1:54 AM, Philippe Mathieu-Daudé wrote: Using the BC1ANY4F instruction with a 24Kf core (MIPS32R2 & ASE_MIPS16) we get: $ echo -ne '\x03\x20\xf8\x09' > cop1x.bin $ qemu-system-mipsel -bios cop1x.bin unknown branch 0x13000 Aborted (core dumped) (gdb) bt #0 0x7

[RFC PATCH-for-5.0?] target/mips/translate: Report exception in delay slot as UNPREDICTABLE

2020-04-06 Thread Philippe Mathieu-Daudé
Using the BC1ANY4F instruction with a 24Kf core (MIPS32R2 & ASE_MIPS16) we get: $ echo -ne '\x03\x20\xf8\x09' > cop1x.bin $ qemu-system-mipsel -bios cop1x.bin unknown branch 0x13000 Aborted (core dumped) (gdb) bt #0 0x7fe2d38b1e35 in raise () at /lib64/libc.so.6 #1 0x7

[Bug 1871250] [NEW] Failed to create HAX VM

2020-04-06 Thread Russell Morris
Public bug reported: Hi, I'm running the latest (master) of QEMU, though the version doesn't seem to matter - I also checked back to v4.2.0, exactly the same issue. And this isn't about the VM (guest), if I even just try to run, > "c:\Program Files\qemu\qemu-system-x86_64.exe" -accel hax Basica

[Bug 1663287] Re: Illegal delay slot code causes abort on mips64

2020-04-06 Thread Philippe Mathieu-Daudé
Hi Brian, You try to execute a CP1 instruction in a delay slot, which triggers a Reserved Instruction exception. Per the ISA the processor operation is UNPREDICTABLE in such case. What is the behavior on real hardware? An assertion() seems appropriate. Your compiler might be buggy, or you are no

[PATCH v1] nrf51: Fix last GPIO CNF address

2020-04-06 Thread Cameron Esfahani via
NRF51_GPIO_REG_CNF_END doesn't actually refer to the start of the last valid CNF register: it's referring to the last byte of the last valid CNF register. This hasn't been a problem up to now, as current implementation in memory.c turns an unaligned 4-byte read from 0x77f to a single byte read and

Re: [PATCH v1] usb: Add read support for HCIVERSION register to XHCI

2020-04-06 Thread Cameron Esfahani via
I had a look at this failing test case after running applying Cedric's patch (https://github.com/legoater/qemu/commit/d57ac950c4be47a2bafd6c6a96dec2922c2ecd65). It looks like this is just a bug in the test case. The test case is attempting to verify that the CNF registers are programmed correct

Re: qcow2: Zero-initialization of external data files

2020-04-06 Thread Eric Blake
On 2/17/20 10:56 AM, Max Reitz wrote: Hi, AFAIU, external data files with data_file_raw=on are supposed to return the same data as the qcow2 file when read. But we still use the qcow2 metadata structures (which are by default initialized to “everything unallocated”), even though we never ensure

Re: [PATCH-for-5.0?] .github: Enable repo-lockdown bot to refuse GitHub pull requests

2020-04-06 Thread John Snow
On 4/6/20 5:41 PM, Philippe Mathieu-Daudé wrote: > Some GitHub users try to open pull requests against the GitHub > mirror. Unfortunate these get ignored until eventually someone > notices and closes the request. > > Enable the 'Repo Lockdown' [*] 3rd party bot which can autorespond > to pull r

[PATCH-for-5.0?] .github: Enable repo-lockdown bot to refuse GitHub pull requests

2020-04-06 Thread Philippe Mathieu-Daudé
Some GitHub users try to open pull requests against the GitHub mirror. Unfortunate these get ignored until eventually someone notices and closes the request. Enable the 'Repo Lockdown' [*] 3rd party bot which can autorespond to pull requests with a friendly comment, close the request, and then loc

Re: [RFC PATCH v2 7/7] vfio-ccw: Add support for the CRW irq

2020-04-06 Thread Eric Farman
On 4/6/20 12:22 PM, Cornelia Huck wrote: > On Thu, 6 Feb 2020 22:45:09 +0100 > Eric Farman wrote: > >> From: Farhan Ali >> >> The CRW irq will be used by vfio-ccw to notify the userspace >> about any CRWs the userspace needs to handle. Let's add support >> for it. >> >> Signed-off-by: Farhan

Re: [PATCH v3 12/12] configure: Add -Werror to PIE probe

2020-04-06 Thread Philippe Mathieu-Daudé
On 4/3/20 9:11 PM, Alex Bennée wrote: From: Richard Henderson Without -Werror, the probe may succeed, but then compilation fails later when -Werror is added for other reasons. Shows up on windows, where the compiler complains about -fPIC. Signed-off-by: Richard Henderson Signed-off-by: Alex

[Bug 1663287] Re: Illegal delay slot code causes abort on mips64

2020-04-06 Thread martin short
I found the exact same bug. Tested on several hosts and qemu releases. The newest one I tested was on FreeBSD 12.1 host and qemu-4.1.1_1 built from ports. Instructions: 4000d0: 0320f809jalrt9 4000d4: 454545450x45454545 # bc1any4t $fcc1,0x800101f8 I was

[PATCH] ati-vga: Fix checks in ati_2d_blt() to avoid crash

2020-04-06 Thread BALATON Zoltan
In some corner cases (that never happen during normal operation but a malicious guest could program wrong values) pixman functions were called with parameters that result in a crash. Fix this and add more checks to disallow such cases. Reported-by: Ziming Zhang Signed-off-by: BALATON Zoltan ---

Re: [PATCH-for-5.1 v2 00/54] various: Fix error-propagation with Coccinelle scripts

2020-04-06 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200406174743.16956-1-f4...@amsat.org/ 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-for-5.1 v2 00/54] various: Fix error-propagation with Coccinelle scripts

2020-04-06 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200406174743.16956-1-f4...@amsat.org/ Hi, This series failed the asan 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 === #!/bin/bash export A

Re: [PATCH v4 0/3] Fix some AIO context locking in jobs

2020-04-06 Thread John Snow
On 4/2/20 8:48 AM, Kevin Wolf wrote: > Am 01.04.2020 um 10:15 hat Stefan Reiter geschrieben: >> Contains three seperate but related patches cleaning up and fixing some >> issues regarding aio_context_acquire/aio_context_release for jobs. Mostly >> affects blockjobs running for devices that have

Re: [PATCH-for-5.1 v2 37/54] scripts/coccinelle: Add script to catch missing error_propagate() calls

2020-04-06 Thread Eric Blake
On 4/6/20 12:47 PM, Philippe Mathieu-Daudé wrote: In some places in we put an error into a local Error*, but forget to check for failure and pass it back to the caller. Add a Coccinelle patch to catch automatically add the missing code. s/catch/catch and/ Inspired-by: Peter Maydell Signed-o

Re: [PATCH 2/4] atomics: update documentation for C11

2020-04-06 Thread Eric Blake
On 4/6/20 2:13 PM, Paolo Bonzini wrote: Deprecate atomic_mb_read and atomic_mb_set; it is not really possible to use them correctly because they do not interoperate with sequentially-consistent RMW operations. Signed-off-by: Paolo Bonzini --- docs/devel/atomics.rst | 290 -

Re: [PATCH 1/4] atomics: convert to reStructuredText

2020-04-06 Thread Eric Blake
On 4/6/20 2:13 PM, Paolo Bonzini wrote: Signed-off-by: Paolo Bonzini --- docs/devel/atomics.rst | 447 + docs/devel/atomics.txt | 403 - docs/devel/index.rst | 1 + 3 files changed, 448 insertions(+), 403 deleti

Re: FYI GitHub pull request / issue tracker lockdown bot

2020-04-06 Thread John Snow
On 4/3/20 10:22 AM, Daniel P. Berrangé wrote: > QEMU, like libvirt, has a github.com project which contains automated > read-only mirrors of QEMU repositories. > > https://github.com/qemu/ > > An unfortunate side effect of this is that some users will try to open > pull requests against thes

Re: [PATCH v2 16/22] intel_iommu: replay pasid binds after context cache invalidation

2020-04-06 Thread Peter Xu
On Sat, Apr 04, 2020 at 12:00:12PM +, Liu, Yi L wrote: > Hi Peter, > > > From: Peter Xu > > Sent: Saturday, April 4, 2020 12:11 AM > > To: Liu, Yi L > > Subject: Re: [PATCH v2 16/22] intel_iommu: replay pasid binds after context > > cache > > invalidation > > > > On Fri, Apr 03, 2020 at 03

[Bug 1863441] Re: cmd_mode_sense always reports 0x70, no CDROM present

2020-04-06 Thread John Snow
Hi, if you can quote the relevant spec, would you like to include that in a commit message and send a patch? Also, does this result in a bug anywhere visible that we can test against? -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. h

Re: [PATCH-for-5.1 v2 53/54] hw/mips/mips_malta: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
On 4/6/20 7:47 PM, Philippe Mathieu-Daudé wrote: Running the coccinelle script produced: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/find-missing-error_propagate.cocci \ --keep-comments --smpl-spacing --dir . HANDLING:

[PATCH 4/4] async: use explicit memory barriers and relaxed accesses

2020-04-06 Thread Paolo Bonzini
When using C11 atomics, non-seqcst reads and writes do not participate in the total order of seqcst operations. In util/async.c and util/aio-posix.c, in particular, the pattern that we use write ctx->notify_me write bh->scheduled read bh->scheduled

[PATCH 3/4] rcu: do not mention atomic_mb_read/set in documentation

2020-04-06 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- docs/devel/rcu.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/devel/rcu.txt b/docs/devel/rcu.txt index d83fed2f79..0ce15ba198 100644 --- a/docs/devel/rcu.txt +++ b/docs/devel/rcu.txt @@ -132,7 +132,7 @@ The core RCU API is small:

[PATCH 2/4] atomics: update documentation for C11

2020-04-06 Thread Paolo Bonzini
Deprecate atomic_mb_read and atomic_mb_set; it is not really possible to use them correctly because they do not interoperate with sequentially-consistent RMW operations. Signed-off-by: Paolo Bonzini --- docs/devel/atomics.rst | 290 - 1 file changed, 114 i

[RFC PATCH 0/4] async: fix hangs on weakly-ordered architectures

2020-04-06 Thread Paolo Bonzini
Patch 4 fixes qemu-img and qemu-io hangs on weakly-ordered architectures. Patch 1-3 are related docs fixes and improvements. This is RFC because it relies on the iothread being locked during aio_poll on the main AioContext. If I add assertions for this however I see a failure for test 267, so I a

[PATCH 1/4] atomics: convert to reStructuredText

2020-04-06 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- docs/devel/atomics.rst | 447 + docs/devel/atomics.txt | 403 - docs/devel/index.rst | 1 + 3 files changed, 448 insertions(+), 403 deletions(-) create mode 100644 docs/devel/atomics.

Re: [PATCH-for-5.1 7/8] .travis.yml: Run fetch-acceptance-assets before check-acceptance

2020-04-06 Thread Willian Rampazzo
On Mon, Apr 6, 2020 at 3:21 PM Alex Bennée wrote: > > > Willian Rampazzo writes: > > > On Mon, Apr 6, 2020 at 12:39 PM Philippe Mathieu-Daudé > > wrote: > >> > >> On 4/6/20 5:31 PM, Alex Bennée wrote: > >> > > >> > Philippe Mathieu-Daudé writes: > >> > > >> >> Signed-off-by: Philippe Mathieu-Da

Re: [PATCH for-5.0] tcg/i386: Fix %r12 guest_base initialization

2020-04-06 Thread Alex Bennée
Richard Henderson writes: > When %gs cannot be used, we use register offset addressing. > This path is almost never used, so it was clearly not tested. > > Signed-off-by: Richard Henderson Reviewed-by: Alex Bennée Tested-by: Alex Bennée > --- > tcg/i386/tcg-target.inc.c | 2 +- > 1 file c

Re: [RFC PATCH v2 1/7] vfio-ccw: Return IOINST_CC_NOT_OPERATIONAL for EIO

2020-04-06 Thread Eric Farman
On 4/1/20 4:52 AM, Cornelia Huck wrote: > On Wed, 25 Mar 2020 03:24:28 +0100 > Halil Pasic wrote: > >> On Tue, 24 Mar 2020 18:04:30 +0100 >> Cornelia Huck wrote: >> >>> On Thu, 6 Feb 2020 22:45:03 +0100 >>> Eric Farman wrote: >>> From: Farhan Ali EIO is returned by vfio-c

Re: [PATCH-for-5.1 7/8] .travis.yml: Run fetch-acceptance-assets before check-acceptance

2020-04-06 Thread Willian Rampazzo
On Mon, Apr 6, 2020 at 12:39 PM Philippe Mathieu-Daudé wrote: > > On 4/6/20 5:31 PM, Alex Bennée wrote: > > > > Philippe Mathieu-Daudé writes: > > > >> Signed-off-by: Philippe Mathieu-Daudé > >> --- > >> .travis.yml | 2 +- > >> 1 file changed, 1 insertion(+), 1 deletion(-) > >> > >> diff --g

Re: [PATCH-for-5.1 7/8] .travis.yml: Run fetch-acceptance-assets before check-acceptance

2020-04-06 Thread Alex Bennée
Willian Rampazzo writes: > On Mon, Apr 6, 2020 at 12:39 PM Philippe Mathieu-Daudé > wrote: >> >> On 4/6/20 5:31 PM, Alex Bennée wrote: >> > >> > Philippe Mathieu-Daudé writes: >> > >> >> Signed-off-by: Philippe Mathieu-Daudé >> >> --- >> >> .travis.yml | 2 +- >> >> 1 file changed, 1 inse

[PATCH-for-5.1 v2 50/54] scripts/coccinelle: Find eventually missing error_propagate() calls

2020-04-06 Thread Philippe Mathieu-Daudé
In some places in we put an error into a local Error*, but forget to use it. Add a Coccinelle patch to find such cases and report them. Inspired-by: Peter Maydell Signed-off-by: Philippe Mathieu-Daudé --- .../find-missing-error_propagate.cocci| 53 +++ MAINTAINERS

[PATCH-for-5.1 v2 52/54] hw/mips/boston: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Running the coccinelle script produced: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/find-missing-error_propagate.cocci \ --keep-comments --smpl-spacing --dir . HANDLING: ./hw/mips/boston.c [[manual check required: error_prop

[PATCH-for-5.1 v2 43/54] hw/mips/cps: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/object_property_missing_error_propagate.cocci \ --keep-comments --smpl-spacing --in-place --dir hw Unfortunately the cocci script doesn't proper

Re: [PATCH-for-5.1 v2 03/54] hw/arm/allwinner-a10: Move some code from realize() to init()

2020-04-06 Thread Eric Blake
On 4/6/20 12:46 PM, Philippe Mathieu-Daudé wrote: Coccinelle reported: $ spatch ... --timeout 60 --sp-file \ scripts/coccinelle/simplify-init-realize-error_propagate.cocci HANDLING: ./hw/arm/allwinner-a10.c >>> possible moves from aw_a10_init() to aw_a10_realize() in ./hw/arm/allw

Re: [PATCH-for-5.1 v2 38/54] hw/arm/bcm2835_peripherals: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
On 4/6/20 7:47 PM, Philippe Mathieu-Daudé wrote: Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/object_property_missing_error_propagate.cocci \ sigh I forgot to update this, the scrip has

[PATCH-for-5.1 v2 48/54] scripts/coccinelle: Use &error_abort in TypeInfo::instance_init()

2020-04-06 Thread Philippe Mathieu-Daudé
The instance_init() calls are not suppose to fail. Add a Coccinelle script to use &error_abort instead of ignoring errors by using a NULL Error*. Signed-off-by: Philippe Mathieu-Daudé --- .../use-error_abort-in-instance_init.cocci| 52 +++ MAINTAINERS

[PATCH-for-5.1 v2 42/54] hw/i386/x86: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Running the coccinelle script: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/object_property_missing_error_propagate.cocci \ --keep-comments --smpl-spacing --dir hw inserted a block after object_property_set_uint("apic-id") which

Re: [PATCH-for-5.1 6/8] tests/Makefile: Add fetch-acceptance-assets rule

2020-04-06 Thread Alex Bennée
Willian Rampazzo writes: > On Mon, Apr 6, 2020 at 12:41 PM Alex Bennée wrote: >> >> >> Philippe Mathieu-Daudé writes: >> >> > Signed-off-by: Philippe Mathieu-Daudé >> > --- >> > tests/Makefile.include | 7 +++ >> > 1 file changed, 7 insertions(+) >> > >> > diff --git a/tests/Makefile.in

[PATCH-for-5.1 v2 41/54] hw/dma/xilinx_axidma: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/object_property_missing_error_propagate.cocci \ --keep-comments --smpl-spacing --dir hw Then review showed this file has a 'xilinx_axidma_realiz

[PATCH-for-5.1 v2 49/54] various: Use &error_abort in instance_init()

2020-04-06 Thread Philippe Mathieu-Daudé
Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h \ --include-headers --keep-comments --in-place \ --sp-file \ scripts/coccinelle/use-error_abort-in-instance_init.cocci Signed-off-by: Philippe Mathieu-Daudé --- backends/cryptodev-vhost

Re: [PATCH-for-5.1 v2 49/54] various: Use &error_abort in instance_init()

2020-04-06 Thread Philippe Mathieu-Daudé
On 4/6/20 7:47 PM, Philippe Mathieu-Daudé wrote: Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h \ --include-headers --keep-comments --in-place \ --sp-file \ scripts/coccinelle/use-error_abort-in-instance_init.cocci Signed-off-b

[PATCH-for-5.1 v2 36/54] hw/block/onenand: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/use-error_propagate-in-realize.cocci \ --keep-comments --smpl-spacing --in-place --dir hw Signed-off-by: Philippe Mathieu-Daudé --- hw/block/o

[PATCH-for-5.1 v2 54/54] qga/commands-win32: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Running the coccinelle script produced: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/find-missing-error_propagate.cocci \ --keep-comments --smpl-spacing --dir . HANDLING: ./qga/commands-win32.c [[manual check required: error_

[PATCH-for-5.1 v2 34/54] hw/microblaze/xlnx-zynqmp-pmu: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/use-error_propagate-in-realize.cocci \ --keep-comments --smpl-spacing --in-place --dir hw Signed-off-by: Philippe Mathieu-Daudé --- hw/microbl

[PATCH-for-5.1 v2 51/54] migration/colo: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Running the coccinelle script produced: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/find-missing-error_propagate.cocci \ --keep-comments --smpl-spacing --dir . HANDLING: ./migration/colo.c [[manual check required: error_prop

Re: [PATCH-for-5.1 6/8] tests/Makefile: Add fetch-acceptance-assets rule

2020-04-06 Thread Willian Rampazzo
On Mon, Apr 6, 2020 at 12:41 PM Alex Bennée wrote: > > > Philippe Mathieu-Daudé writes: > > > Signed-off-by: Philippe Mathieu-Daudé > > --- > > tests/Makefile.include | 7 +++ > > 1 file changed, 7 insertions(+) > > > > diff --git a/tests/Makefile.include b/tests/Makefile.include > > index

[PATCH-for-5.1 v2 32/54] hw/arm/armv7m: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/use-error_propagate-in-realize.cocci \ --keep-comments --smpl-spacing --in-place --dir hw Signed-off-by: Philippe Mathieu-Daudé --- hw/arm/arm

[PATCH-for-5.1 v2 44/54] hw/misc/macio/macio: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/object_property_missing_error_propagate.cocci \ --keep-comments --smpl-spacing --dir hw Reviewed-by: David Gibson Acked-by: David Gibson Revie

Re: [PATCH-for-5.1 v2 01/54] various: Remove suspicious '\' character outside of #define in C code

2020-04-06 Thread Marc-André Lureau
Hi On Mon, Apr 6, 2020 at 7:48 PM Philippe Mathieu-Daudé wrote: > > Fixes the following coccinelle warnings: > > $ spatch --sp-file --verbose-parsing ... \ > scripts/coccinelle/remove_local_err.cocci > ... > SUSPICIOUS: a \ character appears outside of a #define at > ./target/ppc/tr

Re: [PATCH for-5.0? v2] qcow2: Explicit mention of padding bytes

2020-04-06 Thread Vladimir Sementsov-Ogievskiy
06.04.2020 16:32, Eric Blake wrote: On 4/6/20 3:50 AM, Vladimir Sementsov-Ogievskiy wrote: 03.04.2020 21:19, Eric Blake wrote: Although we already covered the need for padding bytes with our changes in commit 3ae3fcfa, commit 66fcbca5 just added one byte and relied on the rest of the text for i

[PATCH-for-5.1 v2 31/54] hw/riscv/sifive: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/use-error_propagate-in-realize.cocci \ --keep-comments --smpl-spacing --in-place --dir hw Signed-off-by: Philippe Mathieu-Daudé --- hw/riscv/s

[PATCH-for-5.1 v2 47/54] hw/sd/milkymist-memcard: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/object_property_missing_error_propagate.cocci \ --keep-comments --smpl-spacing --dir hw Signed-off-by: Philippe Mathieu-Daudé --- hw/sd/milkym

[PATCH-for-5.1 v2 30/54] hw/arm/msf2-soc: Add missing error-propagation code

2020-04-06 Thread Philippe Mathieu-Daudé
Patch created mechanically by running: $ spatch \ --macro-file scripts/cocci-macro-file.h --include-headers \ --sp-file scripts/coccinelle/use-error_propagate-in-realize.cocci \ --keep-comments --smpl-spacing --in-place --dir hw Signed-off-by: Philippe Mathieu-Daudé --- hw/arm/msf

  1   2   3   4   >