Re: [PATCH 1/1] virtio-gpu: CONTEXT_INIT feature

2021-09-28 Thread Antonio Caggiano
On 28/09/21 07:13, Gerd Hoffmann wrote: @@ -212,6 +212,8 @@ virtio_gpu_base_get_features(VirtIODevice *vdev, uint64_t features, features |= (1 << VIRTIO_GPU_F_RESOURCE_BLOB); } +features |= (1 << VIRTIO_GPU_F_CONTEXT_INIT); This needs a config option, simliar to the

[RFC 2/3] virtio: Add shared memory capability

2021-09-28 Thread Antonio Caggiano
From: "Dr. David Alan Gilbert" Define a new capability type 'VIRTIO_PCI_CAP_SHARED_MEMORY_CFG' and the data structure 'virtio_pci_shm_cap' to go with it. They allow defining shared memory regions with sizes and offsets of 2^32 and more. Multiple instances of the capability are allowed and

[RFC 1/3] virtio-gpu: hostmem

2021-09-28 Thread Antonio Caggiano
From: Gerd Hoffmann Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-pci.c| 14 ++ hw/display/virtio-gpu.c| 1 + hw/display/virtio-vga.c| 32 +++- include/hw/virtio

[RFC 3/3] virtio: Fix shared memory capability

2021-09-28 Thread Antonio Caggiano
Remove virtio_pci_shm_cap as virtio_pci_cap64 should be used instead. Signed-off-by: Antonio Caggiano --- hw/virtio/virtio-pci.c | 4 ++-- include/standard-headers/linux/virtio_pci.h | 7 --- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/hw/virtio

[RFC 0/3] virtio-gpu: Shared memory capability

2021-09-28 Thread Antonio Caggiano
://www.mail-archive.com/qemu-devel@nongnu.org/msg826897.html [1] https://gitlab.freedesktop.org/virgl/qemu/-/commits/virtio-gpu-next/ [2] https://github.com/torvalds/linux/commit/0dd4ff93f4c8dba016ad79384007da4938cd54a1 [3] https://www.mail-archive.com/qemu-devel@nongnu.org/msg827306.html Antonio

[RFC v2 0/2] virtio-gpu: Shared memory capability

2021-09-29 Thread Antonio Caggiano
Previously part of [0], now a patch series on its own. This patch series cherry picks two commits from [1] and applies one fix according to [2], which should answer Gerd's comment [3] on previous patch. RFC as I believe it needs a proper review from both authors of first two commits. v2: Squash

[RFC v2 2/2] virtio: Add shared memory capability

2021-09-29 Thread Antonio Caggiano
re allowed and distinguished by a device-specific 'id'. v2: Remove virtio_pci_shm_cap as virtio_pci_cap64 is used instead. Signed-off-by: Dr. David Alan Gilbert (cherry picked from commit a5d628a3a3c5e60b98b15197c36a77056115) Signed-off-by: Antonio Caggiano --- hw/virtio/virtio-

[RFC v2 1/2] virtio-gpu: hostmem

2021-09-29 Thread Antonio Caggiano
From: Gerd Hoffmann Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-pci.c| 14 ++ hw/display/virtio-gpu.c| 1 + hw/display/virtio-vga.c| 32 +++- include/hw/virtio

virtio-gpu: Get FD for texture

2021-09-27 Thread Antonio Caggiano
am doing something wrong somewhere? Kind regards, Antonio Caggiano

[PATCH 0/1] virtio-gpu: CONTEXT_INIT feature

2021-09-27 Thread Antonio Caggiano
://github.com/oasis-tcs/virtio-spec/commit/aad2b6f3620ec0c9d16aaf046db8c282c24cce3e [2] https://www.mail-archive.com/qemu-devel@nongnu.org/msg827304.html Antonio Caggiano (1): virtio-gpu: CONTEXT_INIT feature hw/display/virtio-gpu-base.c| 2 ++ hw/display/virtio-gpu-virgl.c

[PATCH 1/1] virtio-gpu: CONTEXT_INIT feature

2021-09-27 Thread Antonio Caggiano
Create virgl renderer context with flags using context_id when valid. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-base.c| 2 ++ hw/display/virtio-gpu-virgl.c | 10 -- include/hw/virtio/virtio-gpu-bswap.h| 2 +- include/standard

Re: virtio-gpu: Get FD for texture

2021-09-29 Thread Antonio Caggiano
to a different thread. Does that make sense? Kind regards, Antonio Caggiano On 27/09/21 12:21, Antonio Caggiano wrote: Hi, I am trying to support a Vulkan application in the guest (GTKGlArea+VirGL+venus) which needs to import a GL texture from a GL context. Before doing that, I need to get

[PATCH 0/2] virtio-gpu: Shared memory capability

2021-11-10 Thread Antonio Caggiano
Previously RFC [0] part of [0], now a patch series on its own. This patch series cherry picks two commits from [1] and applies one fix according to [2], which should answer Gerd's comment [3] on previous patch. [0] https://www.mail-archive.com/qemu-devel@nongnu.org/msg840405.html [1]

[PATCH 1/2] virtio-gpu: hostmem

2021-11-10 Thread Antonio Caggiano
From: Gerd Hoffmann Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-pci.c| 14 ++ hw/display/virtio-gpu.c| 1 + hw/display/virtio-vga.c| 32 +++- include/hw/virtio

