Re: [PATCH 05/38] target/riscv: 8-bit Addition & Subtraction Instruction

2021-05-25 Thread Palmer Dabbelt
On Tue, 25 May 2021 22:43:27 PDT (-0700), zhiwei_...@c-sky.com wrote: On 5/24/21 9:00 AM, Palmer Dabbelt wrote: On Mon, 15 Mar 2021 14:22:58 PDT (-0700), alistai...@gmail.com wrote: On Fri, Feb 12, 2021 at 10:14 AM LIU Zhiwei wrote: Signed-off-by: LIU Zhiwei Acked-by: Alistair Francis

Re: [PATCH v6 03/13] virtio-gpu: Add udmabuf helpers

2021-05-25 Thread Gerd Hoffmann
Hi, > +#ifdef CONFIG_LINUX Seems wee need "#if defined(CONFIG_LINUX) && defined(F_GET_SEALS)" here to cover old linux versions. I see some build failures in gitlab CI due to F_GET_SEALS not being defined (crypto-old-nettle for example). > +#include gitlab ci (build-system-alpine): /usr/inc

Re: [PATCH] gitignore: Update with some filetypes

2021-05-25 Thread Viresh Kumar
On 24-03-21, 16:33, Viresh Kumar wrote: > Update .gitignore to ignore .swp and .patch files. > > Signed-off-by: Viresh Kumar > --- > .gitignore | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/.gitignore b/.gitignore > index 75a4be07240f..eb2553026c5e 100644 > --- a/.gitignore > +++ b

[Bug 1878067] Re: Assertion failure in eth_get_gso_type through the e1000e

2021-05-25 Thread Thomas Huth
Ok, thanks for checking! So let's close this ticket now. ** Changed in: qemu Status: Incomplete => Fix Released -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1878067 Title: Assertion failur

[Bug 1878034] Re: memcpy param-overlap through e1000e_write_to_rx_buffers

2021-05-25 Thread Thomas Huth
Ok, confirmed, with that new reproducer it also detects the error here when I compile QEMU with Clang and ASAN enabled. ** Changed in: qemu Status: Incomplete => Confirmed -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https:

Re: [PATCH 05/38] target/riscv: 8-bit Addition & Subtraction Instruction

2021-05-25 Thread LIU Zhiwei
On 5/24/21 9:00 AM, Palmer Dabbelt wrote: On Mon, 15 Mar 2021 14:22:58 PDT (-0700), alistai...@gmail.com wrote: On Fri, Feb 12, 2021 at 10:14 AM LIU Zhiwei wrote: Signed-off-by: LIU Zhiwei Acked-by: Alistair Francis I saw some reviews on the other ones, but since others (like this) j

Re: [RFC PATCH v4 0/7] Use ACPI PCI hot-plug for Q35

2021-05-25 Thread Michael S. Tsirkin
On Thu, May 13, 2021 at 08:26:35AM +0200, Julia Suvorova wrote: > The patch set consists of two parts: > patches 1-4: introduce new feature > 'acpi-pci-hotplug-with-bridge-support' on Q35 > patches 5-7: make the feature default along with changes in ACPI tables > > This way maintainer

Re: [PATCH 08/38] target/riscv: SIMD 16-bit Compare Instructions

2021-05-25 Thread Palmer Dabbelt
On Tue, 25 May 2021 22:30:14 PDT (-0700), Palmer Dabbelt wrote: On Fri, 12 Feb 2021 07:02:26 PST (-0800), zhiwei_...@c-sky.com wrote: Signed-off-by: LIU Zhiwei --- target/riscv/helper.h | 6 target/riscv/insn32.decode | 6 target/riscv/insn_trans/tran

Re: [PATCH 08/38] target/riscv: SIMD 16-bit Compare Instructions

2021-05-25 Thread Palmer Dabbelt
On Fri, 12 Feb 2021 07:02:26 PST (-0800), zhiwei_...@c-sky.com wrote: Signed-off-by: LIU Zhiwei --- target/riscv/helper.h | 6 target/riscv/insn32.decode | 6 target/riscv/insn_trans/trans_rvp.c.inc | 7 target/riscv/packed_helper.c|

[PATCH] linux-user: Remove unnecessary static assert involving __SIGRTMAX

2021-05-25 Thread Michael Forney
Since "linux-user: fix use of SIGRTMIN" (6bc024e7), qemu removed use of __SIGRTMAX except for in this QEMU_BUILD_BUG_ON assert. Presumably, this check is to ensure that the loop in signal_table_init from SIGRTMIN to SIGRTMAX falls within the bounds of host_to_target_signal_table (_NSIG). However,

[PATCH] linux-user: Use public sigev_notify_thread_id member if available

2021-05-25 Thread Michael Forney
_sigev_un._tid is an internal glibc field and is not available on musl libc. The sigevent(7) man page and Linux UAPI headers both use sigev_notify_thread_id as a public way to access this field. musl libc supports this field since 1.2.2[0], and glibc plans to add support as well[1][2]. If sigev_n

[PATCH] linux-user: Fix incorrect use of feature-test-macros

2021-05-25 Thread Michael Forney
The _POSIX_C_SOURCE and _XOPEN_SOURCE macros are used by the application to indicate to libc which declarations it should expose. Since qemu does not define them anywhere, it does not make sense to check their value. Instead, since the intent is to determine whether the host struct stat supports t

