[PATCH v2 20/22] iotests: test m68k with the virt machine

2021-03-23 Thread Alex Bennée
From: Laurent Vivier This allows to cover the virtio tests with a 32bit big-endian virtio-mmio machine. Signed-off-by: Laurent Vivier Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Cornelia Huck Message-Id: <20210319202335.2397060-6-laur...@vivier.eu> Signed-off-by: Alex Bennée --- tests/

[PATCH] device-crash-test: Ignore errors about a bus not being available

2021-03-23 Thread Thomas Huth
Recent QEMU versions now sometimes exit cleanly with an error message that a bus is not available for a specified device. Don't flag those as an error in the device-crash-test script. Signed-off-by: Thomas Huth --- scripts/device-crash-test | 1 + 1 file changed, 1 insertion(+) diff --git a/scr

Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-23 Thread Markus Armbruster
Eric Blake writes: > On 3/23/21 4:40 AM, Markus Armbruster wrote: >> Naming rules differ for the various kinds of names. To prepare >> enforcing them, define functions to check them: check_name_upper(), >> check_name_lower(), and check_name_camel(). For now, these merely >> wrap around check_na

[Bug 1920784] Re: qemu-system-ppc64le fails with kvm acceleration

2021-03-23 Thread Laurent Vivier
You need a kernel with a the following fix for POWER9: commit 25edcc50d76c834479d11fcc7de46f3da4d95121 Author: Fabiano Rosas Date: Thu Feb 4 17:05:17 2021 -0300 KVM: PPC: Book3S HV: Save and restore FSCR in the P9 path The Facility Status and Control Register is a privileged SPR t

Crashes with qemu-system-ppc64

