[PATCH v4 2/4] fdc: Drop deprecated floppy configuration

2021-03-10 Thread Markus Armbruster
Drop the crap deprecated in commit 4a27a638e7 "fdc: Deprecate configuring floppies with -global isa-fdc" (v5.1.0). Signed-off-by: Markus Armbruster Reviewed-by: Daniel P. Berrangé --- docs/system/deprecated.rst | 49 --- docs/system/removed-features.rst | 49 +++ hw/block/fdc.c

[PATCH v4 4/4] blockdev: Drop deprecated bogus -drive interface type

2021-03-10 Thread Markus Armbruster
Drop the crap deprecated in commit a1b40bda08 "blockdev: Deprecate -drive with bogus interface type" (v5.1.0). drive_check_orphaned() no longer depends on qemu_create_cli_devices(). Call it right after board initialization for clarity. Signed-off-by: Markus Armbruster ---

[PATCH v4 1/4] docs/system/deprecated: Fix note on fdc drive properties

2021-03-10 Thread Markus Armbruster
Commit 4a27a638e7 "fdc: Deprecate configuring floppies with -global isa-fdc" actually deprecated any use of floppy controller driver properties, not just with -global. Correct the deprecation note accordingly. Fixes: 4a27a638e718b445648de6b27c709353551d9b44 Signed-off-by: Markus Armbruster

[PATCH v4 3/4] fdc: Inline fdctrl_connect_drives() into fdctrl_realize_common()

2021-03-10 Thread Markus Armbruster
The previous commit rendered the name fdctrl_connect_drives() somewhat misleading. Get rid of it by inlining the (now pretty simple) function into its only caller. Signed-off-by: Markus Armbruster Reviewed-by: Daniel P. Berrangé --- hw/block/fdc.c | 23 --- 1 file changed,

[PATCH v4 0/4] Drop deprecated floppy config & bogus -drive if=T

2021-03-10 Thread Markus Armbruster
v4: * PATCH 3: Move a declaration into a loop [Richard] * PATCH 4: Drop a superfluous call to drive_check_orphaned() [Daniel], fix comments [John] v3: * PATCH 1: New [Daniel] v2: * Rebased, straightforward conflict with commit f5d33dd51f "hw/block/fdc: Remove the check_media_rate property"

Re: [PATCH v6 0/7] net/eth: Fix stack-buffer-overflow in _eth_get_rss_ex_dst_addr()

2021-03-10 Thread Miroslav Rezanina
- Original Message - > From: "Philippe Mathieu-Daudé" > To: qemu-devel@nongnu.org > Cc: "Jason Wang" , "Stefano Garzarella" > , "Thomas Huth" , > "Miroslav Rezanina" , "Dmitry Fleytman" > , "Paolo Bonzini" > , "Laurent Vivier" , "Philippe > Mathieu-Daudé" > Sent: Wednesday, March 10,

Re: [PATCH v3 00/30] qapi/qom: QAPIfy --object and object-add

2021-03-10 Thread Peter Krempa
On Wed, Mar 10, 2021 at 18:30:44 +0100, Kevin Wolf wrote: > Am 10.03.2021 um 15:31 hat Paolo Bonzini geschrieben: > > On 10/03/21 15:22, Peter Krempa wrote: [...] > The keyval parser would create a list if multiple values are given for > the same key. Some care needs to be taken to avoid mixing

Re: [PATCH 8/9] hw/9pfs/9p-synth: Replaced qemu_mutex_lock with QEMU_LOCK_GUARD

2021-03-10 Thread Greg Kurz
On Thu, 11 Mar 2021 05:15:37 +0200 Mahmoud Mandour wrote: > Replaced a call to qemu_mutex_lock and its respective call to > qemu_mutex_unlock and used QEMU_LOCK_GUARD macro in their place. > This simplifies the code by removing the call required to unlock > and also eliminates goto paths. > >

Re: [RFC PATCH v3 02/10] net: Pad short frames to minimum size before send from SLiRP/TAP

2021-03-10 Thread Bin Meng
On Thu, Mar 11, 2021 at 11:33 AM Jason Wang wrote: > > > On 2021/3/11 11:12 上午, Bin Meng wrote: > > On Thu, Mar 11, 2021 at 11:01 AM Jason Wang wrote: > >> > >> On 2021/3/9 6:13 下午, Peter Maydell wrote: > >>> On Tue, 9 Mar 2021 at 09:01, Bin Meng wrote: > Hi Jason, > > On Tue,

[PATCH] replay: don't wait in run_on_cpu

2021-03-10 Thread Pavel Dovgalyuk
In record/replay mode waiting for vCPU to execute the task scheduled by run_on_cpu may lead to deadlock, because when run_on_cpu is executed in main_loop (e.g., in loadvm processing) it holds replay mutex. This patch allows running scheduled task in iothread when it holds the replay mutex.

Re: [PATCH 3/3] Andes AE350 RISC-V Machine

2021-03-10 Thread Dylan Jhong
On Wed, Mar 10, 2021 at 02:15:25PM +0800, Bin Meng wrote: > On Wed, Mar 10, 2021 at 11:36 AM Dylan Jhong wrote: > > > > This provides a RISC-V Board based on Andes's AE350 specification. > > The following machine is implemented: > > > > - 'andes_ae350'; PLIC, PLICSW, PLMT, 16550a UART, VirtIO