[RFC PATCH v4] ppc/spapr: Add support for H_SCM_PERFORMANCE_STATS hcall

2021-05-25 Thread Vaibhav Jain
Add support for H_SCM_PERFORMANCE_STATS described at [1] for spapr nvdimms. This enables guest to fetch performance stats[2] like expected life of an nvdimm ('MemLife ') etc and display them to the user. Linux kernel support for fetching these performance stats and exposing them to the user-space w

[PATCH V7 4/6] net/colo-compare: Move data structure and define to .h file.

2021-05-25 Thread Zhang Chen
Rename structure with COLO index and move it to .h file, It make other modules can reuse COLO code. Signed-off-by: Zhang Chen --- net/colo-compare.c | 132 - net/colo-compare.h | 86 + 2 files changed, 109 insertions(+), 10

[PATCH V7 2/6] util/qemu-sockets.c: Add inet_parse_base to handle InetSocketAddressBase

2021-05-25 Thread Zhang Chen
No need to carry the flag all the time in many scenarios. Signed-off-by: Zhang Chen --- include/qemu/sockets.h | 1 + util/qemu-sockets.c| 14 ++ 2 files changed, 15 insertions(+) diff --git a/include/qemu/sockets.h b/include/qemu/sockets.h index 7d1f813576..d5abc227eb 100644 -

[PATCH V7 6/6] net/net.c: Add handler for COLO passthrough connection

2021-05-25 Thread Zhang Chen
Use connection protocol,src port,dst port,src ip,dst ip as the key to bypass certain network traffic in COLO compare. Signed-off-by: Zhang Chen --- net/net.c | 162 +- 1 file changed, 160 insertions(+), 2 deletions(-) diff --git a/net/net.c b/

[PATCH V7 3/6] hmp-commands: Add new HMP command for COLO passthrough

2021-05-25 Thread Zhang Chen
Add hmp_colo_passthrough_add and hmp_colo_passthrough_del make user can maintain COLO network passthrough list in human monitor Signed-off-by: Zhang Chen --- hmp-commands.hx | 26 ++ include/monitor/hmp.h | 2 ++ monitor/hmp-cmds.c| 82 +

[PATCH V7 5/6] net/colo-compare: Add passthrough list to CompareState

2021-05-25 Thread Zhang Chen
Add passthrough list for each CompareState. Signed-off-by: Zhang Chen --- net/colo-compare.c | 28 net/colo-compare.h | 12 2 files changed, 40 insertions(+) diff --git a/net/colo-compare.c b/net/colo-compare.c index 8175612c5f..2250efd40d 100644 --- a/

[PATCH V7 1/6] qapi/net: Add IPFlowSpec and QMP command for COLO passthrough

2021-05-25 Thread Zhang Chen
Since the real user scenario does not need COLO to monitor all traffic. Add colo-passthrough-add and colo-passthrough-del to maintain a COLO network passthrough list. Add IPFlowSpec struct for all QMP commands. Except protocol field is necessary, other fields are optional. Signed-off-by: Zhang Che

[PATCH V7 0/6] Passthrough specific network traffic in COLO

2021-05-25 Thread Zhang Chen
Due to some real user scenarios don't need to monitor all traffic. And qemu net-filter also need function to more detailed flow control. This series give user ability to passthrough kinds of COLO network stream. For example, windows guest user want to enable windows remote desktop to touch guest(U

Re: proposed schedule for 6.1 release

2021-05-25 Thread Richard Henderson
On 5/24/21 5:27 AM, Peter Maydell wrote: Here's a draft schedule for the 6.1 cycle: 2021-07-13 Soft feature freeze. Only bug fixes after this point. 2021-07-20 Hard feature freeze. Tag rc0 2021-07-27 Tag rc1 2021-08-03 Tag rc2 2021-08-10 Tag rc3 2021-08-17 Release; or tag rc4 if needed 2021-08-2

Re: [PATCH v7 13/23] cpu: Move AVR target vmsd field from CPUClass to DeviceClass

2021-05-25 Thread Richard Henderson
On 5/17/21 3:51 AM, Philippe Mathieu-Daudé wrote: See rationale in previous commit. Targets should use the vmsd field of DeviceClass, not CPUClass. As migration is not important on the AVR target, break the migration compatibility and set the DeviceClass vmsd field. To feel safer, increment the v

Re: [PATCH v7 05/23] cpu: Split as cpu-common / cpu-sysemu

