[PULL v3 73/81] tests: acpi: aarch64/virt: add a test for hmat nodes with no initiators

2022-11-05 Thread Michael S. Tsirkin
From: Hesham Almatary This patch imitates the "tests: acpi: q35: add test for hmat nodes without initiators" commit to test numa nodes with different HMAT attributes, but on AArch64/virt. Tested with: qemu-system-aarch64 -accel tcg \ -machine virt,hmat=on,gic-version=3 -cpu cortex-a57 \ -bios q

Re: [PATCH V5 2/4] intel-iommu: drop VTDBus

2022-11-05 Thread Michael S. Tsirkin
On Fri, Oct 28, 2022 at 02:14:34PM +0800, Jason Wang wrote: > We introduce VTDBus structure as an intermediate step for searching > the address space. This works well with SID based matching/lookup. But > when we want to support SID plus PASID based address space lookup, > this intermediate steps t

[PULL v3 75/81] vfio: move implement of vfio_get_xlat_addr() to memory.c

2022-11-05 Thread Michael S. Tsirkin
From: Cindy Lu - Move the implement vfio_get_xlat_addr to softmmu/memory.c, and change the name to memory_get_xlat_addr(). So we can use this function on other devices, such as vDPA device. - Add a new function vfio_get_xlat_addr in vfio/common.c, and it will check whether the memory is bac

[PULL v3 59/81] tests: acpi: update expected blobs