Re: [PATCH 1/3] Andes RISC-V PLIC

2021-03-10 Thread Dylan Jhong
On Wed, Mar 10, 2021 at 02:05:51PM +0800, Bin Meng wrote: > On Wed, Mar 10, 2021 at 11:34 AM Dylan Jhong wrote: > > > > Andes PLIC (Platform-Level Interrupt Controller) device provides an > > interrupt controller functionality based on Andes's PLIC specification. > > > > The Andes PLIC can handle

[PATCH 3/3] hw/block/nvme: add administrative controller type

2021-03-10 Thread Klaus Jensen
From: Padmakar Kalghatgi Add the 'administrative' nvme device parameter. This causes the controller to behave as an Administrative Controller. See NVM Express v1.4b, Section 7.1.2 ("Administrative Controller"). Signed-off-by: Padmakar Kalghatgi Signed-off-by: Gollu Appalanaidu Signed-off-by:

[PATCH 1/3] hw/block/nvme: add oncs device parameter

2021-03-10 Thread Klaus Jensen
From: Gollu Appalanaidu Add the 'oncs' nvme device parameter to allow optional features to be enabled/disabled explicitly. Since most of these are optional commands, make the CSE log pages dynamic to account for the value of ONCS. Signed-off-by: Gollu Appalanaidu Signed-off-by: Klaus Jensen

[PATCH 2/3] hw/block/nvme: add oacs device parameter

2021-03-10 Thread Klaus Jensen
From: Gollu Appalanaidu Add the 'oacs' nvme device parameter to allow optional features to be enabled/disabled explicitly. Since most of these are optional commands, make the CSE log pages dynamic to account for the value of OACS once the optional commands supported added to device.

[PATCH 0/3] hw/block/nvme: add administrative controller support

2021-03-10 Thread Klaus Jensen
From: Klaus Jensen This series allows the controller to behave as an Administrative Controller. This is useful when emulating a subsystem. Since some commands are prohibited for an Administrative Controller, this series includes patches that make the CSE log page dynamic and allows supported

Re: [PATCH v3 4/4] blockdev: Drop deprecated bogus -drive interface type

2021-03-10 Thread Markus Armbruster
John Snow writes: > On 3/9/21 11:12 AM, Markus Armbruster wrote: >> Drop the crap deprecated in commit a1b40bda08 "blockdev: Deprecate >> -drive with bogus interface type" (v5.1.0). >> >> Signed-off-by: Markus Armbruster >> --- >> docs/system/deprecated.rst | 7 -- >>

Re: [PATCH 1/2] hw: Model ASPEED's Hash and Crypto Engine

2021-03-10 Thread Joel Stanley
On Tue, 9 Mar 2021 at 01:02, Andrew Jeffery wrote: > > > > On Wed, 3 Mar 2021, at 17:33, Joel Stanley wrote: > > The HACE (Hash and Crpyto Engine) is a device that offloads MD5, SHA1, > > SHA2, RSA and other cryptographic algorithms. > > > > This initial model implements a subset of the device's

[PATCH 3/3] fuzz: configure a sparse-mem device, by default

2021-03-10 Thread Alexander Bulekov
The generic-fuzzer often provides randomized DMA addresses to virtual-devices. For a 64-bit address-space, the chance of these randomized addresses coinciding with RAM regions, is fairly small. Even though the fuzzer's instrumentation eventually finds valid addresses, this can take some-time, and

[PATCH 1/3] memory: add a sparse memory device

2021-03-10 Thread Alexander Bulekov
For testing, it can be useful to simulate an enormous amount of memory (e.g. 2^64 RAM). This adds an MMIO device that acts as sparse memory. When something writes a nonzero value to a sparse-mem address, we allocate a block of memory. This block is kept around, until all of the bytes within the

[PATCH 2/3] memory: add tests for the sparse-mem device

2021-03-10 Thread Alexander Bulekov
Signed-off-by: Alexander Bulekov --- MAINTAINERS | 1 + tests/qtest/meson.build | 3 +- tests/qtest/sparse-mem-test.c | 88 +++ 3 files changed, 91 insertions(+), 1 deletion(-) create mode 100644 tests/qtest/sparse-mem-test.c diff --git

[PATCH 0/3] fuzz: Add a sparse-memory device to accelerate fuzzing

2021-03-10 Thread Alexander Bulekov
Hello, The generic-fuzzer often provides virtual-devices with bogus DMA addresses (e.g. 0x4141414141414141). The probability that these fuzzed addresses actually land within RAM is quite small. The fuzzer eventually finds valid addresses, however, this takes some time, and this problem is

Re: [PATCH v3 4/4] blockdev: Drop deprecated bogus -drive interface type

2021-03-10 Thread John Snow
On 3/9/21 11:12 AM, Markus Armbruster wrote: Drop the crap deprecated in commit a1b40bda08 "blockdev: Deprecate -drive with bogus interface type" (v5.1.0). Signed-off-by: Markus Armbruster --- docs/system/deprecated.rst | 7 -- docs/system/removed-features.rst | 7 ++

Re: [RFC PATCH v3 02/10] net: Pad short frames to minimum size before send from SLiRP/TAP