2021-05-25 Thread Richard Henderson
On 5/17/21 3:51 AM, Philippe Mathieu-Daudé wrote: The current cpu.c contains sysemu-specific methods. To avoid building them in user-mode builds, split the current cpu.c as cpu-common.c / cpu-sysemu.c. Start by moving cpu_get_crash_info(). Signed-off-by: Philippe Mathieu-Daudé --- hw/core/{cp

Re: [PATCH v7 02/23] cpu: Restrict target cpu_do_transaction_failed() handlers to sysemu

2021-05-25 Thread Richard Henderson
On 5/17/21 3:51 AM, Philippe Mathieu-Daudé wrote: In commit cbc183d2d9f ("cpu: move cc->transaction_failed to tcg_ops") we restricted the do_transaction_failed() handler to the sysemu part of TCGCPUOps, but forgot to restrict the target specific declarations. Signed-off-by: Philippe Mathieu-Daud

Re: [PATCH v7 04/23] cpu: Remove duplicated 'sysemu/hw_accel.h' header

2021-05-25 Thread Richard Henderson
On 5/17/21 3:51 AM, Philippe Mathieu-Daudé wrote: Signed-off-by: Philippe Mathieu-Daudé --- hw/core/cpu.c | 1 - 1 file changed, 1 deletion(-) Reviewed-by: Richard Henderson r~

Re: [PATCH 2/5] linux-uesr: make exec_path realpath

2021-05-25 Thread Takashi Yamamoto
On Tue, May 25, 2021 at 7:59 AM Takashi Yamamoto wrote: > > On Mon, May 24, 2021 at 7:59 PM Alex Bennée wrote: > > > > > > YAMAMOTO Takashi writes: > > > > > Otherwise, it can be easily fooled by the user app using chdir(). > > > > > > Signed-off-by: YAMAMOTO Takashi > > > --- > > > linux-user

Re: [RFC v3 13/29] vhost: Add vhost_get_iova_range operation

2021-05-25 Thread Jason Wang
在 2021/5/20 上午12:28, Eugenio Pérez 写道: For simplicity, If a device does not support this operation it means that it can handle full (uint64_t)-1 iova address. Note that, we probably need a separated patch for this. And we need to this during vhost-vdpa initialization. If GPA is out of the

[RFC PATCH] linux-user/sparc: Implement v8plus signals

2021-05-25 Thread Richard Henderson
Sparc v8plus is a sparc64 running a 32-bit ABI. The significant difference vs sparc32 is that all 64 bits of the %g and %o registers, plus %xcc, are saved across interrupts, context switches, and signals. There's a special marker in the saved %psr value that's used to indicate that %xcc and the hi

Re: [RFC v3 06/29] virtio-net: Honor VIRTIO_CONFIG_S_DEVICE_STOPPED

2021-05-25 Thread Jason Wang
在 2021/5/26 上午9:06, Jason Wang 写道: 在 2021/5/20 上午12:28, Eugenio Pérez 写道: So the guest can stop and start net device. It implements the RFC https://lists.oasis-open.org/archives/virtio-comment/202012/msg00027.html To stop (as "pause") the device is required to migrate status and vring add

Re: [RFC v3 06/29] virtio-net: Honor VIRTIO_CONFIG_S_DEVICE_STOPPED

2021-05-25 Thread Jason Wang
在 2021/5/20 上午12:28, Eugenio Pérez 写道: So the guest can stop and start net device. It implements the RFC https://lists.oasis-open.org/archives/virtio-comment/202012/msg00027.html To stop (as "pause") the device is required to migrate status and vring addresses between device and SVQ. This is

[PATCH] .mailmap: Update my email address

2021-05-25 Thread Finn Thain
Signed-off-by: Finn Thain --- .mailmap | 1 + 1 file changed, 1 insertion(+) diff --git a/.mailmap b/.mailmap index a1bd659817..772f3e16cf 100644 --- a/.mailmap +++ b/.mailmap @@ -91,6 +91,7 @@ Erik Smit Fabrice Desclaux Fernando Luis Vázquez Cao Fernando Luis Vázquez Cao +Finn Thain

Re: [PATCH 5/5] linux-user: Implement pivot_root

2021-05-25 Thread Takashi Yamamoto
On Wed, May 26, 2021 at 5:22 AM Laurent Vivier wrote: > > Le 24/05/2021 à 06:54, YAMAMOTO Takashi a écrit : > > Used by runc. > > > > Signed-off-by: YAMAMOTO Takashi > > --- > > linux-user/syscall.c | 23 +++ > > 1 file changed, 23 insertions(+) > > > > diff --git a/linux-use

[PATCH v7 29/31] python: add .gitignore

2021-05-25 Thread John Snow
Ignore *Python* build and package output (build, dist, qemu.egg-info); these files are not created as part of a QEMU build. They are created by running the commands 'python3 setup.py ' when preparing tarballs to upload to e.g. PyPI. Ignore miscellaneous cached python confetti (mypy, pylint, et al)

[PATCH v7 30/31] python: add tox support

2021-05-25 Thread John Snow
This is intended to be a manually run, non-CI script. Use tox to test the linters against all python versions from 3.6 to 3.10. This will only work if you actually have those versions installed locally, but Fedora makes this easy: > sudo dnf install python3.6 python3.7 python3.8 python3.9 python3

[PATCH v7 28/31] python: add Makefile for some common tasks

2021-05-25 Thread John Snow
Add "make venv" to create the pipenv-managed virtual environment that contains our explicitly pinned dependencies. Add "make check" to run the python linters [in the host execution environment]. Add "make venv-check" which combines the above two: create/update the venv, then run the linters in th

[PATCH v7 26/31] python: add devel package requirements to setuptools

2021-05-25 Thread John Snow
setuptools doesn't have a formal understanding of development requires, but it has an optional feataures section. Fine; add a "devel" feature and add the requirements to it. To avoid duplication, we can modify pipenv to install qemu[devel] instead. This enables us to run invocations like "pip inst

[PATCH v7 27/31] python: add avocado-framework and tests

2021-05-25 Thread John Snow
Try using avocado to manage our various tests; even though right now they're only invoking shell scripts and not really running any python-native code. Create tests/, and add shell scripts which call out to mypy, flake8, pylint and isort to enforce the standards in this directory. Add avocado-fra

[PATCH v7 22/31] python: add mypy to pipenv

2021-05-25 Thread John Snow
0.730 appears to be about the oldest version that works with the features we want, including nice human readable output (to make sure iotest 297 passes), and type-parameterized Popen generics. 0.770, however, supports adding 'strict' to the config file, so require at least 0.770. Now that we are

[PATCH v7 31/31] gitlab: add python linters to CI

2021-05-25 Thread John Snow
Add a python container that contains just enough juice for us to run the python code quality analysis tools. Base this container on fedora, because fedora has very convenient packaging for testing multiple python versions. Add two tests: check-python-pipenv uses pipenv to test a frozen, very exp

[PATCH v7 25/31] python/qemu: add qemu package itself to pipenv

2021-05-25 Thread John Snow
This adds the python qemu packages themselves to the pipenv manifest. 'pipenv sync' will create a virtual environment sufficient to use the SDK. 'pipenv sync --dev' will create a virtual environment sufficient to use and test the SDK (with pylint, mypy, isort, flake8, etc.) The qemu packages are i

[PATCH v7 24/31] python/qemu: add isort to pipenv

2021-05-25 Thread John Snow
isort 5.0.0 through 5.0.4 has a bug that causes it to misinterpret certain "from ..." clauses that are not related to imports. isort < 5.1.1 has a bug where it does not handle comments near import statements correctly. Require 5.1.2 or greater. isort can be run (in "check" mode) with 'isort -c q

[PATCH v7 19/31] python: add excluded dirs to flake8 config

2021-05-25 Thread John Snow
Instruct flake8 to avoid certain well-known directories created by python tooling that it ought not check. Note that at-present, nothing actually creates a ".venv" directory; but it is in such widespread usage as a de-facto location for a developer's virtual environment that it should be excluded

[PATCH v7 23/31] python: move .isort.cfg into setup.cfg

2021-05-25 Thread John Snow
Signed-off-by: John Snow Reviewed-by: Cleber Rosa --- python/.isort.cfg | 7 --- python/setup.cfg | 8 2 files changed, 8 insertions(+), 7 deletions(-) delete mode 100644 python/.isort.cfg diff --git a/python/.isort.cfg b/python/.isort.cfg deleted file mode 100644 index 6d0fd6cc0

[PATCH v7 20/31] python: Add flake8 to pipenv

2021-05-25 Thread John Snow
flake8 3.5.x does not support the --extend-ignore syntax used in the .flake8 file to gracefully extend default ignores, so 3.6.x is our minimum requirement. There is no known upper bound. flake8 can be run from the python/ directory with no arguments. Signed-off-by: John Snow Reviewed-by: Cleber

[PATCH v7 18/31] python: move flake8 config to setup.cfg

2021-05-25 Thread John Snow
Update the comment concerning the flake8 exception to match commit 42c0dd12, whose commit message stated: A note on the flake8 exception: flake8 will warn on *any* bare except, but pylint's is context-aware and will suppress the warning if you re-raise the exception. Signed-off-by: John Snow Rev

[PATCH v7 21/31] python: move mypy.ini into setup.cfg

2021-05-25 Thread John Snow
mypy supports reading its configuration values from a central project configuration file; do so. Signed-off-by: John Snow Reviewed-by: Cleber Rosa --- python/mypy.ini | 4 python/setup.cfg | 5 + 2 files changed, 5 insertions(+), 4 deletions(-) delete mode 100644 python/mypy.ini dif

[PATCH v7 17/31] python: add pylint to pipenv

2021-05-25 Thread John Snow
We are specifying >= pylint 2.8.x for several reasons: 1. For setup.cfg support, added in pylint 2.5.x 2. To specify a version that has incompatibly dropped bad-whitespace checks (2.6.x) 3. 2.7.x fixes "unsubscriptable" warnings in Python 3.9 4. 2.8.x adds a new, incompatible 'consider-using-wi

[PATCH v7 15/31] python: add pylint import exceptions

2021-05-25 Thread John Snow
Pylint 2.5.x - 2.7.x have regressions that make import checking inconsistent, see: https://github.com/PyCQA/pylint/issues/3609 https://github.com/PyCQA/pylint/issues/3624 https://github.com/PyCQA/pylint/issues/3651 Pinning to 2.4.4 is worse, because it mandates versions of shared dependencies tha

[PATCH v7 13/31] python: add MANIFEST.in

2021-05-25 Thread John Snow
When creating a source or binary distribution via 'python3 setup.py ', the VERSION and PACKAGE.rst files aren't bundled by default. Create a MANIFEST.in file that instructs the build tools to include these so that installation from these files won't fail. This is required by 'tox', as well as by t

[PATCH v7 16/31] python: move pylintrc into setup.cfg

2021-05-25 Thread John Snow
Delete the empty settings now that it's sharing a home with settings for other tools. pylint can now be run from this folder as "pylint qemu". Signed-off-by: John Snow Reviewed-by: Cleber Rosa Tested-by: Cleber Rosa --- python/qemu/machine/pylintrc | 58 p

[PATCH v7 10/31] python: add qemu package installer

2021-05-25 Thread John Snow
Add setup.cfg and setup.py, necessary for installing a package via pip. Add a ReST document (PACKAGE.rst) explaining the basics of what this package is for and who to contact for more information. This document will be used as the landing page for the package on PyPI. List the subpackages we inten

[PATCH v7 06/31] python/machine: disable warning for Popen in _launch()

2021-05-25 Thread John Snow
We handle this resource rather meticulously in shutdown/kill/wait/__exit__ et al, through the laborious mechanisms in _do_shutdown(). Quiet this pylint warning here. Signed-off-by: John Snow Reviewed-by: Cleber Rosa Message-id: 20210517184808.3562549-7-js...@redhat.com Signed-off-by: John Snow

[PATCH v7 14/31] python: Add pipenv support

2021-05-25 Thread John Snow
pipenv is a tool used for managing virtual environments with pinned, explicit dependencies. It is used for precisely recreating python virtual environments. pipenv uses two files to do this: (1) Pipfile, which is similar in purpose and scope to what setup.cfg lists. It specifies the requisite min

[PATCH v7 05/31] python/machine: Disable pylint warning for open() in _pre_launch

2021-05-25 Thread John Snow
Shift the open() call later so that the pylint pragma applies *only* to that one open() call. Add a note that suggests why this is safe: the resource is unconditionally cleaned up in _post_shutdown(). _post_shutdown is called after failed launches (see launch()), and unconditionally after every ca

[PATCH v7 12/31] python: add directory structure README.rst files

2021-05-25 Thread John Snow
Add short readmes to python/, python/qemu/, python/qemu/machine, python/qemu/qmp, and python/qemu/utils that explain the directory hierarchy. These readmes are visible when browsing the source on e.g. gitlab/github and are designed to help new developers/users quickly make sense of the source tree.

[PATCH v7 02/31] python/machine: use subprocess.DEVNULL instead of open(os.path.devnull)

2021-05-25 Thread John Snow
One less file resource to manage, and it helps quiet some pylint >= 2.8.0 warnings about not using a with-context manager for the open call. Signed-off-by: John Snow Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Cleber Rosa Message-id: 20210517184808.3562549-3-js...@redhat.com Signed-off-by:

[PATCH v7 11/31] python: add VERSION file

2021-05-25 Thread John Snow
Python infrastructure as it exists today is not capable reliably of single-sourcing a package version from a parent directory. The authors of pip are working to correct this, but as of today this is not possible. The problem is that when using pip to build and install a python package, it copies f

[PATCH v7 04/31] python/console_socket: Add a pylint ignore

2021-05-25 Thread John Snow
We manage cleaning up this resource ourselves. Pylint should shush. Signed-off-by: John Snow Reviewed-by: Cleber Rosa Message-id: 20210517184808.3562549-5-js...@redhat.com Signed-off-by: John Snow --- python/qemu/console_socket.py | 1 + 1 file changed, 1 insertion(+) diff --git a/python/qemu

[PATCH v7 09/31] python: create qemu packages

2021-05-25 Thread John Snow
move python/qemu/*.py to python/qemu/[machine, qmp, utils]/*.py and update import directives across the tree. This is done to create a PEP420 namespace package, in which we may create subpackages. To do this, the namespace directory ("qemu") should not have any modules in it. Those files will go i

[PATCH v7 01/31] python/console_socket: avoid one-letter variable

2021-05-25 Thread John Snow
Fixes pylint warnings. Signed-off-by: John Snow Reviewed-by: Cleber Rosa Reviewed-by: Philippe Mathieu-Daudé Message-id: 20210517184808.3562549-2-js...@redhat.com Signed-off-by: John Snow --- python/qemu/console_socket.py | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff

[PATCH v7 07/31] python/machine: Trim line length to below 80 chars

2021-05-25 Thread John Snow
One more little delinting fix that snuck in. Signed-off-by: John Snow --- python/qemu/machine.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/qemu/machine.py b/python/qemu/machine.py index 5d72c4ca369..a8837b36e47 100644 --- a/python/qemu/machine.py +++ b/python/qem

[PATCH v7 03/31] python/machine: use subprocess.run instead of subprocess.Popen

2021-05-25 Thread John Snow
use run() instead of Popen() -- to assert to pylint that we are not forgetting to close a long-running program. Signed-off-by: John Snow Reviewed-by: Cleber Rosa Tested-by: Cleber Rosa Message-id: 20210517184808.3562549-4-js...@redhat.com Signed-off-by: John Snow --- python/qemu/machine.py |

[PATCH v7 08/31] iotests/297: add --namespace-packages to mypy arguments

2021-05-25 Thread John Snow
mypy is kind of weird about how it handles imports. For legacy reasons, it won't load PEP 420 namespaces, because of logic implemented prior to that becoming a standard. So, if you plan on using any, you have to pass --namespace-packages. Alright, fine. Signed-off-by: John Snow Reviewed-by: Cleb

[PATCH v7 00/31] python: create installable package

2021-05-25 Thread John Snow
Based-on: https://gitlab.com/cleber.gnu/qemu/-/commits/python-next CI: https://gitlab.com/jsnow/qemu/-/pipelines/309506648 GitLab: https://gitlab.com/jsnow/qemu/-/tree/python-package-mk4 MR: https://gitlab.com/jsnow/qemu/-/merge_requests/7 ABOUT = This series factors the python/qemu directory

Re: [PATCH] tcg/aarch64/tcg-target.c.inc: correction of rotate bit number

2021-05-25 Thread Richard Henderson
On 5/25/21 2:46 AM, Yasuo Kuwahara wrote: The last argument of tcg_out_extr() must be in the range 0-31 if ext==0. Before the fix, when m==0 it becomes 32 and it crashes with an Illegal instruction in Apple Silicon. After the fix, it will be 0. If m is in the range 1-31, it is the same as be

Re: [PATCH v6 23/25] python: add .gitignore

2021-05-25 Thread John Snow
On 5/25/21 4:42 PM, Cleber Rosa wrote: On Tue, May 25, 2021 at 04:10:55PM -0400, John Snow wrote: On 5/25/21 3:36 PM, Cleber Rosa wrote: On Wed, May 12, 2021 at 07:12:39PM -0400, John Snow wrote: Ignore *Python* build and package output (build, dist, qemu.egg-info); these files are not created

Re: [RFC PATCH] configure: Do not add --warn-common to the linker flags anymore

2021-05-25 Thread Richard Henderson
On 5/25/21 4:11 AM, Thomas Huth wrote: We are compiling with -fno-common since commit 4c288acbd6 ("configure: Always build with -fno-common"), so --warn-common (which had been added in commit 49237acdb725e in 2008 already) should not be necessary anymore nowadays. Signed-off-by: Thomas Huth ---

Re: [PATCH 2/3] meson: List if X11 dependency is detected

2021-05-25 Thread Richard Henderson
On 5/25/21 3:46 AM, Philippe Mathieu-Daudé wrote: It is sometimes useful to know if X11 is detected. Signed-off-by: Philippe Mathieu-Daudé --- meson.build | 1 + 1 file changed, 1 insertion(+) Reviewed-by: Richard Henderson r~

Re: [PATCH 1/3] meson: Only build virtfs-proxy-helper if all requisites are found

2021-05-25 Thread Richard Henderson
On 5/25/21 3:46 AM, Philippe Mathieu-Daudé wrote: We first set have_virtfs_proxy_helper depending on have_virtfs, then update have_virtfs... While this might work, it is not clear when looking at the code logic. Move the have_virtfs_proxy_helper assignation*after* updating have_virtfs to make it

Re: [PATCH] replay: fix watchpoint processing for reverse debugging

2021-05-25 Thread Richard Henderson
On 5/11/21 2:11 AM, Pavel Dovgalyuk wrote: This patch enables reverse debugging with watchpoints. Reverse continue scans the execution to find the breakpoints and watchpoints that should fire. It uses helper function replay_breakpoint() for that. But this function needs to access icount, which ca

[PATCH v2 11/12] linux-user/aarch64: Enable hwcap bits for bfloat16

2021-05-25 Thread Richard Henderson
Signed-off-by: Richard Henderson --- linux-user/elfload.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/linux-user/elfload.c b/linux-user/elfload.c index 1ab97e38e0..17ab06f612 100644 --- a/linux-user/elfload.c +++ b/linux-user/elfload.c @@ -659,7 +659,9 @@ static uint32_t get_elf_hwcap2(

[PATCH v2 10/12] target/arm: Implement bfloat widening fma (indexed)

2021-05-25 Thread Richard Henderson
This is BFMLAL{B,T} for both AArch64 AdvSIMD and SVE, and VFMA{B,T}.BF16 for AArch32 NEON. Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target/arm/helper.h | 2 ++ target/arm/neon-shared.decode | 2 ++ target/arm/sve.decode | 2 ++ target/arm/translate-a6

[PATCH v2 12/12] target/arm: Enable BFloat16 extensions

2021-05-25 Thread Richard Henderson
Disable BF16 again for !have_neon and !have_vfp during realize. Signed-off-by: Richard Henderson --- target/arm/cpu.c | 3 +++ target/arm/cpu64.c | 3 +++ target/arm/cpu_tcg.c | 1 + 3 files changed, 7 insertions(+) diff --git a/target/arm/cpu.c b/target/arm/cpu.c index 7aeb4b1381..cfc03c

[PATCH v2 06/12] target/arm: Implement bfloat16 dot product (vector)

2021-05-25 Thread Richard Henderson
This is BFDOT for both AArch64 AdvSIMD and SVE, and VDOT.BF16 for AArch32 NEON. Signed-off-by: Richard Henderson --- target/arm/helper.h | 3 +++ target/arm/neon-shared.decode | 2 ++ target/arm/sve.decode | 3 +++ target/arm/translate-a64.c| 20 ++ targe

[PATCH v2 07/12] target/arm: Implement bfloat16 dot product (indexed)

2021-05-25 Thread Richard Henderson
This is BFDOT for both AArch64 AdvSIMD and SVE, and VDOT.BF16 for AArch32 NEON. Signed-off-by: Richard Henderson --- target/arm/helper.h | 2 ++ target/arm/neon-shared.decode | 2 ++ target/arm/sve.decode | 3 +++ target/arm/translate-a64.c| 41 ++

[PATCH v2 08/12] target/arm: Implement bfloat16 matrix multiply accumulate

2021-05-25 Thread Richard Henderson
This is BFMMLA for both AArch64 AdvSIMD and SVE, and VMMLA.BF16 for AArch32 NEON. Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target/arm/helper.h | 3 +++ target/arm/neon-shared.decode | 2 ++ target/arm/sve.decode | 6 +++-- target/arm/translate-a64.c

[PATCH v2 09/12] target/arm: Implement bfloat widening fma (vector)

2021-05-25 Thread Richard Henderson
This is BFMLAL{B,T} for both AArch64 AdvSIMD and SVE, and VFMA{B,T}.BF16 for AArch32 NEON. Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target/arm/helper.h | 3 +++ target/arm/neon-shared.decode | 3 +++ target/arm/sve.decode | 3 +++ target/arm/translate

[PATCH v2 05/12] softfpu: Add float_round_to_odd_inf

2021-05-25 Thread Richard Henderson
For Arm BFDOT and BFMMLA, we need a version of round-to-odd that overflows to infinity, instead of the max normal number. Cc: Alex Bennée Signed-off-by: Richard Henderson --- include/fpu/softfloat-types.h | 4 +++- fpu/softfloat-parts.c.inc | 6 -- 2 files changed, 7 insertions(+), 3 de

[PATCH v2 01/12] target/arm: Add isar_feature_{aa32, aa64, aa64_sve}_bf16

2021-05-25 Thread Richard Henderson
Note that the SVE BFLOAT16 support does not require SVE2, it is an independent extension. Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target/arm/cpu.h | 15 +++ 1 file changed, 15 insertions(+) diff --git a/target/arm/cpu.h b/target/arm/cpu.h index 04f8be35bf..d

[PATCH v2 03/12] target/arm: Implement scalar float32 to bfloat16 conversion

2021-05-25 Thread Richard Henderson
This is the 64-bit BFCVT and the 32-bit VCVT{B,T}.BF16.F32. Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target/arm/helper.h| 1 + target/arm/vfp.decode | 2 ++ target/arm/translate-a64.c | 19 +++ target/arm/translate-vfp.c | 24 +++

[PATCH v2 02/12] target/arm: Unify unallocated path in disas_fp_1src

2021-05-25 Thread Richard Henderson
Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target/arm/translate-a64.c | 15 ++- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/target/arm/translate-a64.c b/target/arm/translate-a64.c index ceac0ee2bd..510cb6ca5e 100644 --- a/target/arm/translate-a6

[PATCH v2 04/12] target/arm: Implement vector float32 to bfloat16 conversion

2021-05-25 Thread Richard Henderson
This is BFCVT{N,T} for both AArch64 AdvSIMD and SVE, and VCVT.BF16.F32 for AArch32 NEON. Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target/arm/helper-sve.h | 4 target/arm/helper.h | 1 + target/arm/neon-dp.decode | 1 + target/arm/sve.decode |

[PATCH v2 00/12] target/arm: Implement BFloat16

2021-05-25 Thread Richard Henderson
Whee! All prerequisites are now merged. Patches missing r-b: 05-softfpu-Add-float_round_to_odd_inf.patch 06-target-arm-Implement-bfloat16-dot-product-vector.patch 07-target-arm-Implement-bfloat16-dot-product-indexed.patch 11-linux-user-aarch64-Enable-hwcap-bits-for-bfloat16.patch 12-ta

[Bug 1891748] Re: qemu-arm-static 5.1 can't run gcc

2021-05-25 Thread Devaev Maxim
Okay, what do you think this problem might be related to? I'm glad your tests are working, but I'm definitely not the only one with this problem. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1891748

Re: [PATCH v6 25/25] python: add tox support

2021-05-25 Thread John Snow
On 5/25/21 4:46 PM, Cleber Rosa wrote: On Tue, May 25, 2021 at 04:25:37PM -0400, John Snow wrote: On 5/25/21 4:15 PM, Cleber Rosa wrote: On Wed, May 12, 2021 at 07:12:41PM -0400, John Snow wrote: This is intended to be a manually run, non-CI script. Use tox to test the linters against all pyt

Re: [PATCH] target/riscv: Pass the same value to oprsz and maxsz.

2021-05-25 Thread Alistair Francis
On Fri, May 21, 2021 at 3:48 PM LIU Zhiwei wrote: > > Since commit e2e7168a214b0ed98dc357bba96816486a289762, if oprsz > is still zero(as we don't use this field), simd_desc will trigger an > assert. > > Besides, tcg_gen_gvec_*_ptr calls simd_desc in it's implementation. > Here we pass the value to

Re: [PATCH v1 1/1] target/riscv/pmp: Add assert for ePMP operations

2021-05-25 Thread Alistair Francis
On Fri, May 21, 2021 at 8:56 AM Alistair Francis wrote: > > Although we construct epmp_operation in such a way that it can only be > between 0 and 15 Coverity complains that we don't handle the other > possible cases. To fix Coverity and make it easier for humans to read > add a default case to th

Re: [PULL v3 36/42] target/riscv: Remove the hardcoded MSTATUS_SD macro

2021-05-25 Thread Alistair Francis
On Fri, May 21, 2021 at 12:09 PM LIU Zhiwei wrote: > > > On 5/21/21 6:55 AM, Alistair Francis wrote: > > On Thu, May 20, 2021 at 11:55 PM Peter Maydell > > wrote: > >> On Tue, 11 May 2021 at 11:22, Alistair Francis > >> wrote: > >>> Signed-off-by: Alistair Francis > >>> Reviewed-by: Richard H

Re: [PATCH v2 3/7] ACPI ERST: support for ACPI ERST feature

2021-05-25 Thread Igor Mammedov
On Tue, 25 May 2021 20:22:26 + Eric DeVolder wrote: > Igor, > Thank you for the pointers, I've turned the corner on the use of hostmem-file > and am able to use it now! > I do have one question regarding hostmem-file. In the VMStateDescription, I > used to have this for the contents > of th

Re: [PATCH v6 25/25] python: add tox support

2021-05-25 Thread Cleber Rosa
On Tue, May 25, 2021 at 04:25:37PM -0400, John Snow wrote: > On 5/25/21 4:15 PM, Cleber Rosa wrote: > > On Wed, May 12, 2021 at 07:12:41PM -0400, John Snow wrote: > > > This is intended to be a manually run, non-CI script. > > > > > > Use tox to test the linters against all python versions from 3.

Re: [PATCH v6 22/25] python: add Makefile for some common tasks

2021-05-25 Thread Cleber Rosa
On Tue, May 25, 2021 at 03:45:26PM -0400, John Snow wrote: > On 5/25/21 3:24 PM, Cleber Rosa wrote: > > On Wed, May 12, 2021 at 07:12:38PM -0400, John Snow wrote: > > > Add "make venv" to create the pipenv-managed virtual environment that > > > contains our explicitly pinned dependencies. > > > >

Re: [PATCH v6 23/25] python: add .gitignore

2021-05-25 Thread Cleber Rosa
On Tue, May 25, 2021 at 04:10:55PM -0400, John Snow wrote: > On 5/25/21 3:36 PM, Cleber Rosa wrote: > > On Wed, May 12, 2021 at 07:12:39PM -0400, John Snow wrote: > > > Ignore *Python* build and package output (build, dist, qemu.egg-info); > > > these files are not created as part of a QEMU build.

Re: [PATCH v6 20/25] python: add devel package requirements to setuptools

2021-05-25 Thread Cleber Rosa
On Tue, May 25, 2021 at 01:43:42PM -0400, John Snow wrote: > On 5/25/21 12:13 PM, Cleber Rosa wrote: > > On Wed, May 12, 2021 at 07:12:36PM -0400, John Snow wrote: > > > setuptools doesn't have a formal understanding of development requires, > > > but it has an optional feataures section. Fine; add

Re: [PATCH v6 18/25] python/qemu: add isort to pipenv

2021-05-25 Thread Cleber Rosa
On Tue, May 25, 2021 at 01:21:25PM -0400, John Snow wrote: > On 5/25/21 11:56 AM, Cleber Rosa wrote: > > On Wed, May 12, 2021 at 07:12:34PM -0400, John Snow wrote: > > > isort 5.0.0 through 5.0.4 has a bug that causes it to misinterpret > > > certain "from ..." clauses that are not related to impor

Re: [PATCH v6 24/25] gitlab: add python linters to CI

2021-05-25 Thread John Snow
On 5/25/21 3:55 PM, Cleber Rosa wrote: On Wed, May 12, 2021 at 07:12:40PM -0400, John Snow wrote: Add python3.6 to the fedora container image: we need it to run the linters against that explicit version to make sure we don't break our minimum version promise. Add pipenv so that we can fetch pre

Re: [PATCH v6 06/25] python: add directory structure README.rst files

2021-05-25 Thread Cleber Rosa
On Tue, May 25, 2021 at 01:14:50PM -0400, John Snow wrote: > On 5/24/21 10:33 PM, Cleber Rosa wrote: > > On Wed, May 12, 2021 at 07:12:22PM -0400, John Snow wrote: > > > Add short readmes to python/, python/qemu/, python/qemu/machine, > > > python/qemu/qmp, and python/qemu/utils that explain the di

Re: [PATCH v6 25/25] python: add tox support

2021-05-25 Thread John Snow
On 5/25/21 4:15 PM, Cleber Rosa wrote: On Wed, May 12, 2021 at 07:12:41PM -0400, John Snow wrote: This is intended to be a manually run, non-CI script. Use tox to test the linters against all python versions from 3.6 to 3.9. This will only work if you actually have those versions installed loca

Re: [PATCH v2 3/7] ACPI ERST: support for ACPI ERST feature

2021-05-25 Thread Eric DeVolder
Igor, Thank you for the pointers, I've turned the corner on the use of hostmem-file and am able to use it now! I do have one question regarding hostmem-file. In the VMStateDescription, I used to have this for the contents of the nvram (backed by a file): VMSTATE_VARRAY_UINT32(nvram, ER

Re: [PATCH 5/5] linux-user: Implement pivot_root

2021-05-25 Thread Laurent Vivier
Le 24/05/2021 à 06:54, YAMAMOTO Takashi a écrit : > Used by runc. > > Signed-off-by: YAMAMOTO Takashi > --- > linux-user/syscall.c | 23 +++ > 1 file changed, 23 insertions(+) > > diff --git a/linux-user/syscall.c b/linux-user/syscall.c > index 2947e79dc0..e739921e86 100644

Re: [PATCH v6 25/25] python: add tox support

2021-05-25 Thread Cleber Rosa
On Wed, May 12, 2021 at 07:12:41PM -0400, John Snow wrote: > This is intended to be a manually run, non-CI script. > > Use tox to test the linters against all python versions from 3.6 to > 3.9. This will only work if you actually have those versions installed > locally, but Fedora makes this easy:

  1   2   3   4   5   >