Re: [PATCH 0/4] qemu-storage-daemon: QAPIfy --chardev the stupid way

2020-10-28 Thread Markus Armbruster
Paolo Bonzini writes: > On 26/10/20 11:10, Markus Armbruster wrote: >> Kevin's "[PATCH v2 0/6] qemu-storage-daemon: QAPIfy --chardev" >> involves surgery to the QAPI generator. Some (most?) of it should go >> away if we deprecate the "data" wrappers due to simple unions in QMP. >> >> Do we real

[PATCH 2/4] kvm: Replace DEBUG_KVM with CONFIG_DEBUG_KVM

2020-10-28 Thread AlexChen
Now we can control the definition of DPRINTF by CONFIG_DEBUG_KVM, so let's replace DEBUG_KVM with CONFIG_DEBUG_KVM. Signed-off-by: AlexChen --- accel/kvm/kvm-all.c | 3 +-- target/i386/kvm.c | 4 +--- target/mips/kvm.c | 6 -- target/s390x/kvm.c | 6 +++--- 4 files changed, 9 insertions

[PATCH 1/4] configure: Add a --enable-debug-kvm option to configure

2020-10-28 Thread AlexChen
This patch allows CONFIG_DEBUG_KVM to be defined when passing an option to the configure script. Signed-off-by: AlexChen --- configure | 10 ++ 1 file changed, 10 insertions(+) diff --git a/configure b/configure index e6754c1e87..2cdef5be4c 100755 --- a/configure +++ b/configure @@ -338

[PATCH 0/4] kvm: Add a --enable-debug-kvm option to configure

2020-10-28 Thread AlexChen
The current 'DEBUG_KVM' macro is defined in many files, and turning on the debug switch requires code modification, which is very inconvenient, so this series add an option to configure to support the definition of the 'DEBUG_KVM' macro. In addition, patches 3 and 4 also make printf always compile

[PATCH 3/4] kvm: make printf always compile in debug output

2020-10-28 Thread AlexChen
Wrapped printf calls inside debug macros (DPRINTF) in `if` statement. This will ensure that printf function will always compile even if debug output is turned off and, in turn, will prevent bitrot of the format strings. Signed-off-by: AlexChen --- accel/kvm/kvm-all.c | 10 -- 1 file chan

[PATCH 4/4] i386/kvm: make printf always compile in debug output

2020-10-28 Thread AlexChen
Wrapped printf calls inside debug macros (DPRINTF) in `if` statement. This will ensure that printf function will always compile even if debug output is turned off and, in turn, will prevent bitrot of the format strings. Signed-off-by: AlexChen --- target/i386/kvm.c | 11 +-- 1 file chang

Re: [PATCH 3/4] char: Flat alternative to overly nested chardev-add arguments

2020-10-28 Thread Markus Armbruster
Eric Blake writes: > On 10/26/20 5:10 AM, Markus Armbruster wrote: >> chardev-add's arguments use an annoying amount of nesting. Example: >> >> {"execute": "chardev-add", >> "arguments": { >> "id":"sock0", >> "backend": { >> "type": "socket", >> "data

Re: [PATCH 4/4] qemu-storage-daemon: QAPIfy --chardev

2020-10-28 Thread Markus Armbruster
Eric Blake writes: > On 10/26/20 5:10 AM, Markus Armbruster wrote: >> From: Kevin Wolf >> >> This removes the dependency on QemuOpts from the --chardev option of >> the storage daemon. >> >> Help on option parameters is still wrong. Marked FIXME. >> >> There are quite a few differences betwe

Re: [PATCH 0/4] kvm: Add a --enable-debug-kvm option to configure

2020-10-28 Thread Paolo Bonzini
On 28/10/20 08:11, AlexChen wrote: > The current 'DEBUG_KVM' macro is defined in many files, and turning on > the debug switch requires code modification, which is very inconvenient, > so this series add an option to configure to support the definition of > the 'DEBUG_KVM' macro. > In addition, pat

Re: [PATCH-for-5.2] block/nvme: Fix nvme_submit_command() on big-endian host

2020-10-28 Thread Stefan Hajnoczi
On Tue, Oct 27, 2020 at 05:04:07PM +0100, Philippe Mathieu-Daudé wrote: > The Completion Queue Command Identifier is a 16-bit value, > so nvme_submit_command() is unlikely to work on big-endian > hosts, as the relevant bits are truncated. > > The "Completion Queue Entry: DW 2" describes it as: >

Re: [PATCH] Revert series: virtiofsd: Announce submounts to the guest

2020-10-28 Thread Stefan Hajnoczi
On Tue, Oct 27, 2020 at 08:13:28PM -0600, Alex Williamson wrote: > This reverts the following commits due to their basis on a bogus > linux kernel header update: What was the issue? Did the sub-mounts series include kernel header changes that haven't landed in Linux yet? signature.asc Descriptio

[PATCH] block: Move bdrv_drain_all_end_quiesce() to block_int.h

2020-10-28 Thread Greg Kurz
This function is really an internal helper for bdrv_close(). Update its doc comment to make this clear and make the function private. Signed-off-by: Greg Kurz --- As suggested by Stefan here: https://lists.gnu.org/archive/html/qemu-devel/2020-10/msg08235.html --- include/block/block.h |

Re: [PULL 00/32] VFIO updates 2020-10-26 (for QEMU 5.2 soft-freeze)