2021-03-10 Thread Jason Wang
On 2021/3/11 11:12 上午, Bin Meng wrote: On Thu, Mar 11, 2021 at 11:01 AM Jason Wang wrote: On 2021/3/9 6:13 下午, Peter Maydell wrote: On Tue, 9 Mar 2021 at 09:01, Bin Meng wrote: Hi Jason, On Tue, Mar 9, 2021 at 5:00 PM Bin Meng wrote: Hi Jason, On Tue, Mar 9, 2021 at 4:57 PM Jason

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

2021-03-10 Thread 王洪浩
Will do, thanks! Stefan Hajnoczi 于2021年3月8日周一 下午6:27写道: > > On Fri, Oct 16, 2020 at 07:26:40PM +0800, wanghonghao wrote: > > This patch replace the global coroutine queue with a lock-free stack of > > which > > the elements are coroutine queues. Threads can put coroutine queues into the > >

Re: [PULL 00/20] ppc-for-6.0 queue 20210310

2021-03-10 Thread Ivan Warren
On 3/11/2021 2:47 AM, David Gibson wrote: Sorry, I've forgotten this issue. If you had a patch, can you resend it please. Not mine.. (I reported it, but can't remember who sent it)... diff --git a/target/ppc/cpu.h b/target/ppc/cpu.h index 2609e4082e..4a05e4e544 100644 ---

Re: [RFC PATCH v3 02/10] net: Pad short frames to minimum size before send from SLiRP/TAP

2021-03-10 Thread Bin Meng
On Thu, Mar 11, 2021 at 11:01 AM Jason Wang wrote: > > > On 2021/3/9 6:13 下午, Peter Maydell wrote: > > On Tue, 9 Mar 2021 at 09:01, Bin Meng wrote: > >> Hi Jason, > >> > >> On Tue, Mar 9, 2021 at 5:00 PM Bin Meng wrote: > >>> Hi Jason, > >>> > >>> On Tue, Mar 9, 2021 at 4:57 PM Jason Wang

Re: [PATCH v2 10/12] hw/block/pflash_cfi01: Extract pflash_mode_read_array()

2021-03-10 Thread Bin Meng
On Thu, Mar 11, 2021 at 1:37 AM Philippe Mathieu-Daudé wrote: > > The same pattern is used when setting the flash in READ_ARRAY mode: > - Set the state machine command to READ_ARRAY > - Reset the write_cycle counter > - Reset the memory region in ROMD > > Refactor the current code by extracting

Re: [PATCH v2 12/12] hw/block/pflash_cfi: Replace DPRINTF with trace events

2021-03-10 Thread Bin Meng
On Thu, Mar 11, 2021 at 1:43 AM Philippe Mathieu-Daudé wrote: > > From: David Edmondson > > Rather than having a device specific debug implementation in > pflash_cfi01.c and pflash_cfi02.c, use the standard tracing facility. > > Signed-off-by: David Edmondson > Reviewed-by: Philippe

Re: [PATCH v2 08/12] hw/block/pflash_cfi02: Add DeviceReset method

2021-03-10 Thread Bin Meng
On Thu, Mar 11, 2021 at 1:22 AM Philippe Mathieu-Daudé wrote: > > Signed-off-by: Philippe Mathieu-Daudé > --- > hw/block/pflash_cfi02.c | 8 > 1 file changed, 8 insertions(+) > Reviewed-by: Bin Meng

Re: [PATCH v2 11/12] hw/block/pflash_cfi01: Correct the type of PFlashCFI01.ro

2021-03-10 Thread Bin Meng
On Thu, Mar 11, 2021 at 1:28 AM Philippe Mathieu-Daudé wrote: > > From: David Edmondson > > PFlashCFI01.ro is a bool, declare it as such. > > Signed-off-by: David Edmondson > Reviewed-by: Philippe Mathieu-Daudé > Message-Id: <20210216142721.1985543-3-david.edmond...@oracle.com> >

Re: [PATCH v2 07/12] hw/block/pflash_cfi02: Factor out pflash_reset_state_machine()

2021-03-10 Thread Bin Meng
On Thu, Mar 11, 2021 at 1:36 AM Philippe Mathieu-Daudé wrote: > > There is multiple places resetting the internal state machine. > Factor the code out in a new pflash_reset_state_machine() method. > > Signed-off-by: Philippe Mathieu-Daudé > --- > hw/block/pflash_cfi02.c | 20

Re: [RFC PATCH v3 02/10] net: Pad short frames to minimum size before send from SLiRP/TAP

2021-03-10 Thread Jason Wang
On 2021/3/9 6:13 下午, Peter Maydell wrote: On Tue, 9 Mar 2021 at 09:01, Bin Meng wrote: Hi Jason, On Tue, Mar 9, 2021 at 5:00 PM Bin Meng wrote: Hi Jason, On Tue, Mar 9, 2021 at 4:57 PM Jason Wang wrote: On 2021/3/9 4:35 下午, Bin Meng wrote: Hi Jason, On Tue, Mar 9, 2021 at 4:23 PM

Question about edge-triggered interrupt

2021-03-10 Thread LIU Zhiwei
Hi folks, Currently, I am writing an interrupt controller (CLIC) for RISC-V. I can't find a good way to process edge-triggered interrupt. According to edge-triggered definition, if I select an edge-triggered  interrupt to serve , it will clean its pending status. However after serving the

Re: [PATCH v4 00/78] target/arm: Implement SVE2

