Re: [RFC v2 16/24] target/arm: move sve_zcr_len_for_el to common_cpu

2021-03-03 Thread Claudio Fontana
On 3/2/21 5:41 AM, Richard Henderson wrote: > On 3/1/21 8:49 AM, Claudio Fontana wrote: >> it is required by arch-dump.c and cpu.c, so apparently >> we need this for KVM too? >> >> Signed-off-by: Claudio Fontana >> --- >> target/arm/cpu-common.c | 33 + >> target/

Re: [PATCH] hw/elf_ops: Fix a typo

2021-03-03 Thread David Edmondson
On Thursday, 2021-02-25 at 19:13:44 +01, Philippe Mathieu-Daudé wrote: > g_mapped_file_new_from_fd()'s parameter is named 'writable'. > > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: David Edmondson > --- > include/hw/elf_ops.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >

Re: [PATCH] chardev: add nodelay option

2021-03-03 Thread Markus Armbruster
Paolo Bonzini writes: > On 02/03/21 12:39, Daniel P. Berrangé wrote: >> On Tue, Mar 02, 2021 at 12:04:44PM +0100, Paolo Bonzini wrote: >>> The "delay" option was introduced as a way to enable Nagle's algorithm >>> with ",nodelay". Since the short form for boolean options has now been >>> depreca

Re: [RFC PATCH 00/26] Confidential guest live migration

2021-03-03 Thread Dov Murik
The errors reported below on patch 02/26 are due to rebasing an older patch from AMD. I didn't want to make any changes to the code (except make it compile and run correctly) because this feature (encrypted pages bitmap) is still work-in-progress (in KVM and QEMU). -Dov On 02/03/2021 23:24, no-r

Re: [PATCH v2 01/42] esp: checkpatch fixes

2021-03-03 Thread Mark Cave-Ayland
On 01/03/2021 19:43, Laurent Vivier wrote: Le 09/02/2021 à 20:29, Mark Cave-Ayland a écrit : Signed-off-by: Mark Cave-Ayland Reviewed-by: Philippe Mathieu-Daudé --- hw/scsi/esp.c | 52 ++- 1 file changed, 31 insertions(+), 21 deletions(-) di

Re: [PATCH v2 09/42] esp: introduce esp_get_tc() and esp_set_tc()

2021-03-03 Thread Mark Cave-Ayland
On 01/03/2021 21:24, Laurent Vivier wrote: Le 09/02/2021 à 20:29, Mark Cave-Ayland a écrit : This simplifies reading and writing the TC register value without having to manually shift each individual 8-bit value. Signed-off-by: Mark Cave-Ayland Reviewed-by: Philippe Mathieu-Daudé --- hw/sc

Re: [PATCH v2 2/3] migration/ram: Modify ram_save_host_page() to match the comment

2021-03-03 Thread david.edmondson
On Monday, 2021-03-01 at 16:21:31 +08, Kunkun Jiang wrote: > According to the comment, when the host page is a huge page, the > migration_rate_limit() should be executed. If not, this function > can be omitted to save time. > > Signed-off-by: Keqian Zhu > Signed-off-by: Kunkun Jiang Reviewed-by

Re: [PATCH v2 1/3] migration/ram: Modify the code comment of ram_save_host_page()

2021-03-03 Thread David Edmondson
On Monday, 2021-03-01 at 16:21:30 +08, Kunkun Jiang wrote: > The ram_save_host_page() has been modified several times > since its birth. But the comment hasn't been modified as it should > be. It'd better to modify the comment to explain ram_save_host_page() > more clearly. I don't think that it'

Re: [PATCH] multi-process: Initialize variables declared with g_auto*

2021-03-03 Thread Jag Raman
> On Mar 3, 2021, at 2:06 AM, Zenghui Yu wrote: > > Quote docs/devel/style.rst (section "Automatic memory deallocation"): > > * Variables declared with g_auto* MUST always be initialized, > otherwise the cleanup function will use uninitialized stack memory > > Initialize @name properly to g

Re: [PATCH v2 11/42] esp: apply transfer length adjustment when STC is zero at TC load time

