From 1ff788db9781615be745671ebdb2eb82c137c5b8 Mon Sep 17 00:00:00 2001 From: Marc-André Lureau Date: Tue, 8 Oct 2024 16:50:27 +0400 Subject: ui: refactor using a common qemu_pixman_shareable MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Use a common shareable type for win32 & unix, and helper functions. This simplify the code as it avoids a lot of #ifdef'ery. Note: if it helps review, commits could be reordered to introduce the common type before introducing shareable memory for unix. Suggested-by: Akihiko Odaki Signed-off-by: Marc-André Lureau Reviewed-by: Akihiko Odaki Message-ID: <20241008125028.1177932-19-marcandre.lureau@redhat.com> --- include/hw/virtio/virtio-gpu.h | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'include/hw/virtio/virtio-gpu.h') diff --git a/include/hw/virtio/virtio-gpu.h b/include/hw/virtio/virtio-gpu.h index 7509d13265..e343110e23 100644 --- a/include/hw/virtio/virtio-gpu.h +++ b/include/hw/virtio/virtio-gpu.h @@ -51,11 +51,7 @@ struct virtio_gpu_simple_resource { unsigned int iov_cnt; uint32_t scanout_bitmask; pixman_image_t *image; -#ifdef WIN32 - HANDLE handle; -#else - int shmfd; -#endif + qemu_pixman_shareable share_handle; uint64_t hostmem; uint64_t blob_size; -- cgit 1.4.1