Re: [RFC QEMU PATCH v3 1/1] xen: Use gsi instead of irq for mapping pirq

2023-12-11 Thread Chen, Jiqian
On 2023/12/11 23:33, Roger Pau Monné wrote: > On Mon, Dec 11, 2023 at 12:52:40AM +0800, Jiqian Chen wrote: >> In PVH dom0, it uses the linux local interrupt mechanism, >> when it allocs irq for a gsi, it is dynamic, and follow >> the principle of applying first, distributing first. And >> the irq n

Re: [RFC] string-output-visitor: show structs as ""

2023-12-11 Thread Markus Armbruster
Stefan Hajnoczi writes: > StringOutputVisitor crashes when it visits a struct because > ->start_struct() is NULL. > > Show "" instead of crashing. This is necessary because the > virtio-blk-pci iothread-vq-mapping parameter that I'd like to introduce > soon is a list of IOThreadMapping structs. >

Re: [PATCH v9 0/9] Unified CPU type check

2023-12-11 Thread Gavin Shan
Hi Phil, On 12/4/23 10:47, Gavin Shan wrote: This series bases on Phil's repository because the prepatory commits have been queued to the branch. https://gitlab.com/philmd/qemu.git (branch: cpus-next) There are two places where the user specified CPU type is checked to see if it's supported

Re: [PATCH 0/3] Support for Zoned UFS

2023-12-11 Thread Jeuk Kim
I've already done all the ufs related review. If the SCSI maintainers approve this patchset, I'll put it in my tree and create a pull request. Thank you, Jeuk On 12/8/2023 3:09 PM, Daejun Park wrote: This patch enables zoned support for UFS devices. By applying this patch, a QEMU run can

Re: [PATCH 1/3] hw/ufs: Support for Zoned UFS

2023-12-11 Thread Jeuk Kim
On 12/8/2023 3:13 PM, Daejun Park wrote: This patch enables zoned ufs support. By setting the LU parameter, each LU can be a host-managed zoned device. This patch manages the zone condition and write pointer of each zone for a zoned LU. It supports the report zones and reset write pointer comman

Re: [PATCH 3/3] tests/qtest: Add tests for Zoned UFS

2023-12-11 Thread Jeuk Kim
On 12/8/2023 3:22 PM, Daejun Park wrote: This patch includes the following tests Test VPD page and report zones Test write and unaligned write error Signed-off-by: Daejun Park Reviewed-by: Jeuk Kim

RE: [PATCH for-9.0 03/10] vfio/container: Initialize VFIOIOMMUOps under vfio_init_container()

2023-12-11 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Subject: Re: [PATCH for-9.0 03/10] vfio/container: Initialize VFIOIOMMUOps >under vfio_init_container() > >On 12/11/23 06:59, Duan, Zhenzhong wrote: >> >> >>> -Original Message- >>> From: Cédric Le Goater >>> Sent: Friday, December 8,

Re: [PATCH RFC v2 00/12] virtio-net: add support for SR-IOV emulation

2023-12-11 Thread Jason Wang
On Mon, Dec 11, 2023 at 4:29 PM Akihiko Odaki wrote: > > On 2023/12/11 16:26, Jason Wang wrote: > > On Mon, Dec 11, 2023 at 1:30 PM Akihiko Odaki > > wrote: > >> > >> On 2023/12/11 11:52, Jason Wang wrote: > >>> On Sun, Dec 10, 2023 at 12:06 PM Akihiko Odaki > >>> wrote: > > Introduc

Re: [PATCH v7 1/5] ebpf: Added eBPF map update through mmap.

2023-12-11 Thread Jason Wang
On Mon, Dec 11, 2023 at 10:07 PM Akihiko Odaki wrote: > > On 2023/12/11 22:48, Yuri Benditovich wrote: > > Akihiko, > > This series was already discussed several months ago. > > I'd suggest to postpone commenting on it and resume them after merging. > > I found a pull request: > https://lore.kerne

Re: [PATCH v7 5/5] ebpf: Updated eBPF program and skeleton.

2023-12-11 Thread Jason Wang
On Mon, Dec 11, 2023 at 7:51 PM Yuri Benditovich wrote: > > Hello Jason, > Can you please let us know what happens with this series? It should be my bad, it is in V1 of the pull request but missed accidentally in V2 of the pull. I've merged it here, https://gitlab.com/jasowang/qemu.git Please

Re: QEMU developers fortnightly conference call for agenda for 2023-12-12

2023-12-11 Thread Zhao Liu
Hi Philippe, On Mon, Dec 11, 2023 at 08:04:28PM +0100, Philippe Mathieu-Daudé wrote: > Date: Mon, 11 Dec 2023 20:04:28 +0100 > From: Philippe Mathieu-Daudé > Subject: Re: QEMU developers fortnightly conference call for agenda for > 2023-12-12 > > Hi Zhao, > [snip] > > FYI I have your series

Re: [PATCH 2/2] hw/usb/hcd-xhci.c: allow unaligned access to Capability Registers

2023-12-11 Thread Tomoyuki Hirose
Thanks for comment. On Mon, Dec 11, 2023 at 10:57 PM Peter Maydell wrote: > We should definitely look at fixing the unaligned access > stuff, but the linked bug report is not trying to do an > unaligned access -- it wants to do a 2-byte read from offset 2, > which is aligned. The capability regis

Re: [PATCH 22/24] exec/cpu-all: Restrict inclusion of 'exec/user/guest-base.h'

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: Declare 'have_guest_base' in "exec/user/guest-base.h". Very few files require this header, so explicitly include it there instead of "exec/cpu-all.h" which is used in many source files. Assert this user-specific header is only included from user em

Re: [PATCH 24/24] target: Restrict 'sysemu/reset.h' to system emulation

