[Qemu-devel] [PATCH v9 6/6] tests: qmp-test: add queue full test

2018-10-08 Thread Peter Xu
We'll need to include "monitor/monitor.h" for the queue length macro, then we don't need to hard code it. Suggested-by: Markus Armbruster Reviewed-by: Marc-André Lureau Signed-off-by: Peter Xu --- tests/qmp-test.c | 26 ++ 1 file changed, 26 insertions(+) diff --git a/

[Qemu-devel] [PATCH v9 5/6] tests: add oob functional test for test-qmp-cmds

2018-10-08 Thread Peter Xu
Straightforward test just to let the test-qmp-cmds be complete. Reviewed-by: Marc-André Lureau Signed-off-by: Peter Xu --- tests/test-qmp-cmds.c | 16 1 file changed, 16 insertions(+) diff --git a/tests/test-qmp-cmds.c b/tests/test-qmp-cmds.c index 4ab2b6e5ce..481cb069ca 10064

[Qemu-devel] [PATCH v9 4/6] Revert "tests: Add parameter to qtest_init_without_qmp_handshake"

2018-10-08 Thread Peter Xu
This reverts commit ddee57e0176f6ab53b13c6c97605b62737a8fd7a. Meanwhile, revert one line from fa198ad9bdef to make sure qtest_init_without_qmp_handshake() will only pass in one parameter. Reviewed-by: Markus Armbruster Reviewed-by: Marc-André Lureau Signed-off-by: Peter Xu --- tests/libqtest.

[Qemu-devel] [PATCH v9 3/6] monitor: remove "x-oob", turn oob on by default

2018-10-08 Thread Peter Xu
OOB commands were introduced in commit cf869d53172. Unfortunately, we ran into a regression, and had to disable them by default for 2.12 (commit be933ffc23). http://lists.gnu.org/archive/html/qemu-devel/2018-03/msg06231.html The regression has since been fixed (commit 951702f39c7 "monitor: bin

[Qemu-devel] [PATCH v9 1/6] monitor: Suspend monitor instead dropping commands

2018-10-08 Thread Peter Xu
When a QMP client sends in-band commands more quickly that we can process them, we can either queue them without limit (QUEUE), drop commands when the queue is full (DROP), or suspend receiving commands when the queue is full (SUSPEND). None of them is ideal: * QUEUE lets a misbehaving client mak

Re: [Qemu-devel] [RFC PATCH 00/21] Trace updates and plugin RFC

2018-10-08 Thread Pavel Dovgalyuk
> From: Alex Bennée [mailto:alex.ben...@linaro.org] > Any serious analysis tool should allow for us to track all memory > accesses so I think the guest_mem_before trace point should probably > be split into guest_mem_before_store and guest_mem_after_load. We > could go the whole hog and add potenti

[Qemu-devel] [PATCH v9 2/6] monitor: resume the monitor earlier if needed

2018-10-08 Thread Peter Xu
Currently when QMP request queue full we won't resume the monitor until we have completely handled the current command. It's not necessary since even before it's handled the queue is already non-full. Moving the resume logic earlier before the command execution. Note that now monitor_resume() is

[Qemu-devel] [PATCH v9 0/6] monitor: enable OOB by default