[PATCH 2/2] virtio: Add shared memory capability

2021-11-10 Thread Antonio Caggiano
re allowed and distinguished by a device-specific 'id'. v2: Remove virtio_pci_shm_cap as virtio_pci_cap64 is used instead. Signed-off-by: Dr. David Alan Gilbert (cherry picked from commit a5d628a3a3c5e60b98b15197c36a77056115) Signed-off-by: Antonio Caggiano --- hw/virtio/virtio-

Re: virtio-gpu: Mapping blob resources

2021-07-23 Thread Antonio Caggiano
ote: On Fri, Jul 23, 2021 at 03:33:24PM +0200, Antonio Caggiano wrote: Hi, I am trying to implement blob resource mapping support, but there is something I still did not manage to figure out. According to the spec, VIRTIO_GPU_CMD_RESOURCE_MAP_BLOB maps a host-only blob resource into an off

virtio-gpu: Mapping blob resources

2021-07-23 Thread Antonio Caggiano
Hi, I am trying to implement blob resource mapping support, but there is something I still did not manage to figure out. According to the spec, VIRTIO_GPU_CMD_RESOURCE_MAP_BLOB maps a host-only blob resource into an offset in the host visible memory region. So, I believe I will need

[PATCH 4/7] virtio-gpu: Resource UUID

2021-07-27 Thread Antonio Caggiano
Enable resource UUID feature and implement command resource assign UUID. For the moment, use the resource ID as UUID. Signed-off-by: Antonio Caggiano --- hw/display/trace-events| 1 + hw/display/virtio-gpu-base.c | 2 ++ hw/display/virtio-gpu-virgl.c | 3 +++ hw/display/virtio

[PATCH 7/7] virtio-gpu: Handle resource blob commands

2021-07-27 Thread Antonio Caggiano
Support BLOB resources creation by calling virgl_renderer_resource_create_blob. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-virgl.c| 148 +++ hw/display/virtio-gpu.c | 9 +- include/hw/virtio/virtio-gpu-bswap.h | 18 include/hw

[PATCH 3/7] virtio: Add shared memory capability

2021-07-27 Thread Antonio Caggiano
'id'. Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. Signed-off-by: Dr. David Alan Gilbert Signed-off-by: Antonio Caggiano (cherry picked from commit a5d628a3a3c5e60b98b15197c36a77056115) --- hw/display/virtio-gpu-pci.c | 2 +- hw/display/virtio-vga.c | 2 +- hw/virtio/virtio-pci.c

[PATCH 6/7] virtio-gpu: Initialize Venus

2021-07-27 Thread Antonio Caggiano
Enable VirGL unstable APIs and request Venus when initializing VirGL. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-virgl.c | 2 +- meson.build | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/display/virtio-gpu-virgl.c b/hw/display/virtio

[PATCH 1/7] virtio-gpu: CONTEXT_INIT feature

2021-07-27 Thread Antonio Caggiano
Create virgl renderer context with flags using context_id when valid. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-base.c| 2 ++ hw/display/virtio-gpu-virgl.c | 10 -- include/hw/virtio/virtio-gpu-bswap.h| 2 +- include/standard

[PATCH 2/7] virtio-gpu: hostmem [wip]

2021-07-27 Thread Antonio Caggiano
From: Gerd Hoffmann --- hw/display/virtio-gpu-base.c| 4 +++ hw/display/virtio-gpu-pci.c | 14 + hw/display/virtio-gpu.c | 1 + hw/display/virtio-vga.c | 32 +++-- include/hw/virtio/virtio-gpu.h

[PATCH 0/7] virtio-gpu: Support Venus Vulkan driver

2021-07-27 Thread Antonio Caggiano
] https://share.collabora.com/index.php/s/RM5igzZMH2o749W/preview [2] https://gitlab.freedesktop.org/olv/drm-misc-next/-/tree/venus-5 [3] https://gitlab.freedesktop.org/mesa/mesa/-/tree/21.1 [4] https://gitlab.freedesktop.org/Fahien/virglrenderer/-/tree/res-mapping Antonio Caggiano (5): virtio-gpu

[PATCH 5/7] virtio-gpu: Support Venus capset

2021-07-27 Thread Antonio Caggiano
Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-virgl.c | 21 + include/standard-headers/linux/virtio_gpu.h | 2 ++ 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/hw/display/virtio-gpu-virgl.c b/hw/display/virtio-gpu-virgl.c index

Re: virtio-gpu: Mapping blob resources

2021-07-26 Thread Antonio Caggiano
On 26/07/21 10:19, Gerd Hoffmann wrote: On Fri, Jul 23, 2021 at 05:07:52PM +0200, Antonio Caggiano wrote: I added it to the gpu hostmem at the offset specified by the map command. I enabled the subregion, and then I used subregion->addr for the vkMapMemory call. Hmm, no. I'd suggest to fi

[PATCH v2 1/8] virtio-gpu: CONTEXT_INIT feature

2021-07-28 Thread Antonio Caggiano
Create virgl renderer context with flags using context_id when valid. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-base.c| 2 ++ hw/display/virtio-gpu-virgl.c | 10 -- include/hw/virtio/virtio-gpu-bswap.h| 2 +- include/standard