2023-12-11 Thread gaosong
在 2023/12/12 上午5:20, Philippe Mathieu-Daudé 写道: vCPU "reset" is only possible with system emulation. Signed-off-by: Philippe Mathieu-Daudé --- target/i386/cpu.c | 2 +- target/loongarch/cpu.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) Reviewed-by: Song Gao Thanks. Song

Re: [PATCH 20/24] exec: Declare abi_ptr type in its own 'tcg/abi_ptr.h' header

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: The abi_ptr type is declared in "exec/cpu_ldst.h" with all the load/store helpers. Some source files requiring abi_ptr type don't need the load/store helpers. In order to simplify, create a new "tcg/abi_ptr.h" header. Signed-off-by: Philippe Mathi

[PATCH v2] vfio: Include libgen.h for basename API

2023-12-11 Thread Khem Raj
Glibc has two implementation one based on POSIX which is used when libgen.h is included and second implementation is GNU implementation which is used when string.h is included. The functions are no identical in behavior. Musl C library does not implement the GNU version, but it has provided a decla

[PATCH] vfio: Include libgen.h for basename API

2023-12-11 Thread Khem Raj
Glibc has two implementation one based on POSIX which is used when libgen.h is included and second implementation is GNU implementation which is used when string.h is included. The functions are no identical in behavior. Musl C library does not implement the GNU version, but it has provided a decla

[PATCH v4 2/4] tcg: Make tb_cflags() usable from target-agnostic code

2023-12-11 Thread Ilya Leoshkevich
Currently tb_cflags() is defined in exec-all.h, which is not usable from target-agnostic code. Move it to translation-block.h, which is. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Ilya Leoshkevich Reviewed-by: Richard Henderson --- include/exec/exec-all.h | 6 -- include/e

[PATCH v4 4/4] accel/tcg: Move perf and debuginfo support to tcg

2023-12-11 Thread Ilya Leoshkevich
tcg/ should not depend on accel/tcg/, but perf and debuginfo support provided by the latter are being used by tcg/tcg.c. Since that's the only user, move both to tcg/. Suggested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Ilya Leoshkevich Reviewed-by: Richard

[PATCH v4 3/4] accel/tcg: Remove #ifdef TARGET_I386 from perf.c

2023-12-11 Thread Ilya Leoshkevich
Preparation for moving perf.c to tcg/. This affects only profiling guest code, which has code in a non-0 based segment, e.g., 16-bit code, which is not particularly important. Suggested-by: Richard Henderson Signed-off-by: Ilya Leoshkevich Reviewed-by: Alex Bennée Reviewed-by: Richard Henderso

[PATCH v4 1/4] accel/tcg: Make use of qemu_target_page_mask() in perf.c

2023-12-11 Thread Ilya Leoshkevich
Stop using TARGET_PAGE_MASK in order to make perf.c more target-agnostic. Signed-off-by: Ilya Leoshkevich --- accel/tcg/perf.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/accel/tcg/perf.c b/accel/tcg/perf.c index cd1aa99a7ee..ba75c1bbe45 100644 --- a/accel/tcg/perf.c ++

[PATCH v4 0/4] accel/tcg: Move perf and debuginfo support to tcg

2023-12-11 Thread Ilya Leoshkevich
Based-on: 20231211212003.21686-1-phi...@linaro.org v3 -> v4: Rebase on top of Philippe's series. Move perf.h and debuginfo.h (Richard). v2: https://patchew.org/QEMU/20230630234230.596193-1-...@linux.ibm.com/ v2 -> v3: Rebased. This series was lost and forgotten until Philippe

Re: [PATCH] xen: fix condition for enabling the Xen accelerator

2023-12-11 Thread Stefano Stabellini
On Sat, 9 Dec 2023, Paolo Bonzini wrote: > A misspelled condition in xen_native.h is hiding a bug in the enablement of > Xen for qemu-system-aarch64. The bug becomes apparent when building for > Xen 4.18. > > While the i386 emulator provides the xenpv machine type for multiple > architectures, >

Re: [PATCH 19/24] exec/user: Do not include 'cpu.h' in 'abitypes.h'

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: First, "exec/user/abitypes.h" is missing the following includes (they are included by "cpu.h"): - "exec/target_long.h" - "exec/cpu-all.h" - "exec/tswap.h" Second, it only requires the definitions from "cpu-param.h", not the huge "cpu.h". In

Re: [PATCH 18/24] accel/tcg: Un-inline retaddr helpers to 'user-retaddr.h'

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: set_helper_retaddr() is only used in accel/tcg/user-exec.c. clear_helper_retaddr() is only used in accel/tcg/user-exec.c and accel/tcg/user-exec.c. No need to expose their definitions to all user-emulation files including "exec/cpu_ldst.h", move

Re: [PATCH 15/24] exec/cpu-all: Remove unused headers

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: Nothing is required from the "qemu/thread.h" and "hw/core/cpu.h" headers. Signed-off-by: Philippe Mathieu-Daudé --- include/exec/cpu-all.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/include/exec/cpu-all.h b/include/exec/cpu-all.h ind

Re: [PATCH 16/24] exec/cpu-all: Reduce 'qemu/rcu.h' header inclusion

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: "exec/cpu-all.h" doesn't need definitions from "qemu/rcu.h", however "exec/ram_addr.h" does. Signed-off-by: Philippe Mathieu-Daudé --- include/exec/cpu-all.h | 1 - include/exec/ram_addr.h | 1 + 2 files changed, 1 insertion(+), 1 deletion(-

Re: [PATCH 12/24] target/i386: Include missing 'exec/exec-all.h' header

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: The XRSTOR instruction ends calling tlb_flush(), declared in "exec/exec-all.h". Signed-off-by: Philippe Mathieu-Daudé --- target/i386/tcg/fpu_helper.c | 1 + 1 file changed, 1 insertion(+) Reviewed-by: Richard Henderson r~