2018-10-08 Thread Peter Xu
Based-on: <20180828191048.29806-1-arm...@redhat.com> Based-on: <2018090716.1675-1-arm...@redhat.com> (this series is based on Markus's monitor-next tree) v9: - add r-bs - release the qmp queue lock before resume [Marc-Andre] v8: - remove patch 1 & 2 since already in the QAPI pull - squash pa

Re: [Qemu-devel] [PATCH v2] ssi-sd: Make devices picking up backends unavailable with -device

2018-10-08 Thread Thomas Huth
On 2018-10-09 08:08, Markus Armbruster wrote: > Device models aren't supposed to go on fishing expeditions for > backends. They should expose suitable properties for the user to set. > For onboard devices, board code sets them. > > Device ssi-sd picks up its block backend in its init() method wit

Re: [Qemu-devel] [PATCH 06/31] char: Use error_printf() to print help and such

2018-10-08 Thread Philippe Mathieu-Daudé
On 08/10/2018 19:31, Markus Armbruster wrote: > Calling error_report() in a function that takes an Error ** argument > is suspicious. Convert a few that are actually help and such to > error_printf(). > > Improves output of -chardev help from > > qemu-system-x86_64: -chardev help: Available

[Qemu-devel] [PATCH v2] ssi-sd: Make devices picking up backends unavailable with -device

2018-10-08 Thread Markus Armbruster
Device models aren't supposed to go on fishing expeditions for backends. They should expose suitable properties for the user to set. For onboard devices, board code sets them. Device ssi-sd picks up its block backend in its init() method with drive_get_next() instead. This mistake is already mar

Re: [Qemu-devel] [PATCH 19/31] vl: Clean up error reporting in parse_add_fd()

2018-10-08 Thread Philippe Mathieu-Daudé
On 08/10/2018 19:31, Markus Armbruster wrote: > Calling error_report() in a function that takes an Error ** argument > is suspicious. chardev_init_func() does that, and then fails without > setting an error. Its caller main(), via qemu_opts_foreach(), is fine > with it, but clean it up anyway. >

Re: [Qemu-devel] [PATCH 31/31] vl: Simplify call of parse_name()

2018-10-08 Thread Philippe Mathieu-Daudé
On 08/10/2018 19:31, Markus Armbruster wrote: > main() checks for parse_name() failure even though it can't actually > fail. That's okay. Simplify it to check by passing &error_fatal, > like the other users of qemu_opts_foreach(). > > Signed-off-by: Markus Armbruster Reviewed-by: Philippe Math

Re: [Qemu-devel] [PATCH 23/31] vl: Clean up error reporting in device_init_func()

2018-10-08 Thread Philippe Mathieu-Daudé
On 08/10/2018 19:31, Markus Armbruster wrote: > Calling error_report() in a function that takes an Error ** argument > is suspicious. device_init_func() does that, and then fails without > setting an error. Its caller main(), via qemu_opts_foreach(), is fine > with it, but clean it up anyway. >

Re: [Qemu-devel] [PATCH 20/31] vl: Clean up error reporting in machine_set_property()

2018-10-08 Thread Philippe Mathieu-Daudé
On 08/10/2018 19:31, Markus Armbruster wrote: > Calling error_report() in a function that takes an Error ** argument > is suspicious. machine_set_property() does that, and then fails without > setting an error. Its caller main(), via qemu_opts_foreach(), is fine > with it, but clean it up anyway.

Re: [Qemu-devel] [PATCH 21/31] vl: Clean up error reporting in mon_init_func()

2018-10-08 Thread Philippe Mathieu-Daudé
On 08/10/2018 19:31, Markus Armbruster wrote: > Calling error_report() in a function that takes an Error ** argument > is suspicious. mon_init_func() does that, and then fails without > setting an error. Its caller main(), via qemu_opts_foreach(), is fine > with it, but clean it up anyway. > > S

Re: [Qemu-devel] [PATCH v2] vl.c: print error message if load fw_cfg file failed

2018-10-08 Thread Li Qiang
Hello Philippe, Philippe Mathieu-Daudé 于2018年10月9日周二 下午1:52写道: > Hi Li, > > On 09/10/2018 04:39, Li Qiang wrote: > > It makes sense to print the error message while reading > > file failed. > > OK > > > > > Change since v1: > > free error > > Changes are useful for reviewer, but not in the git

[Qemu-devel] [PATCH] i386: pc_sysfw: load bios using rom API

2018-10-08 Thread Li Qiang
As the bios is a ROM, just using rom API. AFAICS no functionality changed. Signed-off-by: Li Qiang --- hw/i386/pc_sysfw.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/i386/pc_sysfw.c b/hw/i386/pc_sysfw.c index 091e22dd60..7f469fd582 100644 --- a/hw/i386/pc_sy

Re: [Qemu-devel] [PATCH v2] vl.c: print error message if load fw_cfg file failed

2018-10-08 Thread Philippe Mathieu-Daudé
Hi Li, On 09/10/2018 04:39, Li Qiang wrote: > It makes sense to print the error message while reading > file failed. OK > > Change since v1: > free error Changes are useful for reviewer, but not in the git history. You can have them automatically stripped if you place them below the next '---'

[Qemu-devel] [PATCH v2 3/3] Travis support for the acceptance tests

2018-10-08 Thread Cleber Rosa
This enables the execution of the acceptance tests on Travis. Because the Travis environment is based on Ubuntu Trusty, it requires the python3-pip. Note: while another supposedely required component on newer versions (such as on Bionic) split the Python 3 installation further on the python3-venv

[Qemu-devel] [PATCH v2 2/3] Acceptance tests: add make rule for running them

2018-10-08 Thread Cleber Rosa
The acceptance (aka functional, aka Avocado-based) tests are Python files located in "tests/acceptance" that need to be run with the Avocado libs and test runner. Let's provide a convenient way for QEMU developers to run them, by making use of the tests-venv with the required setup. Also, while t

[Qemu-devel] [PATCH v2 0/3] Bootstrap Python venv and acceptance/functional tests

2018-10-08 Thread Cleber Rosa
TL;DR = Allow acceptance tests to be run with `make check-acceptance`. Details === This introduces a Python virtual environment that will be setup within the QEMU build directory, that will contain the exact environment that tests may require. There's one current caveat: it requires Pyt

[Qemu-devel] [PATCH v2 1/3] Bootstrap Python venv for tests

2018-10-08 Thread Cleber Rosa
A number of QEMU tests are written in Python, and may benefit from an untainted Python venv. By using make rules, tests that depend on specific Python libs can set that rule as a requiment, along with rules that require the presence or installation of specific libraries. The tests/venv-requiremen

Re: [Qemu-devel] [PATCH 09/31] ioapic: Fix error handling in realize()

2018-10-08 Thread Peter Xu
On Mon, Oct 08, 2018 at 07:31:03PM +0200, Markus Armbruster wrote: > Calling error_report() in a function that takes an Error ** argument > is suspicious. ioapic_realize() does that, and then exit()s. > Currently mostly harmless, as the device cannot be hot-plugged. > > Fixes: 20fd4b7b6d9282fe0cb

[Qemu-devel] [PATCH v2] vl.c: print error message if load fw_cfg file failed

2018-10-08 Thread Li Qiang
It makes sense to print the error message while reading file failed. Change since v1: free error Signed-off-by: Li Qiang Reviewed-by: Philippe Mathieu-Daud?? --- vl.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/vl.c b/vl.c index 4e25c78..69fc77c 100644 --- a/vl.c

Re: [Qemu-devel] [PATCH] util: aio-posix: fix a typo

2018-10-08 Thread Fam Zheng
On Sun, 10/07 19:16, Li Qiang wrote: > Cc: qemu-triv...@nongnu.org > Signed-off-by: Li Qiang Reviewed-by: Fam Zheng

Re: [Qemu-devel] [PATCH 03/31] cpus hw target: Use warn_report() & friends to report warnings

2018-10-08 Thread David Gibson
On Mon, Oct 08, 2018 at 07:30:57PM +0200, Markus Armbruster wrote: > Calling error_report() in a function that takes an Error ** argument > is suspicious. Convert a few that are actually warnings to > warn_report(). > > While there, split a warning consisting of multiple sentences to > conform to

Re: [Qemu-devel] [PATCH 01/31] Use error_fatal to simplify obvious fatal errors (again)

2018-10-08 Thread David Gibson
On Mon, Oct 08, 2018 at 07:30:55PM +0200, Markus Armbruster wrote: > Add a slight improvement of the Coccinelle semantic patch from commit > 07d04a0219b, and use it to clean up. It leaves dead Error * variables > behind, cleaned up manually. > > Cc: David Gibson > Cc: Alexander Graf > Cc: Eric

[Qemu-devel] [Bug 1795527] Re: Malformed audio and video output stuttering after upgrade to QEMU 3.0

2018-10-08 Thread tlloss
UPDATE 2 (STUTTERING ELIMINATED, AUDIO ISSUES _STILL_ PRESENT) I think I've tracked down the source of the stuttering that affected my machine, and it doesn't seem to be QEMU-related. I'm going to write something about it here anyway, waiting to report it to other, more appropriate channels, hop

[Qemu-devel] [RFC v2 5/5] cputlb: dynamically resize TLBs based on use rate

2018-10-08 Thread Emilio G. Cota
Perform the resizing only on flushes, otherwise we'd have to take a perf hit by either rehashing the array or unnecessarily flushing it. We grow the array aggressively, and reduce the size more slowly. This accommodates mixed workloads, where some processes might be memory-heavy while others are n

[Qemu-devel] [RFC v2 1/5] tcg: Add tlb_index and tlb_entry helpers

2018-10-08 Thread Emilio G. Cota
From: Richard Henderson Isolate the computation of an index from an address into a helper before we change that function. Signed-off-by: Richard Henderson [ cota: convert tlb_vaddr_to_host; use atomic_read on addr_write ] Signed-off-by: Emilio G. Cota --- accel/tcg/softmmu_template.h | 72

[Qemu-devel] [RFC v2 0/5] Dynamic TLB sizing

2018-10-08 Thread Emilio G. Cota
v1: https://lists.gnu.org/archive/html/qemu-devel/2018-10/msg01146.html Changes since v1: - Add tlb_index and tlb_entry helpers from Richard - Introduce sizeof_tlb() and tlb_n_entries() - Extract tlb_mask as its own array in CPUArchState, as suggested by Richard. For the associated helpers (t

[Qemu-devel] [RFC v2 3/5] cputlb: do not evict empty entries to the vtlb

2018-10-08 Thread Emilio G. Cota
Currently we evict an entry to the victim TLB when it doesn't match the current address. But it could be that there's no match because the current entry is empty (i.e. all -1's, for instance via tlb_flush). Do not evict the entry to the vtlb in that case. This change will help us keep track of the

[Qemu-devel] [RFC v2 4/5] cputlb: track TLB use rate

2018-10-08 Thread Emilio G. Cota
This paves the way for implementing a dynamically-sized softmmu. Signed-off-by: Emilio G. Cota --- include/exec/cpu-defs.h | 5 + accel/tcg/cputlb.c | 17 ++--- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/include/exec/cpu-defs.h b/include/exec/cpu-defs.h

[Qemu-devel] [RFC v2 2/5] (XXX) cputlb: introduce indirection for TLB size

2018-10-08 Thread Emilio G. Cota
This paves the way for implementing dynamic TLB resizing. XXX: convert other TCG backends Signed-off-by: Emilio G. Cota --- include/exec/cpu-defs.h | 10 ++ include/exec/cpu_ldst.h | 14 +- accel/tcg/cputlb.c| 18 +++--- tcg/i386/tcg-target.inc.c | 28

Re: [Qemu-devel] [PATCH v2 7/7] block/qcow2-refcount: fix out-of-file L2 entries to be read-as-zero

2018-10-08 Thread Vladimir Sementsov-Ogievskiy
On 10/09/2018 01:21 AM, Max Reitz wrote: > On 09.10.18 00:14, Vladimir Sementsov-Ogievskiy wrote: >> >> >> On 10/09/2018 01:08 AM, Max Reitz wrote: >>> On 09.10.18 00:02, Vladimir Sementsov-Ogievskiy wrote: On 10/08/2018 11:51 PM, Max Reitz wrote: > On 17.08.18 14:22, Vladimir

Re: [Qemu-devel] [PATCH v1 11/12] hw/arm: versal: Add a model of Xilinx Versal SoC

2018-10-08 Thread Edgar E. Iglesias
On Mon, Oct 08, 2018 at 02:19:09PM +0100, Peter Maydell wrote: > On 3 October 2018 at 16:07, Edgar E. Iglesias > wrote: > > From: "Edgar E. Iglesias" > > > > Add a model of Xilinx Versal SoC. > > > > Signed-off-by: Edgar E. Iglesias > > --- > > default-configs/aarch64-softmmu.mak | 1 + > >

Re: [Qemu-devel] [PATCH v2 7/7] block/qcow2-refcount: fix out-of-file L2 entries to be read-as-zero

2018-10-08 Thread Max Reitz
On 09.10.18 00:14, Vladimir Sementsov-Ogievskiy wrote: > > > On 10/09/2018 01:08 AM, Max Reitz wrote: >> On 09.10.18 00:02, Vladimir Sementsov-Ogievskiy wrote: >>> >>> >>> On 10/08/2018 11:51 PM, Max Reitz wrote: On 17.08.18 14:22, Vladimir Sementsov-Ogievskiy wrote: > Rewrite corrupted

[Qemu-devel] possible BUG, ATS12NSOPW fails

2018-10-08 Thread Stefano Stabellini
Hi Peter, I am chasing an address translation error, and it looks like it might be a QEMU bug, because I cannot reproduce the problem on a physical board. The issue is that a requested ATS12NSOPW translation in Xen is reported as failing by QEMU, but actually the address is correct. The workflow

Re: [Qemu-devel] [PATCH v2 7/7] block/qcow2-refcount: fix out-of-file L2 entries to be read-as-zero

2018-10-08 Thread Vladimir Sementsov-Ogievskiy
On 10/09/2018 01:08 AM, Max Reitz wrote: > On 09.10.18 00:02, Vladimir Sementsov-Ogievskiy wrote: >> >> >> On 10/08/2018 11:51 PM, Max Reitz wrote: >>> On 17.08.18 14:22, Vladimir Sementsov-Ogievskiy wrote: Rewrite corrupted L2 table entry, which reference space out of underlying file.

Re: [Qemu-devel] [PATCH v2 7/7] block/qcow2-refcount: fix out-of-file L2 entries to be read-as-zero

2018-10-08 Thread Max Reitz
On 09.10.18 00:02, Vladimir Sementsov-Ogievskiy wrote: > > > On 10/08/2018 11:51 PM, Max Reitz wrote: >> On 17.08.18 14:22, Vladimir Sementsov-Ogievskiy wrote: >>> Rewrite corrupted L2 table entry, which reference space out of >>> underlying file. >>> >>> Make this L2 table entry read-as-all-zero

Re: [Qemu-devel] [PATCH v2 04/12] qemu-option: improve qemu_opts_print_help() output

2018-10-08 Thread Max Reitz
First of all, this patch broke iotest 082. But then again, all that'd be needed is a correction of the reference output. However: On 07.09.18 09:59, Marc-André Lureau wrote: > Modify qemu_opts_print_help(): > - to print expected argument type > - skip description if not available > - sort lines

Re: [Qemu-devel] [PATCH v2 7/7] block/qcow2-refcount: fix out-of-file L2 entries to be read-as-zero

2018-10-08 Thread Vladimir Sementsov-Ogievskiy
On 10/08/2018 11:51 PM, Max Reitz wrote: > On 17.08.18 14:22, Vladimir Sementsov-Ogievskiy wrote: >> Rewrite corrupted L2 table entry, which reference space out of >> underlying file. >> >> Make this L2 table entry read-as-all-zeros without any allocation. >> >> Signed-off-by: Vladimir Sementsov-

[Qemu-devel] [Bug 1796754] Re: ioctl SIOCGIFCONF causes qemu-aarch64-static to crash with "received signal outside vCPU context"

2018-10-08 Thread Ke Liu
I was hit by this issue when I tried to run some Java program. And it turns out jdk sets the buf to NULL: http://hg.openjdk.java.net/jdk7/jdk7/jdk/file/887e525597f8/src/solaris/native/java/net/NetworkInterface.c#l1042 Setting to NULL is valid according to http://man7.org/linux/man- pages/man7/netd

Re: [Qemu-devel] [PATCH] qemu-system-hppa: Raise exception 26 on emulated hardware

2018-10-08 Thread Richard Henderson
On 10/7/18 1:51 PM, Helge Deller wrote: > On PCXS chips (PA7000, pa 1.1a), trap #18 is raised on memory faults, > while all later chips (>= PA7100) generate either trap #26, #27 or #28 > (depending on the fault type). > > Since the current qemu emulation emulates a B160L machine (with a > PA7300LC

[Qemu-devel] [PATCH v3 03/10] target/arm: Convert v8 extensions from feature bits to isar tests

2018-10-08 Thread Richard Henderson
Most of the v8 extensions are self-contained within the ISAR registers and are not implied by other feature bits, which makes them the easiest to convert. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- target/arm/cpu.h | 123 +-

[Qemu-devel] [PATCH v3 00/10] target/arm: Rely on id regs instead of features

2018-10-08 Thread Richard Henderson
This edition fixes a number of conflicts with master, and adds a few field definitions from ARMv8.5, courtesy of Philippe. It also fixes a big think-o in a last-minute change to the sve system mode patch set that was applied to master today. That would be patch 1. Sorry for not testing the origin

[Qemu-devel] [PATCH v3 01/10] target/arm: Fix aarch64_sve_change_el wrt EL0

2018-10-08 Thread Richard Henderson
At present we assert: arm_el_is_aa64: Assertion `el >= 1 && el <= 3' failed. The comment in arm_el_is_aa64 explains why asking about EL0 without extra information is impossible. Add an extra argument to provide it from the surrounding context. Fixes: 0ab5953b00b3 Signed-off-by: Richard Hender

[Qemu-devel] [PATCH v3 02/10] target/arm: Define fields of ISAR registers

2018-10-08 Thread Richard Henderson
Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- target/arm/cpu.h | 88 1 file changed, 88 insertions(+) diff --git a/target/arm/cpu.h b/target/arm/cpu.h index 54362ddce8..f00c0444c4 100644 --- a/target/arm/cpu.h +++ b/tar

Re: [Qemu-devel] [PATCH v1 10/12] target/arm: Add the Cortex-A72

2018-10-08 Thread Edgar E. Iglesias
On Mon, Oct 08, 2018 at 02:10:29PM +0100, Peter Maydell wrote: > On 3 October 2018 at 16:07, Edgar E. Iglesias > wrote: > > From: "Edgar E. Iglesias" > > > > Add the ARM Cortex-A72. > > > > Signed-off-by: Edgar E. Iglesias > > --- > > target/arm/cpu64.c | 59 > > ++

[Qemu-devel] [PATCH v3 05/10] target/arm: Fix cortex-a7 id_isar0

2018-10-08 Thread Richard Henderson
The incorrect value advertised only thumb2 div without arm div. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- target/arm/cpu.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/target/arm/cpu.c b/target/arm/cpu.c index ac46641541..83a6cb535f 1006

[Qemu-devel] [PATCH v3 07/10] target/arm: Convert jazelle from feature bit to isar1 test

2018-10-08 Thread Richard Henderson
Having V6 alone imply jazelle was wrong for cortex-m0. Change to an assertion for V6 & !M. This was harmless, because the only place we tested ARM_FEATURE_JAZELLE was for 'bxj' in disas_arm(), which is unreachable for M-profile cores. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard He

[Qemu-devel] [PATCH v3 04/10] target/arm: Align cortex-r5 id_isar0

2018-10-08 Thread Richard Henderson
The missing nibble made it more difficult to read. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- target/arm/cpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/arm/cpu.c b/target/arm/cpu.c index b7d9942aa3..ac46641541 100644 --- a/target/a

[Qemu-devel] [PATCH v3 06/10] target/arm: Convert division from feature bits to isar0 tests

2018-10-08 Thread Richard Henderson
Both arm and thumb2 division are controlled by the same ISAR field, which takes care of the arm implies thumb case. Having M imply thumb2 division was wrong for cortex-m0, which is v6m and does not have thumb2 at all, much less thumb2 division. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by:

[Qemu-devel] [PATCH v3 09/10] target/arm: Convert sve from feature bit to aa64pfr0 test

2018-10-08 Thread Richard Henderson
Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- target/arm/cpu.h| 16 +++- target/arm/translate-a64.h | 1 + linux-user/aarch64/signal.c | 4 ++-- linux-user/elfload.c| 2 +- linux-user/syscall.c| 10 ++ target/arm/cpu6

[Qemu-devel] [PATCH v3 08/10] target/arm: Convert t32ee from feature bit to isar3 test

2018-10-08 Thread Richard Henderson
Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- target/arm/cpu.h | 6 +- linux-user/elfload.c | 2 +- target/arm/cpu.c | 4 target/arm/helper.c | 2 +- target/arm/machine.c | 3 +-- 5 files changed, 8 insertions(+), 9 deletions(-) diff --git a/target/a

[Qemu-devel] [PATCH v3 10/10] target/arm: Convert v8.2-fp16 from feature bit to aa64pfr0 test

2018-10-08 Thread Richard Henderson
Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- target/arm/cpu.h | 17 +++- target/arm/translate-a64.h | 1 + target/arm/translate.h | 1 + linux-user/elfload.c | 6 +- target/arm/cpu64.c | 9 ++--- target/arm/helper.c

Re: [Qemu-devel] [PATCH 30/31] blockdev: Convert drive_new() to Error

2018-10-08 Thread Max Reitz
On 08.10.18 19:31, Markus Armbruster wrote: > Calling error_report() from within a a function that takes an Error ** > argument is suspicious. drive_new() does that, and its caller > drive_init_func() then exit()s. I'm afraid I don't quite follow you here. There is no function here that takes an

Re: [Qemu-devel] [PATCH 29/31] vl: Assert drive_new() does not fail in default_drive()

2018-10-08 Thread Max Reitz
On 08.10.18 19:31, Markus Armbruster wrote: > If creating (empty) default drives fails, it's a bug. Therefore, > assert() is more appropriate than exit(1). > > Cc: Kevin Wolf > Cc: Max Reitz > Signed-off-by: Markus Armbruster > --- > vl.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletion

Re: [Qemu-devel] [PATCH v2 7/7] block/qcow2-refcount: fix out-of-file L2 entries to be read-as-zero

2018-10-08 Thread Max Reitz
On 17.08.18 14:22, Vladimir Sementsov-Ogievskiy wrote: > Rewrite corrupted L2 table entry, which reference space out of > underlying file. > > Make this L2 table entry read-as-all-zeros without any allocation. > > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > block/qcow2-refcount.c | 32 +

Re: [Qemu-devel] [PATCH 30/31] blockdev: Convert drive_new() to Error

2018-10-08 Thread Eric Blake
On 10/8/18 12:31 PM, Markus Armbruster wrote: Calling error_report() from within a a function that takes an Error ** s/a a/a/ argument is suspicious. drive_new() does that, and its caller drive_init_func() then exit()s. Its caller main(), via qemu_opts_foreach(), is fine with it, but clean

Re: [Qemu-devel] [PATCH 29/31] vl: Assert drive_new() does not fail in default_drive()

2018-10-08 Thread Eric Blake
On 10/8/18 12:31 PM, Markus Armbruster wrote: If creating (empty) default drives fails, it's a bug. Therefore, assert() is more appropriate than exit(1). Cc: Kevin Wolf Cc: Max Reitz Signed-off-by: Markus Armbruster --- vl.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) The a

Re: [Qemu-devel] [PATCH 28/31] fsdev: Clean up error reporting in qemu_fsdev_add()

2018-10-08 Thread Eric Blake
On 10/8/18 12:31 PM, Markus Armbruster wrote: Calling error_report() from within a a function that takes an Error ** s/a a/a/ argument is suspicious. qemu_fsdev_add() does that, and its caller fsdev_init_func() then fails without setting an error. Its caller main(), via qemu_opts_foreach(),

Re: [Qemu-devel] [PATCH v2 2/7] block/qcow2-refcount: avoid eating RAM

2018-10-08 Thread Max Reitz
On 08.10.18 22:22, Vladimir Sementsov-Ogievskiy wrote: > > > On 10/08/2018 06:31 PM, Max Reitz wrote: >> On 17.08.18 14:22, Vladimir Sementsov-Ogievskiy wrote: >>> qcow2_inc_refcounts_imrt() (through realloc_refcount_array()) can eat >>> an unpredictable amount of memory on corrupted table entrie

Re: [Qemu-devel] [PATCH 18/31] qom: Clean up error reporting in user_creatable_add_opts_foreach()

2018-10-08 Thread Eric Blake
On 10/8/18 12:31 PM, Markus Armbruster wrote: Calling error_report() in a function that takes an Error ** argument is suspicious. user_creatable_add_opts_foreach() does that, and then fails without setting an error. Its caller main(), via qemu_opts_foreach(), is fine with it, but clean it up an

Re: [Qemu-devel] [PATCH 02/31] block: Use warn_report() & friends to report warnings

2018-10-08 Thread Eric Blake
On 10/8/18 12:30 PM, Markus Armbruster wrote: Calling error_report() in a function that takes an Error ** argument is suspicious. Convert a few that are actually warnings to warn_report(). While there, split warnings consisting of multiple sentences to conform to conventions spelled out in warn

Re: [Qemu-devel] [PATCH 01/31] Use error_fatal to simplify obvious fatal errors (again)

2018-10-08 Thread Eric Blake
On 10/8/18 12:30 PM, Markus Armbruster wrote: Add a slight improvement of the Coccinelle semantic patch from commit 07d04a0219b, which shares the same commit title, but does not actually have a semantic patch, but rather defers to the even older 007b065. But I'm not too worried about either

Re: [Qemu-devel] [Qemu-block] [PATCH v11 07/31] iotests.py: Add node_info()

2018-10-08 Thread Max Reitz
On 08.10.18 21:59, John Snow wrote: > > > On 10/08/2018 03:57 PM, Max Reitz wrote: >> On 08.10.18 21:34, John Snow wrote: >>> >>> >>> On 10/05/2018 07:39 PM, Max Reitz wrote: This function queries a node; since we cannot do that right now, it executes query-named-block-nodes and returns

Re: [Qemu-devel] [PATCH v2 2/7] block/qcow2-refcount: avoid eating RAM

2018-10-08 Thread Vladimir Sementsov-Ogievskiy
On 10/08/2018 06:31 PM, Max Reitz wrote: > On 17.08.18 14:22, Vladimir Sementsov-Ogievskiy wrote: >> qcow2_inc_refcounts_imrt() (through realloc_refcount_array()) can eat >> an unpredictable amount of memory on corrupted table entries, which are >> referencing regions far beyond the end of file.

Re: [Qemu-devel] [PATCH v2 2/7] block/qcow2-refcount: avoid eating RAM

2018-10-08 Thread Vladimir Sementsov-Ogievskiy
On 10/08/2018 06:31 PM, Max Reitz wrote: > On 17.08.18 14:22, Vladimir Sementsov-Ogievskiy wrote: >> qcow2_inc_refcounts_imrt() (through realloc_refcount_array()) can eat >> an unpredictable amount of memory on corrupted table entries, which are >> referencing regions far beyond the end of file.

Re: [Qemu-devel] [PATCH] migration: invalidate cache before source start

2018-10-08 Thread John Snow
On 10/08/2018 11:36 AM, Vladimir Sementsov-Ogievskiy wrote: > 26.06.2018 11:44, Vladimir Sementsov-Ogievskiy wrote: >> 25.06.2018 20:50, Dr. David Alan Gilbert wrote: >>> * Dr. David Alan Gilbert (dgilb...@redhat.com) wrote: * Vladimir Sementsov-Ogievskiy (vsement...@virtuozzo.com) wrote: >

Re: [Qemu-devel] [RFC 2/6] cputlb: do not evict invalid entries to the vtlb

2018-10-08 Thread Emilio G. Cota
On Mon, Oct 08, 2018 at 12:46:26 -0700, Richard Henderson wrote: > On 10/8/18 7:42 AM, Emilio G. Cota wrote: > > On Sun, Oct 07, 2018 at 19:09:01 -0700, Richard Henderson wrote: > >> On 10/6/18 2:45 PM, Emilio G. Cota wrote: > >>> Currently we evict an entry to the victim TLB when it doesn't match

Re: [Qemu-devel] [PATCH v2 1/2] MAINTAINERS: Replace myself with John Snow for block jobs

2018-10-08 Thread John Snow
On 09/26/2018 02:05 PM, Jeff Cody wrote: > I'll not be involved with day-to-day qemu development, and John > Snow is a block jobs wizard. Have him take over block job > maintainership duties. > ... I didn't realize he wrote it like this, and I am told I should accept compliments, ... Well, f

Re: [Qemu-devel] [PATCH v2 6/7] block/qcow2-refcount: fix out-of-file L1 entries to be zero

2018-10-08 Thread Max Reitz
On 17.08.18 14:22, Vladimir Sementsov-Ogievskiy wrote: > Zero out corrupted L1 table entry, which reference L2 table out of > underlying file. > Zero L1 table entry means that "the L2 table and all clusters described > by this L2 table are unallocated." > > Signed-off-by: Vladimir Sementsov-Ogievs

[Qemu-devel] [Bug 1796754] [NEW] ioctl SIOCGIFCONF causes qemu-aarch64-static to crash with "received signal outside vCPU context"

2018-10-08 Thread Ke Liu
Public bug reported: To reproduce it, compile the attached crash.c under aarch64 to a.out and execute on x86_64 qemu-aarch64-static ./a.out It will print the following and crash: socket=3 qemu:handle_cpu_signal received signal outside vCPU context @ pc=0x60038cd6 qemu:handle_cpu_signal received

Re: [Qemu-devel] [Qemu-block] [PATCH v11 07/31] iotests.py: Add node_info()

2018-10-08 Thread Max Reitz
On 08.10.18 21:34, John Snow wrote: > > > On 10/05/2018 07:39 PM, Max Reitz wrote: >> This function queries a node; since we cannot do that right now, it >> executes query-named-block-nodes and returns the matching node's object. >> >> Signed-off-by: Max Reitz >> --- >> tests/qemu-iotests/iotes

Re: [Qemu-devel] [Qemu-block] [PATCH v11 07/31] iotests.py: Add node_info()

2018-10-08 Thread John Snow
On 10/08/2018 03:57 PM, Max Reitz wrote: > On 08.10.18 21:34, John Snow wrote: >> >> >> On 10/05/2018 07:39 PM, Max Reitz wrote: >>> This function queries a node; since we cannot do that right now, it >>> executes query-named-block-nodes and returns the matching node's object. >>> >>> Signed-off

Re: [Qemu-devel] [PATCH v1 06/12] net: cadence_gem: Add support for selecting the DMA MemoryRegion

2018-10-08 Thread Edgar E. Iglesias
On Mon, Oct 08, 2018 at 01:30:20PM +0100, Peter Maydell wrote: > On 3 October 2018 at 16:07, Edgar E. Iglesias > wrote: > > From: "Edgar E. Iglesias" > > > > Add support for selecting the Memory Region that the GEM > > will do DMA to. > > > > Signed-off-by: Edgar E. Iglesias > > --- > > hw/net

Re: [Qemu-devel] [PATCH v1 09/12] target-arm: powerctl: Enable HVC when starting CPUs to EL2

2018-10-08 Thread Edgar E. Iglesias
On Mon, Oct 08, 2018 at 01:41:36PM +0100, Peter Maydell wrote: > On 3 October 2018 at 16:07, Edgar E. Iglesias > wrote: > > From: "Edgar E. Iglesias" > > > > When QEMU provides the equivalent of the EL3 firmware, we > > need to enable HVCs in scr_el3 when turning on CPUs that > > target EL2. > >

Re: [Qemu-devel] [PATCH v1 06/12] net: cadence_gem: Add support for selecting the DMA MemoryRegion

2018-10-08 Thread Edgar E. Iglesias
On Mon, Oct 08, 2018 at 01:24:51PM +0100, Peter Maydell wrote: > On 3 October 2018 at 16:07, Edgar E. Iglesias > wrote: > > From: "Edgar E. Iglesias" > > > > Add support for selecting the Memory Region that the GEM > > will do DMA to. > > > > Signed-off-by: Edgar E. Iglesias > > --- > > > > @

Re: [Qemu-devel] [PATCH v2 5/7] block/qcow2-refcount: check_refcounts_l2: split fix_l2_entry_to_zero

2018-10-08 Thread Max Reitz
On 17.08.18 14:22, Vladimir Sementsov-Ogievskiy wrote: > Split entry repairing to separate function, to be reused later. > > Note: entry in in-memory l2 table (local variable in > check_refcounts_l2) is not updated after this patch. > > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > block/

Re: [Qemu-devel] [PATCH] tests: Disable test-bdrv-drain

2018-10-08 Thread Eric Blake
On 10/8/18 11:40 AM, Kevin Wolf wrote: Am 08.10.2018 um 17:43 hat Peter Maydell geschrieben: Looking at the backtraces I'm wondering if this is the result of an implicit reliance on the order in which per-thread destructors are called (which is left unspecified by POSIX) -- the destructor functi

Re: [Qemu-devel] [Qemu-block] [PATCH 05/10] docs/devel/testing.rst: add missing newlines after code block

2018-10-08 Thread John Snow
On 10/04/2018 12:18 PM, Cleber Rosa wrote: > The line immediate following a ".. code::" block is considered > to contains arguments to the "code directive". The lack of a > new line gives me during at parse time: > >testing.rst:63: (ERROR/3) Error in "code" directive: >maximum 1 argume

Re: [Qemu-devel] [RFC 2/6] cputlb: do not evict invalid entries to the vtlb

2018-10-08 Thread Richard Henderson
On 10/8/18 7:42 AM, Emilio G. Cota wrote: > On Sun, Oct 07, 2018 at 19:09:01 -0700, Richard Henderson wrote: >> On 10/6/18 2:45 PM, Emilio G. Cota wrote: >>> Currently we evict an entry to the victim TLB when it doesn't match >>> the current address. But it could be that there's no match because >>

Re: [Qemu-devel] [Qemu-block] [PATCH 09/10] scripts/qemu.py: use a more consistent docstring style

2018-10-08 Thread John Snow
On 10/04/2018 12:18 PM, Cleber Rosa wrote: > Signed-off-by: Cleber Rosa > --- > dtc | 2 +- > scripts/qemu.py | 65 +++-- > 2 files changed, 42 insertions(+), 25 deletions(-) > > diff --git a/dtc b/dtc > index 88f18909db..e54388015a 160

Re: [Qemu-devel] [Qemu-block] [PATCH v11 07/31] iotests.py: Add node_info()

2018-10-08 Thread John Snow
On 10/05/2018 07:39 PM, Max Reitz wrote: > This function queries a node; since we cannot do that right now, it > executes query-named-block-nodes and returns the matching node's object. > > Signed-off-by: Max Reitz > --- > tests/qemu-iotests/iotests.py | 7 +++ > 1 file changed, 7 inserti

Re: [Qemu-devel] insecure git submodule URLs

2018-10-08 Thread Eric Blake
On 7/15/18 7:56 PM, Jann Horn via Qemu-devel wrote: On Sun, Jul 15, 2018 at 11:18 PM Peter Maydell wrote: On 15 July 2018 at 20:50, Jann Horn via Qemu-devel wrote: I noticed that when I build QEMU from git for the first time, it pulls in submodules over the insecure git:// protocol - in othe

Re: [Qemu-devel] [PULL 0/8] softfloat queue

2018-10-08 Thread Eric Blake
Adding Jeff and Stefan On 10/8/18 8:47 AM, Peter Maydell wrote: On 5 October 2018 at 19:01, Richard Henderson wrote: The following changes since commit ae7a4c0a4604bcfed40170db6cca576c44d872a2: Merge remote-tracking branch 'remotes/cohuck/tags/s390x-20181004' into staging (2018-10-05 16:0

Re: [Qemu-devel] [PATCH v2 2/2] docs: Document vCPU hotplug procedure

2018-10-08 Thread Eric Blake
On 10/1/18 3:59 AM, Igor Mammedov wrote: Anyway, what about this: The command returns an object with a "qom-path" member for each present CPU. In this case, it shows an IvyBridge-IBRS-x86_64-cpu in socket 0. It returns an object without a "qom-path" for every possibly CPU

Re: [Qemu-devel] [PATCH] sdl2: Support all virtio-gpu formats

2018-10-08 Thread Max Reitz
On 08.10.18 20:50, Max Reitz wrote: > There are some 2D resource formats that can be used through virtio-gpu, > but which are not supported by SDL2 when used for a scanout; these are > all alpha-channel formats and also XBGR (RGBX in non-BE pixman). Oops, it's the other way round. The virtio-gpu

Re: [Qemu-devel] [PATCH 05/31] vfio: Clean up error reporting after previous commit

2018-10-08 Thread Alex Williamson
On Mon, 8 Oct 2018 19:30:59 +0200 Markus Armbruster wrote: > The previous commit changed vfio's warning messages from > > vfio warning: DEV-NAME: Could not frobnicate > > to > > warning: vfio DEV-NAME: Could not frobnicate > > To match this change, change error messages from > >

Re: [Qemu-devel] [PATCH 04/31] vfio: Use warn_report() & friends to report warnings

2018-10-08 Thread Alex Williamson
On Mon, 8 Oct 2018 19:30:58 +0200 Markus Armbruster wrote: > The vfio code reports warnings like > > error_report(WARN_PREFIX "Could not frobnicate", DEV-NAME); > > where WARN_PREFIX is defined so the message comes out as > > vfio warning: DEV-NAME: Could not frobnicate > > This usag

[Qemu-devel] [PATCH] sdl2: Support all virtio-gpu formats

2018-10-08 Thread Max Reitz
There are some 2D resource formats that can be used through virtio-gpu, but which are not supported by SDL2 when used for a scanout; these are all alpha-channel formats and also XBGR (RGBX in non-BE pixman). Add these formats in the switch converting pixman to SDL format constants so a guest canno

Re: [Qemu-devel] [PATCH 14/14] block: Stop passing flags to bdrv_reopen_queue_child()

2018-10-08 Thread Max Reitz
On 08.10.18 20:13, Alberto Garcia wrote: > On Mon 08 Oct 2018 04:48:50 AM CEST, Max Reitz wrote: > >>> +/* Old values are used for options that aren't set yet */ >>> +old_options = qdict_clone_shallow(bs->options); >>> +bdrv_join_options(bs, options, old_options); >>> +qobject_unre

Re: [Qemu-devel] [PATCH] tcg: Add tlb_index and tlb_entry helpers

2018-10-08 Thread Emilio G. Cota
On Sun, Oct 07, 2018 at 18:05:22 -0700, Richard Henderson wrote: > Isolate the computation of an index from an address into a > helper before we change that function. > > Signed-off-by: Richard Henderson > --- > > Emilio, this should make your dynamic tlb sizing patch 1/6 > significantly smaller

[Qemu-devel] [PATCH v1 4/5] RISC-V: Add missing free for plic_hart_config

2018-10-08 Thread Alistair Francis
From: Michael Clark Cc: Palmer Dabbelt Cc: Sagar Karandikar Cc: Bastian Koppelmann Cc: Alistair Francis Signed-off-by: Michael Clark Reviewed-by: Alistair Francis --- hw/riscv/virt.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/riscv/virt.c b/hw/riscv/virt.c index 005169eabc..6

[Qemu-devel] [PATCH v1 2/5] RISC-V: Move non-ops from op_helper to cpu_helper

2018-10-08 Thread Alistair Francis
From: Michael Clark This patch makes op_helper.c contain only instruction operation helpers used by translate.c and moves any unrelated cpu helpers into cpu_helper.c. No logic is changed by this patch. Cc: Sagar Karandikar Cc: Bastian Koppelmann Cc: Palmer Dabbelt Cc: Alistair Francis Signed

[Qemu-devel] [PATCH v1 5/5] RISC-V: Don't add NULL bootargs to device-tree

2018-10-08 Thread Alistair Francis
From: Michael Clark Cc: Palmer Dabbelt Cc: Alistair Francis Signed-off-by: Michael Clark Reviewed-by: Alistair Francis --- hw/riscv/sifive_u.c | 4 +++- hw/riscv/spike.c| 6 -- hw/riscv/virt.c | 4 +++- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/hw/riscv/sifi

[Qemu-devel] [PATCH v1 3/5] RISC-V: Update CSR and interrupt definitions

2018-10-08 Thread Alistair Francis
From: Michael Clark * Add user-mode CSR defininitions. * Reorder CSR definitions to match the specification. * Change H mode interrupt comment to 'reserved'. * Remove unused X_COP interrupt. * Add user-mode interrupts. * Remove erroneous until comments on machine mode interrupts. * Move together

[Qemu-devel] [PATCH v1 0/5] Misc RISC-V patches

2018-10-08 Thread Alistair Francis
These are some patches that I have cherry picked from Michael's RISC-V tree that are ready to be applied. Unless anyone has any comments against these I'll send a PR later this week. Michael Clark (5): RISC-V: Allow setting and clearing multiple irqs RISC-V: Move non-ops from op_helper to cpu_

  1   2   3   4   >