2021-03-10 Thread Richard Henderson
On 3/10/21 2:17 PM, Peter Maydell wrote: On Tue, 9 Mar 2021 at 16:20, Richard Henderson wrote: After a 6-month hiatus, sve2 is back. This time, with RISU testing vs FVP 11.13.36. Based-on: 20210309155305.11301-1-richard.hender...@linaro.org ("target/arm: sve1 fixes") Are you hoping to

Re: [PULL 00/20] ppc-for-6.0 queue 20210310

2021-03-10 Thread David Gibson
20210307' > > into staging (2021-03-09 13:50:35 +) > > > > are available in the Git repository at: > > > >https://gitlab.com/dgibson/qemu.git tags/ppc-for-6.0-20210310 > > > > for you to fetch changes up to eb7f80fd26d73e7e1af105431da58971b1dba517:

Re: [RFC PATCH 18/21] contrib/gitdm: Add Wind River to the domain map

2021-03-10 Thread Bin Meng
Hi Philippe, On Thu, Oct 8, 2020 at 7:13 PM Bin Meng wrote: > > Hi Philippe, > > On Mon, Oct 5, 2020 at 2:05 AM Philippe Mathieu-Daudé wrote: > > > > There is a number of contributors from this domain, > > add its own entry to the gitdm domain map. > > > > Cc: Bill Paul > > Cc: Bin Meng > >

Re: [PULL 00/20] ppc-for-6.0 queue 20210310

2021-03-10 Thread Bin Meng
> > > b2ae1009d7cca2701e17eae55ae2d44fd22c942a: > > > > > > Merge remote-tracking branch > > > 'remotes/mcayland/tags/qemu-sparc-20210307' into staging (2021-03-09 > > > 13:50:35 +) > > > > > > are available in the Git repository at: &

Re: [PATCH] vfio: Support host translation granule size

2021-03-10 Thread Keqian Zhu
Hi Alex, On 2021/3/11 4:24, Alex Williamson wrote: > On Wed, 10 Mar 2021 15:19:33 +0800 > Kunkun Jiang wrote: > >> Hi Alex, >> >> On 2021/3/10 7:17, Alex Williamson wrote: >>> On Thu, 4 Mar 2021 21:34:46 +0800 >>> Kunkun Jiang wrote: >>> The cpu_physical_memory_set_dirty_lebitmap() can

Re: [PATCH 00/26] tcg: Workaround macOS 11.2 mprotect bug

2021-03-10 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20210311002156.253711-1-richard.hender...@linaro.org/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20210311002156.253711-1-richard.hender...@linaro.org Subject: [PATCH 00/26]

Re: [PATCH 1/2] hw/mips/jazz: Use generic I/O bus via get_system_io()

2021-03-10 Thread Jiaxun Yang
On Thu, Mar 11, 2021, at 3:12 AM, Philippe Mathieu-Daudé wrote: > No need to create a local ISA I/O MemoryRegion, use get_system_io(). > > This partly reverts commit 5c63bcf7501527b844f61624957bdba254d75bfc. > > Signed-off-by: Philippe Mathieu-Daudé No luck to boot arcboot with current jazz

Re: [PATCH 16/26] tcg: Move MAX_CODE_GEN_BUFFER_SIZE to tcg-target.h

2021-03-10 Thread BALATON Zoltan
On Wed, 10 Mar 2021, Richard Henderson wrote: Remove the ifdef ladder and move each define into the appropriate header file. Signed-off-by: Richard Henderson --- tcg/aarch64/tcg-target.h | 1 + tcg/arm/tcg-target.h | 1 + tcg/i386/tcg-target.h| 2 ++ tcg/mips/tcg-target.h| 6

[PATCH 24/26] util/osdep: Add qemu_mprotect_rw

2021-03-10 Thread Richard Henderson
For --enable-tcg-interpreter on Windows, we will need this. Signed-off-by: Richard Henderson --- include/qemu/osdep.h | 1 + util/osdep.c | 9 + 2 files changed, 10 insertions(+) diff --git a/include/qemu/osdep.h b/include/qemu/osdep.h index ba15be9c56..5cc2e57bdf 100644 ---

[RFC] tests/migration: introduce multifd into guestperf toolkit

2021-03-10 Thread huangy81
From: Hyman Current guestperf tool does not support multifd migration, introducing it is good idea so that we can compare the performence of all type of migration. Signed-off-by: Hyman --- tests/migration/guestperf/comparison.py | 14 ++ tests/migration/guestperf/engine.py |

[PATCH 25/26] tcg: Merge buffer protection and guard page protection

2021-03-10 Thread Richard Henderson
Do not handle protections on a case-by-case basis in the various alloc_code_gen_buffer instances; do it within a single loop in tcg_region_init. Signed-off-by: Richard Henderson --- tcg/region.c | 40 +--- 1 file changed, 29 insertions(+), 11 deletions(-)

[PATCH 21/26] tcg: Return the map protection from alloc_code_gen_buffer

2021-03-10 Thread Richard Henderson
Change the interface from a boolean error indication to a negative error vs a non-negative protection. For the moment this is only interface change, not making use of the new data. Signed-off-by: Richard Henderson --- tcg/region.c | 63 +++- 1

[PATCH 26/26] tcg: When allocating for !splitwx, begin with PROT_NONE

2021-03-10 Thread Richard Henderson
There's a change in mprotect() behaviour [1] in the latest macOS on M1 and it's not yet clear if it's going to be fixed by Apple. In this case, instead of changing permissions of N guard pages, we change permissions of N rwx regions. The same number of syscalls are required either way. [1]