Re: [PATCH 06/24] semihosting/guestfd: Remove unused 'semihosting/uaccess.h' header

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: Nothing in guestfd.c requires "semihosting/uaccess.h". Signed-off-by: Philippe Mathieu-Daudé --- semihosting/guestfd.c | 1 - 1 file changed, 1 deletion(-) diff --git a/semihosting/guestfd.c b/semihosting/guestfd.c index 955c2efbd0..fd7e60979

Re: [PATCH 05/24] semihosting/uaccess: Avoid including 'cpu.h'

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: "semihosting/uaccess.h" only requires declarations from "exec/cpu-defs.h". Avoid including the huge "cpu.h". Signed-off-by: Philippe Mathieu-Daudé --- include/semihosting/uaccess.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Review

Re: [PATCH 04/24] accel: Include missing 'exec/cpu_ldst.h' header

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: Theses files call cpu_ldl_code() which is declared in "exec/cpu_ldst.h". Signed-off-by: Philippe Mathieu-Daudé --- accel/tcg/translator.c| 1 + target/hexagon/translate.c| 1 + target/microblaze/cpu.c | 1 + target/microbla

Re: [PATCH 03/24] target: Define TCG_GUEST_DEFAULT_MO in 'cpu-param.h'

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: accel/tcg/ files requires the following definitions: - TARGET_LONG_BITS - TARGET_PAGE_BITS - TARGET_PHYS_ADDR_SPACE_BITS - TCG_GUEST_DEFAULT_MO The first 3 are defined in "cpu-param.h". The last one in "cpu.h", with a bunch of definit

Re: [PATCH 02/24] exec: Expose 'target_page.h' API to user emulation

2023-12-11 Thread Richard Henderson
On 12/11/23 13:19, Philippe Mathieu-Daudé wrote: User-only objects might benefit from the "exec/target_page.h" API, which allows to build some objects once for all targets. Signed-off-by: Philippe Mathieu-Daudé --- meson.build | 2 +- page-target.c| 43 ++

Re: [PATCH 24/24] target: Restrict 'sysemu/reset.h' to system emulation

2023-12-11 Thread Warner Losh
On Mon, Dec 11, 2023 at 2:23 PM Philippe Mathieu-Daudé wrote: > vCPU "reset" is only possible with system emulation. > > Signed-off-by: Philippe Mathieu-Daudé > --- > target/i386/cpu.c | 2 +- > target/loongarch/cpu.c | 2 ++ > 2 files changed, 3 insertions(+), 1 deletion(-) > Reviewed-by

Re: [PATCH 14/24] gdbstub: Include missing 'hw/core/cpu.h' header

2023-12-11 Thread Warner Losh
On Mon, Dec 11, 2023 at 2:22 PM Philippe Mathieu-Daudé wrote: > Functions such gdb_get_cpu_pid() dereference CPUState so > require the structure declaration from "hw/core/cpu.h": > > static uint32_t gdb_get_cpu_pid(CPUState *cpu) > { > ... > return cpu->cluster_index + 1; > } > > Si

Re: [PATCH 02/24] exec: Expose 'target_page.h' API to user emulation

2023-12-11 Thread Warner Losh
On Mon, Dec 11, 2023 at 2:20 PM Philippe Mathieu-Daudé wrote: > User-only objects might benefit from the "exec/target_page.h" > API, which allows to build some objects once for all targets. > > Signed-off-by: Philippe Mathieu-Daudé > --- > meson.build | 2 +- > page-target.c| 43 +

Re: [PATCH 01/24] exec: Include 'cpu.h' before validating CPUArchState placement

2023-12-11 Thread Warner Losh
On Mon, Dec 11, 2023 at 2:53 PM Warner Losh wrote: > > > On Mon, Dec 11, 2023 at 2:20 PM Philippe Mathieu-Daudé > wrote: > >> CPUArchState 'env' field is defined within the ArchCPU structure, >> so we need to include each target "cpu.h" header which defines it. >> >> Signed-off-by: Philippe Math

Re: [PATCH 01/24] exec: Include 'cpu.h' before validating CPUArchState placement

2023-12-11 Thread Warner Losh
On Mon, Dec 11, 2023 at 2:20 PM Philippe Mathieu-Daudé wrote: > CPUArchState 'env' field is defined within the ArchCPU structure, > so we need to include each target "cpu.h" header which defines it. > > Signed-off-by: Philippe Mathieu-Daudé > --- > include/exec/cpu-all.h | 9 + > 1 file

Re: [PULL 20/20] tracing: install trace events file only if necessary

2023-12-11 Thread Carlos Santos
On Mon, Dec 11, 2023 at 4:58 PM Stefan Hajnoczi wrote: > > On Wed, Dec 06, 2023 at 07:26:01AM -0300, Carlos Santos wrote: > > On Thu, Apr 20, 2023 at 9:10 AM Stefan Hajnoczi wrote: > > > > > > From: Carlos Santos > > > > > > It is not useful when configuring with --enable-trace-backends=nop. > >

Re: [PATCH v2 0/3] Virtio dmabuf improvements

2023-12-11 Thread Stefan Hajnoczi
On Thu, 7 Dec 2023 at 09:55, Albert Esteve wrote: > > v1: https://www.mail-archive.com/qemu-devel@nongnu.org/msg1005257.html > v1 -> v2: > - Solved an unitialized uuid value on vhost-user source > - Changed cleanup strategy, and traverse all objects in the > table to remove them instead.

Re: [PATCH 20/24] exec: Declare abi_ptr type in its own 'tcg/abi_ptr.h' header

