[PATCH v5 15/15] hw/i2c: Introduce i2c_start_recv() and i2c_start_send()

2021-06-17 Thread Philippe Mathieu-Daudé
To ease reviewing code using the I2C bus API, introduce the i2c_start_recv() and i2c_start_send() helpers which don't take the confusing 'is_recv' boolean argument. Use these new helpers in the SMBus / AUX bus models. Suggested-by: Richard Henderson Reviewed-by: Richard Henderson

[PATCH v5 10/15] hw/misc/auxbus: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-17 Thread Philippe Mathieu-Daudé
Instead of using the confuse i2c_send_recv(), replace i2c_send_recv(send = true) by i2c_send() and i2c_send_recv(send = false) by i2c_recv(). During the replacement we also change a while() statement by for(). The resulting code is easier to review. Reviewed-by: Richard Henderson Acked-by:

[PATCH v3 07/44] target/arm: Implement MVE VABS

2021-06-17 Thread Peter Maydell
Implement the MVE VABS functions (both integer and floating point). Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson --- target/arm/helper-mve.h| 6 ++ target/arm/mve.decode | 3 +++ target/arm/mve_helper.c| 13 + target/arm/translate-mve.c | 15

[PATCH v3 16/44] target/arm: Implement MVE VABD

2021-06-17 Thread Peter Maydell
Implement the MVE VABD insn. Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson --- target/arm/helper-mve.h| 7 +++ target/arm/mve.decode | 3 +++ target/arm/mve_helper.c| 5 + target/arm/translate-mve.c | 2 ++ 4 files changed, 17 insertions(+) diff --git

[PATCH v3 22/44] target/arm: Implement MVE VADD (scalar)

2021-06-17 Thread Peter Maydell
Implement the scalar form of the MVE VADD insn. This takes the scalar operand from a general purpose register. Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson --- target/arm/helper-mve.h| 4 target/arm/mve.decode | 7 ++ target/arm/mve_helper.c| 22

[PATCH v3 24/44] target/arm: Implement MVE VHADD, VHSUB (scalar)

2021-06-17 Thread Peter Maydell
Implement the scalar variants of the MVE VHADD and VHSUB insns. Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson --- target/arm/helper-mve.h| 16 target/arm/mve.decode | 4 target/arm/mve_helper.c| 8 target/arm/translate-mve.c | 4

[PATCH v3 39/44] target/arm: Implement MVE VRHADD

2021-06-17 Thread Peter Maydell
Implement the MVE VRHADD insn, which performs a rounded halving addition. Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson --- target/arm/helper-mve.h| 8 target/arm/mve.decode | 3 +++ target/arm/mve_helper.c| 6 ++ target/arm/translate-mve.c | 2 ++ 4

[PATCH v5 5/6] ui/vnc: Use qcrypto_tls_creds_check_endpoint()

2021-06-17 Thread Philippe Mathieu-Daudé
Avoid accessing QCryptoTLSCreds internals by using the qcrypto_tls_creds_check_endpoint() helper. Signed-off-by: Philippe Mathieu-Daudé --- ui/vnc.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ui/vnc.c b/ui/vnc.c index b3d4d7b9a5f..f7d63a16dd5 100644 ---

[PULL 3/7] audio: move code to audio/audio.c

2021-06-17 Thread Gerd Hoffmann
From: Volker Rümelin Move the code to generate the pa_context_new() application name argument to a function in audio/audio.c. The new function audio_application_name() will also be used in the jackaudio backend. Signed-off-by: Volker Rümelin Message-Id:

[RFC PATCH v2] Add a post for the new TCG cache modelling plugin

2021-06-17 Thread Mahmoud Mandour
This post introduces the new TCG plugin `cache` that's used for cache modelling. This plugin is a part of my GSoC 2021 participation. Signed-off-by: Mahmoud Mandour --- v1 -> v2: Elaborated some more in the introduction and broken up some sentences. Changed the example of blocked

[PATCH v6 6/7] migration/dirtyrate: move init step of calculation to main thread

2021-06-17 Thread huangy81
From: Hyman Huang(黄勇) since main thread may "query dirty rate" at any time, it's better to move init step into main thead so that synchronization overhead between "main" and "get_dirtyrate" can be reduced. Signed-off-by: Hyman Huang(黄勇) --- migration/dirtyrate.c | 23 +++

[PULL 4/7] jackaudio: avoid that the client name contains the word (NULL)

2021-06-17 Thread Gerd Hoffmann
From: Volker Rümelin Currently with jackaudio client name and qemu guest name unset, the JACK client names are out-(NULL) and in-(NULL). These names are user visible in the patch bay. Replace the function call to qemu_get_vm_name() with a call to audio_application_name() which replaces NULL with

Re: [PATCH v9] qapi: introduce 'query-kvm-cpuid' action

2021-06-17 Thread Valeriy Vdovin
On Thu, Jun 17, 2021 at 01:58:09PM +0200, Claudio Fontana wrote: > On 6/17/21 9:49 AM, Valeriy Vdovin wrote: > > On Thu, Jun 17, 2021 at 07:22:36AM +0200, Markus Armbruster wrote: > >> Valeriy Vdovin writes: > >> > >>> Introducing new qapi method 'query-kvm-cpuid'. This method can be used to > >>

Re: [PATCH] virtiofsd: Don't allow file creation with FUSE_OPEN