[PATCH v2 2/8] virtio-gpu: hostmem [wip]

2021-07-28 Thread Antonio Caggiano
From: Gerd Hoffmann --- hw/display/virtio-gpu-base.c| 4 +++ hw/display/virtio-gpu-pci.c | 14 + hw/display/virtio-gpu.c | 1 + hw/display/virtio-vga.c | 32 +++-- include/hw/virtio/virtio-gpu.h

[PATCH v2 8/8] virtio-gpu: Handle resource blob commands

2021-07-28 Thread Antonio Caggiano
Support BLOB resources creation by calling virgl_renderer_resource_create_blob. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-virgl.c| 148 +++ hw/display/virtio-gpu.c | 9 +- include/hw/virtio/virtio-gpu-bswap.h | 18 include/hw

[PATCH v2 5/8] virtio-gpu: Resource UUID

2021-07-28 Thread Antonio Caggiano
Enable resource UUID feature and implement command resource assign UUID. For the moment, use the resource ID as UUID. Signed-off-by: Antonio Caggiano --- hw/display/trace-events| 1 + hw/display/virtio-gpu-base.c | 2 ++ hw/display/virtio-gpu-virgl.c | 3 +++ hw/display/virtio

[PATCH v2 0/8] virtio-gpu: Support Venus Vulkan driver

2021-07-28 Thread Antonio Caggiano
-mapping Antonio Caggiano (6): virtio-gpu: CONTEXT_INIT feature virtio-gpu: Shared memory capability virtio-gpu: Resource UUID virtio-gpu: Support Venus capset virtio-gpu: Initialize Venus virtio-gpu: Handle resource blob commands Dr. David Alan Gilbert (1): virtio: Add shared memory

[PATCH v2 6/8] virtio-gpu: Support Venus capset

2021-07-28 Thread Antonio Caggiano
Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-virgl.c | 21 + include/standard-headers/linux/virtio_gpu.h | 2 ++ 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/hw/display/virtio-gpu-virgl.c b/hw/display/virtio-gpu-virgl.c index

[PATCH v2 4/8] virtio-gpu: Shared memory capability

2021-07-28 Thread Antonio Caggiano
Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. Also, remove struct virtio_pci_shm_cap as virtio_pci_cap64 can be used instead. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-pci.c | 2 +- hw/display/virtio-vga.c | 2 +- hw/virtio/virtio

[PATCH v2 7/8] virtio-gpu: Initialize Venus

2021-07-28 Thread Antonio Caggiano
Enable VirGL unstable APIs and request Venus when initializing VirGL. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-virgl.c | 2 +- meson.build | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/display/virtio-gpu-virgl.c b/hw/display/virtio

[PATCH v2 3/8] virtio: Add shared memory capability

2021-07-28 Thread Antonio Caggiano
From: "Dr. David Alan Gilbert" Define a new capability type 'VIRTIO_PCI_CAP_SHARED_MEMORY_CFG' and the data structure 'virtio_pci_shm_cap' to go with it. They allow defining shared memory regions with sizes and offsets of 2^32 and more. Multiple instances of the capability are allowed and

Re: [PATCH 2/2] virtio: Add shared memory capability

2022-01-06 Thread Antonio Caggiano
Where's that commit? I think we should drop this, right? Yes, I will submit another version without that line. You don't need & mask32 I think. cpu_to_le32 will truncate the value. Makes sense, will be fixed in next version. So it's a new API, but where's the user? I guess just include

Re: [PATCH 17/21] virtio-gpu-virgl: teach it to get the QEMU EGL display

2023-08-30 Thread Antonio Caggiano
that (e.g. as opposed to GLX)? Kind regards, Antonio Caggiano On 06/06/2023 13:56, marcandre.lur...@redhat.com wrote: From: Marc-André Lureau virgl offers a few features that require to have access to the underlying EGLDisplay. This is the case for the D3D texture sharing support. The API callback

Re: [PATCH 17/21] virtio-gpu-virgl: teach it to get the QEMU EGL display

2023-08-30 Thread Antonio Caggiano
that (e.g. as opposed to GLX)? Kind regards, Antonio Caggiano On 06/06/2023 13:56, marcandre.lur...@redhat.com wrote: From: Marc-André Lureau virgl offers a few features that require to have access to the underlying EGLDisplay. This is the case for the D3D texture sharing support. The API callback

Re: [PATCH 17/21] virtio-gpu-virgl: teach it to get the QEMU EGL display

2023-08-30 Thread Antonio Caggiano
Thanks for your answer, that'll help. On 30/08/2023 13:49, Marc-André Lureau wrote: Hi Antonio On Wed, Aug 30, 2023 at 3:14 PM Antonio Caggiano wrote: Hi Marc-André, I've been testing this, but I can't find where qemu_egl_display is set when using sdl. Whil ui/gtk.c sets

Re: [QEMU PATCH v4 12/13] virtio-gpu: Initialize Venus

2023-08-31 Thread Antonio Caggiano
Hi Huang, Thank you for pushing this forward! On 31/08/2023 11:32, Huang Rui wrote: From: Antonio Caggiano Request Venus when initializing VirGL. Signed-off-by: Antonio Caggiano Signed-off-by: Huang Rui --- v1->v2: - Rebase to latest version hw/display/virtio-gpu-virgl.c