2023-12-11 Thread Philippe Mathieu-Daudé
On 11/12/23 22:19, Philippe Mathieu-Daudé wrote: The abi_ptr type is declared in "exec/cpu_ldst.h" with all the load/store helpers. Some source files requiring abi_ptr type don't need the load/store helpers. In order to simplify, create a new "tcg/abi_ptr.h" header. Signed-off-by: Philippe Mathi

[PATCH 21/24] exec/cpu_ldst: Avoid including 'cpu.h'

2023-12-11 Thread Philippe Mathieu-Daudé
"exec/cpu_ldst.h" doesn't need to huge "cpu.h" header, but simply: - exec/cpu-defs.h - exec/tlb-common.h - exec/user/abitypes.h - exec/user/guest-base.h Signed-off-by: Philippe Mathieu-Daudé --- include/exec/cpu_ldst.h | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a

[PATCH 15/24] exec/cpu-all: Remove unused headers

2023-12-11 Thread Philippe Mathieu-Daudé
Nothing is required from the "qemu/thread.h" and "hw/core/cpu.h" headers. Signed-off-by: Philippe Mathieu-Daudé --- include/exec/cpu-all.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/include/exec/cpu-all.h b/include/exec/cpu-all.h index 9a7b5737d3..b1e293a08f 100644 --- a/include/exec/c

Re: [PATCH v2 07/20] util/dsa: Implement DSA device start and stop logic.

2023-12-11 Thread Fabiano Rosas
Hao Xiang writes: > * DSA device open and close. > * DSA group contains multiple DSA devices. > * DSA group configure/start/stop/clean. > > Signed-off-by: Hao Xiang > Signed-off-by: Bryan Zhang > --- > include/qemu/dsa.h | 49 +++ > util/dsa.c | 338 +++

[PATCH 19/24] exec/user: Do not include 'cpu.h' in 'abitypes.h'

2023-12-11 Thread Philippe Mathieu-Daudé
First, "exec/user/abitypes.h" is missing the following includes (they are included by "cpu.h"): - "exec/target_long.h" - "exec/cpu-all.h" - "exec/tswap.h" Second, it only requires the definitions from "cpu-param.h", not the huge "cpu.h". In order to avoid "cpu.h", pick the minimum required head

[PATCH 23/24] exec/cpu-all: Extract page-protection definitions to page-prot-common.h

2023-12-11 Thread Philippe Mathieu-Daudé
Extract page-protection definitions from "exec/cpu-all.h" to "exec/page-prot-common.h". The list of files requiring the new header was generated using: $ git grep -wE \ 'PAGE_(READ|WRITE|EXEC|BITS|VALID|ANON|RESERVED|TARGET_.|PASSTHROUGH)' Signed-off-by: Philippe Mathieu-Daudé --- bsd-user/b

[PATCH 22/24] exec/cpu-all: Restrict inclusion of 'exec/user/guest-base.h'

2023-12-11 Thread Philippe Mathieu-Daudé
Declare 'have_guest_base' in "exec/user/guest-base.h". Very few files require this header, so explicitly include it there instead of "exec/cpu-all.h" which is used in many source files. Assert this user-specific header is only included from user emulation. Signed-off-by: Philippe Mathieu-Daudé --

[PATCH 24/24] target: Restrict 'sysemu/reset.h' to system emulation

2023-12-11 Thread Philippe Mathieu-Daudé
vCPU "reset" is only possible with system emulation. Signed-off-by: Philippe Mathieu-Daudé --- target/i386/cpu.c | 2 +- target/loongarch/cpu.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/target/i386/cpu.c b/target/i386/cpu.c index dfb96217ad..17b6962d43 100644 ---

Re: [PATCH 03/24] target: Define TCG_GUEST_DEFAULT_MO in 'cpu-param.h'

2023-12-11 Thread Philippe Mathieu-Daudé
On 11/12/23 22:19, Philippe Mathieu-Daudé wrote: accel/tcg/ files requires the following definitions: - TARGET_LONG_BITS - TARGET_PAGE_BITS - TARGET_PHYS_ADDR_SPACE_BITS - TCG_GUEST_DEFAULT_MO The first 3 are defined in "cpu-param.h". The last one in "cpu.h", with a bunch of definit

[PATCH 04/24] accel: Include missing 'exec/cpu_ldst.h' header

2023-12-11 Thread Philippe Mathieu-Daudé
Theses files call cpu_ldl_code() which is declared in "exec/cpu_ldst.h". Signed-off-by: Philippe Mathieu-Daudé --- accel/tcg/translator.c| 1 + target/hexagon/translate.c| 1 + target/microblaze/cpu.c | 1 + target/microblaze/translate.c | 1 + target/nios2/translate.c | 1

[PATCH 16/24] exec/cpu-all: Reduce 'qemu/rcu.h' header inclusion

2023-12-11 Thread Philippe Mathieu-Daudé
"exec/cpu-all.h" doesn't need definitions from "qemu/rcu.h", however "exec/ram_addr.h" does. Signed-off-by: Philippe Mathieu-Daudé --- include/exec/cpu-all.h | 1 - include/exec/ram_addr.h | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/include/exec/cpu-all.h b/include/exec/

[PATCH 18/24] accel/tcg: Un-inline retaddr helpers to 'user-retaddr.h'