[PATCH 15/26] tcg: Introduce tcg_max_ctxs

2021-03-10 Thread Richard Henderson
Finish the divorce of tcg/ from hw/, and do not take the max cpu value from MachineState; just rememver what we were passed in tcg_init. Signed-off-by: Richard Henderson --- tcg/internal.h | 3 ++- tcg/region.c | 6 +++--- tcg/tcg.c | 23 ++- 3 files changed, 15

[PATCH 19/26] tcg: Tidy split_cross_256mb

2021-03-10 Thread Richard Henderson
Return output buffer and size via output pointer arguments, rather than returning size via tcg_ctx->code_gen_buffer_size. Signed-off-by: Richard Henderson --- tcg/region.c | 15 +++ 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/tcg/region.c b/tcg/region.c index

[PATCH 23/26] tcg: Do not set guard pages in the rx buffer

2021-03-10 Thread Richard Henderson
We only need guard pages in the rw buffer to avoid buffer overruns. Let the rx buffer keep large pages all the way through. Signed-off-by: Richard Henderson --- tcg/region.c | 8 +--- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/tcg/region.c b/tcg/region.c index

[PATCH 16/26] tcg: Move MAX_CODE_GEN_BUFFER_SIZE to tcg-target.h

2021-03-10 Thread Richard Henderson
Remove the ifdef ladder and move each define into the appropriate header file. Signed-off-by: Richard Henderson --- tcg/aarch64/tcg-target.h | 1 + tcg/arm/tcg-target.h | 1 + tcg/i386/tcg-target.h| 2 ++ tcg/mips/tcg-target.h| 6 ++ tcg/ppc/tcg-target.h | 2 ++

[PATCH 12/26] tcg: Create tcg_init

2021-03-10 Thread Richard Henderson
Perform both tcg_context_init and tcg_region_init. Do not leave this split to the caller. Signed-off-by: Richard Henderson --- include/tcg/tcg.h | 3 +-- tcg/internal.h| 1 + accel/tcg/translate-all.c | 3 +-- tcg/tcg.c | 9 - 4 files changed, 11

[PATCH 22/26] tcg: Sink qemu_madvise call to common code

2021-03-10 Thread Richard Henderson
Move the call out of the N versions of alloc_code_gen_buffer and into tcg_region_init. Signed-off-by: Richard Henderson --- tcg/region.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/tcg/region.c b/tcg/region.c index f25ec1ecad..7640aac243 100644 ---

[PATCH 17/26] tcg: Replace region.end with region.total_size

2021-03-10 Thread Richard Henderson
A size is easier to work with than an end point, particularly during initial buffer allocation. Signed-off-by: Richard Henderson --- tcg/region.c | 29 + 1 file changed, 17 insertions(+), 12 deletions(-) diff --git a/tcg/region.c b/tcg/region.c index

[PATCH 11/26] accel/tcg: Rename tcg_init to tcg_init_machine

2021-03-10 Thread Richard Henderson
We shortly want to use tcg_init for something else. Since the hook is called init_machine, match that. Signed-off-by: Richard Henderson --- accel/tcg/tcg-all.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/accel/tcg/tcg-all.c b/accel/tcg/tcg-all.c index

[PATCH 20/26] tcg: Allocate code_gen_buffer into struct tcg_region_state

2021-03-10 Thread Richard Henderson
Do not mess around with setting values within tcg_init_ctx. Put the values into 'region' directly, which is where they will live for the lifetime of the program. Signed-off-by: Richard Henderson --- tcg/region.c | 61 ++-- 1 file changed, 26

[PATCH 18/26] tcg: Tidy tcg_n_regions

2021-03-10 Thread Richard Henderson
Compute the value using straight division and bounds, rather than a loop. Pass in tb_size rather than reading from tcg_init_ctx.code_gen_buffer_size, Signed-off-by: Richard Henderson --- tcg/region.c | 29 - 1 file changed, 12 insertions(+), 17 deletions(-) diff

[PATCH 06/26] tcg: Split out tcg_region_initial_alloc

2021-03-10 Thread Richard Henderson
This has only one user, and currently needs an ifdef, but will make more sense after some code motion. Signed-off-by: Richard Henderson --- tcg/tcg.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/tcg/tcg.c b/tcg/tcg.c index 2b631fccdf..3316a22bde 100644 ---

[PATCH 14/26] accel/tcg: Pass down max_cpus to tcg_init

2021-03-10 Thread Richard Henderson
Start removing the include of hw/boards.h from tcg/. Pass down the max_cpus value from tcg_init_machine, where we have the MachineState already. Signed-off-by: Richard Henderson --- include/tcg/tcg.h | 2 +- tcg/internal.h | 2 +- accel/tcg/tcg-all.c | 10 +- tcg/region.c

[PATCH 13/26] accel/tcg: Merge tcg_exec_init into tcg_init_machine

2021-03-10 Thread Richard Henderson
There is only one caller, and shortly we will need access to the MachineState, which tcg_init_machine already has. Signed-off-by: Richard Henderson --- accel/tcg/internal.h | 2 ++ include/sysemu/tcg.h | 2 -- accel/tcg/tcg-all.c | 14 +- accel/tcg/translate-all.c

[PATCH 07/26] tcg: Split out tcg_region_prologue_set