[PATCH v2] ui/gtk-egl: Check EGLSurface before doing scanout

2023-10-16 Thread Antonio Caggiano
that point, the gd_egl_init() will succeed and the EGLContext and EGLSurface stored in the VirtualGfxConsole will be valid. Signed-off-by: Antonio Caggiano Reviewed-by: Marc-André Lureau --- ui/gtk-egl.c | 17 - 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/ui/gtk-egl.c b/ui

[PATCH] ui/gtk-egl: Check EGLSurface before doing scanout

2023-10-13 Thread Antonio Caggiano
that point, the gd_egl_init() will succeed and the EGLContext and EGLSurface stored in the VirtualGfxConsole will be valid. Signed-off-by: Antonio Caggiano --- ui/gtk-egl.c | 17 - 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/ui/gtk-egl.c b/ui/gtk-egl.c index a1060fd80f..

Re: [PATCH] gtk: force realization of drawing area

2023-10-18 Thread Antonio Caggiano
Reviewed-by: Antonio Caggiano On 17/10/2023 13:16, marcandre.lur...@redhat.com wrote: From: Marc-André Lureau Fixes the GL context creation from a widget that isn't yet realized (in a hidden tab for example). Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1727 Signed-off-by: Marc

[RFC] mem: Fix mem region size when is UINT64_MAX