2023-12-11 Thread Philippe Mathieu-Daudé
set_helper_retaddr() is only used in accel/tcg/user-exec.c. clear_helper_retaddr() is only used in accel/tcg/user-exec.c and accel/tcg/user-exec.c. No need to expose their definitions to all user-emulation files including "exec/cpu_ldst.h", move them to a new "user-retaddr.h" header (restricted t

[PATCH 20/24] exec: Declare abi_ptr type in its own 'tcg/abi_ptr.h' header

2023-12-11 Thread Philippe Mathieu-Daudé
The abi_ptr type is declared in "exec/cpu_ldst.h" with all the load/store helpers. Some source files requiring abi_ptr type don't need the load/store helpers. In order to simplify, create a new "tcg/abi_ptr.h" header. Signed-off-by: Philippe Mathieu-Daudé --- include/exec/cpu_ldst.h | 17 +++--

[PATCH 02/24] exec: Expose 'target_page.h' API to user emulation

2023-12-11 Thread Philippe Mathieu-Daudé
User-only objects might benefit from the "exec/target_page.h" API, which allows to build some objects once for all targets. Signed-off-by: Philippe Mathieu-Daudé --- meson.build | 2 +- page-target.c| 43 +++ system/physmem.c | 35 ---

[PATCH 09/24] hw/ppc/spapr_hcall: Remove unused 'exec/exec-all.h' included header

2023-12-11 Thread Philippe Mathieu-Daudé
Signed-off-by: Philippe Mathieu-Daudé --- hw/ppc/spapr_hcall.c | 1 - 1 file changed, 1 deletion(-) diff --git a/hw/ppc/spapr_hcall.c b/hw/ppc/spapr_hcall.c index 522a2396c7..fcefd1d1c7 100644 --- a/hw/ppc/spapr_hcall.c +++ b/hw/ppc/spapr_hcall.c @@ -8,7 +8,6 @@ #include "qemu/main-loop.h" #in

[PATCH 01/24] exec: Include 'cpu.h' before validating CPUArchState placement

2023-12-11 Thread Philippe Mathieu-Daudé
CPUArchState 'env' field is defined within the ArchCPU structure, so we need to include each target "cpu.h" header which defines it. Signed-off-by: Philippe Mathieu-Daudé --- include/exec/cpu-all.h | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/include/exec/cpu-all.

[PATCH 03/24] target: Define TCG_GUEST_DEFAULT_MO in 'cpu-param.h'

2023-12-11 Thread Philippe Mathieu-Daudé
accel/tcg/ files requires the following definitions: - TARGET_LONG_BITS - TARGET_PAGE_BITS - TARGET_PHYS_ADDR_SPACE_BITS - TCG_GUEST_DEFAULT_MO The first 3 are defined in "cpu-param.h". The last one in "cpu.h", with a bunch of definitions irrelevant for TCG. By moving the TCG_GUEST_DEFAUL

[PATCH 14/24] gdbstub: Include missing 'hw/core/cpu.h' header

2023-12-11 Thread Philippe Mathieu-Daudé
Functions such gdb_get_cpu_pid() dereference CPUState so require the structure declaration from "hw/core/cpu.h": static uint32_t gdb_get_cpu_pid(CPUState *cpu) { ... return cpu->cluster_index + 1; } Signed-off-by: Philippe Mathieu-Daudé --- gdbstub/gdbstub.c | 1 + 1 file changed,

[PATCH 07/24] host/load-extract: Include missing 'qemu/atomic.h' and 'qemu/int128.h'

2023-12-11 Thread Philippe Mathieu-Daudé
int128_make128(), int128_getlo() and int128_urshift() are declared in "qemu/int128.h". qatomic_read__nocheck() is declared in "qemu/atomic.h". Signed-off-by: Philippe Mathieu-Daudé --- host/include/generic/host/load-extract-al16-al8.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/host/i

[PATCH 17/24] target/ppc/excp_helper: Avoid 'abi_ptr' in system emulation

2023-12-11 Thread Philippe Mathieu-Daudé
'abi_ptr' is a user specific type. The system emulation equivalent is 'target_ulong'. Use it in ppc_ldl_code() to emphasis this is not an user emulation function. Signed-off-by: Philippe Mathieu-Daudé --- target/ppc/excp_helper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [PATCH 00/24] exec: Rework of various headers (user focused)

2023-12-11 Thread Philippe Mathieu-Daudé
(Forgot to Cc rev.ng folks) On 11/12/23 22:19, Philippe Mathieu-Daudé wrote: Hi, These patches are extracted from a bigger work where "exec/{exec,cpu,translate}-all.h" are split in various specific APIs. This helped: - differenciate/build: . user VS system . target-specific VS

[PATCH 12/24] target/i386: Include missing 'exec/exec-all.h' header

2023-12-11 Thread Philippe Mathieu-Daudé
The XRSTOR instruction ends calling tlb_flush(), declared in "exec/exec-all.h". Signed-off-by: Philippe Mathieu-Daudé --- target/i386/tcg/fpu_helper.c | 1 + 1 file changed, 1 insertion(+) diff --git a/target/i386/tcg/fpu_helper.c b/target/i386/tcg/fpu_helper.c index 4430d3d380..3bb018fbae 1006

[PATCH 13/24] accel/tcg: Include missing 'hw/core/cpu.h' header

2023-12-11 Thread Philippe Mathieu-Daudé
tcg_cpu_init_cflags() accesses CPUState fields, so requires "hw/core/cpu.h" to get its structure definition. Signed-off-by: Philippe Mathieu-Daudé --- accel/tcg/tcg-accel-ops.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/accel/tcg/tcg-accel-ops.c b/accel/tcg/tcg-accel-ops.c index 1b572

[PATCH 11/24] hw/s390x/ipl: Remove unused 'exec/exec-all.h' included header

2023-12-11 Thread Philippe Mathieu-Daudé
Signed-off-by: Philippe Mathieu-Daudé --- hw/s390x/ipl.c | 1 - 1 file changed, 1 deletion(-) diff --git a/hw/s390x/ipl.c b/hw/s390x/ipl.c index 515dcf51b5..62182d81a0 100644 --- a/hw/s390x/ipl.c +++ b/hw/s390x/ipl.c @@ -35,7 +35,6 @@ #include "qemu/cutils.h" #include "qemu/option.h" #include

[PATCH 10/24] hw/misc/mips_itu: Remove unnecessary 'exec/exec-all.h' header

2023-12-11 Thread Philippe Mathieu-Daudé
mips_itu.c only requires declarations from "hw/core/cpu.h" and "cpu.h". Avoid including the huge "exec/exec-all.h" header. Signed-off-by: Philippe Mathieu-Daudé --- hw/misc/mips_itu.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/misc/mips_itu.c b/hw/misc/mips_itu.c in

[PATCH 06/24] semihosting/guestfd: Remove unused 'semihosting/uaccess.h' header

2023-12-11 Thread Philippe Mathieu-Daudé
Nothing in guestfd.c requires "semihosting/uaccess.h". Signed-off-by: Philippe Mathieu-Daudé --- semihosting/guestfd.c | 1 - 1 file changed, 1 deletion(-) diff --git a/semihosting/guestfd.c b/semihosting/guestfd.c index 955c2efbd0..fd7e609790 100644 --- a/semihosting/guestfd.c +++ b/semihostin

[PATCH 05/24] semihosting/uaccess: Avoid including 'cpu.h'

2023-12-11 Thread Philippe Mathieu-Daudé
"semihosting/uaccess.h" only requires declarations from "exec/cpu-defs.h". Avoid including the huge "cpu.h". Signed-off-by: Philippe Mathieu-Daudé --- include/semihosting/uaccess.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/semihosting/uaccess.h b/include/semihos

[PATCH 08/24] host/atomic128: Include missing 'qemu/atomic.h' header

2023-12-11 Thread Philippe Mathieu-Daudé
qatomic_cmpxchg__nocheck(), qatomic_read__nocheck(), qatomic_set__nocheck() are defined in "qemu/atomic.h". Include it in order to avoid: In file included from include/exec/helper-proto.h:10: In file included from include/exec/helper-proto-common.h:10: In file included from include/qemu/atom

[PATCH 00/24] exec: Rework of various headers (user focused)

2023-12-11 Thread Philippe Mathieu-Daudé
Hi, These patches are extracted from a bigger work where "exec/{exec,cpu,translate}-all.h" are split in various specific APIs. This helped: - differenciate/build: . user VS system . target-specific VS generic which is necessary for heterogeneous build - reduced header pressure

Re: [PULL 20/20] tracing: install trace events file only if necessary

2023-12-11 Thread Stefan Hajnoczi
On Wed, Dec 06, 2023 at 07:26:01AM -0300, Carlos Santos wrote: > On Thu, Apr 20, 2023 at 9:10 AM Stefan Hajnoczi wrote: > > > > From: Carlos Santos > > > > It is not useful when configuring with --enable-trace-backends=nop. > > > > Signed-off-by: Carlos Santos > > Signed-off-by: Stefan Hajnoczi

[RFC] string-output-visitor: show structs as ""

2023-12-11 Thread Stefan Hajnoczi
StringOutputVisitor crashes when it visits a struct because ->start_struct() is NULL. Show "" instead of crashing. This is necessary because the virtio-blk-pci iothread-vq-mapping parameter that I'd like to introduce soon is a list of IOThreadMapping structs. Cc: Markus Armbruster Signed-off-by:

Re: [PATCH v8 00/19] virtio-net RSS/hash report fixes and improvements

2023-12-11 Thread Yuri Benditovich
I'm adding also Yan On Mon, Dec 11, 2023 at 9:51 PM Yuri Benditovich < yuri.benditov...@daynix.com> wrote: > Hi Michael, > Sure, I've reviewed that also, there was a fruitful discussion > till the series rеаched its final form. > At the beginning of September we've got the response from Jason tha

Re: [PATCH v8 00/19] virtio-net RSS/hash report fixes and improvements

2023-12-11 Thread Yuri Benditovich
Hi Michael, Sure, I've reviewed that also, there was a fruitful discussion till the series rеаched its final form. At the beginning of September we've got the response from Jason that the series is queued upstream so we were calm and switched to libvirt part )) Seems like a misunderstanding, let's