2021-06-17 Thread Dr. David Alan Gilbert
* Greg Kurz (gr...@kaod.org) wrote: > A well behaved FUSE client uses FUSE_CREATE to create files. It isn't > supposed to pass O_CREAT along a FUSE_OPEN request, as documented in > the "fuse_lowlevel.h" header : > > /** > * Open a file > * > * Open flags are available in

[PATCH 1/7] net/vmnet: dependencies setup, initial preparations

2021-06-17 Thread Vladislav Yaroshchuk
Add 'vmnet' customizable option and 'vmnet.framework' probe into configure; Create source files for network client driver, update meson.build; Add 'vmnet' into qapi::net::NetClientDriver options list. Signed-off-by: Vladislav Yaroshchuk --- configure | 31 +++

Re: [PATCH] hw/nvme: fix pin-based interrupt behavior (again)

2021-06-17 Thread Keith Busch
On Thu, Jun 17, 2021 at 12:08:20PM +0200, Klaus Jensen wrote: > if (cq->tail != cq->head) { > +if (!pending) { > +n->cq_pending++; > +} You should check cq->irq_enabled before incrementing cq_pending. You don't want to leave the irq asserted when polled queues

Re: [PATCH v7 3/7] memory: make global_dirty_tracking a bitmask

2021-06-17 Thread Peter Xu
On Thu, Jun 17, 2021 at 10:12:04PM +0800, huang...@chinatelecom.cn wrote: > From: Hyman Huang(黄勇) > > dirty rate measurement may start or stop dirty tracking during > calculation. this conflict with migration because stop dirty > tracking make migration leave dirty pages out then that'll be > a

Re: [PULL 00/33] Misc patches for 2021-06-15

2021-06-17 Thread Thomas Huth
On 17/06/2021 12.06, Alex Bennée wrote: Philippe Mathieu-Daudé writes: On 6/15/21 4:17 PM, Peter Maydell wrote: On Tue, 15 Jun 2021 at 14:42, Paolo Bonzini wrote: The following changes since commit 894fc4fd670aaf04a67dc7507739f914ff4bacf2: Merge remote-tracking branch

[PATCH v2 01/11] qom: export more functions for use with non-UserCreatable objects

2021-06-17 Thread Paolo Bonzini
Machines and accelerators are not user-creatable but they are going to share similar command-line parsing machinery. Export functions that will be used with -machine and -accel in softmmu/vl.c. Reviewed-by: Daniel P. Berrangé Signed-off-by: Paolo Bonzini --- include/qom/object.h| 23

[PATCH] block/rbd: Add support for rbd image encryption

2021-06-17 Thread Or Ozeri
Starting from ceph Pacific, RBD has built-in support for image-level encryption. Currently supported formats are LUKS version 1 and 2. There are 2 new relevant librbd APIs for controlling encryption, both expect an open image context: rbd_encryption_format: formats an image (i.e. writes the LUKS

[PATCH v2 03/11] keyval: introduce keyval_parse_into

2021-06-17 Thread Paolo Bonzini
Allow parsing multiple keyval sequences into the same dictionary. This will be used to simplify the parsing of the -M command line option, which is currently a .merge_lists = true QemuOpts group. Reviewed-by: Markus Armbruster Reviewed-by: Daniel P. Berrangé Signed-off-by: Paolo Bonzini ---

Re: [PATCH] virtiofsd: Don't allow file creation with FUSE_OPEN

2021-06-17 Thread Greg Kurz
On Thu, 17 Jun 2021 15:29:12 +0100 "Dr. David Alan Gilbert" wrote: > * Greg Kurz (gr...@kaod.org) wrote: > > A well behaved FUSE client uses FUSE_CREATE to create files. It isn't > > supposed to pass O_CREAT along a FUSE_OPEN request, as documented in > > the "fuse_lowlevel.h" header : > > > >

Re: [RFC 0/3] qtest: pick tests that require KVM at runtime

2021-06-17 Thread Claudio Fontana
On 6/16/21 5:24 PM, Igor Mammedov wrote: > > Sometimes it's necessary to execute a test that depends on KVM, > however qtest is not aware if tested QEMU binary supports KVM > on the host it the test is executed. Hello, It seems to me that we are constantly re-implementing the same feature with

[PATCH v2] meson: Add gnutls as a dependency to libmigration

2021-06-17 Thread Akihiko Odaki
qemu-file-channel.c may depend on GnuTLS. Signed-off-by: Akihiko Odaki --- meson.build | 1 + 1 file changed, 1 insertion(+) diff --git a/meson.build b/meson.build index a2311eda6ec..29d854699ca 100644 --- a/meson.build +++ b/meson.build @@ -2090,6 +2090,7 @@ libio = static_library('io',

[PATCH 2/4] target/mips: Extract Code Compaction ASE translation routines

2021-06-17 Thread Philippe Mathieu-Daudé
Extract 1100+ lines from the huge translate.c to a new file, 'mips16e_translate.c.inc'. As there are too many inter- dependencies we don't compile it as another object, but keep including it in the big translate.o. We gain in code maintainability. Signed-off-by: Philippe Mathieu-Daudé

Re: GICv3 for MTTCG

2021-06-17 Thread shashi . mallela
Hi Andrey, The issue doesnt seem related to ITS patchset as the implementation has no changes around MTTCG or vCPU configurations. if this patchset were not applied(with only commit 3e9f48b),do you still see the hang issue? Thanks Shashi On Thu, 2021-06-17 at 16:43 +, Andrey Shinkevich

Re: [PULL 28/34] nbd/client-connection: return only one io channel

2021-06-17 Thread Vladimir Sementsov-Ogievskiy
15.06.2021 23:47, Eric Blake wrote: From: Vladimir Sementsov-Ogievskiy block/nbd doesn't need underlying sioc channel anymore. So, we can update nbd/client-connection interface to return only one top-most io channel, which is more straight forward. Signed-off-by: Vladimir Sementsov-Ogievskiy

[PATCH v5 5/7] bios-tables-test: Allow changes in DSDT ACPI tables

2021-06-17 Thread Julia Suvorova
All DSDT Q35 tables will be modified because ACPI hot-plug is enabled by default. Signed-off-by: Julia Suvorova Reviewed-by: Igor Mammedov --- tests/qtest/bios-tables-test-allowed-diff.h | 11 +++ 1 file changed, 11 insertions(+) diff --git

[PATCH 2/4] fuzz: add an instrumentation filter

2021-06-17 Thread Alexander Bulekov
By default, -fsanitize=fuzzer instruments all code with coverage information. However, this means that libfuzzer will track coverage over hundreds of source files that are unrelated to virtual-devices. This means that libfuzzer will optimize inputs for coverage observed in timer code, memory APIs

Re: [PATCH v5 4/7] hw/pci/pcie: Do not set HPC flag if acpihp is used

2021-06-17 Thread Michael S. Tsirkin
On Thu, Jun 17, 2021 at 09:07:36PM +0200, Julia Suvorova wrote: > Instead of changing the hot-plug type in _OSC register, do not > set the 'Hot-Plug Capable' flag. This way guest will choose ACPI > hot-plug if it is preferred and leave the option to use SHPC with > pcie-pci-bridge. > > The

[PATCH v6 3/8] virtiofsd: Fix xattr operations overwriting errno

2021-06-17 Thread Vivek Goyal
getxattr/setxattr/removexattr/listxattr operations handle regualar and non-regular files differently. For the case of non-regular files we do fchdir(/proc/self/fd) and the xattr operation and then revert back to original working directory. After this we are saving errno and that's buggy because

[PATCH v5 1/7] hw/acpi/pcihp: Enhance acpi_pcihp_disable_root_bus() to support Q35

2021-06-17 Thread Julia Suvorova
PCI Express does not allow hot-plug on pcie.0. Check for Q35 in acpi_pcihp_disable_root_bus() to be able to forbid hot-plug using the 'acpi-root-pci-hotplug' flag. Signed-off-by: Julia Suvorova Reviewed-by: Igor Mammedov --- hw/acpi/pcihp.c | 3 ++- 1 file changed, 2 insertions(+), 1

Re: [PATCH v3 1/2] semihosting/arm-compat: replace heuristic for softmmu SYS_HEAPINFO

2021-06-17 Thread Peter Maydell
On Tue, 15 Jun 2021 at 18:01, Alex Bennée wrote: > > The previous numbers were a guess at best and rather arbitrary without > taking into account anything that might be loaded. Instead of using > guesses based on the state of registers implement a new function that > scans MemoryRegions for the

[PATCH v5 2/7] hw/i386/acpi-build: Add ACPI PCI hot-plug methods to Q35

2021-06-17 Thread Julia Suvorova
Implement notifications and gpe to support q35 ACPI PCI hot-plug. Use 0xcc4 - 0xcd7 range for 'acpi-pci-hotplug' io ports. Signed-off-by: Julia Suvorova Reviewed-by: Igor Mammedov --- hw/i386/acpi-build.h| 4 include/hw/acpi/ich9.h | 2 ++ include/hw/acpi/pcihp.h | 3 ++-

Re: [PATCH] x86: add SEV hashing to fw_cfg for kernel/initrd/cmdline

2021-06-17 Thread Eduardo Habkost
On Thu, Jun 17, 2021 at 3:17 PM Dov Murik wrote: > > > > On 17/06/2021 20:22, Eduardo Habkost wrote: > > On Thu, Jun 17, 2021 at 03:48:52PM +0300, Dov Murik wrote: > >> > >> > >> On 15/06/2021 22:53, Philippe Mathieu-Daudé wrote: > >>> Hi Dov, James, > >>> > >>> +Connor who asked to be reviewer.

Re: [PATCH v16 43/99] target/arm: move a15 cpu model away from the TCG-only models

2021-06-17 Thread Claudio Fontana
On 6/17/21 8:01 PM, Alex Bennée wrote: > > Richard Henderson writes: > >> On 6/4/21 8:52 AM, Alex Bennée wrote: >>> From: Claudio Fontana >>> Cortex-A15 is the only ARM cpu class we need in KVM too. >>> We will be able to move it to tcg/ once the board code and >>> configurations >>> are fixed.

Re: [Virtio-fs] [PATCH v2 7/9] virtiofsd: Add inodes_by_handle hash table

2021-06-17 Thread Vivek Goyal
On Wed, Jun 16, 2021 at 03:38:13PM +0200, Max Reitz wrote: > On 11.06.21 22:04, Vivek Goyal wrote: > > On Wed, Jun 09, 2021 at 05:55:49PM +0200, Max Reitz wrote: > > > Currently, lo_inode.fhandle is always NULL and so always keep an O_PATH > > > FD in lo_inode.fd. Therefore, when the respective

[PATCH v3 0/4] STM32VLDISCOVERY Machine Model

2021-06-17 Thread Alexandre Iooss
This patch series adds the STM32VLDISCOVERY Machine to QEMU Information on the board is available at: https://www.st.com/en/evaluation-tools/stm32vldiscovery.html v3: - Add test for STM32VLDISCOVERY USART1 v2: - Add documentation of STM32 boards - Fixed number of interrupts - Fixed

[PATCH v3 3/4] docs/system: arm: Add stm32 boards description

2021-06-17 Thread Alexandre Iooss
This adds the target guide for Netduino 2, Netduino Plus 2 and STM32VLDISCOVERY. Signed-off-by: Alexandre Iooss --- MAINTAINERS| 1 + docs/system/arm/stm32.rst | 66 ++ docs/system/target-arm.rst | 1 + 3 files changed, 68 insertions(+)

Re: [PATCH] x86: add SEV hashing to fw_cfg for kernel/initrd/cmdline

2021-06-17 Thread Philippe Mathieu-Daudé
Hi Dov, +Thomas On 6/17/21 2:48 PM, Dov Murik wrote: > On 15/06/2021 22:53, Philippe Mathieu-Daudé wrote: >> Hi Dov, James, >> >> +Connor who asked to be reviewer. >> >> On 6/15/21 5:20 PM, Eduardo Habkost wrote: >>> On Tue, May 25, 2021 at 06:59:31AM +, Dov Murik wrote: From: James

Re: [PATCH] block/nvme: Fix VFIO_MAP_DMA failed: No space left on device

2021-06-17 Thread Philippe Mathieu-Daudé
On 6/17/21 2:40 PM, Maxim Levitsky wrote: > On Mon, 2021-06-14 at 18:03 +0200, Philippe Mathieu-Daudé wrote: >> On 6/11/21 1:46 PM, Philippe Mathieu-Daudé wrote: >>> When the NVMe block driver was introduced (see commit bdd6a90a9e5, >>> January 2018), Linux VFIO_IOMMU_MAP_DMA ioctl was only

[PATCH 4/9] target/mips: Move translate.h to tcg/ sub directory

2021-06-17 Thread Philippe Mathieu-Daudé
We moved various TCG source files in commit a2b0a27d33e ("target/mips: Move TCG source files under tcg/ sub directory") but forgot to move the header declaring their prototypes. Do it now, since all it declares is TCG specific. Signed-off-by: Philippe Mathieu-Daudé --- target/mips/{ =>

Re: [PATCH v2] meson: Add gnutls as a dependency to libmigration

2021-06-17 Thread Akihiko Odaki
2021年6月18日(金) 2:39 Philippe Mathieu-Daudé : > > On 6/17/21 7:19 PM, Akihiko Odaki wrote: > > qemu-file-channel.c may depend on GnuTLS. > > > > Signed-off-by: Akihiko Odaki > > --- > > meson.build | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/meson.build b/meson.build > > index

Re: [PATCH v16 43/99] target/arm: move a15 cpu model away from the TCG-only models

2021-06-17 Thread Alex Bennée
Richard Henderson writes: > On 6/4/21 8:52 AM, Alex Bennée wrote: >> From: Claudio Fontana >> Cortex-A15 is the only ARM cpu class we need in KVM too. >> We will be able to move it to tcg/ once the board code and >> configurations >> are fixed. >> Signed-off-by: Claudio Fontana >>

[PATCH v6 8/8] virtiofsd: Add an option to enable/disable posix acls

2021-06-17 Thread Vivek Goyal
fuse has an option FUSE_POSIX_ACL which needs to be opted in by fuse server to enable posix acls. As of now we are not opting in for this, so posix acls are disabled on virtiofs by default. Add virtiofsd option "-o posix_acl/no_posix_acl" to let users enable/disable posix acl support. By default

[PATCH v6 7/8] virtiofsd: Switch creds, drop FSETID for system.posix_acl_access xattr

2021-06-17 Thread Vivek Goyal
When posix access acls are set on a file, it can lead to adjusting file permissions (mode) as well. If caller does not have CAP_FSETID and it also does not have membership of owner group, this will lead to clearing SGID bit in mode. Current fuse code is written in such a way that it expects file

[PULL 3/4] Hexagon (target/hexagon) cleanup gen_store_conditional[48] functions

2021-06-17 Thread Taylor Simpson
Previously the store-conditional code was writing to hex_pred[prednum]. Then, the fGEN_TCG override was reading from there to the destination variable so that the packet commit logic would handle it properly. The correct implementation is to write to the destination variable and don't have the

[PATCH v3 1/4] stm32f100: Add the stm32f100 SoC

2021-06-17 Thread Alexandre Iooss
This SoC is similar to stm32f205 SoC. This will be used by the STM32VLDISCOVERY to create a machine. Signed-off-by: Alexandre Iooss --- MAINTAINERS| 6 ++ hw/arm/Kconfig | 6 ++ hw/arm/meson.build | 1 + hw/arm/stm32f100_soc.c | 182

Re: [PATCH v2] meson: Add gnutls as a dependency to libmigration

2021-06-17 Thread Philippe Mathieu-Daudé
On 6/17/21 7:19 PM, Akihiko Odaki wrote: > qemu-file-channel.c may depend on GnuTLS. > > Signed-off-by: Akihiko Odaki > --- > meson.build | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/meson.build b/meson.build > index a2311eda6ec..29d854699ca 100644 > --- a/meson.build > +++

[PATCH 3/9] target/mips: Move TCG trace events to tcg/ sub directory

2021-06-17 Thread Philippe Mathieu-Daudé
Commit a2b0a27d33e ("target/mips: Move TCG source files under tcg/ sub directory") forgot to move the trace-event file. As it only contains TCG events, move it for consistency. Signed-off-by: Philippe Mathieu-Daudé --- meson.build| 2 +- target/mips/tcg/translate.c

[PATCH 0/9] target/mips: Various fixes & cleanups

2021-06-17 Thread Philippe Mathieu-Daudé
Fixes and cleanup accumulated during the last month. Nothing particularly exciting :/ Please review, Phil. Philippe Mathieu-Daudé (9): target/mips: Do not abort on invalid instruction target/mips: Fix more TCG temporary leaks in gen_pool32a5_nanomips_insn target/mips: Move TCG trace

[PATCH 2/9] target/mips: Fix more TCG temporary leaks in gen_pool32a5_nanomips_insn

2021-06-17 Thread Philippe Mathieu-Daudé
Fix multiple TCG temporary leaks in gen_pool32a5_nanomips_insn(). Fixes: 3285a3e4445 ("target/mips: Add emulation of DSP ASE for nanoMIPS - part 1") Signed-off-by: Philippe Mathieu-Daudé --- target/mips/tcg/translate.c | 4 1 file changed, 4 insertions(+) diff --git

[PATCH 6/9] target/mips: Remove SmartMIPS / MDMX unuseful comments

2021-06-17 Thread Philippe Mathieu-Daudé
These placeholder comments for SmartMIPS and MDMX extensions have been added commit 3c824109da0 ("target-mips: microMIPS ASE support"). More than 11 years later it is safe to assume there won't be added soon, so remove these unuseful comments. Signed-off-by: Philippe Mathieu-Daudé ---

[PATCH 0/2] target/mips: Simplify MSA decodetree

2021-06-17 Thread Philippe Mathieu-Daudé
Merge MSA32 & MSA64. Philippe Mathieu-Daudé (2): target/mips: Remove pointless gen_msa() target/mips: Merge msa32/msa64 decodetree definitions target/mips/tcg/{msa32.decode => msa.decode} | 8 +--- target/mips/tcg/msa64.decode | 17

[PATCH 5/9] target/mips: Restrict some system specific declarations to sysemu

2021-06-17 Thread Philippe Mathieu-Daudé
Commit 043715d1e0f ("target/mips: Update ITU to utilize SAARI and SAAR CP0 registers") declared itc_reconfigure() in public namespace, while it is restricted to system emulation. Similarly commit 5679479b9a1 ("target/mips: Move CP0 helpers to sysemu/cp0.c") restricted cpu_mips_soft_irq()

[PATCH 8/9] target/mips: Constify host_to_mips_errno[]

2021-06-17 Thread Philippe Mathieu-Daudé
Keep host_to_mips_errno[] in .rodata by marking the array const. Signed-off-by: Philippe Mathieu-Daudé --- target/mips/tcg/sysemu/mips-semi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/mips/tcg/sysemu/mips-semi.c b/target/mips/tcg/sysemu/mips-semi.c index

[PATCH 1/4] target/mips: Add declarations for generic TCG helpers

2021-06-17 Thread Philippe Mathieu-Daudé
To be able to extract the microMIPS ISA and Code Compaction ASE translation routines to different source files, declare few TCG helpers which are also used by translate.c in "translate.h". Signed-off-by: Philippe Mathieu-Daudé --- target/mips/tcg/translate.h | 5 +

[PATCH v6 2/8] virtiofsd: Fix fuse setxattr() API change issue

2021-06-17 Thread Vivek Goyal
With kernel header updates fuse_setxattr_in struct has grown in size. But this new struct size only takes affect if user has opted in for fuse feature FUSE_SETXATTR_EXT otherwise fuse continues to send "fuse_setxattr_in" of older size. Older size is determined by FUSE_COMPAT_SETXATTR_IN_SIZE. Fix

[PATCH v6 6/8] virtiofsd: Add capability to change/restore umask

2021-06-17 Thread Vivek Goyal
When parent directory has default acl and a file is created in that directory, then umask is ignored and final file permissions are determined using default acl instead. (man 2 umask). Currently, fuse applies the umask and sends modified mode in create request accordingly. fuse server can set

[PATCH v6 4/8] virtiofsd: Add support for extended setxattr

2021-06-17 Thread Vivek Goyal
Add the bits to enable support for setxattr_ext if fuse offers it. Do not enable it by default yet. Let passthrough_ll opt-in. Enabling it by deafult kind of automatically means that you are taking responsibility of clearing SGID if ACL is set. Signed-off-by: Vivek Goyal ---

Re: GICv3 for MTTCG

2021-06-17 Thread Andrey Shinkevich
On 6/17/21 8:44 PM, shashi.mall...@linaro.org wrote: > Hi Andrey, > > The issue doesnt seem related to ITS patchset as the implementation has > no changes around MTTCG or vCPU configurations. > > if this patchset were not applied(with only commit 3e9f48b),do you > still see the hang issue? No,

[PATCH v2 03/11] hw/nvme: reimplement dsm to allow cancellation

2021-06-17 Thread Klaus Jensen
From: Klaus Jensen Prior to this patch, a loop was used to issue multiple "fire and forget" aios for each range in the command. Without a reference to the aiocb returned from the blk_aio_pdiscard calls, the aios cannot be canceled. Fix this by processing the ranges one after another. As a

[PATCH v2 00/11] hw/nvme: reimplement all multi-aio commands with custom aiocbs

2021-06-17 Thread Klaus Jensen
From: Klaus Jensen This series reimplements flush, dsm, copy, zone reset and format nvm to allow cancellation. I posted an RFC back in March ("hw/block/nvme: convert ad-hoc aio tracking to aiocb") and I've applied some feedback from Stefan and reimplemented the remaining commands. The basic

[PATCH v2 04/11] hw/nvme: save reftag when generating pi

2021-06-17 Thread Klaus Jensen
From: Klaus Jensen Prepare nvme_dif_pract_generate_dif() and nvme_dif_check() to be callable in smaller increments by making the reftag a pointer parameter updated by the function. Signed-off-by: Klaus Jensen --- hw/nvme/nvme.h | 4 ++-- hw/nvme/ctrl.c | 10 +- hw/nvme/dif.c | 22

[PATCH v2 10/11] hw/nvme: reimplement format nvm to allow cancellation

2021-06-17 Thread Klaus Jensen
From: Klaus Jensen Prior to this patch, the aios associated with broadcast format are submitted anonymously (no aiocb reference saved from the blk_aio call). Fix this by formatting the namespaces one after another, saving a reference to the aiocb for each. Signed-off-by: Klaus Jensen ---

[PATCH v5 7/7] bios-tables-test: Update golden binaries

2021-06-17 Thread Julia Suvorova
Add ACPI hot-plug registers to DSDT Q35 tables. Changes in the tables: +Scope (_SB.PCI0) +{ +OperationRegion (PCST, SystemIO, 0x0CC4, 0x08) +Field (PCST, DWordAcc, NoLock, WriteAsZeros) +{ +PCIU, 32, +PCID, 32 +} + +

Re: [PATCH v2 20/23] hw/acpi: Do not restrict ACPI core routines to x86 architecture

2021-06-17 Thread Michael S. Tsirkin
On Wed, Jun 16, 2021 at 10:43:25PM +0200, Philippe Mathieu-Daudé wrote: > ACPI core routines (in core.c) are not really x86-specific. > > Signed-off-by: Philippe Mathieu-Daudé > --- > hw/acpi/meson.build | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git

Re: GICv3 for MTTCG

2021-06-17 Thread Andrey Shinkevich
Dear Shashi, I have applied the version 4 of the series "GICv3 LPI and ITS feature implementation" right after the commit 3e9f48b as before (because the GCCv7.5 is unavailable in the YUM repository for CentOS-7.9). The guest OS still hangs at its start when QEMU is configured with 4 or more

[PATCH v3 2/4] stm32vldiscovery: Add the STM32VLDISCOVERY Machine

2021-06-17 Thread Alexandre Iooss
This is a Cortex-M3 based machine. Information can be found at: https://www.st.com/en/evaluation-tools/stm32vldiscovery.html Signed-off-by: Alexandre Iooss --- MAINTAINERS | 6 +++ default-configs/devices/arm-softmmu.mak | 1 + hw/arm/Kconfig

[PATCH v3 4/4] tests/boot-serial-test: Add STM32VLDISCOVERY board testcase

2021-06-17 Thread Alexandre Iooss
New mini-kernel test for STM32VLDISCOVERY USART1. Signed-off-by: Alexandre Iooss --- tests/qtest/boot-serial-test.c | 37 ++ 1 file changed, 37 insertions(+) diff --git a/tests/qtest/boot-serial-test.c b/tests/qtest/boot-serial-test.c index

[PATCH 2/2] target/mips: Merge msa32/msa64 decodetree definitions

2021-06-17 Thread Philippe Mathieu-Daudé
We don't need to maintain 2 sets of decodetree definitions. Merge them into a single file. Signed-off-by: Philippe Mathieu-Daudé --- target/mips/tcg/{msa32.decode => msa.decode} | 8 +--- target/mips/tcg/msa64.decode | 17 - target/mips/tcg/msa_translate.c

[PATCH 9/9] target/mips: Optimize regnames[] arrays

2021-06-17 Thread Philippe Mathieu-Daudé
Since all entries are no more than 3/4/6 bytes (including nul terminator), can save space and pie runtime relocations by declaring regnames[] as array of 3/4/6 const char. Inspired-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- target/mips/internal.h | 2 +-

[PATCH 1/9] target/mips: Do not abort on invalid instruction

2021-06-17 Thread Philippe Mathieu-Daudé
On real hardware an invalid instruction doesn't halt the world, but usually triggers a RESERVED INSTRUCTION exception. TCG guest code shouldn't abort QEMU anyway. Signed-off-by: Philippe Mathieu-Daudé --- target/mips/tcg/translate.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)

[PATCH 7/9] target/mips: Remove microMIPS BPOSGE32 / BPOSGE64 unuseful cases

2021-06-17 Thread Philippe Mathieu-Daudé
These switch cases for the microMIPS BPOSGE32 / BPOSGE64 opcodes have been added commit 3c824109da0 ("target-mips: microMIPS ASE support"). More than 11 years later it is safe to assume there won't be added soon. The cases fall back to the default which generates a RESERVED INSTRUCTION, so it is

[PATCH v6 5/8] virtiofsd: Add umask to seccom allow list

2021-06-17 Thread Vivek Goyal
Patches in this series are going to make use of "umask" syscall. So allow it. Signed-off-by: Vivek Goyal Reviewed-by: Stefan Hajnoczi --- tools/virtiofsd/passthrough_seccomp.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/virtiofsd/passthrough_seccomp.c

Re: [PATCH v6 0/8] virtiofsd: Add support to enable/disable posix acls

2021-06-17 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20210617181213.1177835-1-vgo...@redhat.com/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20210617181213.1177835-1-vgo...@redhat.com Subject: [PATCH v6 0/8] virtiofsd: Add

Re: [PULL 00/34] NBD patches for 2021-06-15

2021-06-17 Thread Vladimir Sementsov-Ogievskiy
17.06.2021 12:42, Peter Maydell wrote: On Tue, 15 Jun 2021 at 21:50, Eric Blake wrote: The following changes since commit 1ea06abceec61b6f3ab33dadb0510b6e09fb61e2: Merge remote-tracking branch 'remotes/berrange-gitlab/tags/misc-fixes-pull-request' into staging (2021-06-14 15:59:13

Re: [PATCH] hw/nvme: fix pin-based interrupt behavior (again)

2021-06-17 Thread Klaus Jensen
On Jun 17 07:50, Keith Busch wrote: On Thu, Jun 17, 2021 at 12:08:20PM +0200, Klaus Jensen wrote: if (cq->tail != cq->head) { +if (!pending) { +n->cq_pending++; +} You should check cq->irq_enabled before incrementing cq_pending. You don't want to leave the irq

[PATCH v2 08/11] hw/nvme: reimplement the copy command to allow aio cancellation

2021-06-17 Thread Klaus Jensen
From: Klaus Jensen Before this patch the code would issue several aios simultaneously without saving a reference to the aiocb. Without the aiocb reference the individual copies cannot be canceled. Fix this by issuing copies of the ranges one after another. Signed-off-by: Klaus Jensen ---

[PATCH v5 0/7] Use ACPI PCI hot-plug for Q35

2021-06-17 Thread Julia Suvorova
The patch set consists of two parts: patches 1-4: introduce new feature 'acpi-pci-hotplug-with-bridge-support' on Q35 patches 5-7: make the feature default along with changes in ACPI tables With the feature disabled Q35 falls back to the native hot-plug. Pros * no racy behavior

[PATCH v2 06/11] hw/nvme: use prinfo directly in nvme_check_prinfo and nvme_dif_check

2021-06-17 Thread Klaus Jensen
From: Klaus Jensen The nvme_check_prinfo() and nvme_dif_check() functions operate on the 16 bit "control" member of the NvmeCmd. These functions do not otherwise operate on an NvmeCmd or an NvmeRequest, so change them to expect the actual 4 bit PRINFO field and add constants that work on this

Re: [PATCH v9] qapi: introduce 'query-kvm-cpuid' action

2021-06-17 Thread Eduardo Habkost
On Thu, Jun 17, 2021 at 05:53:11PM +0200, Claudio Fontana wrote: > On 6/17/21 5:39 PM, Valeriy Vdovin wrote: > > On Thu, Jun 17, 2021 at 04:14:17PM +0200, Markus Armbruster wrote: > >> Claudio Fontana writes: > >> > >>> On 6/17/21 1:09 PM, Markus Armbruster wrote: > Valeriy Vdovin writes: >

[PATCH 0/4] target/mips: Extract microMIPS ISA and Code Compaction ASE apart

2021-06-17 Thread Philippe Mathieu-Daudé
Extract the microMIPS ISA and Code Compaction ASE translation routines to different source files. Patches rebased and already reviewed, except patch #1. Philippe Mathieu-Daudé (4): target/mips: Add declarations for generic TCG helpers target/mips: Extract Code Compaction ASE translation

[PATCH v5 3/7] hw/acpi/ich9: Enable ACPI PCI hot-plug

2021-06-17 Thread Julia Suvorova
Add acpi_pcihp to ich9_pm as part of 'acpi-pci-hotplug-with-bridge-support' option. Set default to false. Signed-off-by: Julia Suvorova Reviewed-by: Igor Mammedov --- hw/i386/acpi-build.h | 1 + include/hw/acpi/ich9.h | 3 ++ hw/acpi/ich9.c | 67

[PATCH v2 02/11] hw/nvme: add nvme_block_status_all helper

2021-06-17 Thread Klaus Jensen
From: Klaus Jensen Pull the gist of nvme_check_dulbe() into a helper function. This is in preparation for dsm refactoring. Signed-off-by: Klaus Jensen --- hw/nvme/ctrl.c | 41 - 1 file changed, 28 insertions(+), 13 deletions(-) diff --git

[PATCH v2 07/11] hw/nvme: add dw0/1 to the req completion trace event

2021-06-17 Thread Klaus Jensen
From: Klaus Jensen Some commands report additional useful information in dw0 and dw1 of the completion queue entry. Add them to the trace. Signed-off-by: Klaus Jensen --- hw/nvme/ctrl.c | 2 ++ hw/nvme/trace-events | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git

Re: [PATCH v3 4/4] tests/boot-serial-test: Add STM32VLDISCOVERY board testcase

2021-06-17 Thread Thomas Huth
On 17/06/2021 18.56, Alexandre Iooss wrote: New mini-kernel test for STM32VLDISCOVERY USART1. Signed-off-by: Alexandre Iooss --- tests/qtest/boot-serial-test.c | 37 ++ 1 file changed, 37 insertions(+) diff --git a/tests/qtest/boot-serial-test.c

[PATCH RFC] meson: add option to use zstd for qcow2 compression by default

2021-06-17 Thread Vladimir Sementsov-Ogievskiy
Recently we added support of zstd to qcow2 format, as zstd seems to be better than zlib in general, and which is important (as qcow2 compression used mostly for backups) compressed writes are faster with zstd. Let's add a build option to use zstd by default. Signed-off-by: Vladimir

[PATCH v5 4/7] hw/pci/pcie: Do not set HPC flag if acpihp is used

2021-06-17 Thread Julia Suvorova
Instead of changing the hot-plug type in _OSC register, do not set the 'Hot-Plug Capable' flag. This way guest will choose ACPI hot-plug if it is preferred and leave the option to use SHPC with pcie-pci-bridge. The ability to control hot-plug for each downstream port is retained, while

[PATCH 4/4] fuzz: fix the ES1370 generic-fuzzer config.

2021-06-17 Thread Alexander Bulekov
TYPE_ES1370 is "ES1370", capitalized. Fix the config to account for that. Signed-off-by: Alexander Bulekov --- tests/qtest/fuzz/generic_fuzz_configs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qtest/fuzz/generic_fuzz_configs.h

Re: [PATCH v2 00/23] target/i386/sev: Housekeeping (OVMF + SEV-disabled binaries)

2021-06-17 Thread Michael S. Tsirkin
On Wed, Jun 16, 2021 at 10:43:05PM +0200, Philippe Mathieu-Daudé wrote: > Hi, > > While testing James & Dov patch: > https://www.mail-archive.com/qemu-devel@nongnu.org/msg810571.html > I wasted some time trying to figure out how OVMF was supposed to > behave until realizing the binary I was using

Re: [PATCH v5 0/7] Use ACPI PCI hot-plug for Q35

2021-06-17 Thread Michael S. Tsirkin
On Thu, Jun 17, 2021 at 09:07:32PM +0200, Julia Suvorova wrote: > The patch set consists of two parts: > patches 1-4: introduce new feature > 'acpi-pci-hotplug-with-bridge-support' on Q35 > patches 5-7: make the feature default along with changes in ACPI tables > > With the feature

[PULL 4/4] Hexagon (target/hexagon) remove unused TCG variables

2021-06-17 Thread Taylor Simpson
Reviewed-by: Richard Henderson Signed-off-by: Taylor Simpson --- target/hexagon/genptr.c| 6 -- target/hexagon/translate.c | 11 ++- 2 files changed, 2 insertions(+), 15 deletions(-) diff --git a/target/hexagon/genptr.c b/target/hexagon/genptr.c index bd18cb1..5dbabe0 100644

[PULL 2/4] Hexagon (target/hexagon) fix l2fetch instructions

2021-06-17 Thread Taylor Simpson
Y4_l2fetch == l2fetch(Rs32, Rt32) Y5_l2fetch == l2fetch(Rs32, Rtt32) The semantics for these instructions are present, but the encodings are missing. Note that these are treated as nops in qemu, so we add overrides. Test case added to tests/tcg/hexagon/misc.c Reviewed-by: Richard Henderson >

[PULL 1/4] Hexagon (target/hexagon) fix bug in fLSBNEW*

2021-06-17 Thread Taylor Simpson
Change fLSBNEW/fLSBNEW0/fLSBNEW1 from copy to "x & 1" Remove gen_logical_not function Clean up fLSBNEWNOT to use andi-1 followed by xori-1 Test cases added to tests/tcg/hexagon/misc.c Reviewed-by: Richard Henderson Signed-off-by: Taylor Simpson --- target/hexagon/macros.h| 27

[PATCH] meson: Add gnutls as a dependency to libmigration

2021-06-17 Thread Akihiko Odaki
qemu-file-channel.c may depend on GnuTLS. Signed-off-by: Akihiko Odaki --- meson.build | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build index a2311eda6ec..b8812dff387 100644 --- a/meson.build +++ b/meson.build @@ -2090,6 +2090,7 @@ libio =

Re: [PATCH] x86: add SEV hashing to fw_cfg for kernel/initrd/cmdline

2021-06-17 Thread Eduardo Habkost
On Thu, Jun 17, 2021 at 03:48:52PM +0300, Dov Murik wrote: > > > On 15/06/2021 22:53, Philippe Mathieu-Daudé wrote: > > Hi Dov, James, > > > > +Connor who asked to be reviewer. > > > > On 6/15/21 5:20 PM, Eduardo Habkost wrote: > >> On Tue, May 25, 2021 at 06:59:31AM +, Dov Murik wrote: >

[PATCH 1/2] target/mips: Remove pointless gen_msa()

2021-06-17 Thread Philippe Mathieu-Daudé
Only trans_MSA() calls gen_msa(), inline it to simplify. Signed-off-by: Philippe Mathieu-Daudé --- target/mips/tcg/msa_translate.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/target/mips/tcg/msa_translate.c b/target/mips/tcg/msa_translate.c index

[PATCH 4/4] target/mips: Add declarations for generic DSP TCG helpers

2021-06-17 Thread Philippe Mathieu-Daudé
To be able to extract the DSP ASE translation routines to different source file, declare few TCG helpers, MASK_SPECIAL3 and a DSP register in "translate.h". Signed-off-by: Philippe Mathieu-Daudé --- target/mips/tcg/translate.h | 7 +++ target/mips/tcg/translate.c | 10 +- 2 files

[PATCH v6 0/8] virtiofsd: Add support to enable/disable posix acls

2021-06-17 Thread Vivek Goyal
Hi, This is V6 of the patches. Changes since V5: - Kernel patches for extended setxattr have been merged in 5.13-rc1. These patches have been modified to work with FUSE_SETXATTR_EXT. Currently posix ACL support does not work well with virtiofs and bunch of tests fail when I run xfstests

  1   2   3   4   5   >