2022-11-05 Thread Michael S. Tsirkin
From: Igor Mammedov Expected changes are: 1) Moving _GPE scope declaration achec of all _E0x methods +Scope (_GPE) +{ +Name (_HID, "ACPI0006" /* GPE Block Device */) // _HID: Hardware ID +} + Scope (_SB) { Device (\_SB.PCI0.PRES)

[PULL v3 40/81] vhost-net: vhost-kernel: introduce vhost_net_virtqueue_reset()

2022-11-05 Thread Michael S. Tsirkin
From: Kangjie Xu Introduce vhost_virtqueue_reset(), which can reset the specific virtqueue in the device. Then it will unmap vrings and the desc of the virtqueue. Here we do not reuse the vhost_net_stop_one() or vhost_dev_stop(), because they work at queue pair level. We do not use vhost_virtque

[PULL v3 57/81] tests: acpi: pc/q35 whitelist DSDT before \_GPE cleanup

2022-11-05 Thread Michael S. Tsirkin
From: Igor Mammedov Signed-off-by: Igor Mammedov Message-Id: <20221017102146.2254096-10-imamm...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- tests/qtest/bios-tables-test-allowed-diff.h | 34 + 1 file changed, 34 insertions(+) diff --g

[PULL v3 74/81] tests: virt: Update expected *.acpihmatvirt tables

2022-11-05 Thread Michael S. Tsirkin
From: Hesham Almatary * Expected ACPI Data Table [HMAT] [000h 4]Signature : "HMAT"[Heterogeneous Memory Attributes Table] [004h 0004 4] Table Length : 0120 [008h 0008 1] Revision : 02 [009h 0009 1] Ch

[PULL v3 14/81] acpi/tests/avocado/bits: add acpi and smbios avocado tests that uses biosbits

2022-11-05 Thread Michael S. Tsirkin
From: Ani Sinha This introduces QEMU acpi/smbios biosbits avocado test which is run from within the python virtual environment. When the bits tests are run, bits binaries are downloaded from an external repo/location, bios bits iso is regenerated containing the acpi/smbios bits tests that are mai

[PULL v3 49/81] acpi: pc: vga: use AcpiDevAmlIf interface to build VGA device descriptors

2022-11-05 Thread Michael S. Tsirkin
From: Igor Mammedov Signed-off-by: Igor Mammedov Message-Id: <20221017102146.2254096-2-imamm...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin NB: we do not expect any functional change in any ACPI tables with this change. It's only a refactoring. Reviewed-by: A

[PULL v3 78/81] intel-iommu: convert VTD_PE_GET_FPD_ERR() to be a function

2022-11-05 Thread Michael S. Tsirkin
From: Jason Wang We used to have a macro for VTD_PE_GET_FPD_ERR() but it has an internal goto which prevents it from being reused. This patch convert that macro to a dedicated function and let the caller to decide what to do (e.g using goto or not). This makes sure it can be re-used for other fun

[PULL v3 27/81] hw/mem/cxl-type3: Add MSIX support

2022-11-05 Thread Michael S. Tsirkin
From: Jonathan Cameron This will be used by several upcoming patch sets so break it out such that it doesn't matter which one lands first. Signed-off-by: Jonathan Cameron Message-Id: <20221014151045.24781-3-jonathan.came...@huawei.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S.

[PULL v3 56/81] tests: acpi: update expected blobs

2022-11-05 Thread Michael S. Tsirkin
From: Igor Mammedov Expected change in q35 tests: @@ -2797,14 +2797,6 @@ DefinitionBlock ("", "DSDT", 1, "BOCHS ", "BXPC ", 0x0001) } } -Scope (_SB.PCI0) -{ -Device (SMB0) -{ -

[PULL v3 47/81] virtio-rng-pci: Allow setting nvectors, so we can use MSI-X

2022-11-05 Thread Michael S. Tsirkin
From: David Daney Most other virtio-pci devices allow MSI-X, let's have it for rng too. Signed-off-by: David Daney Reviewed-by: Marcin Nowakowski Signed-off-by: Philippe Mathieu-Daudé Message-Id: <20221014160947.66105-1-phi...@fungible.com> Reviewed-by: Stefan Hajnoczi Reviewed-by: Michael S

[PULL v3 69/81] tests: acpi: q35: add test for hmat nodes without initiators

2022-11-05 Thread Michael S. Tsirkin
From: Brice Goglin expected HMAT: [000h 4]Signature : "HMAT"[Heterogeneous Memory Attributes Table] [004h 0004 4] Table Length : 0120 [008h 0008 1] Revision : 02 [009h 0009 1] Checksum : 4F [00Ah 00

[PULL v3 38/81] vhost: expose vhost_virtqueue_start()

2022-11-05 Thread Michael S. Tsirkin
From: Kangjie Xu Expose vhost_virtqueue_start(), we need to use it when restarting a virtqueue. Signed-off-by: Kangjie Xu Signed-off-by: Xuan Zhuo Acked-by: Jason Wang Message-Id: <20221017092558.111082-8-xuanz...@linux.alibaba.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. T

[PULL v3 44/81] virtio-net: support queue_enable

2022-11-05 Thread Michael S. Tsirkin
From: Kangjie Xu Support queue_enable in vhost-kernel scenario. It can be called when a vq reset operation has been performed and the vq is restared. It should be noted that we can restart the vq when the vhost has already started. When launching a new vhost device, the vhost is not started and

[PULL v3 60/81] hw/acpi/erst.c: Fix memory handling issues

2022-11-05 Thread Michael S. Tsirkin
From: "Christian A. Ehrhardt" - Fix memset argument order: The second argument is the value, the length goes last. - Fix an integer overflow reported by Alexander Bulekov. Both issues allow the guest to overrun the host buffer allocated for the ERST memory device. Cc: Eric DeVolder Cc: qemu-

[PULL v3 31/81] hw/virtio/virtio-iommu-pci: Enforce the device is plugged on the root bus

2022-11-05 Thread Michael S. Tsirkin
From: Eric Auger In theory the virtio-iommu-pci could be plugged anywhere in the PCIe topology and as long as the dt/acpi info are properly built this should work. However at the moment we fail to do that because the virtio-iommu-pci BDF is not computed at plug time and in that case vms->virtio_i

[PULL v3 11/81] acpi/tests/avocado/bits: initial commit of test scripts that are run by biosbits

2022-11-05 Thread Michael S. Tsirkin
From: Ani Sinha This is initial commit of cpuid, acpi and smbios python test scripts for biosbits to execute. No change has been made to them from the original code written by the biosbits author Josh Triplett. They are required to be installed into the bits iso file and then run from within the

[PULL v3 28/81] hw/cxl/cdat: CXL CDAT Data Object Exchange implementation

2022-11-05 Thread Michael S. Tsirkin
From: Huai-Cheng Kuo The Data Object Exchange implementation of CXL Coherent Device Attribute Table (CDAT). This implementation is referring to "Coherent Device Attribute Table Specification, Rev. 1.03, July. 2022" and "Compute Express Link Specification, Rev. 3.0, July. 2022" This patch adds co

[PULL v3 12/81] acpi/tests/avocado/bits: disable acpi PSS tests that are failing in biosbits

2022-11-05 Thread Michael S. Tsirkin
From: Ani Sinha PSS tests in acpi test suite seems to be failing in biosbits. This is because the test is unable to find PSS support in QEMU bios. Let us disable them for now so that make check does not fail. We can fix the tests and re-enable them later. Example failure: ACPI _PSS (Pstate

[PULL v3 22/81] tests/acpi: virt: allow acpi MADT and FADT changes

2022-11-05 Thread Michael S. Tsirkin
From: Miguel Luis Step 3 from bios-tables-test.c documented procedure. Signed-off-by: Miguel Luis Message-Id: <20221011181730.10885-2-miguel.l...@oracle.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Acked-by: Ani Sinha --- tests/qtest/bios-tables-test-allowed-diff.h

[PULL v3 29/81] hw/mem/cxl-type3: Add CXL CDAT Data Object Exchange

2022-11-05 Thread Michael S. Tsirkin
From: Huai-Cheng Kuo The CDAT can be specified in two ways. One is to add ",cdat=" in "-device cxl-type3"'s command option. The file is required to provide the whole CDAT table in binary mode. The other is to use the default that provides some 'reasonable' numbers based on type of memory and size

[PATCH RFC 1/3] virtio: distinguish between started and running

2022-11-05 Thread Michael S. Tsirkin
virtio core often needs to know whether device is started, this is what virtio_device_started already did. However, backends want to know whether virtio is actually running which also depends on whether vm is running. To address this we moved the check to virtio_device_started, but this changes vir

[PATCH RFC 3/3] virtio: revert changes to virtio_device_started

2022-11-05 Thread Michael S. Tsirkin
virtio core often needs to know whether device is started, this is what virtio_device_started already did. However, backends want to know whether virtio is actually running which also depends on whether vm is running. To address this we moved the check to virtio_device_started, but this changes vir

[PATCH RFC 2/3] gpio: use virtio_device_running

2022-11-05 Thread Michael S. Tsirkin
Same as other vhost-user devices, vhost-user-gpio cares whether device is running not whether frontend is started. Switch to that. Fixes: 27ba7b027f ("hw/virtio: add boilerplate for vhost-user-gpio device") Cc: "Viresh Kumar" Signed-off-by: Michael S. Tsirkin --- hw/virtio/vhost-user-gpio.c | 4

[PATCH RFC 0/3] virtio fix up started checks

2022-11-05 Thread Michael S. Tsirkin
This is an attempt to fix up device started checks. Unfortunately this causes failures in CI and I could not figure it out. The simplest way to test is to set QEMU_CI to 2 on gitlab, then push there. Alternatively, push to gitlab, then create pipeline while setting QEMU_CI to 1, then run amd64-fe

[PULL 1/7] qapi: virtio: Fix the introduced version

2022-11-05 Thread Laurent Vivier
From: Han Han The items of qapi/virtio.json are introduced at a5ebce38576. They will be in the version 7.2 not 7.1. Signed-off-by: Han Han Reviewed-by: Laurent Vivier Message-Id: <20221101014647.3000801-1-h...@redhat.com> Signed-off-by: Laurent Vivier --- qapi/virtio.json | 34 ++

[PULL 3/7] xen/pt: fix syntax error that causes FTBFS in some configurations

2022-11-05 Thread Laurent Vivier
From: Chuck Zmudzinski When Qemu is built with --enable-xen and --disable-xen-pci-passthrough and the target os is linux, the build fails with: meson.build:3477:2: ERROR: File xen_pt_stub.c does not exist. Fixes: 582ea95f5f93 ("meson: convert hw/xen") Signed-off-by: Chuck Zmudzinski Reviewed-

[PULL 6/7] target/tricore: Rename csfr.def -> csfr.h.inc

2022-11-05 Thread Laurent Vivier
From: Philippe Mathieu-Daudé We use the .h.inc extension to include C headers. To be consistent with the rest of the codebase, rename the C headers using the .def extension. IDE/tools using our .editorconfig / .gitattributes will leverage this consistency. Signed-off-by: Philippe Mathieu-Daudé

[PULL 5/7] target/s390x: Rename insn-data/format.def -> insn-data/format.h.inc

2022-11-05 Thread Laurent Vivier
From: Philippe Mathieu-Daudé We use the .h.inc extension to include C headers. To be consistent with the rest of the codebase, rename the C headers using the .def extension. IDE/tools using our .editorconfig / .gitattributes will leverage this consistency. Signed-off-by: Philippe Mathieu-Daudé

[PULL 0/7] Trivial branch for 7.2 patches

2022-11-05 Thread Laurent Vivier
The following changes since commit 6295a58ad1b73985b9c32d184de7d2ed1fbe1774: Merge tag 'pull-target-arm-20221104' of https://git.linaro.org/people/pmaydell/qemu-arm into staging (2022-11-04 11:01:17 -0400) are available in the Git repository at: https://gitlab.com/laurent_vivier/qemu.git

[PULL 2/7] Fix some typos in documentation and comments

2022-11-05 Thread Laurent Vivier
From: Stefan Weil Most of them were found and fixed using codespell. Signed-off-by: Stefan Weil Reviewed-by: Peter Maydell Reviewed-by: Thomas Huth Reviewed-by: Stefan Hajnoczi Message-Id: <20221030105944.311940-1...@weilnetz.de> Signed-off-by: Laurent Vivier --- docs/devel/testing.rst

[PULL 7/7] tests/unit: simpler variable sequence for test-io-channel

2022-11-05 Thread Laurent Vivier
From: Alex Bennée This avoids some compilers complaining about a potentially un-initialised [src|dst]argv. In retrospect using GString was overkill for what we are constructing. Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Laurent Vivier Message-Id: <20221103102

[PULL 4/7] target/m68k: Rename qregs.def -> qregs.h.inc

2022-11-05 Thread Laurent Vivier
From: Philippe Mathieu-Daudé We use the .h.inc extension to include C headers. To be consistent with the rest of the codebase, rename the C headers using the .def extension. IDE/tools using our .editorconfig / .gitattributes will leverage this consistency. Signed-off-by: Philippe Mathieu-Daudé

Re: [PULL v3 0/7] loongarch-to-apply queue

2022-11-05 Thread Richard Henderson
5:05 -0400) are available in the Git repository at: https://gitlab.com/gaosong/qemu.git tags/pull-loongarch-20221105 for you to fetch changes up to 6a284614d485f36af6467ce0925df0042aca7a1f: target/loongarch: Fix raise_mmu_exception() set wrong exception_index (2022-11-05 10:5

Re: [PATCH trivial for 7.2 1/2] hw/usb/hcd-xhci.c: spelling: tranfer

2022-11-05 Thread Michael Tokarev
05.11.2022 15:23, Stefan Weil via wrote: .. All typos from this series were also found by codespell. See https://qemu.weilnetz.de/test/typos7 for many more. That list was produced with `make check-spelling` from my previous patch). Yeah, codespell is a good thing. But qemu has just TOO MANY ty

Re: [PATCH trivial for 7.2] hw/ssi/sifive_spi.c: spelling: reigster

2022-11-05 Thread Alistair Francis
On Sat, Nov 5, 2022 at 9:54 PM Michael Tokarev wrote: > > Fixes: 0694dabe9763847f3010b54ab3ec7d367d2f0ff0 > Signed-off-by: Michael Tokarev Reviewed-by: Alistair Francis Alistair > --- > hw/ssi/sifive_spi.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/hw/ssi/sifive

Re: [PATCH trivial for 7.2 1/2] hw/usb/hcd-xhci.c: spelling: tranfer

2022-11-05 Thread Stefan Weil via
Am 05.11.22 um 22:24 schrieb Michael Tokarev: 05.11.2022 15:23, Stefan Weil via wrote: .. All typos from this series were also found by codespell. See https://qemu.weilnetz.de/test/typos7 for many more. That list was produced with `make check-spelling` from my previous patch). Yeah, codespel

Re: [PATCH RFC 0/3] virtio fix up started checks

2022-11-05 Thread Michael S. Tsirkin
On Sat, Nov 05, 2022 at 02:16:29PM -0400, Michael S. Tsirkin wrote: > This is an attempt to fix up device started checks. > Unfortunately this causes failures in CI > and I could not figure it out. > > The simplest way to test is to set QEMU_CI to 2 > on gitlab, then push there. > > Alternatively

Re: [PATCH for-7.2] accel/tcg: Suppress compiler warning with flag -Wclobbered

2022-11-05 Thread Richard Henderson
On 11/5/22 22:44, Stefan Weil wrote: At least some versions of gcc show a warning when compiler flag -Wclobbered is used (tested with gcc on Debian bookworm i386 and with cross gcc for Windows on Debian bullseye). Signed-off-by: Stefan Weil --- accel/tcg/translate-all.c | 3 +++ 1 file chang

[PATCH 1/6] disas/nanomips: Move setjmp into nanomips_dis

2022-11-05 Thread Richard Henderson
Reduce the number of local variables within the scope of the setjmp by moving it to the existing helper. The actual length returned from Disassemble is not used, because we have already determined the length while reading bytes. Fixes: nanomips.c: In function ‘print_insn_nanomips’: nanomips.c:21

[PATCH 0/6] Two -Wclobbered fixes, plus other cleanup

2022-11-05 Thread Richard Henderson
As reported by Stefan, and reproduced on Ubuntu 22.04. r~ Richard Henderson (6): disas/nanomips: Move setjmp into nanomips_dis disas/nanomips: Merge insn{1,2,3} into words[3] disas/nanomips: Split out read_u16 disas/nanomips: Tidy read for 48-bit opcodes tcg: Move TCG_TARGET_HAS_direct

Re: [PATCH v7 resend 0/4] add generic vDPA device support

2022-11-05 Thread longpeng2--- via
在 2022/11/6 0:43, Michael S. Tsirkin 写道: On Sat, Nov 05, 2022 at 04:36:25PM +0800, Longpeng(Mike) wrote: From: Longpeng Hi guys, With the generic vDPA device, QEMU won't need to touch the device types any more, such like vfio. With this kind of passthrough migration is completely MIA rig

[RESEND PATCH 0/6] Two -Wclobbered fixes, plus other cleanup

2022-11-05 Thread Richard Henderson
[ Resend, since apparently only one patch made it to the list. ] Stefan reported for accel/tcg, and I reproduced on Ubuntu 22.04. r~ Richard Henderson (6): disas/nanomips: Move setjmp into nanomips_dis disas/nanomips: Merge insn{1,2,3} into words[3] disas/nanomips: Split out read_u16 di

[RESEND PATCH 2/6] disas/nanomips: Merge insn{1,2,3} into words[3]

2022-11-05 Thread Richard Henderson
Since Disassemble wants the data in this format, collect it that way. This allows using a loop to print the bytes. Signed-off-by: Richard Henderson --- disas/nanomips.c | 44 +--- 1 file changed, 21 insertions(+), 23 deletions(-) diff --git a/disas/nanom

[RESEND PATCH 6/6] accel/tcg: Split out setjmp_gen_code

2022-11-05 Thread Richard Henderson
Isolate the code protected by setjmp. Fixes: translate-all.c: In function ‘tb_gen_code’: translate-all.c:748:51: error: argument ‘cflags’ might be clobbered by ‘longjmp’ or ‘vfork’ [-Werror=clobbered] Signed-off-by: Richard Henderson --- accel/tcg/translate-all.c | 58 ++--

[RESEND PATCH 1/6] disas/nanomips: Move setjmp into nanomips_dis

2022-11-05 Thread Richard Henderson
Reduce the number of local variables within the scope of the setjmp by moving it to the existing helper. The actual length returned from Disassemble is not used, because we have already determined the length while reading bytes. Fixes: nanomips.c: In function ‘print_insn_nanomips’: nanomips.c:21

[RESEND PATCH 3/6] disas/nanomips: Split out read_u16

2022-11-05 Thread Richard Henderson
Split out a helper function for reading a uint16_t with the correct endianness. Signed-off-by: Richard Henderson --- disas/nanomips.c | 48 +++- 1 file changed, 19 insertions(+), 29 deletions(-) diff --git a/disas/nanomips.c b/disas/nanomips.c index 5

[RESEND PATCH 4/6] disas/nanomips: Tidy read for 48-bit opcodes

2022-11-05 Thread Richard Henderson
There is no point in looking for a 48-bit opcode if we've not read the second word for a 32-bit opcode. Signed-off-by: Richard Henderson --- disas/nanomips.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/disas/nanomips.c b/disas/nanomips.c index 52c7537379..092

[RESEND PATCH 5/6] tcg: Move TCG_TARGET_HAS_direct_jump init to tb_gen_code

2022-11-05 Thread Richard Henderson
Signed-off-by: Richard Henderson --- accel/tcg/translate-all.c | 10 -- tcg/tcg.c | 12 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/accel/tcg/translate-all.c b/accel/tcg/translate-all.c index 921944a5ab..9ee21f7f52 100644 --- a/accel/tcg/t

Re: [PATCH v7 resend 0/4] add generic vDPA device support

2022-11-05 Thread Michael S. Tsirkin
On Sun, Nov 06, 2022 at 08:17:07AM +0800, Longpeng (Mike, Cloud Infrastructure Service Product Dept.) wrote: > > > 在 2022/11/6 0:43, Michael S. Tsirkin 写道: > > On Sat, Nov 05, 2022 at 04:36:25PM +0800, Longpeng(Mike) wrote: > > > From: Longpeng > > > > > > Hi guys, > > > > > > With the generi

<    1   2