Re: [PATCH v4 04/46] qapi: modify docstrings to be sphinx-compatible

2020-10-02 Thread John Snow
On 10/2/20 5:19 AM, Markus Armbruster wrote: John Snow writes: On 10/1/20 4:52 AM, Markus Armbruster wrote: John Snow writes: On 9/30/20 4:47 AM, Markus Armbruster wrote: John Snow writes: I did not say "sphinx beautiful", just "sphinx compatible". They will not throw errors when parse

[PULL 34/37] iotests: Allow supported and unsupported formats at the same time

2020-10-02 Thread Kevin Wolf
This is useful for specifying 'generic' as supported (which includes only writable image formats), but still excluding some incompatible writable formats. It also removes more lines than it adds. Signed-off-by: Kevin Wolf Message-Id: <20200924152717.287415-31-kw...@redhat.com> Acked-by: Stefan H

Re: [PULL 00/19] s390x changes

2020-10-02 Thread Peter Maydell
ilable in the Git repository at: > > https://github.com/cohuck/qemu tags/s390x-20201002 > > for you to fetch changes up to be2b567018d987591647935a7c9648e9c45e05e8: > > s390x/tcg: Implement CIPHER MESSAGE WITH A

Re: [PATCH] meson.build: Don't look for libudev for static builds

2020-10-02 Thread Paolo Bonzini
On 02/10/20 16:18, Peter Maydell wrote: >> No, there's no functions at all. You can of course put the detection and >> test in a single loop: >> >> dependencies = {} >> ... >> if targetos == 'linux' and (have_system or have_tools) >> dependencies += {'libudev': 'mpath'} >> endif >> .

Re: [PATCH] gitlab-ci.yml: Only run one test-case per fuzzer

2020-10-02 Thread Darren Kenny
On Friday, 2020-10-02 at 10:35:24 -04, Alexander Bulekov wrote: > With 1000 runs, there is a non-negligible chance that the fuzzer can > trigger a crash. With this CI job, we care about catching build/runtime > issues in the core fuzzing code. Actual device fuzzing takes place on > oss-fuzz. For th

[PATCH V2 1/3] amd-iommu: Add address space notifier and replay support

2020-10-02 Thread Wei Huang
Currently the emulated amd-iommu device does not support memory address space notifier and replay. These two functions are required to have I/O devices supported inside guest VMs as passthru devices. This patch adds basic as_notifier infrastructure and replay function in amd_iommu. Co-developed-by

Re: [PATCH] gitlab-ci.yml: Only run one test-case per fuzzer

2020-10-02 Thread Thomas Huth
On 02/10/2020 16.35, Alexander Bulekov wrote: > With 1000 runs, there is a non-negligible chance that the fuzzer can > trigger a crash. With this CI job, we care about catching build/runtime > issues in the core fuzzing code. Actual device fuzzing takes place on > oss-fuzz. For these purposes, only

Re: [PATCH v3 2/2] arm64: kvm: Introduce MTE VCPU feature