2020-10-28 Thread Cornelia Huck
On Tue, 27 Oct 2020 23:42:57 + Peter Maydell wrote: > On Mon, 26 Oct 2020 at 19:39, Alex Williamson > wrote: > > > > VFIO update 2020-10-26 > > > > * Migration support (Kirti Wankhede) > > * s390 DMA limiting (Matthew Rosato)

Re: [PATCH 4/5] python: add .gitignore

2020-10-28 Thread Thomas Huth
On 27/10/2020 23.38, John Snow wrote: > Ignore build and package output (build, dist, qemu.egg-info); > effectively these are "in-tree" builds of a kind. Since we recently moved away from in-tree builds, could these also be made out-of-tree only? Thomas

Re: [PATCH 0/4] kvm: Add a --enable-debug-kvm option to configure

2020-10-28 Thread Cornelia Huck
On Wed, 28 Oct 2020 08:44:59 +0100 Paolo Bonzini wrote: > On 28/10/20 08:11, AlexChen wrote: > > The current 'DEBUG_KVM' macro is defined in many files, and turning on > > the debug switch requires code modification, which is very inconvenient, > > so this series add an option to configure to sup

[PULL 02/10] sparc32-ledma: use object_initialize_child() for lance child object

2020-10-28 Thread Mark Cave-Ayland
Store the child object directly within the sparc32-ledma object rather than using link properties. Signed-off-by: Mark Cave-Ayland Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20200926140216.7368-3-mark.cave-ayl...@ilande.co.uk> Signed-off-by: Mark Cave-Ayland --- hw/dma/sparc32_dma.c

[PULL 09/10] hw/pci-host/sabre: Remove superfluous address range check

2020-10-28 Thread Mark Cave-Ayland
From: Philippe Mathieu-Daudé The region is registered as 64KiB in sabre_init(): memory_region_init_io(&s->sabre_config, OBJECT(s), &sabre_config_ops, s, "sabre-config", 0x1); Remove the superfluous check. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Mar

[PULL 01/10] sparc32-dma: use object_initialize_child() for espdma and ledma child objects

2020-10-28 Thread Mark Cave-Ayland
Store the child objects directly within the sparc32-dma object rather than using link properties. Signed-off-by: Mark Cave-Ayland Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20200926140216.7368-2-mark.cave-ayl...@ilande.co.uk> Signed-off-by: Mark Cave-Ayland --- hw/dma/sparc32_dma.c

[PULL 00/10] qemu-sparc queue 20201028

2020-10-28 Thread Mark Cave-Ayland
tags/qemu-sparc-20201028 for you to fetch changes up to 0980307e705b5677d9b4158a0a0346abf5041f33: hw/pci-host/sabre: Simplify code initializing variable once (2020-10-28 07:59:26 +) qemu-s

[PULL 05/10] sabre: don't call sysbus_mmio_map() in sabre_realize()

2020-10-28 Thread Mark Cave-Ayland
The device should not map itself but instead should be mapped to sysbus by the sun4u machine. Signed-off-by: Mark Cave-Ayland Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20200926140216.7368-7-mark.cave-ayl...@ilande.co.uk> Signed-off-by: Mark Cave-Ayland --- hw/pci-host/sabre.c | 8 --

[PULL 03/10] sparc32-espdma: use object_initialize_child() for esp child object

2020-10-28 Thread Mark Cave-Ayland
Store the child object directly within the sparc32-espdma object rather than using link properties. Signed-off-by: Mark Cave-Ayland Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20200926140216.7368-4-mark.cave-ayl...@ilande.co.uk> Signed-off-by: Mark Cave-Ayland --- hw/dma/sparc32_dma.c

[PULL 07/10] sabre: increase number of PCI bus IRQs from 32 to 64

2020-10-28 Thread Mark Cave-Ayland
The rework of the sabre IRQs in commit 6864fa3897 "sun4u: update PCI topology to include simba PCI bridges" changed the IRQ routing so that both PCI and legacy OBIO IRQs are routed through the sabre PCI host bridge to the CPU. Unfortunately this commit failed to increase the number of PCI bus IRQs

[PULL 04/10] sparc32-ledma: don't reference nd_table directly within the device

2020-10-28 Thread Mark Cave-Ayland
Instead use qdev_set_nic_properties() to configure the on-board NIC at the sun4m machine level. Signed-off-by: Mark Cave-Ayland Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20200926140216.7368-5-mark.cave-ayl...@ilande.co.uk> Signed-off-by: Mark Cave-Ayland --- hw/dma/sparc32_dma.c | 5 --

[PULL 06/10] hw/display/tcx: Allow 64-bit accesses to framebuffer stippler and blitter

2020-10-28 Thread Mark Cave-Ayland
From: Philippe Mathieu-Daudé <1892...@bugs.launchpad.net> The S24/TCX datasheet is listed as "Unable to locate" on [1]. However the NetBSD revision 1.32 of the driver introduced 64-bit accesses to the stippler and blitter [2]. It is safe to assume these memory regions are 64-bit accessible. QEMU

[PULL 08/10] hw/pci-host/sabre: Update documentation link

2020-10-28 Thread Mark Cave-Ayland
From: Philippe Mathieu-Daudé The current link redirects to https://www.oracle.com/sun/ announcing "Oracle acquired Sun Microsystems in 2010, ..." but does not give hint where to find the datasheet. Use the archived PDF on the Wayback Machine, which works. Signed-off-by: Philippe Mathieu-Daudé

[PULL 10/10] hw/pci-host/sabre: Simplify code initializing variable once

2020-10-28 Thread Mark Cave-Ayland
From: Philippe Mathieu-Daudé We only need to zero-initialize 'val' once. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Mark Cave-Ayland Message-Id: <20201012170950.3491912-4-f4...@amsat.org> Signed-off-by: Mark Cave-Ayland --- hw/pci-host/sabre.c | 12 +--- 1 file changed, 1 ins