2021-03-10 Thread Richard Henderson
This has only one user, but will make more sense after some code motion. Always leave the tcg_init_ctx initialized to the first region, in preparation for tcg_prologue_init(). This also requires that we don't re-allocate the region for the first cpu, lest we hit the assertion for total number of

[PATCH 10/26] accel/tcg: Move alloc_code_gen_buffer to tcg/region.c

2021-03-10 Thread Richard Henderson
Buffer management is integral to tcg. Do not leave the allocation to code outside of tcg/. This is code movement, with further cleanups to follow. Signed-off-by: Richard Henderson --- include/tcg/tcg.h | 2 +- accel/tcg/translate-all.c | 414 +

[PATCH 08/26] tcg: Split out region.c

2021-03-10 Thread Richard Henderson
Signed-off-by: Richard Henderson --- tcg/internal.h | 37 tcg/region.c| 570 tcg/tcg.c | 545 + tcg/meson.build | 1 + 4 files changed, 611 insertions(+), 542 deletions(-) create mode

[PATCH 02/26] meson: Move disas/tci.c to disas/meson.build

2021-03-10 Thread Richard Henderson
There's no reason to do this in the main meson.build. Signed-off-by: Richard Henderson --- meson.build | 1 - disas/meson.build | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build index 8bc472ddeb..f884a62682 100644 --- a/meson.build +++

[PATCH 01/26] meson: Split out tcg/meson.build

2021-03-10 Thread Richard Henderson
Signed-off-by: Richard Henderson --- meson.build | 9 ++--- tcg/meson.build | 13 + 2 files changed, 15 insertions(+), 7 deletions(-) create mode 100644 tcg/meson.build diff --git a/meson.build b/meson.build index adeec153d9..8bc472ddeb 100644 --- a/meson.build +++

[PATCH 09/26] accel/tcg: Inline cpu_gen_init

2021-03-10 Thread Richard Henderson
It consists of one function call and has only one caller. Signed-off-by: Richard Henderson --- accel/tcg/translate-all.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/accel/tcg/translate-all.c b/accel/tcg/translate-all.c index b9057567f4..6d3184e7da 100644 ---

[PATCH 05/26] tcg: Remove error return from tcg_region_initial_alloc__locked

2021-03-10 Thread Richard Henderson
All callers immediately assert on error, so move the assert into the function itself. Signed-off-by: Richard Henderson --- tcg/tcg.c | 19 ++- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/tcg/tcg.c b/tcg/tcg.c index 0a2e5710de..2b631fccdf 100644 --- a/tcg/tcg.c

[PATCH 00/26] tcg: Workaround macOS 11.2 mprotect bug

2021-03-10 Thread Richard Henderson
Supercedes: 20210210105527.74943-1-r.bolsha...@yadro.com ("util/osdep: Avoid mprotect() RWX->NONE on Big Sur 11.2") It took a few more patches than imagined to unify the two places in which we manipulate the tcg code_gen buffer, but the result is surely cleaner. There's a lot more that could be

[PATCH 03/26] meson: Split out fpu/meson.build

2021-03-10 Thread Richard Henderson
Signed-off-by: Richard Henderson --- meson.build | 4 +--- fpu/meson.build | 1 + 2 files changed, 2 insertions(+), 3 deletions(-) create mode 100644 fpu/meson.build diff --git a/meson.build b/meson.build index f884a62682..c8a5ca65e5 100644 --- a/meson.build +++ b/meson.build @@ -1934,9

[PATCH 04/26] tcg: Re-order tcg_region_init vs tcg_prologue_init

2021-03-10 Thread Richard Henderson
Instead of delaying tcg_region_init until after tcg_prologue_init is complete, do tcg_region_init first and let tcg_prologue_init shrink the first region by the size of the generated prologue. Signed-off-by: Richard Henderson --- accel/tcg/tcg-all.c | 11 -

Re: [PATCH 6/7] mac_via: fix 60Hz VIA1 timer interval

2021-03-10 Thread BALATON Zoltan
On Wed, 10 Mar 2021, Mark Cave-Ayland wrote: On 10/03/2021 13:24, Laurent Vivier wrote: Le 10/03/2021 à 14:10, Laurent Vivier a écrit : Le 10/03/2021 à 13:56, Laurent Vivier a écrit : Le 10/03/2021 à 13:32, BALATON Zoltan a écrit : On Wed, 10 Mar 2021, Mark Cave-Ayland wrote: The 60Hz timer

Re: [PULL 00/20] ppc-for-6.0 queue 20210310

2021-03-10 Thread David Gibson
es/mcayland/tags/qemu-sparc-20210307' > > into staging (2021-03-09 13:50:35 +) > > > > are available in the Git repository at: > > > > https://gitlab.com/dgibson/qemu.git tags/ppc-for-6.0-20210310 > > > > for you to fetch changes up to eb7f80fd26

Re: [PATCH 6/7] mac_via: fix 60Hz VIA1 timer interval

2021-03-10 Thread Mark Cave-Ayland
On 10/03/2021 13:24, Laurent Vivier wrote: Le 10/03/2021 à 14:10, Laurent Vivier a écrit : Le 10/03/2021 à 13:56, Laurent Vivier a écrit : Le 10/03/2021 à 13:32, BALATON Zoltan a écrit : On Wed, 10 Mar 2021, Mark Cave-Ayland wrote: The 60Hz timer is initialised using timer_new_ns() meaning

