Re: [PATCH v2 2/3] qemu-img: map: report compressed data blocks

2023-08-28 Thread Andrey Drobyshev
On 8/25/23 17:14, Hanna Czenczek wrote: > On 06.07.23 18:30, Andrey Drobyshev wrote: >> Right now "qemu-img map" reports compressed blocks as containing data >> but having no host offset.  This is not very informative.  Instead, >> let's add another boolean field named "compressed" in case JSON out

Re: [PATCH v2 3/8] machine: Print supported CPU models instead of typenames

2023-08-28 Thread Gavin Shan
Hi Igor, On 8/29/23 00:46, Igor Mammedov wrote: On Mon, 31 Jul 2023 15:07:30 +1000 Gavin Shan wrote: On 7/27/23 19:00, Igor Mammedov wrote: On Thu, 27 Jul 2023 15:16:18 +1000 Gavin Shan wrote: On 7/27/23 09:08, Richard Henderson wrote: On 7/25/23 17:32, Gavin Shan wrote: -static const

Re: [PATCH v2 3/4] qcow2: add zoned emulation capability

2023-08-28 Thread Sam Li
Damien Le Moal 于2023年8月29日周二 14:06写道: > > On 8/28/23 20:55, Sam Li wrote: > >>> +/* close one implicitly open zones to make it available */ > >>> +for (int i = s->zoned_header.zone_nr_conv; > >>> +i < bs->bl.nr_zones; ++i) { > >>> +uint64_t *wp =

Re: [PATCH for-8.2] target/s390x/kvm: Simplify the GPRs, ACRs, CRs and prefix synchronization code

2023-08-28 Thread Cédric Le Goater
Hello Thomas, On 8/28/23 20:20, Thomas Huth wrote: On 14/08/2023 21.06, Thomas Huth wrote: KVM_SYNC_GPRS, KVM_SYNC_ACRS, KVM_SYNC_CRS and KVM_SYNC_PREFIX are available since kernel 3.10. Since we already require at least kernel 3.15 in the s390x KVM code, we can assume that the KVM_CAP_SYNC_REG

Re: [PATCH v2 00/48] tcg patch queue

2023-08-28 Thread Bastian Koppelmann
On Mon, Aug 28, 2023 at 06:52:42PM -0400, Stefan Hajnoczi wrote: > On Thu, 24 Aug 2023 at 14:29, Richard Henderson > wrote: > > > > The following changes since commit 50e7a40af372ee5931c99ef7390f5d3d6fbf6ec4: > > > > Merge tag 'pull-target-arm-20230824' of > > https://git.linaro.org/people/pmay

Re: [PATCH v2 3/4] qcow2: add zoned emulation capability

2023-08-28 Thread Damien Le Moal
On 8/28/23 20:55, Sam Li wrote: >>> +/* close one implicitly open zones to make it available */ >>> +for (int i = s->zoned_header.zone_nr_conv; >>> +i < bs->bl.nr_zones; ++i) { >>> +uint64_t *wp = &s->wps->wp[i]; >>> +if (qcow2_get

[PATCH v4 3/8] vhost: Expose vhost_svq_available_slots()

2023-08-28 Thread Hawkins Jiawei
Next patches in this series will delay the polling and checking of buffers until either the SVQ is full or control commands shadow buffers are full, no longer perform an immediate poll and check of the device's used buffers for each CVQ state load command. To achieve this, this patch exposes vhost

[PATCH v4 5/8] vdpa: Check device ack in vhost_vdpa_net_load_rx_mode()

2023-08-28 Thread Hawkins Jiawei
Considering that vhost_vdpa_net_load_rx_mode() is only called within vhost_vdpa_net_load_rx() now, this patch refactors vhost_vdpa_net_load_rx_mode() to include a check for the device's ack, simplifying the code and improving its maintainability. Signed-off-by: Hawkins Jiawei Acked-by: Eugenio Pé

[PATCH v4 8/8] vdpa: Send cvq state load commands in parallel

2023-08-28 Thread Hawkins Jiawei
This patch enables sending CVQ state load commands in parallel at device startup by following steps: * Refactor vhost_vdpa_net_load_cmd() to iterate through the control commands shadow buffers. This allows different CVQ state load commands to use their own unique buffers. * Delay the polling

[PATCH v4 4/8] vdpa: Avoid using vhost_vdpa_net_load_*() outside vhost_vdpa_net_load()

2023-08-28 Thread Hawkins Jiawei
Next patches in this series will refactor vhost_vdpa_net_load_cmd() to iterate through the control commands shadow buffers, allowing QEMU to send CVQ state load commands in parallel at device startup. Considering that QEMU always forwards the CVQ command serialized outside of vhost_vdpa_net_load()

[PATCH v4 6/8] vdpa: Move vhost_svq_poll() to the caller of vhost_vdpa_net_cvq_add()

2023-08-28 Thread Hawkins Jiawei
This patch moves vhost_svq_poll() to the caller of vhost_vdpa_net_cvq_add() and introduces a helper funtion. By making this change, next patches in this series is able to refactor vhost_vdpa_net_load_x() only to delay the polling and checking process until either the SVQ is full or control command

[PATCH v4 1/8] vhost: Add count argument to vhost_svq_poll()

2023-08-28 Thread Hawkins Jiawei
Next patches in this series will no longer perform an immediate poll and check of the device's used buffers for each CVQ state load command. Instead, they will send CVQ state load commands in parallel by polling multiple pending buffers at once. To achieve this, this patch refactoring vhost_svq_po

[PATCH v4 7/8] vdpa: Introduce cursors to vhost_vdpa_net_loadx()

2023-08-28 Thread Hawkins Jiawei
This patch introduces two new arugments, `out_cursor` and `in_cursor`, to vhost_vdpa_net_loadx(). Addtionally, it includes a helper function vhost_vdpa_net_load_cursor_reset() for resetting these cursors. Furthermore, this patch refactors vhost_vdpa_net_load_cmd() so that vhost_vdpa_net_load_cmd()

[PATCH v4 0/8] vdpa: Send all CVQ state load commands in parallel

2023-08-28 Thread Hawkins Jiawei
This patchset allows QEMU to delay polling and checking the device used buffer until either the SVQ is full or control commands shadow buffers are full, instead of polling and checking immediately after sending each SVQ control command, so that QEMU can send all the SVQ control commands in parallel

[PATCH v4 2/8] vdpa: Use iovec for vhost_vdpa_net_cvq_add()

2023-08-28 Thread Hawkins Jiawei
Next patches in this series will no longer perform an immediate poll and check of the device's used buffers for each CVQ state load command. Consequently, there will be multiple pending buffers in the shadow VirtQueue, making it a must for every control command to have its own buffer. To achieve t

[PATCH v4 1/2] target/i386: Avoid cpu number overflow in legacy topology

2023-08-28 Thread Qian Wen
The legacy topology enumerated by CPUID.1.EBX[23:16] is defined in SDM Vol2: Bits 23-16: Maximum number of addressable IDs for logical processors in this physical package. When threads_per_socket > 255, it will 1) overwrite bits[31:24] which is apic_id, 2) bits [23:16] get truncated. Specificall

[PATCH v4 0/2] Fix overflow of the max number of IDs for logic processor and core

2023-08-28 Thread Qian Wen
CPUID.1.EBX[23:16]: Maximum number of addressable IDs for logical processors in this physical package. CPUID.4:EAX[31:26]: Maximum number of addressable IDs for processor cores in the physical package. The current qemu code doesn't limit the value written to these two fields. If the guest has a hu

[PATCH v4 2/2] target/i386: Avoid overflow of the cache parameter enumerated by leaf 4

2023-08-28 Thread Qian Wen
According to SDM, CPUID.0x4:EAX[31:26] indicates the Maximum number of addressable IDs for processor cores in the physical package. If we launch over 64 cores VM, the 6-bit field will overflow, and the wrong core_id number will be reported. Since the HW reports 0x3f when the intel processor has ov

Re: [RFC PATCH v2 0/6] Add API for list cpu extensions

2023-08-28 Thread LIU Zhiwei
On 2023/8/28 21:58, Igor Mammedov wrote: On Mon, 28 Aug 2023 16:45:30 +0800 LIU Zhiwei wrote: Some times we want to know what is the really mean of one cpu option. For example, in RISC-V, we usually specify a cpu in this way: -cpu rv64,v=on If we don't look into the source code, we can't ge

[RESEND] memory: avoid updating ioeventfds for some address_space

2023-08-28 Thread hongmianquan
When updating ioeventfds, we need to iterate all address spaces, but some address spaces do not register eventfd_add|del call when memory_listener_register() and they do nothing when updating ioeventfds. So we can skip these AS in address_space_update_ioeventfds(). The overhead of memory_region_tr

[PATCH] accel/tcg: mttcg remove false-negative halted assertion

2023-08-28 Thread Nicholas Piggin
mttcg asserts that an execution ending with EXCP_HALTED must have cpu->halted. However between the event or instruction that sets cpu->halted and requests exit and the assertion here, an asynchronous event could clear cpu->halted. This leads to crashes running AIX on ppc/pseries because it uses H_

Re: [PATCH v11 0/9] rutabaga_gfx + gfxstream

2023-08-28 Thread Gurchetan Singh
On Fri, Aug 25, 2023 at 12:37 PM Alyssa Ross wrote: > Alyssa Ross writes: > > > Gurchetan Singh writes: > > > >> On Fri, Aug 25, 2023 at 12:11 AM Alyssa Ross wrote: > >> > >>> Gurchetan Singh writes: > >>> > >>> > On Wed, Aug 23, 2023 at 4:07 AM Alyssa Ross wrote: > >>> > > >>> >> Gurchetan

[PATCH v13 9/9] docs/system: add basic virtio-gpu documentation

2023-08-28 Thread Gurchetan Singh
This adds basic documentation for virtio-gpu. Suggested-by: Akihiko Odaki Signed-off-by: Gurchetan Singh Tested-by: Alyssa Ross Tested-by: Emmanouil Pitsidianakis Tested-by: Akihiko Odaki Reviewed-by: Emmanouil Pitsidianakis Reviewed-by: Antonio Caggiano Reviewed-by: Akihiko Odaki --- doc

[PATCH v13 6/9] gfxstream + rutabaga: add initial support for gfxstream

2023-08-28 Thread Gurchetan Singh
This adds initial support for gfxstream and cross-domain. Both features rely on virtio-gpu blob resources and context types, which are also implemented in this patch. gfxstream has a long and illustrious history in Android graphics paravirtualization. It has been powering graphics in the Android

[PATCH v13 7/9] gfxstream + rutabaga: meson support

2023-08-28 Thread Gurchetan Singh
- Add meson detection of rutabaga_gfx - Build virtio-gpu-rutabaga.c + associated vga/pci files when present Signed-off-by: Gurchetan Singh Tested-by: Alyssa Ross Tested-by: Emmanouil Pitsidianakis Tested-by: Akihiko Odaki Reviewed-by: Emmanouil Pitsidianakis Reviewed-by: Antonio Caggiano R

[PATCH v13 3/9] virtio-gpu: hostmem

2023-08-28 Thread Gurchetan Singh
From: Gerd Hoffmann Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. Signed-off-by: Antonio Caggiano Tested-by: Alyssa Ross Tested-by: Akihiko Odaki Acked-by: Michael S. Tsirkin Reviewed-by: Akihiko Odaki --- hw/display/virtio-gpu-pci.c| 14 ++ hw/display/virtio-gpu

[PATCH v13 8/9] gfxstream + rutabaga: enable rutabaga

2023-08-28 Thread Gurchetan Singh
This change enables rutabaga to receive virtio-gpu-3d hypercalls when it is active. Signed-off-by: Gurchetan Singh Tested-by: Alyssa Ross Tested-by: Emmanouil Pitsidianakis Tested-by: Akihiko Odaki Reviewed-by: Antonio Caggiano Reviewed-by: Emmanouil Pitsidianakis Reviewed-by: Akihiko Odaki

[PATCH v13 1/9] virtio: Add shared memory capability

2023-08-28 Thread Gurchetan Singh
From: "Dr. David Alan Gilbert" Define a new capability type 'VIRTIO_PCI_CAP_SHARED_MEMORY_CFG' to allow defining shared memory regions with sizes and offsets of 2^32 and more. Multiple instances of the capability are allowed and distinguished by a device-specific 'id'. Signed-off-by: Dr. David A

[PATCH v13 4/9] virtio-gpu: blob prep

2023-08-28 Thread Gurchetan Singh
From: Antonio Caggiano This adds preparatory functions needed to: - decode blob cmds - tracking iovecs Signed-off-by: Antonio Caggiano Signed-off-by: Dmitry Osipenko Signed-off-by: Gurchetan Singh Tested-by: Alyssa Ross Tested-by: Emmanouil Pitsidianakis Tested-by: Akihiko Odaki

[PATCH v13 0/9] rutabaga_gfx + gfxstream

2023-08-28 Thread Gurchetan Singh
From: Gurchetan Singh Changes since v12: - Added r-b tags from Antonio Caggiano and Akihiko Odaki - Removed review version from commit messages - I think we're good to merge since we've had multiple people test and review this series?? How to build both rutabaga and gfxstream guest/host libs:

[PATCH v13 5/9] gfxstream + rutabaga prep: added need defintions, fields, and options

2023-08-28 Thread Gurchetan Singh
This modifies the common virtio-gpu.h file have the fields and defintions needed by gfxstream/rutabaga, by VirtioGpuRutabaga. Signed-off-by: Gurchetan Singh Tested-by: Alyssa Ross Tested-by: Emmanouil Pitsidianakis Tested-by: Akihiko Odaki Reviewed-by: Emmanouil Pitsidianakis Reviewed-by: Ant

[PATCH v13 2/9] virtio-gpu: CONTEXT_INIT feature

2023-08-28 Thread Gurchetan Singh
From: Antonio Caggiano The feature can be enabled when a backend wants it. Signed-off-by: Antonio Caggiano Signed-off-by: Gurchetan Singh Tested-by: Alyssa Ross Tested-by: Akihiko Odaki Reviewed-by: Marc-André Lureau Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Akihiko Odaki --- hw/d

Re: [QEMU][PATCH v3 2/2] xen_arm: Initialize RAM and add hi/low memory regions

2023-08-28 Thread Stefano Stabellini
On Fri, 25 Aug 2023, Vikram Garhwal wrote: > From: Oleksandr Tyshchenko > > In order to use virtio backends we need to initialize RAM for the > xen-mapcache (which is responsible for mapping guest memory using foreign > mapping) to work. Calculate and add hi/low memory regions based on > machine-

Re: [QEMU][PATCH v3 1/2] xen_arm: Create virtio-mmio devices during initialization

2023-08-28 Thread Stefano Stabellini
On Fri, 25 Aug 2023, Vikram Garhwal wrote: > From: Oleksandr Tyshchenko > > In order to use virtio backends we need to allocate virtio-mmio > parameters (irq and base) and register corresponding buses. > > Use the constants defined in public header arch-arm.h to be > aligned with the toolstack.

[PULL 34/36] bsd-user: Add glue for statfs related system calls

2023-08-28 Thread Warner Losh
Add glue to call the following syscalls to the freebsd_syscall: freebsd11_statfs statfs freebsd11_fstatfs fstatfs freebsd11_getfsstat getfsstat Signed-off-by: Warner Losh Signed-off-by: Karim Taha Reviewed-by: Richard Henderson --- bsd-user/freebsd/os-syscall.c | 24

[PULL 33/36] bsd-user: Add glue for getfh and related syscalls

2023-08-28 Thread Warner Losh
Add glue to call the following syscalls to the freebsd_syscall: getfh lgetfh fhopen freebsd11_fhstat freebsd11_fhstatfs fhstat fhstatfs Signed-off-by: Warner Losh Signed-off-by: Karim Taha Reviewed-by: Richard Henderson --- bsd-user/freebsd/os-syscall.c | 28 1 fi

[PULL 27/36] bsd-user: Implement freebsd11 statfs related syscalls

2023-08-28 Thread Warner Losh
From: Michal Meloun Implement the freebsd11 variant of the following syscalls: statfs(2) fstatfs(2) getfsstat(2) Co-authored-by: Stacey Son Signed-off-by: Stacey Son Signed-off-by: Michal Meloun Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-us

[PULL 18/36] bsd-user: Implement target_to_host_fcntl_cmd

2023-08-28 Thread Warner Losh
From: Stacey Son Implement the stat conversion functions: target_to_host_fcntl_cmd Signed-off-by: Stacey Son Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.c | 8 1 file changed, 8 insertions(+) diff --git a/bsd-use

[PULL 29/36] bsd-user: Implement freebsd11 netbsd stat related syscalls

2023-08-28 Thread Warner Losh
From: Michal Meloun Forward declaration of the nstat syscalls: nstat nlstat nfstat Co-authored-by: Stacey Son Signed-off-by: Stacey Son Signed-off-by: Michal Meloun Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.h | 7 +

[PULL 28/36] bsd-user: Implement freebsd11 getdirents related syscalls

2023-08-28 Thread Warner Losh
From: Michal Meloun Implement the freebsd11 variant of the following syscalls: getdirentries(2) Co-authored-by: Stacey Son Signed-off-by: Stacey Son Signed-off-by: Michal Meloun Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-sta

[PULL 30/36] bsd-user: Implement do_freebsd_realpathat syscall

2023-08-28 Thread Warner Losh
From: Mikaël Urankar Signed-off-by: Mikaël Urankar Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.h | 26 ++ 1 file changed, 26 insertions(+) diff --git a/bsd-user/freebsd/os-stat.h b/bsd-user/freebsd/

[PULL 07/36] bsd-user: Declarations of h2t and t2h conversion functions.

2023-08-28 Thread Warner Losh
From: Stacey Son Declarations of functions that convert between host and target structs. Co-authored-by: Michal Meloun Signed-off-by: Stacey Son Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/qemu-os.h | 50

[PULL 32/36] bsd-user: Add glue for the freebsd11_stat syscalls

2023-08-28 Thread Warner Losh
Add glue to call the freebsd11_stat syscalls to the freebsd_syscall: freebsd11_stat freebsd11_lstat freebsd11_fstat freebsd11_fstatat freebsd11_nstat, freebsd11_nfstat, freebsd11_nlstat fstatat fstat Signed-off-by: Warner Losh Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off

[PULL 36/36] bsd-user: Add missing break after do_bsd_preadv

2023-08-28 Thread Warner Losh
Without it, we'd call preadv, then write with weird parameters, which is clearly not ideal... Signed-off-by: Warner Losh Reviewed-by: Philippe Mathieu-Daudé Fixes: 770d8abae7 ("bsd-user/bsd-file.h: Meat of the write system calls") Reviewed-by: Richard Henderson Message-Id: <20230820045419.89691

[PULL 14/36] bsd-user: Rename target_freebsd_time_t to target_time_t

2023-08-28 Thread Warner Losh
This is necessary for future code using target_time_t, in bsd-user/syscall_defs. Signed-off-by: Warner Losh Signed-off-by: Karim Taha Reviewed-by: Richard Henderson --- bsd-user/syscall_defs.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/bsd-user/syscall_defs.h b

[PULL 12/36] bsd-user: Add struct target_freebsd_fhandle and fcntl flags

2023-08-28 Thread Warner Losh
From: Stacey Son Add struct target_freebsd_fhandle and fcntl flags to bsd-user/syscall_defs.h Signed-off-by: Stacey Son Signed-off-by: Karim Taha Acked-by: Richard Henderson Reviewed-by: Warner Losh Signed-off-by: Warner Losh --- bsd-user/syscall_defs.h | 51 +++

[PULL 06/36] bsd-user; Update the definitions of __put_user and __get_user macros

2023-08-28 Thread Warner Losh
Use __builtin_choose_expr to avoid type promotion from ?: in __put_user_e and __get_user_e macros. Copied from linux-user/qemu.h, originally by Blue Swirl. Signed-off-by: Warner Losh Signed-off-by: Karim Taha Reviewed-by: Richard Henderson --- bsd-user/qemu.h | 81 ---

[PULL 35/36] bsd-user: Add getdents and fcntl related system calls

2023-08-28 Thread Warner Losh
Add glue to call the following syscalls to the freebsd_syscall: freebsd11_getdents getdirentries freebsd11_getdirentries fcntl Signed-off-by: Warner Losh Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-syscall.c | 16 +++

[PULL 23/36] bsd-user: Implement getdents related syscalls

2023-08-28 Thread Warner Losh
From: Stacey Son Implement the following syscalls: getdents(2) getdirecentries(2) Signed-off-by: Stacey Son Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.h | 72 ++ 1 file changed, 72 inse

[PULL 16/36] bsd-user: Implement h2t_freebsd_fhandle t2h_freebsd_fhandle

2023-08-28 Thread Warner Losh
From: Stacey Son Implement the stat conversion functions: h2t_freebsd_fhandle t2h_freebsd_fhandle Signed-off-by: Stacey Son Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.c | 37 + 1 file c

[PULL 13/36] bsd-user: Define safe_fcntl macro in bsd-user/syscall_defs.h

2023-08-28 Thread Warner Losh
From: Kyle Evans Signed-off-by: Kyle Evans Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/syscall_defs.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bsd-user/syscall_defs.h b/bsd-user/syscall_defs.h index 96ae90b0631..c6699c9943e 10

[PULL 09/36] bsd-user: Add struct target_stat to bsd-user/syscall_defs.h

2023-08-28 Thread Warner Losh
From: Michal Meloun Signed-off-by: Michal Meloun Signed-off-by: Karim Taha Acked-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/syscall_defs.h | 38 ++ 1 file changed, 38 insertions(+) diff --git a/bsd-user/syscall_defs.h b/bsd-user/syscal

[PULL 08/36] bsd-user: Add struct target_freebsd11_stat to bsd-user/syscall_defs

2023-08-28 Thread Warner Losh
From: Stacey Son Signed-off-by: Stacey Son Signed-off-by: Karim Taha Acked-by: Richard Henderson Singed-off-by: Warner Losh --- bsd-user/syscall_defs.h | 33 + 1 file changed, 33 insertions(+) diff --git a/bsd-user/syscall_defs.h b/bsd-user/syscall_defs.h ind

[PULL 03/36] bsd-user: Remove image_info.start_brk

2023-08-28 Thread Warner Losh
From: Richard Henderson This has the same value is image_info.brk, which is also logged, and is otherwise unused. Signed-off-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20230818175736.144194-4-richard.hender...@linaro.org> Reviewed-by: Warner Losh Signed-off-by: War

[PULL 11/36] bsd-user: Add struct target_statfs

2023-08-28 Thread Warner Losh
From: Michal Meloun Add struct target_statfs to bsd-user/syscall_defs.h Signed-off-by: Michal Meloun Signed-off-by: Karim Taha Acked-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/syscall_defs.h | 25 + 1 file changed, 25 insertions(+) diff --git a/bs

[PULL 05/36] bsd-user: Disable clang warnings

2023-08-28 Thread Warner Losh
From: Kyle Evans Implement PRAGMA_DISABLE_PACKED_WARNING and PRAGMA_REENABLE_PACKED_WARNING macros in include/qemu/compiler.h. Signed-off-by: Kyle Evans Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- include/qemu/compiler.h | 30 +

[PULL 31/36] bsd-user: Add os-stat.c to the build

2023-08-28 Thread Warner Losh
From: Karim Taha Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/meson.build | 1 + 1 file changed, 1 insertion(+) diff --git a/bsd-user/freebsd/meson.build b/bsd-user/freebsd/meson.build index f87c788e846..f2f047cca31 100644 --- a/bsd

[PULL 04/36] bsd-user: Move _WANT_FREEBSD macros to include/qemu/osdep.h

2023-08-28 Thread Warner Losh
move _WANT_FREEBSD macros from bsd-user/freebsd/os-syscall.c to include/qemu/osdep.h in order to pull some struct defintions needed later in the build. Signed-off-by: Warner Losh Signed-off-by: Karim Taha Acked-by: Richard Henderson --- bsd-user/freebsd/os-syscall.c | 11 --- include/q

[PULL 26/36] bsd-user: Implement freebsd11 fstat and fhstat related syscalls

2023-08-28 Thread Warner Losh
From: Michal Meloun Implement the freebsd11 variant of the following syscalls: fstat(2) fstatat(2) fhstat(2) fhstatfs(2) Co-authored-by: Stacey Son Signed-off-by: Stacey Son Signed-off-by: Michal Meloun Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh ---

[PULL 17/36] bsd-user: Implement h2t_freebds11_statfs

2023-08-28 Thread Warner Losh
From: Stacey Son Implement the stat conversion functions: h2t_freebds11_statfs Signed-off-by: Stacey Son Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.c | 41 ++ 1 file changed, 41 inserti

[PULL 10/36] bsd-user: Add structs target_freebsd11_{nstat,statfs}

2023-08-28 Thread Warner Losh
From: Stacey Son Add structs target_freebsd11_nstat and target_freebsd11_statfs to bsd-user/syscall_defs.h Signed-off-by: Stacey Son Signed-off-by: Karim Taha Acked-by: Richard Henderson --- bsd-user/syscall_defs.h | 64 + 1 file changed, 64 insertions

[PULL 20/36] bsd-user: Implement stat related syscalls

2023-08-28 Thread Warner Losh
From: Stacey Son Implement the following syscalls: stat(2) lstat(2) fstat(2) fstatat(2) nstat nfstat nlstat Signed-off-by: Stacey Son Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.h | 130

[PULL 25/36] bsd-user: Implement freebsd11 stat related syscalls

2023-08-28 Thread Warner Losh
From: Michal Meloun Rename the following syscalls to the freebsd11 variant: do_freebsd_lstat -> do_freebsd11_lstat do_freebsd_stat -> do_freebsd11_stat Co-authored-by: Stacey Son Signed-off-by: Stacey Son Signed-off-by: Michal Meloun Signed-off-by: Karim Taha Reviewed-by: Richard Henderson

[PULL 01/36] bsd-user: Remove ELF_START_MMAP and image_info.start_mmap

2023-08-28 Thread Warner Losh
From: Richard Henderson The start_mmap value is write-only. Remove the field and the defines that populated it. Signed-off-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20230818175736.144194-2-richard.hender...@linaro.org> Reviewed-by: Warner Losh Signed-off-by: Warne

[PULL 19/36] bsd-uesr: Implement h2t_freebsd_stat and h2t_freebsd_statfs functions

2023-08-28 Thread Warner Losh
From: Michal Meloun They are the 64-bit variants of h2t_freebsd11_stat and h2t_freebsd11_statfs, respectively Signed-off-by: Michal Meloun Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.c | 82

[PULL 15/36] bsd-user: Implement h2t_freebsd11_stat h2t_freebsd_nstat

2023-08-28 Thread Warner Losh
From: Stacey Son Implement the stat conversion functions: h2t_freebsd11_stat h2t_freebsd_nstat Signed-off-by: Stacey Son Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.c | 94 ++ 1 file cha

[PULL 21/36] bsd-user: Implement statfh related syscalls

2023-08-28 Thread Warner Losh
From: Stacey Son Implement the following syscalls: getfh(2) lgetfh(2) fhopen(2) fhstat(2) fhstatfs(2) Signed-off-by: Stacey Son Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.h | 83 ++ 1 f

[PULL 00/36] 2023q3 bsd user patches

2023-08-28 Thread Warner Losh
The following changes since commit 50e7a40af372ee5931c99ef7390f5d3d6fbf6ec4: Merge tag 'pull-target-arm-20230824' of https://git.linaro.org/people/pmaydell/qemu-arm into staging (2023-08-24 10:08:33 -0400) are available in the Git repository at: g...@gitlab.com:bsdimp/qemu.git tags/2023q3-

[PULL 02/36] bsd-user: Remove image_info.mmap

2023-08-28 Thread Warner Losh
From: Richard Henderson This value is unused. Signed-off-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20230818175736.144194-3-richard.hender...@linaro.org> Reviewed-by: Warner Losh Signed-off-by: Warner Losh --- bsd-user/elfload.c | 1 - bsd-user/qemu.h| 1 - 2

[PULL 24/36] bsd-user: Implement stat related syscalls

2023-08-28 Thread Warner Losh
From: Stacey Son Implement the following syscalls: fcntl(2) Signed-off-by: Stacey Son Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.h | 74 ++ 1 file changed, 74 insertions(+) diff --git

[PULL 22/36] bsd-user: Implement statfs related syscalls

2023-08-28 Thread Warner Losh
From: Stacey Son Implement the following syscalls: statfs(2) fstatfs(2) getfsstat(2) Signed-off-by: Stacey Son Signed-off-by: Karim Taha Reviewed-by: Richard Henderson Signed-off-by: Warner Losh --- bsd-user/freebsd/os-stat.h | 69 ++ 1 file changed, 69 i

[PATCH v2 3/7] hw/fsi: Introduce IBM's cfam,fsi-slave

2023-08-28 Thread Ninad Palsule
This is a part of patchset where IBM's Flexible Service Interface is introduced. The Common FRU Access Macro (CFAM), an address space containing various "engines" that drive accesses on busses internal and external to the POWER chip. Examples include the SBEFIFO and I2C masters. The engines hang o

[PATCH v2 7/7] hw/arm: Hook up FSI module in AST2600

2023-08-28 Thread Ninad Palsule
This patchset introduces IBM's Flexible Service Interface(FSI). Time for some fun with inter-processor buses. FSI allows a service processor access to the internal buses of a host POWER processor to perform configuration or debugging. FSI has long existed in POWER processes and so comes with some

[PATCH v2 2/7] hw/fsi: Introduce IBM's scratchpad

2023-08-28 Thread Ninad Palsule
This is a part of patchset where IBM's Flexible Service Interface is introduced. The LBUS device is embeded inside the scratchpad. The scratchpad provides a non-functional registers. There is a 1-1 relation between scratchpad and LBUS devices. Each LBUS device has 1K memory mapped in the LBUS. Si

[PATCH v2 1/7] hw/fsi: Introduce IBM's Local bus

2023-08-28 Thread Ninad Palsule
This is a part of patchset where IBM's Flexible Service Interface is introduced. The LBUS is modelled to maintain the qdev bus hierarchy and to take advantage of the object model to automatically generate the CFAM configuration block. The configuration block presents engines in the order they are

Re: [PATCH v1 5/7] hw/fsi: IBM's On-chip Peripheral Bus

2023-08-28 Thread Ninad Palsule
Thanks for the review Joel. On 8/28/23 23:59, Joel Stanley wrote: On Fri, 25 Aug 2023 at 20:35, Ninad Palsule wrote: This is a part of patchset where IBM's Flexible Service Interface is introduced. The On-Chip Peripheral Bus (OPB): A low-speed bus typically found in POWER processors. This now

[PATCH v2 4/7] hw/fsi: Introduce IBM's FSI

2023-08-28 Thread Ninad Palsule
This is a part of patchset where IBM's Flexible Service Interface is introduced. This commit models the FSI bus. CFAM is hanging out of FSI bus. The bus is model such a way that it is embeded inside the FSI master which is a bus controller. The FSI master: A controller in the platform service pro

[PATCH v2 6/7] hw/fsi: Aspeed APB2OPB interface

2023-08-28 Thread Ninad Palsule
This is a part of patchset where IBM's Flexible Service Interface is introduced. An APB-to-OPB bridge enabling access to the OPB from the ARM core in the AST2600. Hardware limitations prevent the OPB from being directly mapped into APB, so all accesses are indirect through the bridge. Signed-off-

[PATCH v2 5/7] hw/fsi: IBM's On-chip Peripheral Bus

2023-08-28 Thread Ninad Palsule
This is a part of patchset where IBM's Flexible Service Interface is introduced. The On-Chip Peripheral Bus (OPB): A low-speed bus typically found in POWER processors. This now makes an appearance in the ASPEED SoC due to tight integration of the FSI master IP with the OPB, mainly the existence of

[PATCH v2 0/7] Introduce model for IBM's FSI

2023-08-28 Thread Ninad Palsule
Hello, Please review the patch-set version 2. I have incorporated review comments from Joel. Ninad Palsule (7): hw/fsi: Introduce IBM's Local bus hw/fsi: Introduce IBM's scratchpad hw/fsi: Introduce IBM's cfam,fsi-slave hw/fsi: Introduce IBM's FSI hw/fsi: IBM's On-chip Peripheral Bus

Re: [PATCH v1 4/7] hw/fsi: Introduce IBM's FSI

2023-08-28 Thread Ninad Palsule
Thanks for the review, Joel. On 8/28/23 23:57, Joel Stanley wrote: On Fri, 25 Aug 2023 at 20:44, Ninad Palsule wrote: This is a part of patchset where IBM's Flexible Service Interface is introduced. This commit models the FSI bus. CFAM is hanging out of FSI bus. The bus is model such a way th

Re: [PATCH v1 6/7] hw/fsi: Aspeed APB2OPB interface

2023-08-28 Thread Ninad Palsule
Hi Joel, On 8/28/23 23:55, Joel Stanley wrote: On Fri, 25 Aug 2023 at 20:31, Ninad Palsule wrote: This is a part of patchset where IBM's Flexible Service Interface is introduced. An APB-to-OPB bridge enabling access to the OPB from the ARM core in the AST2600. Hardware limitations prevent the

Re: [PATCH v1 7/7] hw/arm: Hook up FSI module in AST2600

2023-08-28 Thread Ninad Palsule
Hi Joel, On 8/28/23 23:48, Joel Stanley wrote: On Fri, 25 Aug 2023 at 20:35, Ninad Palsule wrote: This patchset introduces IBM's Flexible Service Interface(FSI). Time for some fun with inter-processor buses. FSI allows a service processor access to the internal buses of a host POWER processor

Re: [PATCH v1 1/7] hw/fsi: Introduce IBM's Local bus

2023-08-28 Thread Ninad Palsule
Hi Joel, On 8/28/23 23:34, Joel Stanley wrote: On Fri, 25 Aug 2023 at 20:31, Ninad Palsule wrote: This is a part of patchset where IBM's Flexible Service Interface is introduced. The LBUS is modelled to maintain the qdev bus hierarchy and to take advantage of the object model to automatically

Re: [PATCH v2 00/48] tcg patch queue

2023-08-28 Thread Stefan Hajnoczi
On Thu, 24 Aug 2023 at 14:29, Richard Henderson wrote: > > The following changes since commit 50e7a40af372ee5931c99ef7390f5d3d6fbf6ec4: > > Merge tag 'pull-target-arm-20230824' of > https://git.linaro.org/people/pmaydell/qemu-arm into staging (2023-08-24 > 10:08:33 -0400) > > are available in

Re: [PATCH 6/7] vhost-user: allow "vhost_set_vring" to wait for a reply

2023-08-28 Thread Philippe Mathieu-Daudé
On 27/8/23 20:29, Laszlo Ersek wrote: The "vhost_set_vring" function already centralizes the common parts of "vhost_user_set_vring_num", "vhost_user_set_vring_base" and "vhost_user_set_vring_enable". We'll want to allow some of those callers to wait for a reply. Therefore, rebase "vhost_set_vrin

Re: [PATCH 4/7] vhost-user: flatten "enforce_reply" into "vhost_user_write_msg"

2023-08-28 Thread Philippe Mathieu-Daudé
On 27/8/23 20:29, Laszlo Ersek wrote: At this point, only "vhost_user_write_msg" calls "enforce_reply"; embed the latter into the former. This is purely refactoring -- no observable change. Cc: "Michael S. Tsirkin" (supporter:vhost) Cc: Eugenio Perez Martin Cc: German Maglione Cc: Liu Jiang

Re: [PATCH 3/7] vhost-user: factor out "vhost_user_write_msg"

2023-08-28 Thread Philippe Mathieu-Daudé
On 27/8/23 20:29, Laszlo Ersek wrote: The tails of the "vhost_user_set_vring_addr" and "vhost_user_set_u64" functions are now byte-for-byte identical. Factor the common tail out to a new function called "vhost_user_write_msg". This is purely refactoring -- no observable change. Cc: "Michael S.

Re: [PATCH v2 16/16] virtio-mem: Mark memslot alias memory regions unmergeable

2023-08-28 Thread Philippe Mathieu-Daudé
On 25/8/23 15:21, David Hildenbrand wrote: Let's mark the memslot alias memory regions as unmergable, such that flatview and vhost won't merge adjacent memory region aliases and we can atomically map/unmap individual aliases without affecting adjacent alias memory regions. This handles vhost and

Re: [PATCH v2 15/16] memory,vhost: Allow for marking memory device memory regions unmergeable

2023-08-28 Thread Philippe Mathieu-Daudé
On 25/8/23 15:21, David Hildenbrand wrote: Let's allow for marking memory regions unmergeable, to teach flatview code and vhost to not merge adjacent aliases to the same memory region into a larger memory section; instead, we want separate aliases to stay separate such that we can atomically map/

Re: [PATCH v2 04/16] kvm: Return number of free memslots

2023-08-28 Thread Philippe Mathieu-Daudé
On 25/8/23 15:21, David Hildenbrand wrote: Let's return the number of free slots instead of only checking if there is a free slot. While at it, check all address spaces, which will also consider SMM under x86 correctly. Make the stub return UINT_MAX, such that we can call the function unconditio

[PATCH v2 09/11] target/xtensa: Include missing 'qemu/atomic.h' header

2023-08-28 Thread Philippe Mathieu-Daudé
Since commit fa92bd4af7 ("target/xtensa: fix access to the INTERRUPT SR") these files use QEMU atomic API. Explicit the header inclusion instead of relying on implicit and indirect inclusion. Signed-off-by: Philippe Mathieu-Daudé --- hw/xtensa/pic_cpu.c| 1 + target/xtensa/exc_helper.c |

[PATCH v2 00/11] target/translate: Remove unused "exec/cpu_ldst.h" / "qemu/main-loop.h"

2023-08-28 Thread Philippe Mathieu-Daudé
Yet another boring 'header cleanups' series :/ Since v1: - Addressed Richard review comment - Added Richard R-b tag - 3 more patches around 'qemu/qatomic.h' Philippe Mathieu-Daudé (11): target/ppc/pmu: Include missing 'qemu/timer.h' header target/riscv/pmu: Restrict 'qemu/log.h' include to so

[PATCH v2 11/11] exec/translation-block: Clean up includes

2023-08-28 Thread Philippe Mathieu-Daudé
'qemu/atomic.h' and 'exec/target_page.h' are not used. 'qemu/interval-tree.h' is only required for user emulation. Signed-off-by: Philippe Mathieu-Daudé --- include/exec/translation-block.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/exec/translation-block.h

[PATCH v2 06/11] target/helpers: Remove unnecessary 'exec/cpu_ldst.h' header

2023-08-28 Thread Philippe Mathieu-Daudé
These files don't use the CPU ld/st API, remove the unnecessary "exec/cpu_ldst.h" header. Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- target/riscv/pmu.h | 1 - target/cris/op_helper.c | 1 - target/mips/tcg/fpu_helper.c | 1 -

[PATCH v2 02/11] target/riscv/pmu: Restrict 'qemu/log.h' include to source

2023-08-28 Thread Philippe Mathieu-Daudé
Declarations from "riscv/pmu.h" don't need anything from "qemu/log.h", reduce it's inclusion to the source. Signed-off-by: Philippe Mathieu-Daudé --- target/riscv/pmu.h | 1 - target/riscv/pmu.c | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/target/riscv/pmu.h b/target/riscv

[PATCH v2 08/11] target/mips: Remove unused headers in lcsr_helper.c

2023-08-28 Thread Philippe Mathieu-Daudé
This files only access the address_space_ld/st API, declared in "exec/cpu-all.h", already included by "cpu.h". Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson --- target/mips/tcg/sysemu/lcsr_helper.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/target/mips/tcg/syse

[PATCH v2 10/11] qemu/processor: Remove unused 'qemu/atomic.h' header

2023-08-28 Thread Philippe Mathieu-Daudé
Signed-off-by: Philippe Mathieu-Daudé --- include/qemu/processor.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/include/qemu/processor.h b/include/qemu/processor.h index 8e16c9277d..9f0dcdf28f 100644 --- a/include/qemu/processor.h +++ b/include/qemu/processor.h @@ -7,8 +7,6 @@ #ifndef QE

[PATCH v2 01/11] target/ppc/pmu: Include missing 'qemu/timer.h' header

2023-08-28 Thread Philippe Mathieu-Daudé
Since commit c2eff582a3 ("target/ppc: PMU basic cycle count for pseries TCG") pmu_update_cycles() uses QEMU_CLOCK_VIRTUAL and calls qemu_clock_get_ns(), both defined in "qemu/timer.h". Signed-off-by: Philippe Mathieu-Daudé --- target/ppc/power8-pmu.c | 1 + 1 file changed, 1 insertion(+) diff -

[PATCH v2 07/11] target/helper: Remove unnecessary 'qemu/main-loop.h' header

2023-08-28 Thread Philippe Mathieu-Daudé
"qemu/main-loop.h" declares functions related to QEMU's main loop mutex, which these files don't access. Remove the unused "qemu/main-loop.h" header. Signed-off-by: Philippe Mathieu-Daudé --- target/riscv/pmu.h | 1 - target/arm/ptw.c | 1 - target/loongarch

  1   2   3   4   >