Re: [PATCH 2/5] python: add excluded dirs to flake8 config

2020-10-28 Thread Philippe Mathieu-Daudé
On 10/27/20 11:38 PM, John Snow wrote: > Following patches make obvious that we ought to ignore certain > directories to avoid wildly erroneous flake8 output. > > Signed-off-by: John Snow > --- > python/setup.cfg | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/python/setup.cfg b/pyth

[RFC PATCH] hw/arm/virt: use sbsa-ec for reboot and poweroff in secure mode

2020-10-28 Thread Maxim Uvarov
If we're emulating EL3 then the EL3 guest firmware is responsible for providing the PSCI ABI, including reboot, core power down, etc. sbsa-ref machine has an embedded controller to do reboot, poweroff. Machine virt,secure=on can reuse this code to do reboot inside ATF. Signed-off-by: Maxim Uvarov

[PATCH 3/3] hw/9pfs : add space before the open parenthesis '('

2020-10-28 Thread jokenzhang
Signed-off-by: jokenzhang Signed-off-by: Kai Deng Reported-by: Euler Robot --- hw/9pfs/cofs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/9pfs/cofs.c b/hw/9pfs/cofs.c index 55991916ec..0b321b456e 100644 --- a/hw/9pfs/cofs.c +++ b/hw/9pfs/cofs.c @@ -23,7 +23,7 @@ stati

[PATCH 1/3] hw/9pfs : add spaces around operator

2020-10-28 Thread jokenzhang
Signed-off-by: jokenzhang Signed-off-by: Kai Deng Reported-by: Euler Robot --- hw/9pfs/9p-local.c | 10 +- hw/9pfs/9p.c | 16 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/hw/9pfs/9p-local.c b/hw/9pfs/9p-local.c index 3107637209..af52c1daac 1006

[PATCH 2/3] hw/9pfs : open brace '{' following struct go on the same line

2020-10-28 Thread jokenzhang
Signed-off-by: jokenzhang Signed-off-by: Kai Deng Reported-by: Euler Robot --- hw/9pfs/9p.h | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/hw/9pfs/9p.h b/hw/9pfs/9p.h index 3dd1b50b1a..32df81f360 100644 --- a/hw/9pfs/9p.h +++ b/hw/9pfs/9p.h @@ -143,8 +143,7 @@ type

Re: [PATCH 4/5] python: add .gitignore

2020-10-28 Thread Markus Armbruster
Thomas Huth writes: > On 27/10/2020 23.38, John Snow wrote: >> Ignore build and package output (build, dist, qemu.egg-info); >> effectively these are "in-tree" builds of a kind. > > Since we recently moved away from in-tree builds, could these also be made > out-of-tree only? The build should on

Re: [PATCH 4/4] qemu-storage-daemon: QAPIfy --chardev

2020-10-28 Thread Markus Armbruster
Markus Armbruster writes: > From: Kevin Wolf > > This removes the dependency on QemuOpts from the --chardev option of > the storage daemon. > > Help on option parameters is still wrong. Marked FIXME. > > There are quite a few differences between qemu-system-FOO -chardev, > QMP chardev-add, and

Re: [PULL 00/32] VFIO updates 2020-10-26 (for QEMU 5.2 soft-freeze)