Re: [PATCH v2 12/20] migration/multifd: Add new migration option for multifd DSA offloading.

2023-12-11 Thread Fabiano Rosas
Hao Xiang writes: > Intel DSA offloading is an optional feature that turns on if > proper hardware and software stack is available. To turn on > DSA offloading in multifd live migration: > > multifd-dsa-accel="[dsa_dev_path1] ] [dsa_dev_path2] ... [dsa_dev_pathX]" > > This feature is turned off b

Re: QEMU developers fortnightly conference call for agenda for 2023-12-12

2023-12-11 Thread Philippe Mathieu-Daudé
Hi Zhao, On 11/12/23 14:29, Zhao Liu wrote: Hi Juan, On Tue, Dec 05, 2023 at 01:47:52PM +, Juan Quintela wrote: Date: Tue, 05 Dec 2023 13:47:52 + From: Juan Quintela Subject: QEMU developers fortnightly conference call for agenda for 2023-12-12 Hi If you have any topics for the las

Re: [PATCH 18/21] target/arm/kvm: Init cap_has_inject_serror_esr in kvm_arch_init

2023-12-11 Thread Richard Henderson
On 12/11/23 10:43, Philippe Mathieu-Daudé wrote: On 11/12/23 18:09, Richard Henderson wrote: On 11/24/23 03:54, Philippe Mathieu-Daudé wrote: On 23/11/23 05:42, Richard Henderson wrote: There is no need to do this in kvm_arch_init_vcpu per vcpu. Inline kvm_arm_init_serror_injection rather than

Re: [PATCH v3 4/4] accel/tcg: Move perf and debuginfo support to tcg