2023-10-24 Thread Antonio Caggiano
us one. Signed-off-by: Antonio Caggiano --- system/memory.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/system/memory.c b/system/memory.c index a800fbc9e5..d41fc6af88 100644 --- a/system/memory.c +++ b/system/memory.c @@ -1193,9 +1193,6 @@ static void memory_region_do_init(MemoryRegi

Re: [RFC] mem: Fix mem region size when is UINT64_MAX

2023-10-24 Thread Antonio Caggiano
Hi Peter, Thanks for the quick response. On 24/10/2023 12:28, Peter Maydell wrote: On Tue, 24 Oct 2023 at 10:45, Antonio Caggiano wrote: This looks like a bug. When the size is `UINT64_MAX`, it is reset to (Int128)`1 << 64` which actually is `UINT64_MAX + 1`. Then, an assert is tri

Re: [RFC] mem: Fix mem region size when is UINT64_MAX

2023-10-24 Thread Antonio Caggiano
On 24/10/2023 14:00, Peter Maydell wrote: On Tue, 24 Oct 2023 at 11:49, Antonio Caggiano wrote: Hi Peter, Thanks for the quick response. On 24/10/2023 12:28, Peter Maydell wrote: On Tue, 24 Oct 2023 at 10:45, Antonio Caggiano wrote: This looks like a bug. When the size is `UINT64_MAX

Re: [RFC] mem: Fix mem region size when is UINT64_MAX

2023-10-24 Thread Antonio Caggiano
+cc Mark which has a better understanding of our use case. On 24/10/2023 15:21, Peter Maydell wrote: On Tue, 24 Oct 2023 at 13:31, Antonio Caggiano wrote: On 24/10/2023 14:00, Peter Maydell wrote: On Tue, 24 Oct 2023 at 11:49, Antonio Caggiano wrote: Given that we don't run

Re: [PATCH v12 8/9] gfxstream + rutabaga: enable rutabaga

2023-08-25 Thread Antonio Caggiano
"ati-vga", .flag = _vga }, { .driver = "vhost-user-vga", .flag = _vga }, { .driver = "virtio-vga-gl",.flag = _vga }, +{ .driver = "virtio-vga-rutabaga", .flag = _vga }, }; static QemuOptsList qemu_rtc_opts = { Patches 5 to 9: Reviewed-by: Antonio Caggiano Cheers, Antonio

Re: QEMU Virtio GPU features status & roadmap?

2023-11-08 Thread Antonio Caggiano
Hi Hans, +cc Gert and Dmitry On 17/10/2023 02:48, Hans de Ruiter wrote: Hi, I'm working on Virtio GPU drivers for AmigaOS, and would like to know what features are currently stable enough to use. Looking at the master QEMU branch, both Virgl and blob resources are supported, but NOT at the

Re: QEMU Virtio GPU features status & roadmap?

2023-11-08 Thread Antonio Caggiano
Hi Marc-André, On 08/11/2023 12:07, Marc-André Lureau wrote: Hi On Wed, Nov 8, 2023 at 1:04 PM Antonio Caggiano wrote: Hi Hans, +cc Gert and Dmitry On 17/10/2023 02:48, Hans de Ruiter wrote: Hi, I'm working on Virtio GPU drivers for AmigaOS, and would like to know what features

[PATCH v2 0/1] virtio-gpu: CONTEXT_INIT feature

2022-08-25 Thread Antonio Caggiano
://github.com/oasis-tcs/virtio-spec/commit/aad2b6f3620ec0c9d16aaf046db8c282c24cce3e [2] https://www.mail-archive.com/qemu-devel@nongnu.org/msg827304.html Antonio Caggiano (1): virtio-gpu: CONTEXT_INIT feature hw/display/virtio-gpu-base.c | 3 +++ hw/display/virtio-gpu-virgl.c | 19

[PATCH v2 1/1] virtio-gpu: CONTEXT_INIT feature

2022-08-25 Thread Antonio Caggiano
-by: Antonio Caggiano --- hw/display/virtio-gpu-base.c | 3 +++ hw/display/virtio-gpu-virgl.c | 19 +-- hw/display/virtio-gpu.c| 2 ++ include/hw/virtio/virtio-gpu.h | 3 +++ meson.build| 18 ++ 5 files changed, 43 insertions(+), 2

Re: [PATCH v3 1/1] virtio-gpu: CONTEXT_INIT feature

2022-08-26 Thread Antonio Caggiano
Hi Marc-André, On 26/08/2022 12:16, Marc-André Lureau wrote: Hi On Fri, Aug 26, 2022 at 2:12 PM Antonio Caggiano mailto:antonio.caggi...@collabora.com>> wrote: Create virgl renderer context with flags using context_id when valid. v2: - The feature can be enabl

[PATCH v4 0/1] virtio-gpu: CONTEXT_INIT feature

2022-08-26 Thread Antonio Caggiano
://github.com/oasis-tcs/virtio-spec/commit/aad2b6f3620ec0c9d16aaf046db8c282c24cce3e [2] https://www.mail-archive.com/qemu-devel@nongnu.org/msg827304.html Antonio Caggiano (1): virtio-gpu: CONTEXT_INIT feature hw/display/virtio-gpu-base.c | 3 +++ hw/display/virtio-gpu-virgl.c | 16

[PATCH v3 1/1] virtio-gpu: CONTEXT_INIT feature

2022-08-26 Thread Antonio Caggiano
HAVE_VIRGL_CONTEXT_INIT in config_host_data. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-base.c | 3 +++ hw/display/virtio-gpu-virgl.c | 16 ++-- hw/display/virtio-gpu.c| 2 ++ include/hw/virtio/virtio-gpu.h | 3 +++ meson.build| 5 + 5

[PATCH v3 0/1] virtio-gpu: CONTEXT_INIT feature

2022-08-26 Thread Antonio Caggiano
://github.com/oasis-tcs/virtio-spec/commit/aad2b6f3620ec0c9d16aaf046db8c282c24cce3e [2] https://www.mail-archive.com/qemu-devel@nongnu.org/msg827304.html Antonio Caggiano (1): virtio-gpu: CONTEXT_INIT feature hw/display/virtio-gpu-base.c | 3 +++ hw/display/virtio-gpu-virgl.c | 16

[PATCH v4 1/1] virtio-gpu: CONTEXT_INIT feature

2022-08-26 Thread Antonio Caggiano
HAVE_VIRGL_CONTEXT_INIT in config_host_data. Signed-off-by: Antonio Caggiano Reviewed-by: Marc-André Lureau --- hw/display/virtio-gpu-base.c | 3 +++ hw/display/virtio-gpu-virgl.c | 16 ++-- hw/display/virtio-gpu.c| 2 ++ include/hw/virtio/virtio-gpu.h | 3 +++ meson.build

[PATCH 0/5] virtio-gpu: Blob resources

2022-08-29 Thread Antonio Caggiano
Add shared memory and support blob resource creation, mapping and unmapping through virglrenderer new stable APIs[0] when available. [0] https://gitlab.freedesktop.org/virgl/virglrenderer/-/merge_requests/891 Antonio Caggiano (1): virtio-gpu: Handle resource blob commands Dmitry Osipenko (1

[PATCH 2/5] virtio: Add shared memory capability

2022-08-29 Thread Antonio Caggiano
re allowed and distinguished by a device-specific 'id'. v2: Remove virtio_pci_shm_cap as virtio_pci_cap64 is used instead. v3: No need for mask32 as cpu_to_le32 truncates the value. Signed-off-by: Dr. David Alan Gilbert Signed-off-by: Antonio Caggiano --- hw/virtio/virtio-pci.c

[PATCH 4/5] virtio-gpu: Handle resource blob commands

2022-08-29 Thread Antonio Caggiano
Support BLOB resources creation by calling virgl_renderer_resource_create_blob. Signed-off-by: Antonio Caggiano Signed-off-by: Dmitry Osipenko --- hw/display/virtio-gpu-virgl.c| 169 +++ hw/display/virtio-gpu.c | 8 +- include/hw/virtio/virtio-gpu

[PATCH 1/5] Update version for v7.1.0-rc4 release

2022-08-29 Thread Antonio Caggiano
From: Richard Henderson Signed-off-by: Richard Henderson --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 1c944b9863..b8d5f3ebb6 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -7.0.93 +7.0.94 -- 2.34.1

[PATCH 3/5] virtio-gpu: hostmem

2022-08-29 Thread Antonio Caggiano
From: Gerd Hoffmann Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. v2: Formatting fixes Signed-off-by: Antonio Caggiano Acked-by: Michael S. Tsirkin --- hw/display/virtio-gpu-pci.c| 15 +++ hw/display/virtio-gpu.c| 1 + hw/display/virtio-vga.c| 33

[PATCH 5/5] virtio-gpu: Don't require udmabuf when blob support is enabled

2022-08-29 Thread Antonio Caggiano
to 4.5 in guest. Relax the udmabuf requirement. Signed-off-by: Dmitry Osipenko Reviewed-by: Antonio Caggiano --- hw/display/virtio-gpu.c | 20 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio-gpu.c index 527c0aeede

[PATCH v3 0/4] virtio-gpu: Blob resources

2022-09-19 Thread Antonio Caggiano
Add shared memory and support blob resource creation, mapping and unmapping through virglrenderer new stable APIs[0] when available. [0] https://gitlab.freedesktop.org/virgl/virglrenderer/-/merge_requests/891 Antonio Caggiano (1): virtio-gpu: Handle resource blob commands Dmitry Osipenko (1

[PATCH v3 4/4] virtio-gpu: Don't require udmabuf when blob support is enabled

2022-09-19 Thread Antonio Caggiano
to 4.5 in guest. Relax the udmabuf requirement. Signed-off-by: Dmitry Osipenko Reviewed-by: Antonio Caggiano --- hw/display/virtio-gpu.c | 20 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio-gpu.c index f79693d44d

[PATCH v3 1/4] virtio: Add shared memory capability

2022-09-19 Thread Antonio Caggiano
Dr. David Alan Gilbert Signed-off-by: Antonio Caggiano --- v2: Remove virtio_pci_shm_cap as virtio_pci_cap64 is used instead. v3: No need for mask32 as cpu_to_le32 truncates the value. hw/virtio/virtio-pci.c | 18 ++ include/hw/virtio/virtio-pci.h | 4 2 files c

[PATCH v5 0/1] virtio-gpu: CONTEXT_INIT feature

2022-09-19 Thread Antonio Caggiano
://github.com/oasis-tcs/virtio-spec/commit/aad2b6f3620ec0c9d16aaf046db8c282c24cce3e [2] https://www.mail-archive.com/qemu-devel@nongnu.org/msg827304.html Antonio Caggiano (1): virtio-gpu: CONTEXT_INIT feature hw/display/virtio-gpu-base.c | 3 +++ hw/display/virtio-gpu-virgl.c | 16

[PATCH v5 1/1] virtio-gpu: CONTEXT_INIT feature

2022-09-19 Thread Antonio Caggiano
Create virgl renderer context with flags using context_id when valid. The feature can be enabled via the context_init config option. A warning message will be emitted and the feature will not be used when linking with virglrenderer versions without context_init support. Signed-off-by: Antonio

[PATCH v3 3/4] virtio-gpu: Handle resource blob commands

2022-09-19 Thread Antonio Caggiano
Support BLOB resources creation, mapping and unmapping by calling the new stable virglrenderer 0.10 interface. Only enabled when available and via the blob config. E.g. -device virtio-vga-gl,blob=true Signed-off-by: Antonio Caggiano Signed-off-by: Dmitry Osipenko --- v2: Fix memory leaks

[PATCH v3 2/4] virtio-gpu: hostmem

2022-09-19 Thread Antonio Caggiano
From: Gerd Hoffmann Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. Signed-off-by: Antonio Caggiano Acked-by: Michael S. Tsirkin --- v2: Formatting fixes hw/display/virtio-gpu-pci.c| 15 +++ hw/display/virtio-gpu.c| 1 + hw/display/virtio-vga.c| 33

[PATCH] virtio-gpu: Resource UUID

2022-09-21 Thread Antonio Caggiano
Enable resource UUID feature and implement command resource assign UUID. This is done by introducing a hash table to map resource IDs to their UUIDs. Signed-off-by: Antonio Caggiano --- hw/display/trace-events| 1 + hw/display/virtio-gpu-base.c | 2 ++ hw/display/virtio-gpu-virgl.c

Re: [PATCH 0/5] virtio-gpu: Blob resources

2022-09-12 Thread Antonio Caggiano
Hi Marc-André, On 30/08/2022 13:07, Marc-André Lureau wrote: Hi On Mon, Aug 29, 2022 at 7:46 PM Antonio Caggiano mailto:antonio.caggi...@collabora.com>> wrote: Add shared memory and support blob resource creation, mapping and unmapping through virglrenderer new stable APIs[0

[PATCH v2 0/4] virtio-gpu: Blob resources

2022-09-13 Thread Antonio Caggiano
Add shared memory and support blob resource creation, mapping and unmapping through virglrenderer new stable APIs[0] when available. [0] https://gitlab.freedesktop.org/virgl/virglrenderer/-/merge_requests/891 Antonio Caggiano (1): virtio-gpu: Handle resource blob commands Dmitry Osipenko (1

[PATCH v2 1/4] virtio: Add shared memory capability

2022-09-13 Thread Antonio Caggiano
re allowed and distinguished by a device-specific 'id'. v2: Remove virtio_pci_shm_cap as virtio_pci_cap64 is used instead. v3: No need for mask32 as cpu_to_le32 truncates the value. Signed-off-by: Dr. David Alan Gilbert Signed-off-by: Antonio Caggiano --- hw/virtio/virtio-pci.c

[PATCH v2 4/4] virtio-gpu: Don't require udmabuf when blob support is enabled

2022-09-13 Thread Antonio Caggiano
to 4.5 in guest. Relax the udmabuf requirement. Signed-off-by: Dmitry Osipenko Reviewed-by: Antonio Caggiano --- hw/display/virtio-gpu.c | 20 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio-gpu.c index f79693d44d

[PATCH v2 2/4] virtio-gpu: hostmem

2022-09-13 Thread Antonio Caggiano
From: Gerd Hoffmann Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. v2: Formatting fixes Signed-off-by: Antonio Caggiano Acked-by: Michael S. Tsirkin --- hw/display/virtio-gpu-pci.c| 15 +++ hw/display/virtio-gpu.c| 1 + hw/display/virtio-vga.c| 33

[PATCH v2 3/4] virtio-gpu: Handle resource blob commands

2022-09-13 Thread Antonio Caggiano
Support BLOB resources creation, mapping and unmapping by calling the new stable virglrenderer 0.10 interface. Only enabled when available and via the blob config. E.g. -device virtio-vga-gl,blob=true v2: Fix memory leaks and unmap resource on destroy. Signed-off-by: Antonio Caggiano Signed-off

[PATCH v3 0/9] virtio-gpu: Support Venus Vulkan driver

2022-09-26 Thread Antonio Caggiano
resource commands. Antonio Caggiano (7): virtio-gpu: Handle resource blob commands virtio-gpu: CONTEXT_INIT feature virtio-gpu: Unrealize virtio-gpu: Resource UUID virtio-gpu: Support Venus capset virtio-gpu: Initialize Venus virtio-gpu: Get EGL Display callback Dr. David Alan

[PATCH v3 6/9] virtio-gpu: Resource UUID

2022-09-26 Thread Antonio Caggiano
Enable resource UUID feature and implement command resource assign UUID. This is done by introducing a hash table to map resource IDs to their UUIDs. Signed-off-by: Antonio Caggiano --- v3: Destroy the hash table in the unrealize function hw/display/trace-events| 1 + hw/display

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

2022-09-26 Thread Antonio Caggiano
Dr. David Alan Gilbert Signed-off-by: Antonio Caggiano --- v3: - Remove virtio_pci_shm_cap as virtio_pci_cap64 is used instead. - No need for mask32 as cpu_to_le32 truncates the value. hw/virtio/virtio-pci.c | 18 ++ include/hw/virtio/virtio-pci.h | 4 2 files c

[PATCH v3 3/9] virtio-gpu: Handle resource blob commands

2022-09-26 Thread Antonio Caggiano
Support BLOB resources creation, mapping and unmapping by calling the new stable virglrenderer 0.10 interface. Only enabled when available and via the blob config. E.g. -device virtio-vga-gl,blob=true Signed-off-by: Antonio Caggiano Signed-off-by: Dmitry Osipenko --- v3: Fix memory leaks

[PATCH v3 8/9] virtio-gpu: Initialize Venus

2022-09-26 Thread Antonio Caggiano
Request Venus when initializing VirGL. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-virgl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/display/virtio-gpu-virgl.c b/hw/display/virtio-gpu-virgl.c index 16f600adbb..0f17b0 100644 --- a/hw/display/virtio

[PATCH v3 7/9] virtio-gpu: Support Venus capset

2022-09-26 Thread Antonio Caggiano
Add support for the Venus capset, which enables Vulkan support through the Venus Vulkan driver for virtio-gpu. Signed-off-by: Antonio Caggiano --- v3: Improve commit message hw/display/virtio-gpu-virgl.c | 21 + include/standard-headers/linux/virtio_gpu.h | 2

[PATCH v3 2/9] virtio-gpu: hostmem

2022-09-26 Thread Antonio Caggiano
From: Gerd Hoffmann Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. Signed-off-by: Antonio Caggiano Acked-by: Michael S. Tsirkin --- v3: Formatting fixes hw/display/virtio-gpu-pci.c| 15 +++ hw/display/virtio-gpu.c| 1 + hw/display/virtio-vga.c| 33

[PATCH v3 5/9] virtio-gpu: Unrealize

2022-09-26 Thread Antonio Caggiano
Implement an unrealize function for virtio gpu device. Signed-off-by: Antonio Caggiano --- v3: Call virtio_gpu_base_device_unrealize from virtio_gpu_device_unrealize hw/display/virtio-gpu-base.c | 2 +- hw/display/virtio-gpu.c| 11 +++ include/hw/virtio/virtio-gpu.h | 1

[PATCH v3 9/9] virtio-gpu: Get EGL Display callback

2022-09-26 Thread Antonio Caggiano
Implement get_egl_display callback for virglrenderer. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu-virgl.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/hw/display/virtio-gpu-virgl.c b/hw/display/virtio-gpu-virgl.c index 0f17b0..0fd9ad8a3d 100644

[PATCH v3 4/9] virtio-gpu: CONTEXT_INIT feature

2022-09-26 Thread Antonio Caggiano
Create virgl renderer context with flags using context_id when valid. The feature can be enabled via the context_init config option. A warning message will be emitted and the feature will not be used when linking with virglrenderer versions without context_init support. Signed-off-by: Antonio

[PATCH v2 2/2] virtio-gpu: Resource UUID

2022-09-23 Thread Antonio Caggiano
Enable resource UUID feature and implement command resource assign UUID. This is done by introducing a hash table to map resource IDs to their UUIDs. Signed-off-by: Antonio Caggiano --- v2: Destroy the hash table in the unrealize function hw/display/trace-events| 1 + hw/display

[PATCH v2 1/2] virtio-gpu: Unrealize

2022-09-23 Thread Antonio Caggiano
Implement an unrealize function for virtio gpu device. Signed-off-by: Antonio Caggiano --- hw/display/virtio-gpu.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio-gpu.c index 20cc703dcc..412f0fb7ec 100644 --- a/hw/display/virtio-gpu.c

Re: [PATCH] virtio-gpu: Resource UUID

2022-09-23 Thread Antonio Caggiano
Hi Marc-André, On 23/09/2022 10:38, Marc-André Lureau wrote: Hi On Wed, Sep 21, 2022 at 1:24 PM Antonio Caggiano mailto:antonio.caggi...@collabora.com>> wrote: Enable resource UUID feature and implement command resource assign UUID. This is done by introducing a hash table

[PATCH v2 0/2] virtio-gpu: Resource UUID

2022-09-23 Thread Antonio Caggiano
Enable resource UUID feature and implement command resource assign UUID. Antonio Caggiano (2): virtio-gpu: Unrealize virtio-gpu: Resource UUID hw/display/trace-events| 1 + hw/display/virtio-gpu-base.c | 2 ++ hw/display/virtio-gpu-virgl.c | 11 hw/display/virtio-gpu.c

Re: [PATCH] virtio-gpu: Resource UUID

2022-09-23 Thread Antonio Caggiano
Hi Marc-André, On 23/09/2022 10:38, Marc-André Lureau wrote: Hi On Wed, Sep 21, 2022 at 1:24 PM Antonio Caggiano mailto:antonio.caggi...@collabora.com>> wrote: Enable resource UUID feature and implement command resource assign UUID. This is done by introducing a hash table

[PATCH v3 0/2] virtio: Add shared memory capability

2022-08-03 Thread Antonio Caggiano
Previously part of [0], now a patch series on its own. This patch series cherry picks two commits from [1] and applies one fix according to [2], which should answer Gerd's comment [3] on previous patch. v2: Squash patch #3 into patch #2, and formatting fixes to patch #1. v3: Reverse commits

[PATCH v2 1/2] virtio-gpu: hostmem

2022-08-03 Thread Antonio Caggiano
From: Gerd Hoffmann Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. v2: Formatting fixes Signed-off-by: Antonio Caggiano Acked-by: Michael S. Tsirkin --- hw/display/virtio-gpu-pci.c| 15 +++ hw/display/virtio-gpu.c| 1 + hw/display/virtio-vga.c| 33

[PATCH v2 2/2] virtio: Add shared memory capability

2022-08-03 Thread Antonio Caggiano
re allowed and distinguished by a device-specific 'id'. v2: Remove virtio_pci_shm_cap as virtio_pci_cap64 is used instead. v3: No need for mask32 as cpu_to_le32 truncates the value. Signed-off-by: Dr. David Alan Gilbert Signed-off-by: Antonio Caggiano --- hw/virtio/virtio-pci.c

[PATCH v2 0/2] virtio-gpu: Shared memory capability

2022-08-03 Thread Antonio Caggiano
I guess RFC has been waiting long enough [0]. v2: Squash patch #3 into patch #2, and formatting fixes to patch #1. [0] https://www.mail-archive.com/qemu-devel@nongnu.org/msg840405.html Dr. David Alan Gilbert (1): virtio: Add shared memory capability Gerd Hoffmann (1): virtio-gpu: hostmem

[PATCH v3 1/2] virtio: Add shared memory capability

2022-08-03 Thread Antonio Caggiano
re allowed and distinguished by a device-specific 'id'. v2: Remove virtio_pci_shm_cap as virtio_pci_cap64 is used instead. v3: No need for mask32 as cpu_to_le32 truncates the value. Signed-off-by: Dr. David Alan Gilbert Signed-off-by: Antonio Caggiano --- hw/virtio/virtio-pci.c

[PATCH v3 2/2] virtio-gpu: hostmem

2022-08-03 Thread Antonio Caggiano
From: Gerd Hoffmann Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. v2: Formatting fixes Signed-off-by: Antonio Caggiano Acked-by: Michael S. Tsirkin --- hw/display/virtio-gpu-pci.c| 15 +++ hw/display/virtio-gpu.c| 1 + hw/display/virtio-vga.c| 33

[PATCH v3 1/2] virtio: Add shared memory capability

2022-08-16 Thread Antonio Caggiano
re allowed and distinguished by a device-specific 'id'. v2: Remove virtio_pci_shm_cap as virtio_pci_cap64 is used instead. v3: No need for mask32 as cpu_to_le32 truncates the value. Signed-off-by: Dr. David Alan Gilbert Signed-off-by: Antonio Caggiano --- hw/virtio/virtio-pci.c

[PATCH v3 2/2] virtio-gpu: hostmem

2022-08-16 Thread Antonio Caggiano
From: Gerd Hoffmann Use VIRTIO_GPU_SHM_ID_HOST_VISIBLE as id for virtio-gpu. v2: Formatting fixes Signed-off-by: Antonio Caggiano Acked-by: Michael S. Tsirkin --- hw/display/virtio-gpu-pci.c| 15 +++ hw/display/virtio-gpu.c| 1 + hw/display/virtio-vga.c| 33

  1   2   >