2021-03-23 Thread Thomas Huth
In case anyone is interested in fixing those, there are two regressions with qemu-system-ppc64 in the current master branch: $ ./qemu-system-ppc64 -M ppce500 -device macio-oldworld qemu-system-ppc64: ../../devel/qemu/softmmu/memory.c:2443: memory_region_add_subregion_common: Assertion `!subr

Re: [PULL 00/16] riscv-to-apply queue

2021-03-23 Thread Peter Maydell
On Tue, 23 Mar 2021 at 01:59, Alistair Francis wrote: > > The following changes since commit c95bd5ff1660883d15ad6e0005e4c8571604f51a: > > Merge remote-tracking branch 'remotes/philmd/tags/mips-fixes-20210322' into > staging (2021-03-22 14:26:13 +) > > are available in the Git repository at

Re: [RFC PATCH 05/13] blobs: Only install npcm7xx bootrom if ARM system targets are built

2021-03-23 Thread Paolo Bonzini
On 23/03/21 16:51, Philippe Mathieu-Daudé wrote: install_edk2_blobs = install_edk2_blobs or target in edk2_targets install_blobs_alpha = install_blobs_alpha or target in ['alpha-softmmu'] +install_blobs_arm = install_blobs_hppa or target in ['arm-softmmu', 'aarch64-softmmu']

Re: [PATCH 0/4] DEVICE_NOT_DELETED/DEVICE_UNPLUG_ERROR QAPI events

2021-03-23 Thread Daniel Henrique Barboza
On 3/22/21 10:12 PM, David Gibson wrote: On Fri, Mar 12, 2021 at 05:07:36PM -0300, Daniel Henrique Barboza wrote: Hi, This series adds 2 new QAPI events, DEVICE_NOT_DELETED and DEVICE_UNPLUG_ERROR. They were (and are still being) discussed in [1]. Patches 1 and 3 are independent of the ppc

[PATCH v2 01/22] scripts/kernel-doc: strip QEMU_ from function definitions

2021-03-23 Thread Alex Bennée
Some packaged versions of Sphinx (fedora33/alpine so far) have issues with the annotated C code that kernel-doc spits out. Without knowing about things like QEMU_PLUGIN_EXPORT it chokes trying to understand the code. Evidently this is a problem for the kernel as well as the long stream of regex sub

[PATCH v2 04/22] tools/virtiofsd: include --socket-group in help

2021-03-23 Thread Alex Bennée
I confused myself wandering if this had been merged by looking at the help output. It seems fuse_opt doesn't automagically add to help output so lets do it now. Signed-off-by: Alex Bennée Reviewed-by: Connor Kuehl Reviewed-by: Stefan Hajnoczi Updates: f6698f2b03 ("tools/virtiofsd: add support f

Re: [PATCH 19/28] qapi: Rename pragma *-whitelist to *-exceptions

2021-03-23 Thread Markus Armbruster
Eric Blake writes: > On 3/23/21 4:40 AM, Markus Armbruster wrote: >> Rename pragma returns-whitelist to command-returns-exceptions, and >> name-case-whitelist to member-name-case-exceptions. >> >> Signed-off-by: Markus Armbruster >> --- > Doesn't mention anything about the motivation for this i

[PATCH v2 02/22] docs/devel: include the plugin API information from the headers

2021-03-23 Thread Alex Bennée
We have kerneldoc tags for the headers so we might as well extract them into our developer documentation whilst we are at it. Signed-off-by: Alex Bennée Reviewed-by: Aaron Lindsay Message-Id: <20210312172821.31647-4-alex.ben...@linaro.org> Message-Id: <20210320133706.21475-3-alex.ben...@linaro.o

[PATCH v2 03/22] docs/devel: expand style section of memory management

2021-03-23 Thread Alex Bennée
This aims to provide a bit more guidance for those who take on one of our "clean up memory allocation" bite-sized tasks. Signed-off-by: Alex Bennée Reviewed-by: Richard Henderson Message-Id: <20210320133706.21475-4-alex.ben...@linaro.org> --- docs/devel/style.rst | 46 ++

Re: [PATCH 3/4] qemu-iotests: let "check" spawn an arbitrary test command

2021-03-23 Thread Vladimir Sementsov-Ogievskiy
23.03.2021 16:06, Paolo Bonzini wrote: Right now there is no easy way for "check" to print a reproducer command. Because such a reproducer command line would be huge, we can instead teach check to start a command of our choice. This can be for example a Python unit test with arguments to only ru

[Bug 1920784] Status changed to Confirmed

2021-03-23 Thread Ubuntu Kernel Bot
This change was made by a bot. ** Changed in: linux (Ubuntu) Status: New => Confirmed -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1920784 Title: qemu-system-ppc64le fails with kvm acceler

[PATCH v2 05/22] semihosting: move semihosting tests to multiarch

2021-03-23 Thread Alex Bennée
It may be arm-compat-semihosting but more than one architecture uses it so lets move the tests into the multiarch area. We gate it on the feature and split the semicall.h header between the arches. Also clean-up a bit of the Makefile messing about to one common set of runners. Signed-off-by: Alex

Re: [PATCH 4/4] qemu-iotests: fix case of SOCK_DIR already in the environment

2021-03-23 Thread Vladimir Sementsov-Ogievskiy
23.03.2021 16:06, Paolo Bonzini wrote: Due to a typo, in this case the SOCK_DIR was not being created. Signed-off-by: Paolo Bonzini --- tests/qemu-iotests/testenv.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qemu-iotests/testenv.py b/tests/qemu-iotests/testenv

[PATCH v2 12/22] cirrus.yml: Update the FreeBSD task to version 12.2

2021-03-23 Thread Alex Bennée
From: Thomas Huth FreeBSD version 12.1 is out of service now, and the task in the Cirrus-CI is failing. Update to 12.2 to get it working again. Unfortunately, there is a bug in libtasn1 that triggers with the new version of Clang that is used there (see this thread for details: https://lists.gnu.

Re: [PATCH 3/4] qemu-iotests: let "check" spawn an arbitrary test command

2021-03-23 Thread Vladimir Sementsov-Ogievskiy
23.03.2021 20:22, Paolo Bonzini wrote: On 23/03/21 18:11, Vladimir Sementsov-Ogievskiy wrote: If you have positional arguments that must begin with - and don’t look like negative numbers, you can insert the pseudo-argument '--' which tells parse_args() that everything after that is a positiona

[PATCH v2 13/22] utils: Tighter tests for qemu_strtosz

2021-03-23 Thread Alex Bennée
From: Eric Blake Our tests were not validating the return value in all cases, nor was it guaranteeing our documented claim that 'res' is unchanged on error. For that matter, it wasn't as thorough as the existing tests for qemu_strtoi() and friends for proving that endptr and res are sanely set.

[PATCH v2 10/22] gitlab-ci.yml: Merge the trace-backend testing into other jobs

2021-03-23 Thread Alex Bennée
From: Thomas Huth Our gitlab-ci got quite slow in the past weeks, due to the immense amount of jobs that we have, so we should try to reduce the number of jobs. There is no real good reason for having separate jobs just to test the trace backends, we can do this just fine in other jobs, too. Sig

[PATCH v2 09/22] tests/tcg: add HeapInfo checking to semihosting test

2021-03-23 Thread Alex Bennée
Query the SYS_HEAPINFO semicall and do some basic verification of the information via libc calls. Signed-off-by: Alex Bennée Message-Id: <20210320133706.21475-10-alex.ben...@linaro.org> --- v2 - expand test as suggested by Richard --- .../multiarch/arm-compat-semi/semihosting.c | 55 +++

[PATCH 1/2] yank: Remove dependency on qiochannel

2021-03-23 Thread Lukas Straub
Remove dependency on qiochannel by removing yank_generic_iochannel and letting migration and chardev use their own yank function for iochannel. Signed-off-by: Lukas Straub --- MAINTAINERS | 1 + chardev/char-socket.c | 21 ++--- include/qemu/yank.h

Re: [PATCH 1/4] qemu-iotests: allow passing unittest.main arguments to the test scripts

2021-03-23 Thread Vladimir Sementsov-Ogievskiy
23.03.2021 18:29, Paolo Bonzini wrote: On 23/03/21 15:34, Vladimir Sementsov-Ogievskiy wrote: +    def __init__(self, *args, **kwargs): +    super().__init__(stream=ReproducibleTextTestRunner.output, *args, **kwargs) over-79 line (PEP8) Ok, thanks. + +def execute_unittest(argv, debug=

Re: [PATCH v2 08/10] target/hexagon: import parser for idef-parser

2021-03-23 Thread Paolo Montesel via
Thanks for the feedback, it helped us improve the implementation quite a bit. > > +| rvalue QMARK rvalue COLON rvalue > > +{ > > +@1.last_column = @5.last_column; > > +bool is_64bit = ($3.bit_width == 64) || ($5.bit_width == 64); > > +int bit_width = (is_64bit) ? 64 : 32; > > +if (

[PATCH 2/2] yank: Always link full yank code

2021-03-23 Thread Lukas Straub
Yank now only depends on util and can be always linked in. Also remove the stubs as they are not needed anymore. Signed-off-by: Lukas Straub --- MAINTAINERS | 1 - stubs/meson.build | 1 - stubs/yank.c | 23 --- util/meson.build | 2 +- 4 files changed, 1 inser

[PATCH v2 14/22] utils: Work around mingw strto*l bug with 0x

2021-03-23 Thread Alex Bennée
From: Eric Blake Mingw recognizes that "0x" has value 0 without setting errno, but fails to advance endptr to the trailing garbage 'x'. This in turn showed up in our recent testsuite additions for qemu_strtosz (commit 1657ba44b4 utils: Enhance testsuite for do_strtosz()); adjust our remaining te

[PATCH v2 15/22] gitlab: extend timeouts for CFI builds

2021-03-23 Thread Alex Bennée
These builds are running very close to the default build limit and as they are already pared down the only other option is to extend the timeout a little to give some breathing room. Signed-off-by: Alex Bennée Reviewed-by: Thomas Huth Reviewed-by: Willian Rampazzo Reviewed-by: Philippe Mathieu-

[PATCH for 6.0 v2 00/22] fixes for rc1 pre-PR (kernel-doc, semihosting, testing)

2021-03-23 Thread Alex Bennée
Hi, I've added a testing patch to extend the CFI times, Laurent's series to fix the iotest regressions currently keeping the CI from going green and an optimisation to the --enable-docs build to try and start bringing the total CI time down a bit. rc0 is being tagged today so I'll probably roll a

[PATCH v2 17/22] m68k: add the virtio devices aliases

2021-03-23 Thread Alex Bennée
From: Laurent Vivier Similarly to 5f629d943cb0 ("s390x: fix s390 virtio aliases"), define the virtio aliases. This allows to start machines with virtio devices without knowledge of the implementation type. For instance, we can use "-device virtio-scsi" on m68k, s390x or PC, and the device will

[PATCH v2 19/22] iotests: Revert "iotests: use -ccw on s390x for 040, 139, and 182"

2021-03-23 Thread Alex Bennée
From: Laurent Vivier Commit f1d5516ab583 introduces a test in some iotests to check if the machine is a s390-ccw-virtio and to select virtio-*-ccw rather than virtio-*-pci. We don't need that because QEMU already provides aliases to use the correct virtio interface according to the machine type.

[PATCH v2 07/22] semihosting/arm-compat-semi: don't use SET_ARG to report SYS_HEAPINFO

2021-03-23 Thread Alex Bennée
As per the spec: the PARAMETER REGISTER contains the address of a pointer to a four-field data block. So we need to follow arg0 and place the results of SYS_HEAPINFO there. Fixes: 3c37cfe0b1 ("semihosting: Change internal common-semi interfaces to use CPUState *") Signed-off-by: Alex Bennée

Re: [PATCH 1/4] qapi/qdev.json: add DEVICE_NOT_DELETED event

2021-03-23 Thread Eric Blake
On 3/12/21 2:07 PM, Daniel Henrique Barboza wrote: > This new event informs QAPI listeners that a previously issued > 'device_del' command failed to delete the device from the machine. > > Note that no assertion can be made about the failure reason. The goal of > this event is to inform management

Re: [PATCH 3/4] qemu-iotests: let "check" spawn an arbitrary test command

2021-03-23 Thread Paolo Bonzini
On 23/03/21 17:43, Vladimir Sementsov-Ogievskiy wrote: Interesting that REMAINDER documentation disappeared from latest (3.9) python documentation https://docs.python.org/3.9/library/argparse.html , but exists here https://docs.python.org/3.8/library/argparse.html  (and no mark of deprecation

[PATCH v2 11/22] configure: Don't use the __atomic_*_16 functions for testing 128-bit support

2021-03-23 Thread Alex Bennée
From: Thomas Huth The test for 128-bit atomics is causing trouble with FreeBSD 12.2 and --enable-werror: cc -Werror -fPIE -DPIE -std=gnu99 -Wall -m64 -mcx16 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -Wstrict-prototypes -Wredundant-decls -Wundef -Wwrite-strings -Wmissing-prototy

Re: [PATCH 2/2] yank: Always link full yank code

2021-03-23 Thread Thomas Huth
On 23/03/2021 18.52, Lukas Straub wrote: Yank now only depends on util and can be always linked in. Also remove the stubs as they are not needed anymore. Signed-off-by: Lukas Straub --- MAINTAINERS | 1 - stubs/meson.build | 1 - stubs/yank.c | 23 --- util

Re: [PATCH v4 07/17] target/ppc: Disconnect hflags from MSR

2021-03-23 Thread Richard Henderson
On 3/22/21 5:54 PM, David Gibson wrote: On Mon, Mar 22, 2021 at 10:55:46AM -0600, Richard Henderson wrote: On 3/21/21 9:52 PM, David Gibson wrote: +/* + * Bits for env->hflags. + * + * Most of these bits overlap with corresponding bits in MSR, + * but some come from other sources. Be cautious

[PATCH v2 16/22] qdev: define list of archs with virtio-pci or virtio-ccw

2021-03-23 Thread Alex Bennée
From: Laurent Vivier This is used to define virtio-*-pci and virtio-*-ccw aliases rather than substracting the CCW architecture from all the others. Signed-off-by: Laurent Vivier Reviewed-by: Cornelia Huck Message-Id: <20210319202335.2397060-2-laur...@vivier.eu> Signed-off-by: Alex Bennée ---

Re: [PATCH 06/28] tests/qapi-schema: Tweak to demonstrate buggy member name check

2021-03-23 Thread John Snow
On 3/23/21 11:44 AM, Markus Armbruster wrote: John Snow writes: On 3/23/21 5:40 AM, Markus Armbruster wrote: Member name 'u' and names starting with 'has-' or 'has_' are reserved for the generator. check_type() enforces this, covered by tests reserved-member-u and reserved-member-has. These

Re: [PULL 00/20] pc,virtio,pci: fixes, features

2021-03-23 Thread Igor Mammedov
On Tue, 23 Mar 2021 10:13:58 -0400 "Michael S. Tsirkin" wrote: CCing Philippe, maybe he has an idea how to fix it from mips side. > On Tue, Mar 23, 2021 at 10:50:05AM +, Peter Maydell wrote: > > On Mon, 22 Mar 2021 at 22:56, Michael S. Tsirkin wrote: > > > On Mon, Mar 22, 2021 at 06:46:0

[PATCH v2 4/5] qemu-iotests: let "check" spawn an arbitrary test command

2021-03-23 Thread Paolo Bonzini
Right now there is no easy way for "check" to print a reproducer command. Because such a reproducer command line would be huge, we can instead teach check to start a command of our choice. This can be for example a Python unit test with arguments to only run a specific subtest. Move the trailing

Re: [PATCH 1/2] spapr: number of SMP sockets must be equal to NUMA nodes

2021-03-23 Thread Daniel Henrique Barboza
On 3/22/21 10:03 PM, David Gibson wrote: On Fri, Mar 19, 2021 at 03:34:52PM -0300, Daniel Henrique Barboza wrote: Kernel commit 4bce545903fa ("powerpc/topology: Update topology_core_cpumask") cause a regression in the pseries machine when defining certain SMP topologies [1]. The reasoning beh

Re: [PATCH 3/4] qemu-iotests: let "check" spawn an arbitrary test command

2021-03-23 Thread Vladimir Sementsov-Ogievskiy
23.03.2021 20:00, Paolo Bonzini wrote: On 23/03/21 17:43, Vladimir Sementsov-Ogievskiy wrote: Interesting that REMAINDER documentation disappeared from latest (3.9) python documentation https://docs.python.org/3.9/library/argparse.html , but exists here https://docs.python.org/3.8/library/arg

Re: [PATCH 1/4] qemu-iotests: allow passing unittest.main arguments to the test scripts

2021-03-23 Thread Paolo Bonzini
On 23/03/21 17:56, Vladimir Sementsov-Ogievskiy wrote: hmm, just use a separate call of unittest.main, or honestly define a varaible as Union[] or just Any ? All the ugliness goes away if the implementation is done properly. :) For me normal try-finally is a lot more clean than calling atexit(

Re: Crashes with qemu-system-ppc64

2021-03-23 Thread Philippe Mathieu-Daudé
+Mark On 3/23/21 5:48 PM, Thomas Huth wrote: > > In case anyone is interested in fixing those, there are two regressions > with qemu-system-ppc64 in the current master branch: > > $ ./qemu-system-ppc64 -M ppce500 -device macio-oldworld > qemu-system-ppc64: ../../devel/qemu/softmmu/memory.c:2443:

Re: [PATCH v1 1/3] migration: Fix missing qemu_fflush() on buffer file in bg_migration_thread

2021-03-23 Thread Andrey Gruzdev
On 23.03.2021 17:54, Peter Xu wrote: On Tue, Mar 23, 2021 at 10:51:57AM +0300, Andrey Gruzdev wrote: On 22.03.2021 23:17, Peter Xu wrote: On Fri, Mar 19, 2021 at 05:52:47PM +0300, Andrey Gruzdev wrote: Added missing qemu_fflush() on buffer file holding precopy device state. Increased initial Q

Re: [PATCH 3/4] qemu-iotests: let "check" spawn an arbitrary test command

2021-03-23 Thread Paolo Bonzini
On 23/03/21 18:11, Vladimir Sementsov-Ogievskiy wrote: If you have positional arguments that must begin with - and don’t look like negative numbers, you can insert the pseudo-argument '--' which tells parse_args() that everything after that is a positional argument: So, as I understand argpars

[PATCH v2 1/3] vt82c686.c: don't raise SCI when PCI_INTERRUPT_PIN isn't setup

2021-03-23 Thread Isaku Yamahata
Without this patch, the following patch will triger clan runtime sanitizer warnings as follows. This patch proactively works around it. I let v582c686.c maintainer address a correct fix as I'm not sure about fuloong2e device model. > MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}

Re: [PATCH 1/4] qemu-iotests: allow passing unittest.main arguments to the test scripts

2021-03-23 Thread Vladimir Sementsov-Ogievskiy
23.03.2021 20:04, Paolo Bonzini wrote: On 23/03/21 17:56, Vladimir Sementsov-Ogievskiy wrote: hmm, just use a separate call of unittest.main, or honestly define a varaible as Union[] or just Any ? All the ugliness goes away if the implementation is done properly. :) For me normal try-finall

[PATCH v2 2/3] pci: sprinkle assert in PCI pin number

2021-03-23 Thread Isaku Yamahata
If a device model (a) doesn't set the value to a correct interrupt number and then (b) triggers an interrupt for itself, it's device model bug. Add assert on interrupt pin number to catch this kind of bug more obviously. Suggested-by: Peter Maydell Signed-off-by: Isaku Yamahata --- hw/pci/pci.c

[PATCH v2 0/3] reinitialize ACPI PM device on reset

2021-03-23 Thread Isaku Yamahata
Reinitialize ACPI PM device on reset to get preper device state. Oppertunistically add assert on PCI interrupt pin logic to detect device model issues and workaround for found one. Changes from v1: - bug work around hw/isa/vt82c686.c - add assert in hw/pci/pci.c when setting/raising PCI interrupt

[PATCH v2 3/3] acpi:piix4, vt82c686: reinitialize acpi PM device on reset

2021-03-23 Thread Isaku Yamahata
Commit 6be8cf56bc8b made sure that SCI is enabled in PM1.CNT on reset in acpi_only mode by modifying acpi_pm1_cnt_reset() and that worked for q35 as expected. The function was introduced by commit eaba51c573a (acpi, acpi_piix, vt82c686: factor out PM1_CNT logic) that forgot to actually call it a

Re: [PATCH 1/4] qemu-iotests: allow passing unittest.main arguments to the test scripts

2021-03-23 Thread Paolo Bonzini
On 23/03/21 18:27, Vladimir Sementsov-Ogievskiy wrote: Sounds good :) We'll see dots appearing dynamically during test run, yes? Yes, exactly! :) Paolo

[Bug 1920784] Re: qemu-system-ppc64le fails with kvm acceleration

2021-03-23 Thread Laurent Vivier
** Also affects: linux (Ubuntu) Importance: Undecided Status: New -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1920784 Title: qemu-system-ppc64le fails with kvm acceleration Status in Q

Re: Ways to deal with broken machine types

2021-03-23 Thread Daniel P . Berrangé
On Tue, Mar 23, 2021 at 05:54:47PM +0100, Igor Mammedov wrote: > Let me hijack this thread for beyond this case scope. > > I agree that for this particular bug we've done all we could, but > there is broader issue to discuss here. > > We have machine versions to deal with hw compatibility issues

[PATCH v3 1/4] tests: Add tests for yank with the chardev-change case

2021-03-23 Thread Lukas Straub
Add tests for yank with the chardev-change case. Signed-off-by: Lukas Straub --- MAINTAINERS| 1 + tests/unit/meson.build | 3 +- tests/unit/test-yank.c | 201 + 3 files changed, 204 insertions(+), 1 deletion(-) create mode 100644 tests/un

[PATCH 0/2] yank: Always link full yank code

2021-03-23 Thread Lukas Straub
Hello Everyone, These patches remove yank's dependency on qiochannel and always link it in. Please Review. Regards, Lukas Straub Lukas Straub (2): yank: Remove dependency on qiochannel yank: Always link full yank code MAINTAINERS | 2 +- chardev/char-socket.c | 21

[PATCH v5 01/10] target/ppc: Extract post_load_update_msr

2021-03-23 Thread Richard Henderson
Extract post_load_update_msr to share between cpu_load_old and cpu_post_load in updating the msr. Suggested-by: Cédric Le Goater Signed-off-by: Richard Henderson --- target/ppc/machine.c | 30 ++ 1 file changed, 14 insertions(+), 16 deletions(-) diff --git a/target/

Re: [PATCH v2 2/3] pci: sprinkle assert in PCI pin number

2021-03-23 Thread Peter Maydell
On Tue, 23 Mar 2021 at 17:26, Isaku Yamahata wrote: > > If a device model > (a) doesn't set the value to a correct interrupt number and then > (b) triggers an interrupt for itself, > it's device model bug. Add assert on interrupt pin number to catch > this kind of bug more obviously. > > Suggested

[PATCH v5 03/10] target/ppc: Reduce env->hflags to uint32_t

2021-03-23 Thread Richard Henderson
It will be stored in tb->flags, which is also uint32_t, so let's use the correct size. Reviewed-by: Cédric Le Goater Reviewed-by: David Gibson Signed-off-by: Richard Henderson --- target/ppc/cpu.h | 4 ++-- target/ppc/misc_helper.c | 2 +- target/ppc/translate.c | 2 +- 3 files chang

[PATCH v3 2/4] chardev/char.c: Move object_property_try_add_child out of chardev_new

2021-03-23 Thread Lukas Straub
Move object_property_try_add_child out of chardev_new into it's callers. This is a preparation for the next patches to fix yank with the chardev-change case. Signed-off-by: Lukas Straub Reviewed-by: Marc-André Lureau Tested-by: Li Zhang --- chardev/char.c | 42 -

Re: [PATCH 1/2] yank: Remove dependency on qiochannel

2021-03-23 Thread Thomas Huth
On 23/03/2021 18.52, Lukas Straub wrote: Remove dependency on qiochannel by removing yank_generic_iochannel and letting migration and chardev use their own yank function for iochannel. Signed-off-by: Lukas Straub --- MAINTAINERS | 1 + chardev/char-socket.c | 21 ++

[PATCH v5 06/10] target/ppc: Put LPCR[GTSE] in hflags

2021-03-23 Thread Richard Henderson
Because this bit was not in hflags, the privilege check for tlb instructions was essentially random. Recompute hflags when storing to LPCR. Reviewed-by: David Gibson Signed-off-by: Richard Henderson --- target/ppc/cpu.h | 1 + target/ppc/helper_regs.c | 3 +++ target/ppc/mmu-hash64.c |

[PATCH v3 0/4] yank: Add chardev tests and fixes

2021-03-23 Thread Lukas Straub
Hello Everyone, These patches increase test coverage for yank, add tests and fix bugs and crashes in yank in combination with chardev-change. Please Review. Regards, Lukas Straub Changes: -v3: -Base on ([PATCH 0/2] yank: Always link full yank code) -Drop patch 1 (tests: Use the normal yank c

[PATCH v3 3/4] chardev/char.c: Always pass id to chardev_new

2021-03-23 Thread Lukas Straub
Always pass the id to chardev_new, since it is needed to register the yank instance for the chardev. Also, after checking that nothing calls chardev_new with id=NULL, assert() that id!=NULL. This fixes a crash when using chardev-change to change a chardev to chardev-socket, which attempts to regis

[PATCH v3 4/4] chardev: Fix yank with the chardev-change case

2021-03-23 Thread Lukas Straub
When changing from chardev-socket (which supports yank) to chardev-socket again, it fails, because the new chardev attempts to register a new yank instance. This in turn fails, as there still is the yank instance from the current chardev. Also, the old chardev shouldn't unregister the yank instance

Re: [PATCH 1/4] qapi/qdev.json: add DEVICE_NOT_DELETED event

2021-03-23 Thread Daniel Henrique Barboza
On 3/23/21 3:00 PM, Eric Blake wrote: On 3/12/21 2:07 PM, Daniel Henrique Barboza wrote: This new event informs QAPI listeners that a previously issued 'device_del' command failed to delete the device from the machine. Note that no assertion can be made about the failure reason. The goal of

Re: [RFC v10 00/49] arm cleanup experiment for kvm-only build

2021-03-23 Thread Alex Bennée
Claudio Fontana writes: > Here a new version of the series that enables kvm-only builds. > > The goal here is to enable the KVM-only build, but there is > some additional cleanup too. First the good news. With --disable-tcg on my AArch64 system I can successfully run: make vm-boot-ssh-ubunt

[PATCH v2 0/5] qemu-iotests: quality of life improvements

2021-03-23 Thread Paolo Bonzini
This series adds a few usability improvements to qemu-iotests, in particular: - arguments can be passed to Python unittests scripts, for example to run only a subset of the test cases (patches 1-2) - it is possible to do "./check -- ../../../tests/qemu-iotests/055 args..." and specify arbitra

[PATCH v2 2/5] qemu-iotests: allow passing unittest.main arguments to the test scripts

2021-03-23 Thread Paolo Bonzini
Python test scripts that use unittest consist of multiple tests. unittest.main allows selecting which tests to run, but currently this is not possible because the iotests wrapper ignores sys.argv. unittest.main command line options also allow the user to pick the desired options for verbosity, fai

[PATCH v2 3/5] qemu-iotests: move command line and environment handling from TestRunner to TestEnv

2021-03-23 Thread Paolo Bonzini
In the next patch, "check" will learn how to execute a test script without going through TestRunner. To enable this, keep only the text output and subprocess handling in the TestRunner; move into TestEnv the logic to prepare for running a subprocess. Reviewed-by: Vladimir Sementsov-Ogievskiy Sig

Re: [PATCH v2 2/5] qemu-iotests: allow passing unittest.main arguments to the test scripts

2021-03-23 Thread Vladimir Sementsov-Ogievskiy
23.03.2021 21:19, Paolo Bonzini wrote: Python test scripts that use unittest consist of multiple tests. unittest.main allows selecting which tests to run, but currently this is not possible because the iotests wrapper ignores sys.argv. unittest.main command line options also allow the user to pi

[PATCH v2 5/5] qemu-iotests: fix case of SOCK_DIR already in the environment

2021-03-23 Thread Paolo Bonzini
Due to a typo, in this case the SOCK_DIR was not being created. Reviewed-by: Vladimir Sementsov-Ogievskiy Signed-off-by: Paolo Bonzini --- tests/qemu-iotests/testenv.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qemu-iotests/testenv.py b/tests/qemu-iotests/testenv

Re: [PATCH for 6.0 v2 00/22] fixes for rc1 pre-PR (kernel-doc, semihosting, testing)

2021-03-23 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20210323165308.15244-1-alex.ben...@linaro.org/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20210323165308.15244-1-alex.ben...@linaro.org Subject: [PATCH for 6.0 v2 00/22] fixes

Re: [PATCH v3 1/3] exec: Rename exec-vary.c as page-vary.c

2021-03-23 Thread Philippe Mathieu-Daudé
On 3/23/21 5:15 PM, Richard Henderson wrote: > exec-vary.c is about variable page size handling, > rename it page-vary.c. Currently this file is target > specific (built once for each target), comment this. > > Signed-off-by: Philippe Mathieu-Daudé > Message-Id: <20210322112427.4045204-2-f4...@am

[PATCH v2 1/5] qemu-iotests: do not buffer the test output

2021-03-23 Thread Paolo Bonzini
Instead of buffering the test output into a StringIO, patch it on the fly by wrapping sys.stdout's write method. This can be done unconditionally, even if using -d, which makes execute_unittest a bit simpler. Signed-off-by: Paolo Bonzini --- tests/qemu-iotests/iotests.py | 68 ++

Re: [PATCH 0/2] yank: Always link full yank code

2021-03-23 Thread Daniel P . Berrangé
On Tue, Mar 23, 2021 at 06:52:19PM +0100, Lukas Straub wrote: > Hello Everyone, > These patches remove yank's dependency on qiochannel and always link it in. > Please Review. It would be useful if the cover letter or commit messages explained to potential reviewers why this is being changed... The

[PATCH v5 10/10] target/ppc: Validate hflags with CONFIG_DEBUG_TCG

2021-03-23 Thread Richard Henderson
Verify that hflags was updated correctly whenever we change cpu state that is used by hflags. Signed-off-by: Richard Henderson --- target/ppc/cpu.h | 5 + target/ppc/helper_regs.c | 29 +++-- 2 files changed, 32 insertions(+), 2 deletions(-) diff --git a/tar

Re: [PATCH v3 2/3] exec: Extract 'page-vary.h' header

2021-03-23 Thread Philippe Mathieu-Daudé
On 3/23/21 5:16 PM, Richard Henderson wrote: > In the next commit we will extract the generic code out of > page-vary.c, only keeping the target specific code. Both > files will use the same TargetPageBits structure, so make > its declaration in a shared header. > > As the common header can not us

[PATCH] hw/usb/hcd-ehci-sysbus: Free USBPacket on instance finalize()

2021-03-23 Thread Philippe Mathieu-Daudé
When building with --enable-sanitizers we get: Direct leak of 32 byte(s) in 2 object(s) allocated from: #0 0x5618479ec7cf in malloc (qemu-system-aarch64+0x233b7cf) #1 0x7f675745f958 in g_malloc (/lib64/libglib-2.0.so.0+0x58958) #2 0x561847f02ca2 in usb_packet_init hw/usb/core.c

Re: [PATCH v2 1/3] vt82c686.c: don't raise SCI when PCI_INTERRUPT_PIN isn't setup

2021-03-23 Thread Philippe Mathieu-Daudé
Hi Isaku, On 3/23/21 6:24 PM, Isaku Yamahata wrote: > Without this patch, the following patch will triger clan runtime > sanitizer warnings as follows. This patch proactively works around it. > I let v582c686.c maintainer address a correct fix as I'm not sure > about fuloong2e device model. > >>

[PATCH] hw/display/xlnx_dp: Free FIFOs adding xlnx_dp_finalize()

2021-03-23 Thread Philippe Mathieu-Daudé
When building with --enable-sanitizers we get: Direct leak of 16 byte(s) in 1 object(s) allocated from: #0 0x5618479ec7cf in malloc (qemu-system-aarch64+0x233b7cf) #1 0x7f675745f958 in g_malloc (/lib64/libglib-2.0.so.0+0x58958) #2 0x561847c2dcc9 in xlnx_dp_init hw/display/xlnx_

[PATCH v5 02/10] target/ppc: Disconnect hflags from MSR

2021-03-23 Thread Richard Henderson
Copying flags directly from msr has drawbacks: (1) msr bits mean different things per cpu, (2) msr has 64 bits on 64 cpus while tb->flags has only 32 bits. Create a enum to define these bits. Document the origin of each bit and validate those bits that must match MSR. This fixes the truncation o

Re: [PATCH v2 4/5] qemu-iotests: let "check" spawn an arbitrary test command

2021-03-23 Thread Vladimir Sementsov-Ogievskiy
23.03.2021 21:19, Paolo Bonzini wrote: Right now there is no easy way for "check" to print a reproducer command. Because such a reproducer command line would be huge, we can instead teach check to start a command of our choice. This can be for example a Python unit test with arguments to only ru

Re: [RFC v10 00/49] arm cleanup experiment for kvm-only build

2021-03-23 Thread Claudio Fontana
Hi Alex, thanks a lot for looking at this, On 3/23/21 7:35 PM, Alex Bennée wrote: > > Claudio Fontana writes: > >> Here a new version of the series that enables kvm-only builds. >> >> The goal here is to enable the KVM-only build, but there is >> some additional cleanup too. > > First the goo

Re: [PATCH v2 2/5] qemu-iotests: allow passing unittest.main arguments to the test scripts

2021-03-23 Thread Vladimir Sementsov-Ogievskiy
23.03.2021 21:19, Paolo Bonzini wrote: Python test scripts that use unittest consist of multiple tests. unittest.main allows selecting which tests to run, but currently this is not possible because the iotests wrapper ignores sys.argv. unittest.main command line options also allow the user to pi

[PATCH v5 05/10] target/ppc: Create helper_scv

2021-03-23 Thread Richard Henderson
Perform the test against FSCR_SCV at runtime, in the helper. This means we can remove the incorrect set against SCV in ppc_tr_init_disas_context and do not need to add an HFLAGS bit. Signed-off-by: Richard Henderson --- target/ppc/helper.h | 1 + target/ppc/excp_helper.c | 9 + t

Re: [PATCH v1 1/3] migration: Fix missing qemu_fflush() on buffer file in bg_migration_thread

2021-03-23 Thread Peter Xu
On Tue, Mar 23, 2021 at 08:21:43PM +0300, Andrey Gruzdev wrote: > > For the long term I think we'd better have a helper: > > > > qemu_put_qio_channel_buffer(QEMUFile *file, QIOChannelBuffer *bioc) > > > > So as to hide this flush operation, which is tricky. We'll have two users so > > fa

[PATCH v5 08/10] target/ppc: Remove env->immu_idx and env->dmmu_idx

2021-03-23 Thread Richard Henderson
We weren't recording MSR_GS in hflags, which means that BookE memory accesses were essentially random vs Guest State. Instead of adding this bit directly, record the completed mmu indexes instead. This makes it obvious that we are recording exactly the information that we need. This also means t

Re: [RFC v10 39/49] target/arm: add tcg cpu accel class

2021-03-23 Thread Alex Bennée
Claudio Fontana writes: > move init, realizefn and reset code into it. w.r.t my testing this is fingered by bisect for causing: Running test qtest-aarch64/migration-test ERROR qtest-aarch64/migration-test - Bail out! ERROR:../../target/arm/tcg/tcg-cpu.c:233:tcg_arm_init_accel_cpu: assert

[PATCH v5 00/10] target/ppc: Fix truncation of env->hflags

2021-03-23 Thread Richard Henderson
Changes for v5: * Rebase on david's ppc-for-6.0 branch (fcc83aa7359d) * Extract post_load_update_msr (clg) * Validate MSR_FOO == HFLAGS_FOO when necessary (david) Changes for v4: * Use hregs_recompute_hflags for hw/ppc/ reset. -- Incorporate Cedric's feedback. Changes for v3: * Fixes for

[PATCH v5 09/10] linux-user/ppc: Fix msr updates for signal handling

2021-03-23 Thread Richard Henderson
In save_user_regs, there are two bugs where we OR in a bit number instead of the bit, clobbering the low bits of MSR. However: The MSR_VR and MSR_SPE bits control the availability of the insns. If the bits were not already set in MSR, then any attempt to access those registers would result in SIG

Re: [RFC v1 0/5] s390x cleanup

2021-03-23 Thread Claudio Fontana
On 3/22/21 8:15 PM, Claudio Fontana wrote: > Hi, I am starting a cleanup series for s390x, > > with the goal of doing similar splits of KVM vs TCG, One annoying thing is that it appears that the cpu accel model does not offer much in terms of refactoring and code simplification opportunities fo

[PATCH v5 04/10] target/ppc: Put dbcr0 single-step bits into hflags

2021-03-23 Thread Richard Henderson
Because these bits were not in hflags, the code generated for single-stepping on BookE was essentially random. Recompute hflags when storing to dbcr0. Reviewed-by: David Gibson Signed-off-by: Richard Henderson --- target/ppc/helper_regs.c | 24 +--- target/ppc/misc_helper.c

Re: [PATCH] i386/acpi: restore device paths for pre-5.1 vms

2021-03-23 Thread Michael S. Tsirkin
On Tue, Mar 23, 2021 at 04:04:11PM +0100, Thomas Lamprecht wrote: > On 23.03.21 15:55, Vitaly Cheptsov wrote: > >> 23 марта 2021 г., в 17:48, Michael S. Tsirkin написал(а): > >> > >> The issue is with people who installed a VM using 5.1 qemu, > >> migrated to 5.2, booted there and set a config on

Re: [PATCH v2 1/5] qemu-iotests: do not buffer the test output

2021-03-23 Thread Vladimir Sementsov-Ogievskiy
23.03.2021 21:19, Paolo Bonzini wrote: Instead of buffering the test output into a StringIO, patch it on the fly by wrapping sys.stdout's write method. This can be done unconditionally, even if using -d, which makes execute_unittest a bit simpler. Signed-off-by: Paolo Bonzini Reviewed-by: Vl

[PATCH v5 07/10] target/ppc: Remove MSR_SA and MSR_AP from hflags

2021-03-23 Thread Richard Henderson
Nothing within the translator -- or anywhere else for that matter -- checks MSR_SA or MSR_AP on the 602. This may be a mistake. However, for the moment, we need not record these bits in hflags. This allows us to simplify HFLAGS_VSX computation by moving it to overlap with MSR_VSX. Reviewed-by:

Re: [PATCH] tests/migration: fix parameter of auto-converge migration

2021-03-23 Thread Dr. David Alan Gilbert
* huang...@chinatelecom.cn (huang...@chinatelecom.cn) wrote: > From: Hyman Huang(黄勇) > > when execute the following test command: > $ ./guestperf-batch.py --auto-converge \ > --auto-converge-step {percent} ... > test aborts and error message be throwed as the following: > "Parameter 'x-cpu-th

Re: Ways to deal with broken machine types

2021-03-23 Thread Michael S. Tsirkin
On Tue, Mar 23, 2021 at 05:40:36PM +, Daniel P. Berrangé wrote: > On Tue, Mar 23, 2021 at 05:54:47PM +0100, Igor Mammedov wrote: > > Let me hijack this thread for beyond this case scope. > > > > I agree that for this particular bug we've done all we could, but > > there is broader issue to dis

Re: [PATCH v2 3/3] acpi:piix4, vt82c686: reinitialize acpi PM device on reset

2021-03-23 Thread Michael S. Tsirkin
On Tue, Mar 23, 2021 at 10:24:31AM -0700, Isaku Yamahata wrote: > Commit 6be8cf56bc8b made sure that SCI is enabled in PM1.CNT > on reset in acpi_only mode by modifying acpi_pm1_cnt_reset() and > that worked for q35 as expected. > > The function was introduced by commit > eaba51c573a (acpi, acpi

<    1   2   3   4   5   6   >