2023-12-11 Thread Richard Henderson
On 12/7/23 16:35, Ilya Leoshkevich wrote: --- a/accel/tcg/translate-all.c +++ b/accel/tcg/translate-all.c @@ -63,7 +63,7 @@ #include "tb-context.h" #include "internal-common.h" #include "internal-target.h" -#include "perf.h" +#include "tcg/perf.h" #include "tcg/insn-start-words.h" Becau

Re: [PATCH 03/40] vdpa: probe descriptor group index for data vqs

2023-12-11 Thread Eugenio Perez Martin
On Thu, Dec 7, 2023 at 7:53 PM Si-Wei Liu wrote: > > Getting it ahead at initialization time instead of start time allows > decision making independent of device status, while reducing failure > possibility in starting device or during migration. > > Adding function vhost_vdpa_probe_desc_group() f

Re: QEMU developers fortnightly conference call for agenda for 2023-12-12

2023-12-11 Thread Philippe Mathieu-Daudé
Cc'ing Brian (this could be a good place to discuss Hexagon semihosting) On 5/12/23 14:47, Juan Quintela wrote: QEMU developers fortnightly conference call Hi If you have any topics for the last qemu conference call of the year, feel free to answer to this email. Later, Juan. QEMU developer

Re: [PATCH v3 3/4] accel/tcg: Remove #ifdef TARGET_I386 from perf.c

2023-12-11 Thread Richard Henderson
On 12/7/23 16:35, Ilya Leoshkevich wrote: Preparation for moving perf.c to tcg/. This affects only profiling guest code, which has code in a non-0 based segment, e.g., 16-bit code, which is not particularly important. Suggested-by: Richard Henderson Signed-off-by: Ilya Leoshkevich --- accel

Re: [PATCH v3 2/4] tcg: Make tb_cflags() usable from target-agnostic code

2023-12-11 Thread Richard Henderson
On 12/7/23 16:35, Ilya Leoshkevich wrote: Currently tb_cflags() is defined in exec-all.h, which is not usable from target-agnostic code. Move it to translation-block.h, which is. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Ilya Leoshkevich --- include/exec/exec-all.h | 6

Re: [PATCH 20/21] target/arm/kvm: Unexport and tidy kvm_arm_sync_mpstate_to_{kvm, qemu}

2023-12-11 Thread Philippe Mathieu-Daudé
On 11/12/23 15:34, Peter Maydell wrote: On Fri, 24 Nov 2023 at 12:06, Philippe Mathieu-Daudé wrote: On 23/11/23 05:42, Richard Henderson wrote: Drop fprintfs and actually use the return values in the callers. Signed-off-by: Richard Henderson --- target/arm/kvm_arm.h | 20

Re: [PATCH 18/21] target/arm/kvm: Init cap_has_inject_serror_esr in kvm_arch_init

2023-12-11 Thread Philippe Mathieu-Daudé
On 11/12/23 18:09, Richard Henderson wrote: On 11/24/23 03:54, Philippe Mathieu-Daudé wrote: On 23/11/23 05:42, Richard Henderson wrote: There is no need to do this in kvm_arch_init_vcpu per vcpu. Inline kvm_arm_init_serror_injection rather than keep separate. Signed-off-by: Richard Henderson

Re: [PATCH 00/40] vdpa-net: improve migration downtime through descriptor ASID and persistent IOTLB

2023-12-11 Thread Eugenio Perez Martin
On Thu, Dec 7, 2023 at 7:50 PM Si-Wei Liu wrote: > > This patch series contain several enhancements to SVQ live migration downtime > for vDPA-net hardware device, specifically on mlx5_vdpa. Currently it is based > off of Eugenio's RFC v2 .load_setup series [1] to utilize the shared facility > and

Re: [PATCH 40/40] vdpa: add trace event for vhost_vdpa_net_load_mq

2023-12-11 Thread Eugenio Perez Martin
On Thu, Dec 7, 2023 at 7:51 PM Si-Wei Liu wrote: > > For better debuggability and observability. > > Signed-off-by: Si-Wei Liu Reviewed-by: Eugenio Pérez > --- > net/trace-events | 1 + > net/vhost-vdpa.c | 2 ++ > 2 files changed, 3 insertions(+) > > diff --git a/net/trace-events b/net/trace

Re: [PATCH 39/40] vdpa: add trace events for vhost_vdpa_net_load_cmd

2023-12-11 Thread Eugenio Perez Martin
On Thu, Dec 7, 2023 at 7:51 PM Si-Wei Liu wrote: > > For better debuggability and observability. > > Signed-off-by: Si-Wei Liu Reviewed-by: Eugenio Pérez > --- > net/trace-events | 2 ++ > net/vhost-vdpa.c | 2 ++ > 2 files changed, 4 insertions(+) > > diff --git a/net/trace-events b/net/trac

Re: [PATCH 37/40] vdpa: add vhost_vdpa_set_dev_vring_base trace for svq mode

2023-12-11 Thread Eugenio Perez Martin
On Thu, Dec 7, 2023 at 7:51 PM Si-Wei Liu wrote: > > For better debuggability and observability. > > Signed-off-by: Si-Wei Liu Reviewed-by: Eugenio Pérez > --- > hw/virtio/trace-events | 2 +- > hw/virtio/vhost-vdpa.c | 5 - > 2 files changed, 5 insertions(+), 2 deletions(-) > > diff --gi

Re: [PATCH 36/40] vdpa: add vhost_vdpa_get_vring_base trace for svq mode

2023-12-11 Thread Eugenio Perez Martin
On Thu, Dec 7, 2023 at 7:51 PM Si-Wei Liu wrote: > > For better debuggability and observability. > > Signed-off-by: Si-Wei Liu Reviewed-by: Eugenio Pérez > --- > hw/virtio/trace-events | 2 +- > hw/virtio/vhost-vdpa.c | 3 ++- > 2 files changed, 3 insertions(+), 2 deletions(-) > > diff --git