Re: [PATCH 2/3] memory: Provide 'base address' argument to mtree_print_mr()

2021-03-10 Thread Mark Cave-Ayland
On 09/03/2021 21:54, Philippe Mathieu-Daudé wrote: +Peter/Mark/Edgar for SoC modelling On 3/9/21 10:39 AM, Philippe Mathieu-Daudé wrote: Hi Peter, On 3/9/21 12:40 AM, Peter Xu wrote:> On Sat, Mar 06, 2021 at 12:54:13AM +0100, Philippe Mathieu-Daudé wrote: @@ -3188,14 +3188,15 @@ void

[PATCH] hw/riscv: Fix OT IBEX reset vector

2021-03-10 Thread Alexander Wagner
The IBEX documentation [1] specifies the reset vector to be "the most significant 3 bytes of the boot address and the reset value (0x80) as the least significant byte". [1] https://github.com/lowRISC/ibex/blob/master/doc/03_reference/exception_interrupts.rst Signed-off-by: Alexander Wagner ---

Re: [PATCH v3 1/3] target/arm: Add support for FEAT_TLBIRANGE

2021-03-10 Thread Rebecca Cran
On 3/10/21 12:24 PM, Richard Henderson wrote: On 3/9/21 6:29 PM, Rebecca Cran wrote: +void tlb_flush_page_range_by_mmuidx(CPUState *cpu, target_ulong addr, +    unsigned int num_pages, uint16_t idxmap) I am not keen on this interface.  I think you should take

Re: [PULL 00/22] Trivial branch for 6.0 patches

2021-03-10 Thread Laurent Vivier
---- > Pull request trivial patches 20210310 > > > > Alexander Bulekov (1): > fuzz-test: remove unneccessary debugging flags > > Eric Blake (1): > scsi: Silence gcc warning &g

[PULL 13/22] scripts/tracetool: Replace the word 'whitelist'

2021-03-10 Thread Laurent Vivier
From: Philippe Mathieu-Daudé 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 P. Berrangé

[PULL 16/22] tests/fp/fp-test: Replace the word 'blacklist'

2021-03-10 Thread Laurent Vivier
From: Philippe Mathieu-Daudé 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 Acked-by: Alex Bennée Reviewed-by:

[PULL 19/22] hw/lm32/Kconfig: Rename CONFIG_LM32 -> CONFIG_LM32_DEVICES

2021-03-10 Thread Laurent Vivier
From: Philippe Mathieu-Daudé We want to be able to use the 'LM32' config for architecture specific features. As CONFIG_LM32 is only used to select peripherals, rename it CONFIG_LM32_DEVICES. Reviewed-by: Alex Bennée Signed-off-by: Philippe Mathieu-Daudé Message-Id:

[PULL 17/22] qemu-common.h: Update copyright string to 2021

2021-03-10 Thread Laurent Vivier
From: Peter Maydell Update the common copyright string that we use in -version reports, About dialogs, etc, to 2021. Signed-off-by: Peter Maydell Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Laurent Vivier Message-Id: <20210309162258.28633-1-peter.mayd...@linaro.org> Signed-off-by:

[PULL 18/22] hw/lm32/Kconfig: Introduce CONFIG_LM32_EVR for lm32-evr/uclinux boards

2021-03-10 Thread Laurent Vivier
From: Philippe Mathieu-Daudé We want to be able to use the 'LM32' config for architecture specific features. Introduce CONFIG_LM32_EVR to select the lm32-evr / lm32-uclinux boards. Reviewed-by: Alex Bennée Signed-off-by: Philippe Mathieu-Daudé Message-Id:

[PULL 04/22] target/hexagon/gen_tcg_funcs: Fix a typo

2021-03-10 Thread Laurent Vivier
From: Philippe Mathieu-Daudé Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Taylor Simpson Message-Id: <20210225181507.3624509-1-f4...@amsat.org> Signed-off-by: Laurent Vivier --- target/hexagon/gen_tcg_funcs.py | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff

[PULL 12/22] ui: Replace the word 'whitelist'

2021-03-10 Thread Laurent Vivier
From: Philippe Mathieu-Daudé 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 Hoffmann

[PULL 11/22] virtio-gpu: Adjust code space style

2021-03-10 Thread Laurent Vivier
From: lijiejun Fix code style. Operator needs align with eight spaces, and delete line space. Signed-off-by: lijiejun Reviewed-by: Philippe Mathieu-Daudé Message-Id: <1615292050-108748-1-git-send-email-a_lijie...@163.com> Signed-off-by: Laurent Vivier --- hw/display/virtio-gpu-3d.c | 3 +--

[PULL 15/22] qemu-options: Replace the word 'blacklist'

2021-03-10 Thread Laurent Vivier
From: Philippe Mathieu-Daudé 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 P. Berrangé

[PULL 09/22] fuzz-test: remove unneccessary debugging flags

2021-03-10 Thread Laurent Vivier
From: Alexander Bulekov These flags cause the output to look strange for 'make check', and they aren't needed to reproduce bugs, if they reappear. Suggested-by: Peter Maydell Signed-off-by: Alexander Bulekov Reviewed-by: Thomas Huth Reviewed-by: Philippe Mathieu-Daudé Message-Id:

[PULL 14/22] seccomp: Replace the word 'blacklist'