2021-03-03 Thread Mark Cave-Ayland
On 01/03/2021 21:35, Laurent Vivier wrote: Le 09/02/2021 à 20:29, Mark Cave-Ayland a écrit : Perform the length adjustment whereby a value of 0 in the STC represents a transfer length of 0x1 at the point where the TC is loaded at the start of a DMA command rather than just when a TI (Transf

Re: [PATCH v2 3/3] migration/ram: Optimize ram_save_host_page()

2021-03-03 Thread David Edmondson
On Monday, 2021-03-01 at 16:21:32 +08, Kunkun Jiang wrote: > Starting from pss->page, ram_save_host_page() will check every page > and send the dirty pages up to the end of the current host page or > the boundary of used_length of the block. If the host page size is > a huge page, the step "check"

Re: [PATCH v3 12/21] sd: emmc: add CMD21 tuning sequence

2021-03-03 Thread Dr. David Alan Gilbert
* Sai Pavan Boddu (saip...@xilinx.com) wrote: > Hi David, > > > -Original Message- > > From: Dr. David Alan Gilbert > > Sent: Monday, March 1, 2021 4:12 PM > > To: Sai Pavan Boddu > > Cc: Markus Armbruster ; Kevin Wolf > > ; Max Reitz ; Vladimir Sementsov- > > Ogievskiy ; Eric Blake ; >

Re: [PATCH] virtio-gpu: Respect graphics update interval for EDID

2021-03-03 Thread Gerd Hoffmann
On Fri, Feb 26, 2021 at 01:47:38PM +0900, Akihiko Odaki wrote: > 2021年2月25日(木) 20:46 Gerd Hoffmann : > > > > Hi, > > > > > > Because of the wasted frames I'd like this to be an option you can > > > > enable when needed. For the majority of use cases this seems to be > > > > no problem ... > > >

[RFC PATCH v2 0/9] net: Handle short frames for SLiRP/TAP interfaces

2021-03-03 Thread Bin Meng
From: Bin Meng The minimum Ethernet frame length is 60 bytes. For short frames with smaller length like ARP packets (only 42 bytes), on a real world NIC it can choose either padding its length to the minimum required 60 bytes, or sending it out directly to the wire. Such behavior can be hardcode

[RFC PATCH v2 1/9] net: Pad short frames to minimum size before send from SLiRP/TAP

2021-03-03 Thread Bin Meng
From: Bin Meng The minimum Ethernet frame length is 60 bytes. For short frames with smaller length like ARP packets (only 42 bytes), on a real world NIC it can choose either padding its length to the minimum required 60 bytes, or sending it out directly to the wire. Such behavior can be hardcoded

[RFC PATCH v2 3/9] hw/net: vmxnet3: Remove the logic of padding short frames in the receive path

2021-03-03 Thread Bin Meng
From: Bin Meng Now that we have implemented unified short frames padding in the QEMU networking codes, remove the same logic in the NIC codes. This actually reverts commit 40a87c6c9b11ef9c14e0301f76abf0eb2582f08e. Signed-off-by: Bin Meng --- (no changes since v1) hw/net/vmxnet3.c | 10 -

[RFC PATCH v2 8/9] hw/net: sungem: Remove the logic of padding short frames in the receive path

2021-03-03 Thread Bin Meng
From: Bin Meng Now that we have implemented unified short frames padding in the QEMU networking codes, remove the same logic in the NIC codes. Signed-off-by: Bin Meng --- (no changes since v1) hw/net/sungem.c | 14 -- 1 file changed, 14 deletions(-) diff --git a/hw/net/sungem.c

[RFC PATCH v2 2/9] hw/net: e1000: Remove the logic of padding short frames in the receive path

2021-03-03 Thread Bin Meng
From: Bin Meng Now that we have implemented unified short frames padding in the QEMU networking codes, remove the same logic in the NIC codes. This actually reverts commit 78aeb23eded2d0b765bf9145c71f80025b568acd. Signed-off-by: Bin Meng --- (no changes since v1) hw/net/e1000.c | 11 +--

[RFC PATCH v2 7/9] hw/net: rtl8139: Remove the logic of padding short frames in the receive path

2021-03-03 Thread Bin Meng
From: Bin Meng Now that we have implemented unified short frames padding in the QEMU networking codes, remove the same logic in the NIC codes. Signed-off-by: Bin Meng --- (no changes since v1) hw/net/rtl8139.c | 12 1 file changed, 12 deletions(-) diff --git a/hw/net/rtl8139.c

[RFC PATCH v2 4/9] hw/net: i82596: Remove the logic of padding short frames in the receive path

2021-03-03 Thread Bin Meng
From: Bin Meng Now that we have implemented unified short frames padding in the QEMU networking codes, remove the same logic in the NIC codes. Signed-off-by: Bin Meng --- (no changes since v1) hw/net/i82596.c | 18 -- 1 file changed, 18 deletions(-) diff --git a/hw/net/i8259

[RFC PATCH v2 6/9] hw/net: pcnet: Remove the logic of padding short frames in the receive path

2021-03-03 Thread Bin Meng
From: Bin Meng Now that we have implemented unified short frames padding in the QEMU networking codes, remove the same logic in the NIC codes. Signed-off-by: Bin Meng --- (no changes since v1) hw/net/pcnet.c | 9 - 1 file changed, 9 deletions(-) diff --git a/hw/net/pcnet.c b/hw/net/

[Bug 1917591] [NEW] qemu-i386 under aarch64: Segfaulting on Steamcmd

2021-03-03 Thread Jaap Buurman
Public bug reported: I am trying to set up a Valheim server on my Raspberry Pi 4 (8GB). I have installed the aarch64 image of Arm Arch Linux. I installed qemu-user-static (version 5.2.0 at this time of writing) from the AUR: https://aur.archlinux.org/packages/qemu-user-static/ I have correctly s

[RFC PATCH v2 5/9] hw/net: ne2000: Remove the logic of padding short frames in the receive path

2021-03-03 Thread Bin Meng
From: Bin Meng Now that we have implemented unified short frames padding in the QEMU networking codes, remove the same logic in the NIC codes. Signed-off-by: Bin Meng --- (no changes since v1) hw/net/ne2000.c | 12 1 file changed, 12 deletions(-) diff --git a/hw/net/ne2000.c b/

[RFC PATCH v2 9/9] hw/net: sunhme: Remove the logic of padding short frames in the receive path

2021-03-03 Thread Bin Meng
From: Bin Meng Now that we have implemented unified short frames padding in the QEMU networking codes, remove the same logic in the NIC codes. Signed-off-by: Bin Meng --- (no changes since v1) hw/net/sunhme.c | 11 --- 1 file changed, 11 deletions(-) diff --git a/hw/net/sunhme.c b/

Re: [PATCH 1/2] coreaudio: Drop support for macOS older than 10.6

2021-03-03 Thread Gerd Hoffmann
On Mon, Mar 01, 2021 at 08:45:53PM +0900, Akihiko Odaki wrote: > Mac OS X 10.6 was released in 2009. Also minimum version required my qemu is 10.13 (I think), so any code for older macos versions is dead anyway. take care, Gerd

Re: [PATCH v3] qemu-storage-daemon: add --pidfile option

2021-03-03 Thread Kevin Wolf
Am 02.03.2021 um 15:27 hat Stefan Hajnoczi geschrieben: > Daemons often have a --pidfile option where the pid is written to a file > so that scripts can stop the daemon by sending a signal. > > The pid file also acts as a lock to prevent multiple instances of the > daemon from launching for a give

Re: [PATCH 2/2] coreaudio: Handle output device change

2021-03-03 Thread Gerd Hoffmann
Hi, > status = coreaudio_get_voice(&core->outputDeviceID); > if (status != kAudioHardwareNoError) { > -coreaudio_logerr2 (status, typ, > - "Could not get default output Device\n"); > -return -1; > +coreaudio_playback_logerr (status, > +

Re: [PATCH 2/2] tests/acceptance: Test ast2600 machine

2021-03-03 Thread Joel Stanley
On Wed, 3 Mar 2021 at 07:43, Cédric Le Goater wrote: > > On 3/3/21 2:22 AM, Joel Stanley wrote: > > This tests a Debian multi-soc arm32 Linux kernel on the AST2600 based > > Tacoma BMC machine. > > > > There is no root file system so the test terminates when boot reaches > > the stage where it att

Re: [PATCH v3 0/2] docs: show how to spawn qemu-storage-daemon with fd passing

2021-03-03 Thread Kevin Wolf
Am 01.03.2021 um 18:27 hat Stefan Hajnoczi geschrieben: > v3: > * Explain how to detect launch errors and that the listen socket must be >closed in the parent process in order for this to work [Daniel] > > v2: > * Use /var/run/qmp.sock instead of /tmp/qmp-$PID.sock to prevent security >i

Re: [PATCH] i386: Add missing cpu feature bits in EPYC-Rome model

2021-03-03 Thread David Edmondson
On Tuesday, 2021-03-02 at 15:20:00 -06, Babu Moger wrote: > Found the following cpu feature bits missing from EPYC-Rome model. > ibrs: Indirect Branch Restricted Speculation > ssbd: Speculative Store Bypass Disable > > These new features will be added in EPYC-Rome-v2. The -cpu help output

Re: [PATCH v1] acpi: increase maximum size for "etc/table-loader" blob

2021-03-03 Thread Michael S. Tsirkin
On Tue, Mar 02, 2021 at 07:43:40PM +0100, David Hildenbrand wrote: > > > > The resizeable memory region that is created for the cmd blob has a > > > > maximum > > > > size of ACPI_BUILD_ALIGN_SIZE - 4k. This used to be sufficient, however, > > > > The expression "ACPI_BUILD_ALIGN_SIZE - 4k" makes

[PATCH] linux-user: Adjust pgd_find_hole_fallback result with guest_loaddr

2021-03-03 Thread Ivan A. Melnikov
While pgd_find_hole_fallback returns the beginning of the hole found, pgb_find_hole returns guest_base, which is somewhat different as the binary qemu-user is loading usually has non-zero load address. Failing to take this into account leads to random crashes if the hole is "just big enough", but

Re: [PATCH v1] acpi: increase maximum size for "etc/table-loader" blob

2021-03-03 Thread David Hildenbrand
On 03.03.21 10:43, Michael S. Tsirkin wrote: On Tue, Mar 02, 2021 at 07:43:40PM +0100, David Hildenbrand wrote: The resizeable memory region that is created for the cmd blob has a maximum size of ACPI_BUILD_ALIGN_SIZE - 4k. This used to be sufficient, however, The expression "ACPI_BUILD_ALIGN_

Re: [PATCH v1] acpi: increase maximum size for "etc/table-loader" blob

2021-03-03 Thread David Hildenbrand
On 02.03.21 19:43, David Hildenbrand wrote: The resizeable memory region that is created for the cmd blob has a maximum size of ACPI_BUILD_ALIGN_SIZE - 4k. This used to be sufficient, however, The expression "ACPI_BUILD_ALIGN_SIZE - 4k" makes no sense to me. ACPI_BUILD_ALIGN_SIZE is #defined in

Re: [PATCH 0/2] Clarify error messages pertaining to 'node-name'

2021-03-03 Thread Kevin Wolf
Am 02.03.2021 um 00:36 hat Connor Kuehl geschrieben: > Some error messages contain ambiguous representations of the 'node-name' > parameter. This can be particularly confusing when exchanging QMP > messages (C = client, S = server): > > C: {"execute": "block_resize", "arguments": { "device": "my_f

[PATCH v7 1/5] qapi: net: Add query-netdev command

2021-03-03 Thread Alexey Kirillov
The query-netdev command is used to get the configuration of the current network device backends (netdevs). This is the QMP analog of the HMP command "info network" but only for netdevs (i.e. excluding NIC and hubports). The query-netdev command returns an array of objects of the NetdevInfo type,

[PATCH v7 0/5] Introducing QMP query-netdev command

2021-03-03 Thread Alexey Kirillov
This patch series introduces a new QMP command "query-netdev" to get information about currently attached backend network devices (netdevs). Also, since the "info_str" field of "NetClientState" is now deprecated, we no longer use it for netdevs, only for NIC/hubports. The HMP command "info networ

[PATCH v7 2/5] tests: Add tests for query-netdev command

2021-03-03 Thread Alexey Kirillov
A simply qtest that checks for correct number of netdevs in the response of the query-netdev. Signed-off-by: Alexey Kirillov Acked-by: Thomas Huth --- tests/qtest/meson.build | 3 + tests/qtest/test-query-netdev.c | 120 2 files changed, 123 insertions

[PATCH v7 3/5] net: Move NetClientState.info_str to dynamic allocations

2021-03-03 Thread Alexey Kirillov
The info_str field of the NetClientState structure is static and has a size of 256 bytes. This amount is often unclaimed, and the field itself is used exclusively for HMP "info network". The patch translates info_str to dynamic memory allocation. This action is also allows us to painlessly discar

Re: [PATCH v2 0/2] gitlab-ci.yml: Add jobs to test CFI

2021-03-03 Thread Daniel P . Berrangé
On Tue, Mar 02, 2021 at 04:01:17PM -0500, Daniele Buono wrote: > On 3/2/2021 11:40 AM, Daniel P. Berrangé wrote: > > The CFI protection is something I'd say is relevant to virtualization > > use cases, not to emulation use cases > > > > https://qemu-project.gitlab.io/qemu/system/security.html

[PATCH v7 4/5] hmp: Use QAPI NetdevInfo in hmp_info_network

2021-03-03 Thread Alexey Kirillov
Replace usage of legacy field info_str of NetClientState for backend network devices with QAPI NetdevInfo stored_config that already used in QMP query-netdev. This change increases the detail of the "info network" output and takes a more general approach to composing the output. NIC and hubports

[PATCH v7 5/5] net: Do not fill legacy info_str for backends

2021-03-03 Thread Alexey Kirillov
As we use QAPI NetClientState->stored_config to store and get information about backend network devices, we can drop fill of legacy field info_str for them. We still use info_str field for NIC and hubports, so we can not completely remove it. Signed-off-by: Alexey Kirillov --- net/l2tpv3.c

Re: [PATCH 1/3] qapi, audio: add query-audiodev command

2021-03-03 Thread Daniel P . Berrangé
On Tue, Mar 02, 2021 at 10:10:56PM +0100, Philippe Mathieu-Daudé wrote: > On 3/2/21 6:55 PM, Daniel P. Berrangé wrote: > > Way back in QEMU 4.0, the -audiodev command line option was introduced > > for configuring audio backends. This CLI option does not use QemuOpts > > so it is not visible for in

Re: [PATCH 2/3] qapi, audio: respect build time conditions in audio schema

2021-03-03 Thread Daniel P . Berrangé
On Tue, Mar 02, 2021 at 01:05:45PM -0600, Eric Blake wrote: > On 3/2/21 11:55 AM, Daniel P. Berrangé wrote: > > Currently the -audiodev accepts any audiodev type regardless of what is > > built in to QEMU. An error only occurs later at runtime when a sound > > device tries to use the audio backend.

Re: [PATCH 1/3] qapi, audio: add query-audiodev command

2021-03-03 Thread Daniel P . Berrangé
On Tue, Mar 02, 2021 at 10:12:43PM +0100, Philippe Mathieu-Daudé wrote: > On 3/2/21 10:10 PM, Philippe Mathieu-Daudé wrote: > > On 3/2/21 6:55 PM, Daniel P. Berrangé wrote: > >> Way back in QEMU 4.0, the -audiodev command line option was introduced > >> for configuring audio backends. This CLI opti

Re: [PATCH] multi-process: Initialize variables declared with g_auto*

2021-03-03 Thread Philippe Mathieu-Daudé
Hi, On 3/3/21 8:06 AM, Zenghui Yu wrote: > Quote docs/devel/style.rst (section "Automatic memory deallocation"): > > * Variables declared with g_auto* MUST always be initialized, > otherwise the cleanup function will use uninitialized stack memory > > Initialize @name properly to get rid of th

Re: [PATCH 2/3] qapi, audio: respect build time conditions in audio schema

2021-03-03 Thread Daniel P . Berrangé
On Wed, Mar 03, 2021 at 08:00:59AM +0100, Gerd Hoffmann wrote: > On Tue, Mar 02, 2021 at 05:55:23PM +, Daniel P. Berrangé wrote: > > Currently the -audiodev accepts any audiodev type regardless of what is > > built in to QEMU. An error only occurs later at runtime when a sound > > device tries

Re: [PATCH v1 8/9] util/mmap-alloc: support RAM_NORESERVE via MAP_NORESERVE

2021-03-03 Thread David Hildenbrand
On 02.03.21 22:44, Peter Xu wrote: On Tue, Mar 02, 2021 at 08:01:11PM +0100, David Hildenbrand wrote: On 02.03.21 18:51, Peter Xu wrote: On Tue, Feb 09, 2021 at 02:49:38PM +0100, David Hildenbrand wrote: +#define OVERCOMMIT_MEMORY_PATH "/proc/sys/vm/overcommit_memory" +static bool map_noreserv

Re: [RFC PATCH v2 1/9] net: Pad short frames to minimum size before send from SLiRP/TAP

2021-03-03 Thread Philippe Mathieu-Daudé
On 3/3/21 10:21 AM, Bin Meng wrote: > From: Bin Meng > > The minimum Ethernet frame length is 60 bytes. For short frames with > smaller length like ARP packets (only 42 bytes), on a real world NIC > it can choose either padding its length to the minimum required 60 > bytes, or sending it out dire

Re: [PATCH] multi-process: Initialize variables declared with g_auto*

2021-03-03 Thread Daniel P . Berrangé
On Wed, Mar 03, 2021 at 03:06:39PM +0800, Zenghui Yu wrote: > Quote docs/devel/style.rst (section "Automatic memory deallocation"): > > * Variables declared with g_auto* MUST always be initialized, > otherwise the cleanup function will use uninitialized stack memory > > Initialize @name properl

Re: [PATCH 1/2] tests/acceptance: Test ast2400 and ast2500 machines

2021-03-03 Thread Philippe Mathieu-Daudé
On 3/3/21 2:22 AM, Joel Stanley wrote: > Test MTD images from the OpenBMC project on AST2400 and AST2500 SoCs > from ASPEED, by booting Palmetto and Romulus BMC machines. > > The images are fetched from OpenBMC's release directory on github. You need to justify here why this is safe to run that o

Re: [PATCH v2 6/8] qemu-options: Replace the word 'blacklist'

2021-03-03 Thread Daniel P . Berrangé
On Fri, Feb 05, 2021 at 06:18:15PM +0100, Philippe Mathieu-Daudé wrote: > Follow the inclusive terminology from the "Conscious Language in your > Open Source Projects" guidelines [*] and replace the word "blacklist" > appropriately. > > [*] https://github.com/conscious-lang/conscious-lang-docs/blo

Re: [PATCH v1] vhost-vdpa: Set discarding of RAM broken when initializing the backend

2021-03-03 Thread David Hildenbrand
On 03.03.21 03:53, Jason Wang wrote: On 2021/3/3 12:21 上午, David Hildenbrand wrote: Similar to VFIO, vDPA will go ahead an map+pin all guest memory. Memory that used to be discarded will get re-populated and if we discard+re-access memory after mapping+pinning, the pages mapped into the vDPA IO

Re: [PATCH] multi-process: Initialize variables declared with g_auto*

2021-03-03 Thread Philippe Mathieu-Daudé
On 3/3/21 11:17 AM, Daniel P. Berrangé wrote: > On Wed, Mar 03, 2021 at 03:06:39PM +0800, Zenghui Yu wrote: >> Quote docs/devel/style.rst (section "Automatic memory deallocation"): >> >> * Variables declared with g_auto* MUST always be initialized, >> otherwise the cleanup function will use unini

Re: [PATCH v2 0/8] misc: Replace the words 'blacklist/whitelist'

2021-03-03 Thread Philippe Mathieu-Daudé
Hi Laurent, On 2/5/21 6:18 PM, Philippe Mathieu-Daudé wrote: > Follow the inclusive terminology from the "Conscious Language in your > Open Source Projects" guidelines [*] and replace the words "blacklist" > and "whitelist" appropriately. > > Series expected to go via the qemu-trivial@ tree. I

Re: [RFC PATCH v2 1/9] net: Pad short frames to minimum size before send from SLiRP/TAP

2021-03-03 Thread Bin Meng
Hi Philippe, On Wed, Mar 3, 2021 at 6:15 PM Philippe Mathieu-Daudé wrote: > > On 3/3/21 10:21 AM, Bin Meng wrote: > > From: Bin Meng > > > > The minimum Ethernet frame length is 60 bytes. For short frames with > > smaller length like ARP packets (only 42 bytes), on a real world NIC > > it can ch

kvmvapic post_load

2021-03-03 Thread Pavel Dovgalyuk
I've got the following issue while testing reverse debugging functions. kvmvapic stalls in vapic_enable_tpr_reporting function, which is called at post_load phase. Does anyone have an idea how to fix this issue? Here is the backtrace for main thread, which loadvm and post_load functions.

Re: [PATCH v1] vhost-vdpa: Set discarding of RAM broken when initializing the backend

2021-03-03 Thread David Hildenbrand
On 03.03.21 11:26, David Hildenbrand wrote: On 03.03.21 03:53, Jason Wang wrote: On 2021/3/3 12:21 上午, David Hildenbrand wrote: Similar to VFIO, vDPA will go ahead an map+pin all guest memory. Memory that used to be discarded will get re-populated and if we discard+re-access memory after mappi

[PATCH v3 0/5] hw/sd: sdhci: Fixes to CVE-2020-17380, CVE-2020-25085, CVE-2021-3409

2021-03-03 Thread Bin Meng
This series includes several fixes to CVE-2020-17380, CVE-2020-25085 and CVE-2021-3409 that are heap-based buffer overflow issues existing in the sdhci model. These CVEs are pretty much similar, and were filed using different reproducers. With this series, current known reproducers I have cannot b

[PATCH v3 4/5] hw/sd: sdhci: Limit block size only when SDHC_BLKSIZE register is writable

2021-03-03 Thread Bin Meng
The codes to limit the maximum block size is only necessary when SDHC_BLKSIZE register is writable. Signed-off-by: Bin Meng Tested-by: Alexander Bulekov Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Bin Meng --- (no changes since v2) Changes in v2: - new patch: sdhci: Limit block size

[PATCH v3 1/5] hw/sd: sdhci: Don't transfer any data when command time out

2021-03-03 Thread Bin Meng
At the end of sdhci_send_command(), it starts a data transfer if the command register indicates data is associated. But the data transfer should only be initiated when the command execution has succeeded. With this fix, the following reproducer: outl 0xcf8 0x80001810 outl 0xcfc 0xe1068000 outl 0x

[PATCH v3 5/5] hw/sd: sdhci: Reset the data pointer of s->fifo_buffer[] when a different block size is programmed

2021-03-03 Thread Bin Meng
If the block size is programmed to a different value from the previous one, reset the data pointer of s->fifo_buffer[] so that s->fifo_buffer[] can be filled in using the new block size in the next transfer. With this fix, the following reproducer: outl 0xcf8 0x80001010 outl 0xcfc 0xe000 outl

[PATCH v3 2/5] hw/sd: sdhci: Don't write to SDHC_SYSAD register when transfer is in progress

2021-03-03 Thread Bin Meng
Per "SD Host Controller Standard Specification Version 7.00" chapter 2.2.1 SDMA System Address Register: This register can be accessed only if no transaction is executing (i.e., after a transaction has stopped). With this fix, the following reproducer: outl 0xcf8 0x80001010 outl 0xcfc 0xfbefff00

[PATCH v3 3/5] hw/sd: sdhci: Correctly set the controller status for ADMA

2021-03-03 Thread Bin Meng
When an ADMA transfer is started, the codes forget to set the controller status to indicate a transfer is in progress. With this fix, the following 2 reproducers: https://paste.debian.net/plain/1185136 https://paste.debian.net/plain/1185141 cannot be reproduced with the following QEMU command li

Inconsistent virtio-net-pci MSI vector count

2021-03-03 Thread Stefan Hajnoczi
Hi Jason, I stumbled across something strange with virtio-net multi-queue today. It doesn't seem to be a bug in practice, just an inconsistency. Here are the details in case you think something needs to be changed: libvirt uses the vectors = 2 * N + 2 formula from https://www.linux-kvm.org/page/Mu

Re: [PATCH] arm/ast2600: Fix SMP booting with -kernel

2021-03-03 Thread Cédric Le Goater
On 3/3/21 2:05 AM, Joel Stanley wrote: > The ast2600 machines do not have PSCI firmware, so this property should > have never been set. Removing this node fixes SMP booting Linux kernels > that have PSCI enabled, as Linux fails to find PSCI in the device tree > and falls back to the soc-specific me

Re: [PATCH 1/2] tests/acceptance: Test ast2400 and ast2500 machines

2021-03-03 Thread Joel Stanley
On Wed, 3 Mar 2021 at 10:19, Philippe Mathieu-Daudé wrote: > > On 3/3/21 2:22 AM, Joel Stanley wrote: > > Test MTD images from the OpenBMC project on AST2400 and AST2500 SoCs > > from ASPEED, by booting Palmetto and Romulus BMC machines. > > > > The images are fetched from OpenBMC's release direct

Re: [PATCH v4] net/macos: implement vmnet-based netdev

2021-03-03 Thread Phillip Tennen
Thanks very much for your help and feedback! Apologies for my delay in following up. I'll submit a new version that implements the feedback you've provided here, as well as the QAPI schema changes @Markus Armbruster (thanks to you as well for your time and review!) pointed out. Phillip On Wed,

Re: [PATCH v1 7/9] memory: introduce RAM_NORESERVE and wire it up in qemu_ram_mmap()

2021-03-03 Thread Cornelia Huck
On Tue, 2 Mar 2021 20:02:34 +0100 David Hildenbrand wrote: > On 02.03.21 18:32, Peter Xu wrote: > > On Tue, Feb 09, 2021 at 02:49:37PM +0100, David Hildenbrand wrote: > >> @@ -899,13 +899,17 @@ int kvm_s390_mem_op_pv(S390CPU *cpu, uint64_t > >> offset, void *hostbuf, > >>* to grow. We also

Re: [PATCH v3] target/s390x: Implement the MVPG condition-code-option bit

2021-03-03 Thread Thomas Huth
On 03/03/2021 07.25, Thomas Huth wrote: On 03/03/2021 03.44, Richard Henderson wrote: If the CCO bit is set, MVPG should not generate an exception but report page translation faults via a CC code. Create a new helper, access_prepare_nf, which can use probe_access_flags in non-faulting mode, and

Re: [PATCH v1 7/9] memory: introduce RAM_NORESERVE and wire it up in qemu_ram_mmap()

2021-03-03 Thread David Hildenbrand
On 03.03.21 12:35, Cornelia Huck wrote: On Tue, 2 Mar 2021 20:02:34 +0100 David Hildenbrand wrote: On 02.03.21 18:32, Peter Xu wrote: On Tue, Feb 09, 2021 at 02:49:37PM +0100, David Hildenbrand wrote: @@ -899,13 +899,17 @@ int kvm_s390_mem_op_pv(S390CPU *cpu, uint64_t offset, void *hostbuf,

Re: [PATCH v1 7/9] memory: introduce RAM_NORESERVE and wire it up in qemu_ram_mmap()

2021-03-03 Thread Thomas Huth
On 03/03/2021 12.35, Cornelia Huck wrote: On Tue, 2 Mar 2021 20:02:34 +0100 David Hildenbrand wrote: On 02.03.21 18:32, Peter Xu wrote: On Tue, Feb 09, 2021 at 02:49:37PM +0100, David Hildenbrand wrote: @@ -899,13 +899,17 @@ int kvm_s390_mem_op_pv(S390CPU *cpu, uint64_t offset, void *hostbu

[RFC v3 01/23] target/arm: move translate modules to tcg/

2021-03-03 Thread Claudio Fontana
Signed-off-by: Claudio Fontana Reviewed-by: Richard Henderson --- target/arm/{ => tcg}/translate-a64.h | 0 target/arm/{ => tcg}/translate.h | 0 target/arm/{ => tcg}/a32-uncond.decode| 0 target/arm/{ => tcg}/a32.decode | 0 target/arm/{ => tcg}/m-nocp.decode

[RFC v3 03/23] arm: tcg: only build under CONFIG_TCG

2021-03-03 Thread Claudio Fontana
Signed-off-by: Claudio Fontana Reviewed-by: Richard Henderson --- target/arm/tcg/meson.build | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/target/arm/tcg/meson.build b/target/arm/tcg/meson.build index 0bd4e9d954..3b4146d079 100644 --- a/target/arm/tcg/meson.build +++

[RFC v3 09/23] target/arm: move cpu definitions to common cpu module

2021-03-03 Thread Claudio Fontana
Signed-off-by: Claudio Fontana --- target/arm/cpu-common.c | 41 + target/arm/tcg/helper.c | 29 - target/arm/meson.build | 1 + 3 files changed, 42 insertions(+), 29 deletions(-) create mode 100644 target/arm/cpu-common.c di

[RFC v3 02/23] target/arm: move helpers to tcg/

2021-03-03 Thread Claudio Fontana
Signed-off-by: Claudio Fontana Reviewed-by: Richard Henderson [claudio: moved vec_internal.h and op_addsub.h to tcg/ too] Signed-off-by: Claudio Fontana --- meson.build | 1 + target/arm/{ => tcg}/op_addsub.h | 0 target/arm/tcg/trace.h | 1 + tar

[RFC v3 05/23] target/arm: only build psci for TCG

2021-03-03 Thread Claudio Fontana
We do not move psci.c to tcg/ because we expect other hypervisors to use it (waiting for HVF enablement). Signed-off-by: Claudio Fontana Cc: Alexander Graf --- target/arm/meson.build | 4 1 file changed, 4 insertions(+) diff --git a/target/arm/meson.build b/target/arm/meson.build index 01

[RFC v3 14/23] target/arm: split vfp state setting from tcg helpers

2021-03-03 Thread Claudio Fontana
cpu-vfp.c: vfp_get_fpsr and vfp_set_fpsr are needed also for KVM, so create a new cpu-vfp.c tcg/cpu-vfp.c: vfp_get_fpscr_from_host and vv are TCG-only, so we move the implementation to tcg/cpu-vfp.c kvm/helper-stubs.c: vfp_get_fpscr_from_host and vv stubs for KVM. Signe

[RFC v3 00/23] arm cleanup experiment for kvm-only build

2021-03-03 Thread Claudio Fontana
Here a new version of the series that enables kvm-only builds. The goal here is to enable the KVM-only build. The move of kvm code to kvm/ is planned for the next series, along with the splitting of the accelerator-specific extensions to the cpu class. v2 -> v3: * "target/arm: tcg: add sysemu a

[RFC v3 04/23] target/arm: tcg: add sysemu and user subsirs

2021-03-03 Thread Claudio Fontana
Signed-off-by: Claudio Fontana --- target/arm/tcg/meson.build| 3 +++ target/arm/tcg/sysemu/meson.build | 3 +++ target/arm/tcg/user/meson.build | 3 +++ 3 files changed, 9 insertions(+) create mode 100644 target/arm/tcg/sysemu/meson.build create mode 100644 target/arm/tcg/user/meson.

[RFC v3 16/23] target/arm: move sve_zcr_len_for_el to common_cpu

2021-03-03 Thread Claudio Fontana
it is required by arch-dump.c and cpu.c, so apparently we need this for KVM too Signed-off-by: Claudio Fontana --- target/arm/cpu-common.c | 43 + target/arm/tcg/helper.c | 33 --- 2 files changed, 43 insertions(+), 33 deletions

[RFC v3 06/23] target/arm: split off cpu-sysemu.c

2021-03-03 Thread Claudio Fontana
move work is needed later on to split things into tcg-specific portions and kvm-specific portions of this Signed-off-by: Claudio Fontana --- target/arm/internals.h | 8 ++- target/arm/cpu-sysemu.c | 105 target/arm/cpu.c| 83 --

Re: [PATCH v2 3/3] migration/ram: Optimize ram_save_host_page()

2021-03-03 Thread Kunkun Jiang
On 2021/3/3 16:56, David Edmondson wrote: On Monday, 2021-03-01 at 16:21:32 +08, Kunkun Jiang wrote: Starting from pss->page, ram_save_host_page() will check every page and send the dirty pages up to the end of the current host page or the boundary of used_length of the block. If the host page

[RFC v3 12/23] target/arm: move cpsr_read, cpsr_write to cpu_common

2021-03-03 Thread Claudio Fontana
we need as a result to move switch_mode too, so we put an implementation into cpu_user and cpu_sysemu. Signed-off-by: Claudio Fontana --- target/arm/cpu.h| 2 + target/arm/cpu-common.c | 182 + target/arm/cpu-sysemu.c | 29 ++ target/arm/cpu-user.c

[RFC v3 10/23] target/arm: only perform TCG cpu and machine inits if TCG enabled

2021-03-03 Thread Claudio Fontana
of note, cpreg lists were previously initialized by TCG first, and then thrown away and replaced with the data coming from KVM. Now we just initialize once, either for TCG or for KVM. Signed-off-by: Claudio Fontana --- target/arm/cpu.c | 32 ++-- target/arm/kvm.c

[RFC v3 21/23] target/arm: move sve_exception_el out of TCG helpers

2021-03-03 Thread Claudio Fontana
we need this for KVM too. Signed-off-by: Claudio Fontana --- target/arm/cpu-sysemu.c | 60 target/arm/cpu-user.c | 5 target/arm/tcg/helper.c | 61 - 3 files changed, 65 insertions(+), 61 deletions(-) diff

[RFC v3 17/23] target/arm: move arm_sctlr away from tcg helpers

2021-03-03 Thread Claudio Fontana
this function is used for kvm too, add it to the cpu-common module. Signed-off-by: Claudio Fontana --- target/arm/cpu-common.c | 11 +++ target/arm/tcg/helper.c | 11 --- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/target/arm/cpu-common.c b/target/arm/cpu-com

[RFC v3 11/23] target/arm: kvm: add stubs for some helpers

2021-03-03 Thread Claudio Fontana
at least the armv7m one should go away with proper configuration changes (only enabling possible boards for KVM). Signed-off-by: Claudio Fontana --- target/arm/kvm/helper-stubs.c | 27 +++ target/arm/kvm/meson.build| 3 +++ target/arm/meson.build| 1 + 3 fil

[RFC v3 20/23] target/arm: split 32bit cpu models from cpu.c to cpu32.c

2021-03-03 Thread Claudio Fontana
just like we have cpu64.c for the 64bit cpu models, spawn a cpu32.c from cpu.c. cpu.c will continue to contain the common parts. Signed-off-by: Claudio Fontana --- target/arm/cpu-qom.h | 3 - target/arm/cpu.h | 4 +- target/arm/cpu32.h | 27 ++ target/arm/cpu.c | 608 +---

[RFC v3 23/23] target/arm: wrap call to aarch64_sve_change_el in tcg_enabled()

2021-03-03 Thread Claudio Fontana
After this patch it is possible to build only kvm: ./configure --disable-tcg --enable-kvm Signed-off-by: Claudio Fontana --- target/arm/cpu-sysemu.c | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/target/arm/cpu-sysemu.c b/target/arm/cpu-sysemu.c index 471f666ca

Re: [PATCH v3] target/s390x: Implement the MVPG condition-code-option bit

2021-03-03 Thread David Hildenbrand
On 03.03.21 12:36, Thomas Huth wrote: On 03/03/2021 07.25, Thomas Huth wrote: On 03/03/2021 03.44, Richard Henderson wrote: If the CCO bit is set, MVPG should not generate an exception but report page translation faults via a CC code. Create a new helper, access_prepare_nf, which can use probe

[RFC v3 18/23] target/arm: move arm_cpu_list to common_cpu

2021-03-03 Thread Claudio Fontana
Signed-off-by: Claudio Fontana Reviewed-by: Richard Henderson --- target/arm/cpu-common.c | 42 + target/arm/tcg/helper.c | 41 2 files changed, 42 insertions(+), 41 deletions(-) diff --git a/target/arm/cpu-common.

[RFC v3 15/23] target/arm: move arm_mmu_idx* to cpu-mmu

2021-03-03 Thread Claudio Fontana
Signed-off-by: Claudio Fontana --- target/arm/cpu-mmu.c| 95 + target/arm/tcg/helper.c | 95 - 2 files changed, 95 insertions(+), 95 deletions(-) diff --git a/target/arm/cpu-mmu.c b/target/arm/cpu-mmu.c index f46

[RFC v3 13/23] target/arm: add temporary stub for arm_rebuild_hflags

2021-03-03 Thread Claudio Fontana
this should go away once the configuration and hw/arm is clean Signed-off-by: Claudio Fontana --- target/arm/arm-powerctl.c | 8 +--- target/arm/kvm/helper-stubs.c | 6 ++ 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/target/arm/arm-powerctl.c b/target/arm/arm-power

Re: [PATCH v2 1/8] ui: Replace the word 'whitelist'

2021-03-03 Thread Alex Bennée
Philippe Mathieu-Daudé writes: > Follow the inclusive terminology from the "Conscious Language in your > Open Source Projects" guidelines [*] and replace the words "whitelist" > appropriately. > > [*] https://github.com/conscious-lang/conscious-lang-docs/blob/main/faq.md > > Reviewed-by: Gerd H

Re: [PATCH v2 3/8] scripts/tracetool: Replace the word 'whitelist'

2021-03-03 Thread Alex Bennée
Philippe Mathieu-Daudé writes: > Follow the inclusive terminology from the "Conscious Language in your > Open Source Projects" guidelines [*] and replace the words "whitelist" > appropriately. > > [*] https://github.com/conscious-lang/conscious-lang-docs/blob/main/faq.md > > Reviewed-by: Daniel

[RFC v3 19/23] target/arm: move aarch64_sync_32_to_64 (and vv) to cpu code

2021-03-03 Thread Claudio Fontana
and arm_phys_excp_target_el since it is tied up inside the same #ifdef block. aarch64_sync_32_to_64 and aarch64_sync_64_to_32 are mixed in with the TCG helpers, but they shouldn't, as they are needed for KVM too. kvm_arch_get_registers() { if (!is_a64(env)) { aarch64_sync_64_to_32(env

Re: [PATCH v2 5/8] seccomp: Replace the word 'blacklist'

2021-03-03 Thread Alex Bennée
Philippe Mathieu-Daudé writes: > Follow the inclusive terminology from the "Conscious Language in your > Open Source Projects" guidelines [*] and replace the word "blacklist" > appropriately. > > [*] https://github.com/conscious-lang/conscious-lang-docs/blob/main/faq.md > > Reviewed-by: Daniel

Re: [PATCH v2 4/8] scripts/device-crash-test: Replace the word 'whitelist'

2021-03-03 Thread Alex Bennée
Philippe Mathieu-Daudé writes: > Follow the inclusive terminology from the "Conscious Language in your > Open Source Projects" guidelines [*] and replace the word "whitelist" > appropriately. > > [*] https://github.com/conscious-lang/conscious-lang-docs/blob/main/faq.md > > Reviewed-by: Daniel

[RFC v3 22/23] target/arm: move TCG cpu and models inside tcg/

2021-03-03 Thread Claudio Fontana
to avoid confusion, move the TCG-only 32bit cpu models definitions inside tcg/tcg-cpu-models.c The 64bit cpu models (a53/a57/a72/max) remain in cpu64.c . Signed-off-by: Claudio Fontana --- target/arm/cpu.h | 1 - target/arm/internals.h| 5

  1   2   3   4   >