Re: [PATCH 35/40] vdpa: add vhost_vdpa_set_address_space_id trace

2023-12-11 Thread Eugenio Perez Martin
On Thu, Dec 7, 2023 at 7:51 PM Si-Wei Liu wrote: > > For better debuggability and observability. > > Signed-off-by: Si-Wei Liu Reviewed-by: Eugenio Pérez > --- > net/trace-events | 3 +++ > net/vhost-vdpa.c | 3 +++ > 2 files changed, 6 insertions(+) > > diff --git a/net/trace-events b/net/tr

[PATCH v7 10/11] hw/net: GMAC Tx Implementation

2023-12-11 Thread Nabih Estefan
From: Nabih Estefan Diaz - Implementation of Transmit function for packets - Implementation for reading and writing from and to descriptors in memory for Tx NOTE: This function implements the steps detailed in the datasheet for transmitting messages from the GMAC. Change-Id: I6b8ba0736fa5cc86

[PATCH v7 04/11] hw/net: Add NPCMXXX GMAC device

2023-12-11 Thread Nabih Estefan
From: Hao Wu This patch implements the basic registers of GMAC device and sets registers for networking functionalities. Tested: The following message shows up with the change: Broadcom BCM54612E stmmac-0:00: attached PHY driver [Broadcom BCM54612E] (mii_bus:phy_addr=stmmac-0:00, irq=POLL) stmm

[PATCH v7 03/11] hw/misc: Add qtest for NPCM7xx PCI Mailbox

2023-12-11 Thread Nabih Estefan
From: Hao Wu This patches adds a qtest for NPCM7XX PCI Mailbox module. It sends read and write requests to the module, and verifies that the module contains the correct data after the requests. Change-Id: I3948da277fc26352068420a26d8cc7cb2674cf40 Signed-off-by: Hao Wu Signed-off-by: Nabih Estef

[PATCH v7 09/11] hw/net: GMAC Rx Implementation

2023-12-11 Thread Nabih Estefan
From: Nabih Estefan Diaz - Implementation of Receive function for packets - Implementation for reading and writing from and to descriptors in memory for Rx When RX starts, we need to flush the queued packets so that they can be received by the GMAC device. Without this it won't work with TAP N

[PATCH v7 11/11] tests/qtest: Adding PCS Module test to GMAC Qtest

2023-12-11 Thread Nabih Estefan
From: Nabih Estefan Diaz - Add PCS Register check to npcm_gmac-test Change-Id: Iddbd17df490004deadeb734a1dd7420a7e6963d5 Signed-off-by: Nabih Estefan Reviewed-by: Tyrone Ting --- tests/qtest/npcm_gmac-test.c | 134 ++- 1 file changed, 133 insertions(+), 1 dele

[PATCH v7 06/11] tests/qtest: Creating qtest for GMAC Module

2023-12-11 Thread Nabih Estefan
From: Nabih Estefan Diaz - Created qtest to check initialization of registers in GMAC Module. - Implemented test into Build File. Change-Id: I399e52af301492d0eb97b556c1f67be44122779d Signed-off-by: Nabih Estefan Reviewed-by: Tyrone Ting --- tests/qtest/meson.build | 2 + tests/qtest/

[PATCH v7 08/11] hw/net: General GMAC Implementation

2023-12-11 Thread Nabih Estefan
From: Nabih Estefan Diaz - General GMAC Register handling - GMAC IRQ Handling - Added traces in some methods for debugging - Lots of declarations for accessing information on GMAC Descriptors (npcm_gmac.h file) NOTE: With code on this state, the GMAC can boot-up properly and will show up in th

[PATCH v7 01/11] hw/misc: Add Nuvoton's PCI Mailbox Module

2023-12-11 Thread Nabih Estefan
From: Hao Wu The PCI Mailbox Module is a high-bandwidth communcation module between a Nuvoton BMC and CPU. It features 16KB RAM that are both accessible by the BMC and core CPU. and supports interrupt for both sides. This patch implements the BMC side of the PCI mailbox module. Communication wit

[PATCH v7 05/11] hw/arm: Add GMAC devices to NPCM7XX SoC

2023-12-11 Thread Nabih Estefan
From: Hao Wu Change-Id: I0e323acbe9d1ac5138764e7fe70a8423af414454 Signed-off-by: Hao Wu Signed-off-by: Nabih Estefan Reviewed-by: Tyrone Ting --- hw/arm/npcm7xx.c | 36 ++-- include/hw/arm/npcm7xx.h | 2 ++ 2 files changed, 36 insertions(+), 2 deletion

[PATCH v7 07/11] include/hw/net: Implemented Classes and Masks for GMAC Descriptors

2023-12-11 Thread Nabih Estefan
From: Nabih Estefan Diaz - Implemeted classes for GMAC Receive and Transmit Descriptors - Implemented Masks for said descriptors Change-Id: I1d3c7fafcade53ebf5917f09fd2d78620d14cfd5 Signed-off-by: Nabih Estefan Reviewed-by: Tyrone Ting --- hw/net/npcm_gmac.c | 183

[PATCH v7 02/11] hw/arm: Add PCI mailbox module to Nuvoton SoC

2023-12-11 Thread Nabih Estefan
From: Hao Wu This patch wires the PCI mailbox module to Nuvoton SoC. Change-Id: I64ab900bc8bd7c379a11d86f2b8dcfccb49e66ab Signed-off-by: Hao Wu Signed-off-by: Nabih Estefan Reviewed-by: Tyrone Ting --- docs/system/arm/nuvoton.rst | 2 ++ hw/arm/npcm7xx.c| 3 ++- include/hw/arm/np

  1   2   3   >