2021-03-10 Thread Laurent Vivier
From: Philippe Mathieu-Daudé 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 P. Berrangé

[PULL 07/22] MAINTAINERS: Fix the location of tools manuals

2021-03-10 Thread Laurent Vivier
From: Wainer dos Santos Moschetta The qemu-img.rst, qemu-nbd.rst, virtfs-proxy-helper.rst, qemu-trace-stap.rst, and virtiofsd.rst manuals were moved to docs/tools, so this update MAINTAINERS accordingly. Fixes: a08b4a9fe6c ("docs: Move tools documentation to tools manual") Signed-off-by: Wainer

[PULL 10/22] exec/memory: Use struct Object typedef

2021-03-10 Thread Laurent Vivier
From: Philippe Mathieu-Daudé We forward-declare Object typedef in "qemu/typedefs.h" since commit ca27b5eb7cd ("qom/object: Move Object typedef to 'qemu/typedefs.h'"). Use it everywhere to make the code simpler. Signed-off-by: Philippe Mathieu-Daudé Acked-by: David Gibson Reviewed-by: Laurent

[PULL 08/22] net: Use id_generate() in the network subsystem, too

2021-03-10 Thread Laurent Vivier
From: Thomas Huth We already got a global function called id_generate() to create unique IDs within QEMU. Let's use it in the network subsytem, too, instead of inventing our own ID scheme here. Signed-off-by: Thomas Huth Reviewed-by: Marc-André Lureau Message-Id:

[PULL 03/22] hw/elf_ops: Fix a typo

2021-03-10 Thread Laurent Vivier
From: Philippe Mathieu-Daudé g_mapped_file_new_from_fd()'s parameter is named 'writable'. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Stefano Garzarella Reviewed-by: David Edmondson Message-Id: <20210225181344.3623720-1-phi...@redhat.com> Signed-off-by: Laurent Vivier ---

[PULL 01/22] Various spelling fixes

2021-03-10 Thread Laurent Vivier
From: Michael Tokarev An assorted set of spelling fixes in various places. Signed-off-by: Michael Tokarev Reviewed-by: Stefan Weil Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Peter Maydell Message-Id: <20210309111510.79495-1-...@msgid.tls.msk.ru> Signed-off-by: Laurent Vivier ---

[PULL 05/22] backends/dbus-vmstate: Fix short read error handling

2021-03-10 Thread Laurent Vivier
From: Markus Armbruster When dbus_vmstate_post_load() fails, it complains to stderr. Except on short read, where it checks with g_return_val_if_fail(). This fails silently if G_DISABLE_CHECKS is undefined (it should be), or else pads the short read with uninitialized bytes. Replace

[PULL 06/22] vhost_user_gpu: Drop dead check for g_malloc() failure

2021-03-10 Thread Laurent Vivier
From: Markus Armbruster Signed-off-by: Markus Armbruster Reviewed-by: Marc-André Lureau Reviewed-by: Michael S. Tsirkin Message-Id: <20210126124240.2081959-3-arm...@redhat.com> Signed-off-by: Laurent Vivier --- hw/display/vhost-user-gpu.c | 1 - 1 file changed, 1 deletion(-) diff --git

[PULL 00/22] Trivial branch for 6.0 patches

2021-03-10 Thread Laurent Vivier
-for-6.0-pull-request for you to fetch changes up to 538f049704e9b7a07eeaf326af772fdd30d89576: sysemu: Let VMChangeStateHandler take boolean 'running' argument (2021-03-0= 9 23:13:57 +0100) Pull request trivial patches 20210310

[PULL 02/22] scsi: Silence gcc warning

2021-03-10 Thread Laurent Vivier
From: Eric Blake On Fedora 33, gcc 10.2.1 notes that scsi_cdb_length(buf) can set len==-1, which in turn overflows g_malloc(): [5/5] Linking target qemu-system-x86_64 In function ‘scsi_disk_new_request_dump’, inlined from ‘scsi_new_request’ at ../hw/scsi/scsi-disk.c:2608:9:

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

2021-03-10 Thread David Hildenbrand
> Am 09.03.2021 um 22:05 schrieb Thomas Huth : > > On 04/03/2021 09.10, David Hildenbrand wrote: >>> On 03.03.21 22:36, Richard Henderson wrote: >>> On 3/3/21 1:22 PM, David Hildenbrand wrote: > Am 03.03.2021 um 22:19 schrieb Richard Henderson > : > > On 3/3/21 1:11

[PATCH v5 09/10] KVM: Disable manual dirty log when dirty ring enabled

2021-03-10 Thread Peter Xu
KVM_CAP_MANUAL_DIRTY_LOG_PROTECT2 is for KVM_CLEAR_DIRTY_LOG, which is only useful for KVM_GET_DIRTY_LOG. Skip enabling it for kvm dirty ring. More importantly, KVM_DIRTY_LOG_INITIALLY_SET will not wr-protect all the pages initially, which is against how kvm dirty ring is used - there's no way

[PATCH v5 07/10] KVM: Cache kvm slot dirty bitmap size

2021-03-10 Thread Peter Xu
Cache it too because we'll reference it more frequently in the future. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Peter Xu --- accel/kvm/kvm-all.c | 1 + include/sysemu/kvm_int.h | 1 + 2 files changed, 2 insertions(+) diff --git a/accel/kvm/kvm-all.c b/accel/kvm/kvm-all.c index

  1   2   3   4   5   >