2020-10-28 Thread Max Reitz
On 28.10.20 03:00, Alex Williamson wrote: > On Tue, 27 Oct 2020 23:42:57 + > Peter Maydell wrote: > >> On Mon, 26 Oct 2020 at 19:39, Alex Williamson >> wrote: >>> >>> VFIO update 2020-10-26 >>> >>> * Migration support (Kirti W

Re: [PULL 00/32] VFIO updates 2020-10-26 (for QEMU 5.2 soft-freeze)

2020-10-28 Thread Dr. David Alan Gilbert
* Alex Williamson (alex.william...@redhat.com) wrote: > On Tue, 27 Oct 2020 23:42:57 + > Peter Maydell wrote: > > > On Mon, 26 Oct 2020 at 19:39, Alex Williamson > > wrote: > > > > > > VFIO update 2020-10-26 > > > > > > * Migr

Re: [PATCH 4/5] python: add .gitignore

2020-10-28 Thread Daniel P . Berrangé
On Wed, Oct 28, 2020 at 10:16:33AM +0100, Markus Armbruster wrote: > Thomas Huth writes: > > > On 27/10/2020 23.38, John Snow wrote: > >> Ignore build and package output (build, dist, qemu.egg-info); > >> effectively these are "in-tree" builds of a kind. > > > > Since we recently moved away from

Re: [PATCH v2 1/1] hw/block/m25p80: Fix Numonyx fast read dummy cycle count

2020-10-28 Thread Philippe Mathieu-Daudé
Hi Joe, On 10/28/20 12:43 AM, Joe Komlodi wrote: > Numonyx chips determine the number of cycles to wait based on bits 7:4 in the > volatile configuration register. > > However, if these bits are 0x0 or 0xF, the number of dummy cycles to wait is > 10 on a QIOR or QIOR4 command, or 8 on any other c

Re: [PULL 00/32] VFIO updates 2020-10-26 (for QEMU 5.2 soft-freeze)

2020-10-28 Thread Max Reitz
On 28.10.20 09:11, Cornelia Huck wrote: > On Tue, 27 Oct 2020 23:42:57 + > Peter Maydell wrote: > >> On Mon, 26 Oct 2020 at 19:39, Alex Williamson >> wrote: >>> >>> VFIO update 2020-10-26 >>> >>> * Migration support (Kirti Wan

Re: [PATCH 3/3] iotests: Use Python 3 style super()

2020-10-28 Thread Philippe Mathieu-Daudé
On 10/27/20 5:38 PM, Kevin Wolf wrote: > pylint complains about the use of super with the current class and > instance as arguments in VM.__init__(): > > iotests.py:546:8: R1725: Consider using Python 3 style super() without > arguments (super-with-arguments) > > No reason not to follow the advi

RE: Out-of-Process Device Emulation session at KVM Forum 2020

2020-10-28 Thread Thanos Makatos
> -Original Message- > From: Stefan Hajnoczi > Sent: 27 October 2020 15:14 > To: qemu-devel@nongnu.org > Cc: Alex Bennée ; m...@redhat.com > ; john.g.john...@oracle.com; Elena Ufimtseva > ; kra...@redhat.com; > jag.ra...@oracle.com; Thanos Makatos ; > Felipe Franciosi ; Marc-André Lureau >

Re: [PATCH v2 3/6] configure: add option to enable LTO

2020-10-28 Thread Alex Bennée
Daniele Buono writes: > In terms of ar and linker, if you don't have the right mix it will just > stop at link time with an error. > > In terms of using gcc the errors may be a bit more subtle, similar to > what Daniel mentioned. Succesfully compiling but then showing issues at > runtime or in

Re: [PATCH v3 00/15] python: create installable package

2020-10-28 Thread Philippe Mathieu-Daudé
On 10/27/20 11:08 PM, John Snow wrote: > Ping O:-) > > Looking for feedback from at least Cleber and Eduardo before I barge > ahead and send a PR to include this on master. Additional packaging and > versioning feedback from Dan would be nice. > > (I know we have a very busy two weeks here; I wil

Re: [PATCH] Revert series: virtiofsd: Announce submounts to the guest

2020-10-28 Thread Max Reitz
On 28.10.20 08:55, Stefan Hajnoczi wrote: > On Tue, Oct 27, 2020 at 08:13:28PM -0600, Alex Williamson wrote: >> This reverts the following commits due to their basis on a bogus >> linux kernel header update: > > What was the issue? Did the sub-mounts series include kernel header > changes that hav

Re: [PULL 00/32] VFIO updates 2020-10-26 (for QEMU 5.2 soft-freeze)

2020-10-28 Thread Max Reitz
> changing the flag in question. As Adam wrote, I noted that I would thus *Alex, sorry :/

Re: [PATCH] Revert series: virtiofsd: Announce submounts to the guest

2020-10-28 Thread Dr. David Alan Gilbert
* Alex Williamson (alex.william...@redhat.com) wrote: > This reverts the following commits due to their basis on a bogus > linux kernel header update: > > c93a656f7b65 ("tests/acceptance: Add virtiofs_submounts.py") > 45ced7ca2f27 ("tests/acceptance/boot_linux: Accept SSH pubkey") > 08dce386e77e (

Re: [PATCH] Revert series: virtiofsd: Announce submounts to the guest

2020-10-28 Thread Max Reitz
On 28.10.20 03:13, Alex Williamson wrote: > This reverts the following commits due to their basis on a bogus > linux kernel header update: > > c93a656f7b65 ("tests/acceptance: Add virtiofs_submounts.py") > 45ced7ca2f27 ("tests/acceptance/boot_linux: Accept SSH pubkey") > 08dce386e77e ("virtiofsd:

Re: [PATCH] Revert series: virtiofsd: Announce submounts to the guest

2020-10-28 Thread Dr. David Alan Gilbert
* Max Reitz (mre...@redhat.com) wrote: > On 28.10.20 08:55, Stefan Hajnoczi wrote: > > On Tue, Oct 27, 2020 at 08:13:28PM -0600, Alex Williamson wrote: > >> This reverts the following commits due to their basis on a bogus > >> linux kernel header update: > > > > What was the issue? Did the sub-mou

Re: [PATCH 5/9] target/sparc/translate: silence the compiler warnings

2020-10-28 Thread Philippe Mathieu-Daudé
On 10/28/20 5:18 AM, Chen Qun wrote: > When using -Wimplicit-fallthrough in our CFLAGS, the compiler showed warning: > target/sparc/translate.c: In function ‘gen_st_asi’: > target/sparc/translate.c:2320:12: warning: this statement may fall through > [-Wimplicit-fallthrough=] > 2320 | if (

Re: [PATCH 6/9] target/sparc/win_helper: silence the compiler warnings

2020-10-28 Thread Philippe Mathieu-Daudé
On 10/28/20 5:18 AM, Chen Qun wrote: > When using -Wimplicit-fallthrough in our CFLAGS, the compiler showed warning: > target/sparc/win_helper.c: In function ‘get_gregset’: > target/sparc/win_helper.c:304:9: warning: this statement may fall through > [-Wimplicit-fallthrough=] > 304 | tra

Re: [PATCH 8/9] target/ppc: silence the compiler warnings

2020-10-28 Thread Philippe Mathieu-Daudé
On 10/28/20 5:18 AM, Chen Qun wrote: > When using -Wimplicit-fallthrough in our CFLAGS, the compiler showed warning: > target/ppc/mmu_helper.c: In function ‘dump_mmu’: > target/ppc/mmu_helper.c:1351:12: warning: this statement may fall through > [-Wimplicit-fallthrough=] > 1351 | if (ppc6

Re: [PATCH 9/9] hw/timer/renesas_tmr: silence the compiler warnings

2020-10-28 Thread Philippe Mathieu-Daudé
On 10/28/20 5:18 AM, Chen Qun wrote: > When using -Wimplicit-fallthrough in our CFLAGS, the compiler showed warning: > ../hw/timer/renesas_tmr.c: In function ‘tmr_read’: > ../hw/timer/renesas_tmr.c:221:19: warning: this statement may fall through > [-Wimplicit-fallthrough=] > 221 | } els

RE: Out-of-Process Device Emulation session at KVM Forum 2020

2020-10-28 Thread Thanos Makatos
> -Original Message- > From: Qemu-devel bounces+thanos.makatos=nutanix@nongnu.org> On Behalf Of Thanos > Makatos > Sent: 28 October 2020 09:32 > To: Stefan Hajnoczi ; qemu-devel@nongnu.org > Cc: Elena Ufimtseva ; > john.g.john...@oracle.com; m...@redhat.com ; > jag.ra...@oracle.com;

Re: [PATCH] hw/sd: Zero out function selection fields before being populated

2020-10-28 Thread Philippe Mathieu-Daudé
On 10/28/20 2:36 AM, Bin Meng wrote: > Hi Niek, > > On Wed, Oct 28, 2020 at 3:55 AM Niek Linnenbank > wrote: >> >> Hello Philippe, Bin, >> >> Thanks for your support on this. I've just tried this patch and >> unfortunately it doesn't seem to >> resolve the issue, at least on my machine. This is

Re: [PATCH 02/25] block/nvme: Use hex format to display offset in trace events

2020-10-28 Thread Auger Eric
Hi Philippe, On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: > Use the same format used for the hw/vfio/ trace events. > > Suggested-by: Eric Auger > Signed-off-by: Philippe Mathieu-Daudé > --- > block/trace-events | 12 ++-- > 1 file changed, 6 insertions(+), 6 deletions(-) > > di

Re: [RFC PATCH v4 1/1] tests/vm: Add Haiku test based on their vagrant images

2020-10-28 Thread Philippe Mathieu-Daudé
On 10/28/20 7:02 AM, Thomas Huth wrote: > On 27/10/2020 11.21, Philippe Mathieu-Daudé wrote: >> From: Alexander von Gluck IV >> ... >> +class HaikuVM(basevm.BaseVM): >> +name = "haiku" >> +arch = "x86_64" >> + >> +link = >> "https://app.vagrantup.com/haiku-os/boxes/r1beta2-x86_64/vers

Re: [PATCH 03/25] block/nvme: Report warning with warn_report()

2020-10-28 Thread Auger Eric
Hi Philippe, On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: > Instead of displaying warning on stderr, use warn_report() > which also displays it on the monitor. > > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Eric Auger Thanks Eric > --- > block/nvme.c | 4 ++-- > 1 file changed

Re: [PATCH 04/25] block/nvme: Trace controller capabilities

2020-10-28 Thread Philippe Mathieu-Daudé
On 10/28/20 11:20 AM, Auger Eric wrote: > Hi Philippe, > > On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: >> Controllers have different capabilities and report them in the >> CAP register. We are particularly interested by the page size >> limits. >> >> Reviewed-by: Stefan Hajnoczi >> Signed-

Re: [PULL 00/32] VFIO updates 2020-10-26 (for QEMU 5.2 soft-freeze)

2020-10-28 Thread Cornelia Huck
On Wed, 28 Oct 2020 10:28:39 +0100 Max Reitz wrote: > On 28.10.20 09:11, Cornelia Huck wrote: > > On Tue, 27 Oct 2020 23:42:57 + > > Peter Maydell wrote: > > > >> On Mon, 26 Oct 2020 at 19:39, Alex Williamson > >> wrote: > >>> ---

Re: [PATCH 05/25] block/nvme: Trace nvme_poll_queue() per queue

2020-10-28 Thread Auger Eric
Hi, On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: > As we want to enable multiple queues, report the event > in each nvme_poll_queue() call, rather than once in > the callback calling nvme_poll_queues(). > > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Eric Auger Thanks Eric > ---

Re: [PATCH 07/25] block/nvme: Trace queue pair creation/deletion

2020-10-28 Thread Auger Eric
Hi Philippe, On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Eric Auger Thanks Eric > --- > block/nvme.c | 3 +++ > block/trace-events | 2 ++ > 2 files changed, 5 insertions(+) > > diff --git a/block/nvme.c b/block/nvme.c > inde

Re: [PATCH 04/25] block/nvme: Trace controller capabilities

2020-10-28 Thread Auger Eric
Hi Philippe, On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: > Controllers have different capabilities and report them in the > CAP register. We are particularly interested by the page size > limits. > > Reviewed-by: Stefan Hajnoczi > Signed-off-by: Philippe Mathieu-Daudé > --- > block/nvme

Re: [PATCH 06/25] block/nvme: Improve nvme_free_req_queue_wait() trace information

2020-10-28 Thread Auger Eric
Hi, On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: > What we want to trace is the block driver state and the queue index. > > Suggested-by: Stefan Hajnoczi > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Eric Auger Thanks Eric > --- > block/nvme.c | 2 +- > block/trace-event

Re: [PATCH 04/25] block/nvme: Trace controller capabilities

2020-10-28 Thread Auger Eric
Hi Philippe, On 10/28/20 11:25 AM, Philippe Mathieu-Daudé wrote: > On 10/28/20 11:20 AM, Auger Eric wrote: >> Hi Philippe, >> >> On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: >>> Controllers have different capabilities and report them in the >>> CAP register. We are particularly interested by

[PATCH for-5.2] semihosting: fix order of initialization functions

2020-10-28 Thread Paolo Bonzini
qemu_semihosting_console_init uses semihosting.chardev which is set by qemu_semihosting_connect_chardevs. Thus qemu_semihosting_connect_chardevs has to be called first. Both have to be called after processing -serial and friends though, so that the semihosting console can connect to a multiplexer

Re: [PATCH 09/25] block/nvme: Move definitions before structure declarations

2020-10-28 Thread Auger Eric
Hi, On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: > To be able to use some definitions in structure declarations, > move them earlier. No logical change. > > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Eric Auger Eric > --- > block/nvme.c | 19 ++- > 1 file change

Re: [PATCH 10/25] block/nvme: Use unsigned integer for queue counter/size

2020-10-28 Thread Auger Eric
Hi, On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: > We can not have negative queue count/size/index, use unsigned type. > Rename 'nr_queues' as 'queue_count' to match the spec naming. > > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Eric Auger Thanks Eric > --- > block/nvme.c

Re: [PATCH] virtio: skip guest index check on device load

2020-10-28 Thread Stefan Hajnoczi
On Tue, Oct 27, 2020 at 09:04:46AM -0400, Michael S. Tsirkin wrote: > It's not a waste of time, it's just a lot of work > within guests. Luckily it does no harm to set the NEEDS_RESET bit even if the guest doesn't handle it. If the guest driver is unaware it may continue to submit requests to the

Re: [PATCH 11/25] block/nvme: Make nvme_identify() return boolean indicating error

2020-10-28 Thread Auger Eric
Hi, On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: > Just for consistency, following the example documented since > commit e3fe3988d7 ("error: Document Error API usage rules"), > return a boolean value indicating an error is set or not. Then I think the returned value should be used by the cal

Re: Out-of-Process Device Emulation session at KVM Forum 2020

2020-10-28 Thread Michael S. Tsirkin
On Tue, Oct 27, 2020 at 03:14:00PM +, Stefan Hajnoczi wrote: > There will be a birds-of-a-feather session at KVM Forum, a chance for > us to get together and discuss Out-of-Process Device Emulation. > > Please send suggestions for the agenda! > > These sessions are a good opportunity to reach

Re: [PATCH 12/25] block/nvme: Make nvme_init_queue() return boolean indicating error

2020-10-28 Thread Auger Eric
Hi, On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: > Just for consistency, following the example documented since > commit e3fe3988d7 ("error: Document Error API usage rules"), > return a boolean value indicating an error is set or not. > This simplifies a bit nvme_create_queue_pair(). also dir

Re: [PATCH 13/25] block/nvme: Introduce Completion Queue definitions

2020-10-28 Thread Auger Eric
Hi, On 10/27/20 2:55 PM, Philippe Mathieu-Daudé wrote: > Rename Submission Queue flags with 'Sq' ... to differentiate submission queue flags from command queue flags. and introduce > Completion Queue flag definitions. besides Reviewed-by: Eric Auger Thanks Eric > > Signed-off-by: Philippe M

RE: [PULL 0/1] tricore queue

2020-10-28 Thread Konopik, Andreas (EFS-GH2)
Hi Bastian, sorry for the late reply. On Wed, 2 Sep 2020 at 14:56, Bastian Koppelmann wrote: > On Tue, Sep 01, 2020 at 03:18:40PM +0100, Peter Maydell wrote: > > On Tue, 1 Sep 2020 at 10:59, Bastian Koppelmann > > wrote: > > > > > > The following changes since commit > 2f4c51c0f384d7888a04b4815

Re: [PATCH v3 1/7] configure: option to disable host block devices

2020-10-28 Thread Stefan Hajnoczi
On Tue, Oct 27, 2020 at 08:06:55PM -0700, Joelle van Dyne wrote: > Some hosts (iOS) have a sandboxed filesystem and do not provide low-level > APIs for interfacing with host block devices. > > Signed-off-by: Joelle van Dyne > --- > configure | 4 > meson.build| 1 + > block

Re: [PATCH] virtio: skip guest index check on device load

2020-10-28 Thread Michael S. Tsirkin
On Wed, Oct 28, 2020 at 11:00:38AM +, Stefan Hajnoczi wrote: > On Tue, Oct 27, 2020 at 09:04:46AM -0400, Michael S. Tsirkin wrote: > > It's not a waste of time, it's just a lot of work > > within guests. > > Luckily it does no harm to set the NEEDS_RESET bit even if the guest > doesn't handle

Re: [PATCH v3 3/7] qemu: add support for iOS host

2020-10-28 Thread Stefan Hajnoczi
On Tue, Oct 27, 2020 at 08:06:57PM -0700, Joelle van Dyne wrote: > This introduces support for building for iOS hosts. When the correct Xcode > toolchain is used, iOS host will be detected automatically. > > block: disable features not supported by iOS sandbox > slirp: disable SMB features for iOS

Re: [PATCH 0/4] qemu-storage-daemon: QAPIfy --chardev the stupid way

2020-10-28 Thread Kevin Wolf
Am 28.10.2020 um 08:01 hat Markus Armbruster geschrieben: > Paolo Bonzini writes: > > > On 26/10/20 11:10, Markus Armbruster wrote: > >> Kevin's "[PATCH v2 0/6] qemu-storage-daemon: QAPIfy --chardev" > >> involves surgery to the QAPI generator. Some (most?) of it should go > >> away if we deprec

Re: [PATCH v3 5/7] slirp: update build flags for iOS resolv fix

2020-10-28 Thread Stefan Hajnoczi
On Tue, Oct 27, 2020 at 08:06:59PM -0700, Joelle van Dyne wrote: > A future libslirp update will use libresolv on Darwin systems, so we add the > flags in QEMU build now. > > Signed-off-by: Joelle van Dyne > --- > meson.build | 2 ++ > 1 file changed, 2 insertions(+) Reviewed-by: Stefan Hajnocz

Re: [PATCH v3 4/7] coroutine: add libucontext as external library

2020-10-28 Thread Stefan Hajnoczi
On Tue, Oct 27, 2020 at 08:06:58PM -0700, Joelle van Dyne wrote: I am not a lawyer and haven't consulted any lawyers, but libucontext seems compatible with QEMU's license to me. I think QEMU can mirror the libucontext repo and ship it like the other submodules. No changes to QEMU's ./LICENSE are n

Re: [PATCH v3 6/7] tcg: implement JIT for iOS and Apple Silicon

2020-10-28 Thread Stefan Hajnoczi
On Tue, Oct 27, 2020 at 08:07:00PM -0700, Joelle van Dyne wrote: > On iOS, we cannot allocate RWX pages without special entitlements. As a > workaround, we can allocate a RX region and then mirror map it to a separate > RX region. Then we can write to one region and execute from the other one. "se

Re: [PATCH v3 7/7] block: check availablity for preadv/pwritev on mac

2020-10-28 Thread Stefan Hajnoczi
On Tue, Oct 27, 2020 at 08:07:01PM -0700, Joelle van Dyne wrote: > macOS 11/iOS 14 added preadv/pwritev APIs. Due to weak linking, configure > will succeed with CONFIG_PREADV even when targeting a lower OS version. We > therefore need to check at run time if we can actually use these APIs. > > Sig

Re: [PATCH] block: Move bdrv_drain_all_end_quiesce() to block_int.h

2020-10-28 Thread Stefan Hajnoczi
On Wed, Oct 28, 2020 at 09:07:34AM +0100, Greg Kurz wrote: > This function is really an internal helper for bdrv_close(). Update its > doc comment to make this clear and make the function private. > > Signed-off-by: Greg Kurz > --- > > As suggested by Stefan here: > > https://lists.gnu.org/arch

Re: [PATCH v3 0/7] iOS and Apple Silicon host support

2020-10-28 Thread Stefan Hajnoczi
On Tue, Oct 27, 2020 at 08:06:54PM -0700, Joelle van Dyne wrote: > Based-on: 20201026191540.12434-...@getutm.app > ([PATCH RESEND 0/4] Mirror map JIT memory for TCG) > > These set of changes brings QEMU TCG to iOS devices and future Apple Silicon > devices. They were originally developed last year

Our abstract UNIX domain socket support is a mess

2020-10-28 Thread Markus Armbruster
Commit 776b97d360 "qemu-sockets: add abstract UNIX domain socket support" (v5.1) has made a mess. First, what are abstract UNIX domain sockets? They use a separate "abstract" namespace which is independent of the filesystem. This is a non-portable Linux extension. See unix(7). Traditional path

Re: [PATCH] virtio: skip guest index check on device load

2020-10-28 Thread Stefan Hajnoczi
On Wed, Oct 28, 2020 at 07:30:55AM -0400, Michael S. Tsirkin wrote: > On Wed, Oct 28, 2020 at 11:00:38AM +, Stefan Hajnoczi wrote: > > On Tue, Oct 27, 2020 at 09:04:46AM -0400, Michael S. Tsirkin wrote: > > > It's not a waste of time, it's just a lot of work > > > within guests. > > > > Luckil

Re: [PATCH 1/9] target/i386: silence the compiler warnings in gen_shiftd_rm_T1

2020-10-28 Thread Thomas Huth
On 28/10/2020 05.18, Chen Qun wrote: > The current "#ifdef TARGET_X86_64" statement affects > the compiler's determination of fall through. > > When using -Wimplicit-fallthrough in our CFLAGS, the compiler showed warning: > target/i386/translate.c: In function ‘gen_shiftd_rm_T1’: > target/i386/tra

RE: [PATCH v12 1/3] misc: Add versal-usb2-ctrl-regs module

2020-10-28 Thread Sai Pavan Boddu
Hi Peter, > -Original Message- > From: Sai Pavan Boddu > Sent: Monday, October 26, 2020 10:59 PM > To: Peter Maydell > Cc: Markus Armbruster ; Marc-André Lureau > ; Paolo Bonzini ; > Gerd Hoffmann ; Edgar Iglesias ; > Francisco Eduardo Iglesias ; QEMU Developers de...@nongnu.org>; Alista

Re: [PATCH v4 04/12] libqos/qgraph: add qos_dump_graph()

2020-10-28 Thread Eric Blake
On 10/28/20 12:51 AM, Thomas Huth wrote: +#define GREEN(txt) ( \ +"\033[0;92m" txt \ +"\033[0m" \ +) >>> >>> I don't think this is very portable - and it will only make logs ugly to >>> read in text editors. Could you please simply drop these macros? >>> > Su

Re: [PULL 0/7] LED API patches for 2020-10-26

2020-10-28 Thread Peter Maydell
On Mon, 26 Oct 2020 at 22:06, Philippe Mathieu-Daudé wrote: > > The following changes since commit a5fac424c76d6401ecde4ecb7d846e656d0d6e89: > > Merge remote-tracking branch 'remotes/stefanha-gitlab/tags/block-pull-reque= > st' into staging (2020-10-26 10:33:59 +) > > are available in the Gi

Re: [PATCH v12 1/3] misc: Add versal-usb2-ctrl-regs module

2020-10-28 Thread Peter Maydell
On Wed, 28 Oct 2020 at 12:58, Sai Pavan Boddu wrote: > > Hi Peter, > > > -Original Message- > > From: Sai Pavan Boddu > > Sent: Monday, October 26, 2020 10:59 PM > > To: Peter Maydell > > Cc: Markus Armbruster ; Marc-André Lureau > > ; Paolo Bonzini ; > > Gerd Hoffmann ; Edgar Iglesias ;

Re: [PATCH 1/9] target/i386: silence the compiler warnings in gen_shiftd_rm_T1

2020-10-28 Thread Philippe Mathieu-Daudé
+Tony On 10/28/20 1:57 PM, Thomas Huth wrote: > On 28/10/2020 05.18, Chen Qun wrote: >> The current "#ifdef TARGET_X86_64" statement affects >> the compiler's determination of fall through. >> >> When using -Wimplicit-fallthrough in our CFLAGS, the compiler showed warning: >> target/i386/translate

Re: [PATCH 4/9] linux-user/mips/cpu_loop: silence the compiler warnings

2020-10-28 Thread Thomas Huth
On 28/10/2020 05.18, Chen Qun wrote: > When using -Wimplicit-fallthrough in our CFLAGS, the compiler showed warning: > linux-user/mips/cpu_loop.c: In function ‘cpu_loop’: > linux-user/mips/cpu_loop.c:104:24: warning: this statement may fall through > [-Wimplicit-fallthrough=] > 104 |

Re: [PATCH 1/5] python: add pytest and tests

2020-10-28 Thread John Snow
On 10/28/20 2:19 AM, Thomas Huth wrote: On 27/10/2020 23.38, John Snow wrote: Try using pytest to manage our various tests; even though right now they're only invoking binaries and not really running any python-native code. Create tests/, and add test_lint.py which calls out to mypy, flake8, py

Re: [PATCH 4/5] python: add .gitignore

2020-10-28 Thread John Snow
On 10/28/20 4:13 AM, Thomas Huth wrote: On 27/10/2020 23.38, John Snow wrote: Ignore build and package output (build, dist, qemu.egg-info); effectively these are "in-tree" builds of a kind. Since we recently moved away from in-tree builds, could these also be made out-of-tree only? Thomas

Re: [PATCH v4 04/12] libqos/qgraph: add qos_dump_graph()

2020-10-28 Thread Christian Schoenebeck
On Mittwoch, 28. Oktober 2020 14:00:21 CET Eric Blake wrote: > On 10/28/20 12:51 AM, Thomas Huth wrote: > +#define GREEN(txt) ( \ > +"\033[0;92m" txt \ > +"\033[0m" \ > +) > >>> > >>> I don't think this is very portable - and it will only make logs ugly to > >

Re: [PATCH 4/5] python: add .gitignore

2020-10-28 Thread John Snow
On 10/28/20 5:16 AM, Markus Armbruster wrote: Thomas Huth writes: On 27/10/2020 23.38, John Snow wrote: Ignore build and package output (build, dist, qemu.egg-info); effectively these are "in-tree" builds of a kind. Since we recently moved away from in-tree builds, could these also be made

Re: [PATCH 4/5] python: add .gitignore

2020-10-28 Thread Daniel P . Berrangé
On Wed, Oct 28, 2020 at 09:39:07AM -0400, John Snow wrote: > On 10/28/20 5:16 AM, Markus Armbruster wrote: > > Thomas Huth writes: > > > > > On 27/10/2020 23.38, John Snow wrote: > > > > Ignore build and package output (build, dist, qemu.egg-info); > > > > effectively these are "in-tree" builds o

Re: [PATCH 2/5] python: add excluded dirs to flake8 config

2020-10-28 Thread John Snow
On 10/28/20 4:50 AM, Philippe Mathieu-Daudé wrote: On 10/27/20 11:38 PM, John Snow wrote: Following patches make obvious that we ought to ignore certain directories to avoid wildly erroneous flake8 output. Signed-off-by: John Snow --- python/setup.cfg | 2 ++ 1 file changed, 2 insertions(+)

[PATCH 1/2] plugins: Fix resource leak in connect_socket()

2020-10-28 Thread AlexChen
Close the fd when connect() fails. Reported-by: Euler Robot Signed-off-by: AlexChen --- contrib/plugins/lockstep.c | 1 + 1 file changed, 1 insertion(+) diff --git a/contrib/plugins/lockstep.c b/contrib/plugins/lockstep.c index a696673dff..319bd44b83 100644 --- a/contrib/plugins/lockstep.c +++

[PATCH 2/2] plugins: Fix two resource leaks in connect_socket()

2020-10-28 Thread AlexChen
Either accept() fails or exits normally, we need to close the fd. Reported-by: Euler Robot Signed-off-by: AlexChen --- contrib/plugins/lockstep.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/contrib/plugins/lockstep.c b/contrib/plugins/lockstep.c index 319bd44b83..5aad50869d 100644 ---

[PATCH v2] virtio: skip guest index check on device load

2020-10-28 Thread Felipe Franciosi
QEMU must be careful when loading device state off migration streams to prevent a malicious source from exploiting the emulator. Overdoing these checks has the side effect of allowing a guest to "pin itself" in cloud environments by messing with state which is entirely in its control. Similarly to

  1   2   3   4   >