2020-10-02 Thread Steven Price
On 02/10/2020 15:30, Andrew Jones wrote: On Fri, Sep 25, 2020 at 10:36:07AM +0100, Steven Price wrote: Add a new VM feature 'KVM_ARM_CAP_MTE' which enables memory tagging for a VM. This exposes the feature to the guest and automatically tags memory pages touched by the VM as PG_mte_tagged (and c

[PATCH V2 2/3] amd-iommu: Sync IOVA-to-GPA translation during page invalidation

2020-10-02 Thread Wei Huang
Add support to sync the IOVA-to-GPA translation at the time of IOMMU page invalidation. This function is called when two IOMMU commands, AMDVI_CMD_INVAL_AMDVI_PAGES and AMDVI_CMD_INVAL_AMDVI_ALL, are intercepted. Address space notifiers are called accordingly. Co-developed-by: Wei Huang Signed-of

[PATCH] hw/avr: Add limited support for avr gpio registers

2020-10-02 Thread Heecheol Yang
Add some of these features for avr gpio:   - GPIO I/O : PORTx registers   - Data Direction : DDRx registers Following things are not supported yet:   - PINx registers   - MCUR registers   - Even though read/write for DDRx registers are     implemented, actual direction controls are not     suppo

Re: [PATCH v6 1/4] configure: fixes indent of $meson setup

2020-10-02 Thread Daniel P . Berrangé
On Fri, Oct 02, 2020 at 01:32:27AM +0800, Yonggang Luo wrote: > convert these line from tab to space > > Signed-off-by: Yonggang Luo > --- > configure | 8 > 1 file changed, 4 insertions(+), 4 deletions(-) Reviewed-by: Daniel P. Berrangé Regards, Daniel -- |: https://berrange.com

Re: [PATCH] elfload: use g_new instead of malloc

2020-10-02 Thread Eric Blake
On 10/2/20 3:58 AM, Markus Armbruster wrote: @@ -890,9 +886,8 @@ static abi_ulong load_elf_interp(struct elfhdr * interp_elf_ex, } if (retval < 0) { perror("load_elf_interp"); +g_free(elf_phdata);

Re: [PATCH] meson.build: Don't look for libudev for static builds

2020-10-02 Thread Peter Maydell
On Fri, 2 Oct 2020 at 16:15, Paolo Bonzini wrote: > Or is it loops vs. functions that you find ugly? Lack of functions. Being able to abstract out what you're doing into something with a comprehensible name is a pretty basic software engineering requirement. Yes, you *can* rearrange everything so

Re: [PATCH 09/14] hw/misc/bcm2835_cprman: add a clock mux skeleton implementation

2020-10-02 Thread Philippe Mathieu-Daudé
On 10/2/20 4:42 PM, Philippe Mathieu-Daudé wrote: > On 9/25/20 12:17 PM, Luc Michel wrote: >> The clock multiplexers are the last clock stage in the cprman. Each mux >> outputs one clock signal that goes out of the cprman to the SoC >> peripherals. >> >> Each mux has at most 10 sources. The sources

[PATCH] hw/avr: Add limited support for avr gpio registers

2020-10-02 Thread Hee-cheol Yang
Add some of these features for avr gpio: - GPIO I/O : PORTx registers - Data Direction : DDRx registers Following things are not supported yet: - PINx registers - MCUR registers - Even though read/write for DDRx registers are implemented, actual direction controls are not suppor

Re: [PATCH v6 4/4] win32: Simplify gmtime_r detection not depends on if _POSIX_C_SOURCE are defined on msys2/mingw

2020-10-02 Thread Daniel P . Berrangé
On Fri, Oct 02, 2020 at 01:32:30AM +0800, Yonggang Luo wrote: > We remove the CONFIG_LOCALTIME_R detection option in configure, and move the > check > existence of gmtime_r from configure into C header and source directly by > using macro > `_POSIX_THREAD_SAFE_FUNCTIONS`. > Before this patch, the

Re: KVM call for agenda for 2020-10-06

2020-10-02 Thread John Snow
On 10/2/20 5:09 AM, Juan Quintela wrote: Hi Please, send any topic that you are interested in covering. At the end of Monday I will send an email with the agenda or the cancellation of the call, so hurry up. For this call, we have agenda!! John Snow wants to talk about his new (and excting

[PATCH v2 1/1] riscv: Convert interrupt logs to use qemu_log_mask()

2020-10-02 Thread Alistair Francis
Currently we log interrupts and exceptions using the trace backend in riscv_cpu_do_interrupt(). We also log exceptions using the interrupt log mask (-d int) in riscv_raise_exception(). This patch converts riscv_cpu_do_interrupt() to log both interrupts and exceptions with the interrupt log mask, s

Re: [PATCH v6 0/4] Fixes curses on msys2/mingw

2020-10-02 Thread Daniel P . Berrangé
On Fri, Oct 02, 2020 at 02:47:44PM +0200, Gerd Hoffmann wrote: > On Thu, Oct 01, 2020 at 07:39:33PM +0200, Paolo Bonzini wrote: > > On 01/10/20 19:32, Yonggang Luo wrote: > > > And also convert related configure script to meson. > > > V5-V6 > > > Dropping configure: Fixes ncursesw detection under m

[PATCH v1 2/4] hw/riscv: Return the end address of the loaded firmware

2020-10-02 Thread Alistair Francis
Signed-off-by: Alistair Francis --- include/hw/riscv/boot.h | 8 hw/riscv/boot.c | 28 +--- 2 files changed, 21 insertions(+), 15 deletions(-) diff --git a/include/hw/riscv/boot.h b/include/hw/riscv/boot.h index 451338780a..0acbd8aa6e 100644 --- a/includ

Re: [PATCH v6 2/4] curses: Fixes compiler error that complain don't have langinfo.h on msys2/mingw

2020-10-02 Thread Daniel P . Berrangé
On Fri, Oct 02, 2020 at 01:32:28AM +0800, Yonggang Luo wrote: > msys2/mingw lacks the POSIX-required langinfo.h. > > gcc test.c -DNCURSES_WIDECHAR -I/mingw64/include/ncursesw -pipe -lncursesw > -lgnurx -ltre -lintl -liconv > test.c:4:10: fatal error: langinfo.h: No such file or directory > 4

Re: [PATCH v6 00/14] Reverse debugging

2020-10-02 Thread Paolo Bonzini
On 29/09/20 13:01, Pavel Dovgalyuk wrote: > GDB remote protocol supports reverse debugging of the targets. > It includes 'reverse step' and 'reverse continue' operations. > The first one finds the previous step of the execution, > and the second one is intended to stop at the last breakpoint that >

[PATCH v1 1/1] register: Remove unnecessary NULL check

2020-10-02 Thread Alistair Francis
This patch fixes CID 1432800 by removing an unnecessary check. Signed-off-by: Alistair Francis --- hw/core/register.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/core/register.c b/hw/core/register.c index 31038bd7cc..9ac9bc6bfe 100644 --- a/hw/core/register.c +++ b/hw/

Re: [PATCH v3 0/2] MTE support for KVM guest

2020-10-02 Thread Steven Price
On 02/10/2020 15:36, Andrew Jones wrote: On Fri, Sep 25, 2020 at 10:36:05AM +0100, Steven Price wrote: Version 3 of adding MTE support for KVM guests. See the previous (v2) posting for background: https://lore.kernel.org/r/20200904160018.29481-1-steven.price%40arm.com These patches add suppo

[PATCH v1 0/4] Allow loading a no MMU kernel

2020-10-02 Thread Alistair Francis
This series allows loading a noMMU kernel using the -kernel option. Currently if using -kernel QEMU assumes you also have firmware and loads the kernel at a hardcoded offset. This series changes that so we only load the kernel at an offset if a firmware (-bios) was loaded. This series also adds a

[PATCH v1 1/4] hw/riscv: sifive_u: Allow specifying the CPU

2020-10-02 Thread Alistair Francis
Allow the user to specify the main application CPU for the sifive_u machine. Signed-off-by: Alistair Francis --- include/hw/riscv/sifive_u.h | 1 + hw/riscv/sifive_u.c | 18 +- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/include/hw/riscv/sifive_u.h b/

[PATCH v1 3/4] hw/riscv: Add a riscv_is_32_bit() function

2020-10-02 Thread Alistair Francis
Signed-off-by: Alistair Francis --- include/hw/riscv/boot.h | 2 ++ hw/riscv/boot.c | 9 + 2 files changed, 11 insertions(+) diff --git a/include/hw/riscv/boot.h b/include/hw/riscv/boot.h index 0acbd8aa6e..2975ed1a31 100644 --- a/include/hw/riscv/boot.h +++ b/include/hw/riscv/boo

[PATCH v1 4/4] hw/riscv: Load the kernel after the firmware

2020-10-02 Thread Alistair Francis
Signed-off-by: Alistair Francis --- include/hw/riscv/boot.h | 1 + hw/riscv/boot.c | 10 +- hw/riscv/opentitan.c| 3 ++- hw/riscv/sifive_e.c | 3 ++- hw/riscv/sifive_u.c | 13 +++-- hw/riscv/spike.c| 14 +++--- hw/riscv/virt.c | 14 ++

Re: [PATCH] gitlab-ci.yml: Only run one test-case per fuzzer

2020-10-02 Thread Philippe Mathieu-Daudé
On 10/2/20 5:15 PM, Thomas Huth wrote: > On 02/10/2020 16.35, Alexander Bulekov wrote: >> With 1000 runs, there is a non-negligible chance that the fuzzer can >> trigger a crash. With this CI job, we care about catching build/runtime >> issues in the core fuzzing code. Actual device fuzzing takes p

Re: [PATCH v1 1/1] register: Remove unnecessary NULL check

2020-10-02 Thread Eduardo Habkost
On Fri, Oct 02, 2020 at 08:33:40AM -0700, Alistair Francis wrote: > This patch fixes CID 1432800 by removing an unnecessary check. > > Signed-off-by: Alistair Francis > --- > hw/core/register.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/hw/core/register.c b/hw/core

Re: [PATCH v4 9/9] migration: introduce snapshot-{save, load, delete} QMP commands

2020-10-02 Thread Daniel P . Berrangé
On Mon, Sep 21, 2020 at 01:16:16PM -0500, Eric Blake wrote: > On 9/16/20 3:17 AM, Markus Armbruster wrote: > > Daniel P. Berrangé writes: > > > > > savevm, loadvm and delvm are some of the few HMP commands that have never > > > been converted to use QMP. The reasons for the lack of conversion are

Re: [PATCH] hw/avr: Add limited support for avr gpio registers

2020-10-02 Thread Philippe Mathieu-Daudé
Hi Yang, On 10/2/20 5:24 PM, Heecheol Yang wrote: > Add some of these features for avr gpio: > > Â - GPIO I/O : PORTx registers > Â - Data Direction : DDRx registers > > Following things are not supported yet: > Â - PINx registers > Â - MCUR registers > Â - Even though read/write for DDR

Re: [PULL v8 00/86] Misc QEMU patches for 2020-09-24

2020-10-02 Thread Michal Prívozník
On 9/30/20 9:58 PM, Paolo Bonzini wrote: > Eduardo Habkost (10): docs: Create docs/devel/qom.rst cd442a45db60a1a72fcf980c24bd1227f13f8a87 is the first bad commit Sorry for noticing this earlier, but is this known? The build starts failing for me after this commit: /usr/bin/sphinx-

Re: [PATCH] gitlab-ci.yml: Only run one test-case per fuzzer

2020-10-02 Thread Thomas Huth
On 02/10/2020 17.53, Philippe Mathieu-Daudé wrote: > On 10/2/20 5:15 PM, Thomas Huth wrote: >> On 02/10/2020 16.35, Alexander Bulekov wrote: >>> With 1000 runs, there is a non-negligible chance that the fuzzer can >>> trigger a crash. With this CI job, we care about catching build/runtime >>> issue

[PATCH] hw/acpi/piix4: Rename piix4_pm_add_propeties() to piix4_pm_add_properties()

2020-10-02 Thread Greg Kurz
Signed-off-by: Greg Kurz --- hw/acpi/piix4.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/acpi/piix4.c b/hw/acpi/piix4.c index 894d357f8c35..67a1ea41914f 100644 --- a/hw/acpi/piix4.c +++ b/hw/acpi/piix4.c @@ -437,7 +437,7 @@ static void piix4_pm_machine_ready(Noti

Re: [PATCH v6 00/14] Reverse debugging

2020-10-02 Thread Pavel Dovgalyuk
On 02.10.2020 18:39, Paolo Bonzini wrote: On 29/09/20 13:01, Pavel Dovgalyuk wrote: GDB remote protocol supports reverse debugging of the targets. It includes 'reverse step' and 'reverse continue' operations. The first one finds the previous step of the execution, and the second one is intended

[PATCH v2 1/1] register: Remove unnecessary NULL check

2020-10-02 Thread Alistair Francis
This patch fixes CID 1432800 by removing an unnecessary check. Signed-off-by: Alistair Francis --- hw/core/register.c | 4 1 file changed, 4 deletions(-) diff --git a/hw/core/register.c b/hw/core/register.c index 31038bd7cc..3600ef5bde 100644 --- a/hw/core/register.c +++ b/hw/core/register

Re: [PATCH] hw/acpi/piix4: Rename piix4_pm_add_propeties() to piix4_pm_add_properties()

2020-10-02 Thread Philippe Mathieu-Daudé
On 10/2/20 6:06 PM, Greg Kurz wrote: Maybe add "Fix a typo" to make it obvious. Reviewed-by: Philippe Mathieu-Daudé > Signed-off-by: Greg Kurz > --- > hw/acpi/piix4.c |4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/hw/acpi/piix4.c b/hw/acpi/piix4.c > index 894

Re: [PATCH v1 1/1] register: Remove unnecessary NULL check

2020-10-02 Thread Alistair Francis
On Fri, Oct 2, 2020 at 8:55 AM Eduardo Habkost wrote: > > On Fri, Oct 02, 2020 at 08:33:40AM -0700, Alistair Francis wrote: > > This patch fixes CID 1432800 by removing an unnecessary check. > > > > Signed-off-by: Alistair Francis > > --- > > hw/core/register.c | 2 +- > > 1 file changed, 1 inse

Re: [RFC v5 06/68] target/riscv: rvv-1.0: add translation-time vector context status

2020-10-02 Thread Richard Henderson
On 9/29/20 2:03 PM, frank.ch...@sifive.com wrote: > +++ b/target/riscv/insn_trans/trans_rvv.c.inc > @@ -41,6 +41,7 @@ static bool trans_vsetvl(DisasContext *ctx, arg_vsetvl *a) > gen_get_gpr(s2, a->rs2); > gen_helper_vsetvl(dst, cpu_env, s1, s2); > gen_set_gpr(a->rd, dst); > +mar

Re: [PATCH v3 2/2] arm64: kvm: Introduce MTE VCPU feature

2020-10-02 Thread Andrew Jones
On Fri, Oct 02, 2020 at 04:30:47PM +0100, Steven Price wrote: > On 02/10/2020 15:30, Andrew Jones wrote: > > On Fri, Sep 25, 2020 at 10:36:07AM +0100, Steven Price wrote: > > > + if (system_supports_mte() && kvm->arch.mte_enabled && pfn_valid(pfn)) { > > > > 'system_supports_mte() && kvm->arch.mte

Re: [PULL v8 00/86] Misc QEMU patches for 2020-09-24

2020-10-02 Thread Eduardo Habkost
On Fri, Oct 02, 2020 at 05:58:55PM +0200, Michal Prívozník wrote: > On 9/30/20 9:58 PM, Paolo Bonzini wrote: > > > > Eduardo Habkost (10): > > >docs: Create docs/devel/qom.rst > > cd442a45db60a1a72fcf980c24bd1227f13f8a87 is the first bad commit > > Sorry for noticing this earlier, but is

Re: [PATCH v3 0/2] MTE support for KVM guest

2020-10-02 Thread Andrew Jones
On Fri, Oct 02, 2020 at 04:38:11PM +0100, Steven Price wrote: > On 02/10/2020 15:36, Andrew Jones wrote: > > On Fri, Sep 25, 2020 at 10:36:05AM +0100, Steven Price wrote: > > > Version 3 of adding MTE support for KVM guests. See the previous (v2) > > > posting for background: > > > > > > https:/

Re: [PATCH v6 00/14] Reverse debugging

2020-10-02 Thread Pavel Dovgalyuk
On 02.10.2020 18:39, Paolo Bonzini wrote: On 29/09/20 13:01, Pavel Dovgalyuk wrote: GDB remote protocol supports reverse debugging of the targets. It includes 'reverse step' and 'reverse continue' operations. The first one finds the previous step of the execution, and the second one is intended

Re: [PULL v8 00/86] Misc QEMU patches for 2020-09-24

2020-10-02 Thread Paolo Bonzini
On 02/10/20 17:58, Michal Prívozník wrote: >> > > cd442a45db60a1a72fcf980c24bd1227f13f8a87 is the first bad commit > > Sorry for noticing this earlier, but is this known? The build starts > failing for me after this commit: > > /usr/bin/sphinx-build -Dversion=5.1.50 -Drelease= -W > -Ddepfile=doc

[PATCH v5 06/10] migration: control whether snapshots are ovewritten

2020-10-02 Thread Daniel P . Berrangé
The traditional HMP "savevm" command will overwrite an existing snapshot if it already exists with the requested name. This new flag allows this to be controlled allowing for safer behaviour with a future QMP command. Signed-off-by: Daniel P. Berrangé --- include/migration/snapshot.h | 2 +- mi

[PATCH v5 01/10] block: push error reporting into bdrv_all_*_snapshot functions

2020-10-02 Thread Daniel P . Berrangé
The bdrv_all_*_snapshot functions return a BlockDriverState pointer for the invalid backend, which the callers then use to report an error message. In some cases multiple callers are reporting the same error message, but with slightly different text. In the future there will be more error scenarios

[PATCH v5 02/10] migration: stop returning errno from load_snapshot()

2020-10-02 Thread Daniel P . Berrangé
None of the callers care about the errno value since there is a full Error object populated. This gives consistency with save_snapshot() which already just returns -1. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrangé --- migration/savevm.c | 17 - 1 file cha

[PATCH v5 00/10] migration: bring improved savevm/loadvm/delvm to QMP

2020-10-02 Thread Daniel P . Berrangé
v1: https://lists.gnu.org/archive/html/qemu-devel/2020-07/msg00866.html v2: https://lists.gnu.org/archive/html/qemu-devel/2020-07/msg07523.html v3: https://lists.gnu.org/archive/html/qemu-devel/2020-08/msg07076.html v4: https://lists.gnu.org/archive/html/qemu-devel/2020-09/msg05221.html This s

[PATCH v5 04/10] block: allow specifying name of block device for vmstate storage

2020-10-02 Thread Daniel P . Berrangé
Currently the vmstate will be stored in the first block device that supports snapshots. Historically this would have usually been the root device, but with UEFI it might be the variable store. There needs to be a way to override the choice of block device to store the state in. Signed-off-by: Dani

[PATCH v5 07/10] migration: wire up support for snapshot device selection

2020-10-02 Thread Daniel P . Berrangé
Modify load_snapshot/save_snapshot to accept the device list and vmstate node name parameters previously added to the block layer. Signed-off-by: Daniel P. Berrangé --- include/migration/snapshot.h | 12 ++-- migration/savevm.c | 28 +--- monitor/hmp-cmd

[PATCH v5 05/10] block: rename and alter bdrv_all_find_snapshot semantics

2020-10-02 Thread Daniel P . Berrangé
Currently bdrv_all_find_snapshot() will return 0 if it finds a snapshot, -1 if an error occurs, or if it fails to find a snapshot. New callers to be added want to distinguish between the error scenario and failing to find a snapshot. Rename it to bdrv_all_has_snapshot and make it return -1 on erro

[PATCH v5 08/10] migration: introduce a delete_snapshot wrapper

2020-10-02 Thread Daniel P . Berrangé
Make snapshot deletion consistent with the snapshot save and load commands by using a wrapper around the blockdev layer. The main difference is that we get upfront validation of the passed in device list (if any). Signed-off-by: Daniel P. Berrangé --- include/migration/snapshot.h | 4 +++- migr

[PATCH v5 03/10] block: add ability to specify list of blockdevs during snapshot

2020-10-02 Thread Daniel P . Berrangé
When running snapshot operations, there are various rules for which blockdevs are included/excluded. While this provides reasonable default behaviour, there are scenarios that are not well handled by the default logic. Some of the conditions do not have a single correct answer. Thus there needs to

[PATCH v5 09/10] iotests: add support for capturing and matching QMP events

2020-10-02 Thread Daniel P . Berrangé
When using the _launch_qemu and _send_qemu_cmd functions from common.qemu, any QMP events get mixed in with the output from the commands and responses. This makes it difficult to write a test case as the ordering of events in the output is not stable. This introduces a variable 'capture_events' w

[PATCH v5 10/10] migration: introduce snapshot-{save, load, delete} QMP commands

2020-10-02 Thread Daniel P . Berrangé
savevm, loadvm and delvm are some of the few HMP commands that have never been converted to use QMP. The reasons for the lack of conversion are that they blocked execution of the event thread, and the semantics around choice of disks were ill-defined. Despite this downside, however, libvirt and ap

Re: [PATCH v6 2/4] curses: Fixes compiler error that complain don't have langinfo.h on msys2/mingw

2020-10-02 Thread Yonggang Luo
On Fri, Oct 2, 2020 at 11:36 PM Daniel P. Berrangé wrote: > > On Fri, Oct 02, 2020 at 01:32:28AM +0800, Yonggang Luo wrote: > > msys2/mingw lacks the POSIX-required langinfo.h. > > > > gcc test.c -DNCURSES_WIDECHAR -I/mingw64/include/ncursesw -pipe -lncursesw -lgnurx -ltre -lintl -liconv > > test.

[PATCH v3 0/4] hw/arm/raspi: Fix SYS_timer to unbrick Linux kernels v3.7+

2020-10-02 Thread Philippe Mathieu-Daudé
In this series we implement the COMPARE registers of the SYS_timer, since they are used by Linux. This fixes the hang reported by Niek here: https://www.mail-archive.com/qemu-devel@nongnu.org/msg682090.html Since v2: - Fixed issue in COMPARE register reported by Luc Since v1: - Extracted unrelat

Re: [PATCH v6 2/4] curses: Fixes compiler error that complain don't have langinfo.h on msys2/mingw

2020-10-02 Thread Daniel P . Berrangé
On Sat, Oct 03, 2020 at 12:38:50AM +0800, 罗勇刚(Yonggang Luo) wrote: > On Fri, Oct 2, 2020 at 11:36 PM Daniel P. Berrangé > wrote: > > > > On Fri, Oct 02, 2020 at 01:32:28AM +0800, Yonggang Luo wrote: > > > msys2/mingw lacks the POSIX-required langinfo.h. > > > > > > gcc test.c -DNCURSES_WIDECHAR -I

[PATCH v3 1/4] hw/timer/bcm2835: Introduce BCM2835_SYSTIMER_COUNT definition

2020-10-02 Thread Philippe Mathieu-Daudé
Use the BCM2835_SYSTIMER_COUNT definition instead of the magic '4' value. Reviewed-by: Luc Michel Signed-off-by: Philippe Mathieu-Daudé --- include/hw/timer/bcm2835_systmr.h | 4 +++- hw/timer/bcm2835_systmr.c | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/inclu

Re: [PATCH v3] qemu/atomic.h: rename atomic_ to qatomic_

2020-10-02 Thread Matthew Rosato
On 9/23/20 6:56 AM, Stefan Hajnoczi wrote: clang's C11 atomic_fetch_*() functions only take a C11 atomic type pointer argument. QEMU uses direct types (int, etc) and this causes a compiler error when a QEMU code calls these functions in a source file that also included via a system header file:

[PATCH v3 2/4] hw/timer/bcm2835: Rename variable holding CTRL_STATUS register

2020-10-02 Thread Philippe Mathieu-Daudé
The variable holding the CTRL_STATUS register is misnamed 'status'. Rename it 'ctrl_status' to make it more obvious this register is also used to control the peripheral. Reviewed-by: Luc Michel Signed-off-by: Philippe Mathieu-Daudé --- include/hw/timer/bcm2835_systmr.h | 2 +- hw/timer/bcm2835_

[PATCH v3 3/4] hw/timer/bcm2835: Support the timer COMPARE registers

2020-10-02 Thread Philippe Mathieu-Daudé
This peripheral has 1 free-running timer and 4 compare registers. Only the free-running timer is implemented. Add support the COMPARE registers (each register is wired to an IRQ). Reference: "BCM2835 ARM Peripherals" datasheet [*] chapter 12 "System Timer": The System Timer periphe

[PATCH v3 4/4] hw/arm/bcm2835_peripherals: Correctly wire the SYS_timer IRQs

2020-10-02 Thread Philippe Mathieu-Daudé
The SYS_timer is not directly wired to the ARM core, but to the SoC (peripheral) interrupt controller. Fixes: 0e5bbd74064 ("hw/arm/bcm2835_peripherals: Use the SYS_timer") Reviewed-by: Luc Michel Signed-off-by: Philippe Mathieu-Daudé --- hw/arm/bcm2835_peripherals.c | 13 +++-- 1 file c

[PULL v2 00/11] capstone + disassembler patch queue

2020-10-02 Thread Richard Henderson
Version 2 retains a dummy capstone/all makefile target, to avoid the build failure that Peter saw. r~ The following changes since commit dd8c1e808f1ca311e1f50bff218c3ee3198b1f02: Merge remote-tracking branch 'remotes/cohuck/tags/s390x-20201002' into staging (2020-10-02 14:29:49 +

[PULL v2 01/11] capstone: Convert Makefile bits to meson bits

2020-10-02 Thread Richard Henderson
There are better ways to do this, e.g. meson cmake subproject, but that requires cmake 3.7 and some of our CI environments only provide cmake 3.5. Nor can we add a meson.build file to capstone/, because the git submodule would then always report "untracked files". Fixing that would require creati

Re: [PULL v8 00/86] Misc QEMU patches for 2020-09-24

2020-10-02 Thread Eduardo Habkost
On Fri, Oct 02, 2020 at 06:27:35PM +0200, Paolo Bonzini wrote: > On 02/10/20 17:58, Michal Prívozník wrote: > >> > > > > cd442a45db60a1a72fcf980c24bd1227f13f8a87 is the first bad commit > > > > Sorry for noticing this earlier, but is this known? The build starts > > failing for me after this comm

Re: [PATCH 5/5] qapi: Restrict Xen migration commands to migration.json

2020-10-02 Thread Dr. David Alan Gilbert
* Philippe Mathieu-Daudé (phi...@redhat.com) wrote: > Restricting xen-set-global-dirty-log and xen-load-devices-state > commands migration.json pulls slightly less QAPI-generated code > into user-mode and tools. > > Signed-off-by: Philippe Mathieu-Daudé Looks OK; for migration Acked-by: Dr.

Re: [PATCH v3 3/4] migration: Maintain postcopy faulted addresses

2020-10-02 Thread Dr. David Alan Gilbert
* Peter Xu (pet...@redhat.com) wrote: > Maintain a list of faulted addresses on the destination host for which we're > waiting on. This is implemented using a GTree rather than a real list to make > sure even there're plenty of vCPUs/threads that are faulting, the lookup will > still be fast with

[PATCH v3 06/11] tests/qtest/qos-test: dump QEMU command if verbose

2020-10-02 Thread Christian Schoenebeck
If qtests are run in verbose mode (i.e. if --verbose CL argument was provided) then print the assembled qemu command line for each test. Instead of using g_test_message() rather use printf() in combination with g_test_verbose(), to avoid g_test_message() cluttering the output. Signed-off-by: Chri

[PATCH] tests/test-char: Use a proper fallthrough comment

2020-10-02 Thread Thomas Huth
For being able to compile with -Werror=implicit-fallthrough we need to use comments that the compiler recognizes. Use "fallthrough" instead of "no break" here. Signed-off-by: Thomas Huth --- tests/test-char.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/test-char.c b

[PATCH v3 11/11] tests/9pfs: add local Tmkdir test

2020-10-02 Thread Christian Schoenebeck
This test case uses the 9pfs 'local' driver to create a directory and then checks if the expected directory was actually created (as real directory) on host side. This patch introduces a custom split() implementation, because the test code requires non empty array elements as result. For that reas

[PATCH v3 10/11] tests/9pfs: add virtio_9p_test_path()

2020-10-02 Thread Christian Schoenebeck
This new public function virtio_9p_test_path() allows 9pfs 'local' tests to translate a path from guest scope to host scope. For instance by passing an empty string it would return the root path on host of the exported 9pfs tree. Signed-off-by: Christian Schoenebeck --- tests/qtest/libqos/virtio

Re: [RFC PATCH v4 00/29] Hexagon patch series

2020-10-02 Thread Richard Henderson
On 9/28/20 12:28 PM, Taylor Simpson wrote: > This series adds support for the Hexagon processor with Linux user support > > See patch 02/34 Hexagon README for detailed information. > > Once the series is applied, the Hexagon port will pass "make check-tcg". > The series also includes Hexagon-spec

[PATCH v3 09/11] tests/9pfs: wipe local 9pfs test directory

2020-10-02 Thread Christian Schoenebeck
Before running the first 9pfs test case, make sure the test directory for running the 9pfs 'local' tests on is entirely empty. For that reason simply delete the test directory (if any) before (re)creating it on test suite startup. Signed-off-by: Christian Schoenebeck --- tests/qtest/libqos/virti

Re: [PATCH] tests/test-char: Use a proper fallthrough comment

2020-10-02 Thread Marc-André Lureau
On Fri, Oct 2, 2020 at 9:14 PM Thomas Huth wrote: > For being able to compile with -Werror=implicit-fallthrough we need > to use comments that the compiler recognizes. Use "fallthrough" instead > of "no break" here. > > Signed-off-by: Thomas Huth > Reviewed-by: Marc-André Lureau --- > tests/

[PATCH v3 07/11] tests/9pfs: change qtest name prefix to synth

2020-10-02 Thread Christian Schoenebeck
All existing 9pfs test cases are using the 'synth' fs driver so far, which means they are not accessing real files, but a purely simulated (in RAM only) file system. Let's make this clear by changing the prefix of the individual qtest case names from 'fs/' to 'synth/'. That way they'll be easily d

Re: [PATCH 0/4] linux-user: update syscall_nr headers to Linux 5.9-rc7

2020-10-02 Thread Richard Henderson
On 9/29/20 7:30 PM, Laurent Vivier wrote: > Laurent Vivier (4): > linux-user: update syscall_nr.h to Linux 5.9-rc7 > linux-user: update mips/syscall-args-o32.c.inc to Linux 5.9-rc7 > linux-user: update syscall.tbl to Linux 5.9-rc7 > linux-user: remove _sysctl Reviewed-by: Richard Henderson

[PATCH v3 04/11] tests/qtest/qos-test: dump qos graph if verbose

2020-10-02 Thread Christian Schoenebeck
If qtests were run in verbose mode (i.e. if --verbose CL argument was provided) then dump the generated qos graph (all nodes and edges, along with their current individual availability status) to stdout. See API doc comment on function qos_dump_graph() for details. Signed-off-by: Christian Schoen

[PATCH v3 00/11] 9pfs: add tests using local fs driver

2020-10-02 Thread Christian Schoenebeck
The currently existing 9pfs test cases are all solely using the 9pfs 'synth' fileystem driver, which is a very simple and purely simulated (in RAM only) filesystem. There are issues though where the 'synth' fs driver is not sufficient. For example the following two bugs need test cases running the

[PATCH v3 02/11] libqos/qgraph: add qos_node_create_driver_named()

2020-10-02 Thread Christian Schoenebeck
So far the qos subsystem of the qtest framework had the limitation that only one instance of the same official QEMU (QMP) driver name could be created for qtests. That's because a) the created qos node names must always be unique, b) the node name must match the official QEMU driver name being inst

Re: [PATCH] tests/test-char: Use a proper fallthrough comment

2020-10-02 Thread Philippe Mathieu-Daudé
On 10/2/20 7:13 PM, Thomas Huth wrote: > For being able to compile with -Werror=implicit-fallthrough we need > to use comments that the compiler recognizes. Use "fallthrough" instead > of "no break" here. > > Signed-off-by: Thomas Huth > --- > tests/test-char.c | 2 +- > 1 file changed, 1 insert

[PATCH v3 03/11] libqos/qgraph: add qos_dump_graph()

2020-10-02 Thread Christian Schoenebeck
This new function is purely for debugging purposes. It prints the current qos graph to stdout and allows to identify problems in the created qos graph e.g. when writing new qos tests. Coloured output is used to mark available nodes in green colour, whereas unavailable nodes are marked in red colou

[PATCH v3 01/11] libqos/qgraph: add qemu_name to QOSGraphNode

2020-10-02 Thread Christian Schoenebeck
Add new member variable 'qemu_name' to struct QOSGraphNode. This new member may be optionally set in case a different name for the node (which must always be a unique name) vs. its actually associated QEMU (QMP) device name is required. Signed-off-by: Christian Schoenebeck --- tests/qtest/libqo

[PATCH v3 05/11] tests/qtest/qos-test: dump environment variables if verbose

2020-10-02 Thread Christian Schoenebeck
If qtests are run in verbose mode (i.e. if --verbose CL argument was provided) then print all environment variables to stdout before running the individual tests. Instead of using g_test_message() rather use printf() in combination with g_test_verbose(), to avoid g_test_message() cluttering the ou

Re: [PATCH v3 4/4] migration: Sync requested pages after postcopy recovery

2020-10-02 Thread Dr. David Alan Gilbert
* Peter Xu (pet...@redhat.com) wrote: > We synchronize the requested pages right after a postcopy recovery happens. > This helps to synchronize the prioritized pages on source so that the faulted > threads can be served faster. > > Reported-by: Xiaohui Li > Signed-off-by: Peter Xu > --- > migra

[PATCH v3 08/11] tests/9pfs: introduce local tests

2020-10-02 Thread Christian Schoenebeck
This patch introduces 9pfs test cases using the 9pfs 'local' filesystem driver which reads/writes/creates/deletes real files and directories. In this initial version, there is only one local test which actually only checks if the 9pfs 'local' device was created successfully. Before the 9pfs 'loca

Re: [PULL v8 00/86] Misc QEMU patches for 2020-09-24

2020-10-02 Thread Michal Prívozník
On 10/2/20 6:22 PM, Eduardo Habkost wrote: On Fri, Oct 02, 2020 at 05:58:55PM +0200, Michal Prívozník wrote: On 9/30/20 9:58 PM, Paolo Bonzini wrote: Eduardo Habkost (10): docs: Create docs/devel/qom.rst cd442a45db60a1a72fcf980c24bd1227f13f8a87 is the first bad commit Sorry for n

Re: [PULL v8 00/86] Misc QEMU patches for 2020-09-24

2020-10-02 Thread Paolo Bonzini
On 02/10/20 19:26, Michal Prívozník wrote: > On 10/2/20 6:22 PM, Eduardo Habkost wrote: >> On Fri, Oct 02, 2020 at 05:58:55PM +0200, Michal Prívozník wrote: >>> On 9/30/20 9:58 PM, Paolo Bonzini wrote: Eduardo Habkost (10): >>>     docs: Create docs/devel/qom.rst >>> >>> cd442a4

[PATCH v6 00/10] Fix scsi devices plug/unplug races w.r.t virtio-scsi iothread

2020-10-02 Thread Paolo Bonzini
changes from previous version: - add comment to patch 1 - fix testsuite breakage by not using drain_call_rcu in qmp_device_del Maxim Levitsky (7): scsi/scsi_bus: switch search direction in scsi_device_find device_core: use drain_call_rcu in in qmp_device_add device-core: use RCU for list of

[PATCH v6 01/10] qdev: add "check if address free" callback for buses

2020-10-02 Thread Paolo Bonzini
Check if an address is free on the bus before plugging in the device. This makes it possible to do the check without any side effects, and to detect the problem early without having to do it in the realize callback. Signed-off-by: Paolo Bonzini --- hw/core/qdev.c | 17 +++--

[PATCH v6 08/10] scsi/scsi_bus: Add scsi_device_get

2020-10-02 Thread Paolo Bonzini
From: Maxim Levitsky Add scsi_device_get which finds the scsi device and takes a reference to it. Suggested-by: Stefan Hajnoczi Signed-off-by: Maxim Levitsky Message-Id: <20200913160259.32145-8-mlevi...@redhat.com> Signed-off-by: Paolo Bonzini --- hw/scsi/scsi-bus.c | 11 +++ inc

[PATCH v6 02/10] scsi: switch to bus->check_address

2020-10-02 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- hw/scsi/scsi-bus.c | 122 - 1 file changed, 75 insertions(+), 47 deletions(-) diff --git a/hw/scsi/scsi-bus.c b/hw/scsi/scsi-bus.c index 3284a5d1fb..94921c04b1 100644 --- a/hw/scsi/scsi-bus.c +++ b/hw/scsi/scsi-bus.c @@

[PATCH v6 04/10] device_core: use drain_call_rcu in in qmp_device_add

2020-10-02 Thread Paolo Bonzini
From: Maxim Levitsky Soon, a device removal might only happen on RCU callback execution. This is okay for device-del which provides a DEVICE_DELETED event, but not for the failure case of device-add. To avoid changing monitor semantics, just drain all pending RCU callbacks on error. Signed-off-

[PATCH v6 10/10] scsi/scsi_bus: fix races in REPORT LUNS

2020-10-02 Thread Paolo Bonzini
From: Maxim Levitsky Currently scsi_target_emulate_report_luns iterates over the child device list twice, and there is no guarantee that this list is the same in both iterations. The reason for iterating twice is that the first iteration calculates how much memory to allocate. However if we use

[PATCH v6 03/10] scsi/scsi_bus: switch search direction in scsi_device_find

2020-10-02 Thread Paolo Bonzini
From: Maxim Levitsky This change will allow us to convert the bus children list to RCU, while not changing the logic of this function Signed-off-by: Maxim Levitsky Reviewed-by: Stefan Hajnoczi Message-Id: <20200913160259.32145-2-mlevi...@redhat.com> Signed-off-by: Paolo Bonzini --- hw/scsi/s

[PATCH v6 05/10] device-core: use RCU for list of children of a bus

2020-10-02 Thread Paolo Bonzini
From: Maxim Levitsky This fixes the race between device emulation code that tries to find a child device to dispatch the request to (e.g a scsi disk), and hotplug of a new device to that bus. Note that this doesn't convert all the readers of the list but only these that might go over that list w

[PATCH v6 06/10] device-core: use atomic_set on .realized property

2020-10-02 Thread Paolo Bonzini
From: Maxim Levitsky Some code might race with placement of new devices on a bus. We currently first place a (unrealized) device on the bus and then realize it. As a workaround, users that scan the child device list, can check the realized property to see if it is safe to access such a device. U

[PATCH v6 07/10] scsi/scsi-bus: scsi_device_find: don't return unrealized devices

2020-10-02 Thread Paolo Bonzini
The device core first places a device on the bus and then realizes it. Make scsi_device_find avoid returing such devices to avoid races in drivers that use an iothread (currently virtio-scsi) Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1812399 Suggested-by: Paolo Bonzini Signed-off-by:

[PATCH v6 09/10] virtio-scsi: use scsi_device_get

2020-10-02 Thread Paolo Bonzini
From: Maxim Levitsky This will help us to avoid the scsi device disappearing after we took a reference to it. It doesn't by itself forbid case when we try to access an unrealized device Suggested-by: Stefan Hajnoczi Signed-off-by: Maxim Levitsky Reviewed-by: Stefan Hajnoczi Message-Id: <2020

<    1   2   3   4   >