summaryrefslogtreecommitdiffstats
path: root/include/hw/virtio
diff options
context:
space:
mode:
authorMarc-André Lureau2021-02-04 11:52:22 +0100
committerGerd Hoffmann2021-02-04 15:58:54 +0100
commitff64d44fb8f6636ece3064f86babe48e3807533d (patch)
treedd7de7a2fa18b732f0300ffac213971c220f7b75 /include/hw/virtio
parentui: remove console_has_gl_dmabuf() (diff)
downloadqemu-ff64d44fb8f6636ece3064f86babe48e3807533d.tar.gz
qemu-ff64d44fb8f6636ece3064f86babe48e3807533d.tar.xz
qemu-ff64d44fb8f6636ece3064f86babe48e3807533d.zip
vhost-user-gpu: add a configuration flag for dmabuf usage
Let's inform VirtioGPUBase that vhost-user-gpu require DMABUF messages. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20210204105232.834642-11-marcandre.lureau@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'include/hw/virtio')
-rw-r--r--include/hw/virtio/virtio-gpu.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/hw/virtio/virtio-gpu.h b/include/hw/virtio/virtio-gpu.h
index 1aed7275c8..4f3dbf79f9 100644
--- a/include/hw/virtio/virtio-gpu.h
+++ b/include/hw/virtio/virtio-gpu.h
@@ -71,6 +71,7 @@ enum virtio_gpu_base_conf_flags {
VIRTIO_GPU_FLAG_VIRGL_ENABLED = 1,
VIRTIO_GPU_FLAG_STATS_ENABLED,
VIRTIO_GPU_FLAG_EDID_ENABLED,
+ VIRTIO_GPU_FLAG_DMABUF_ENABLED,
};
#define virtio_gpu_virgl_enabled(_cfg) \
@@ -79,6 +80,8 @@ enum virtio_gpu_base_conf_flags {
(_cfg.flags & (1 << VIRTIO_GPU_FLAG_STATS_ENABLED))
#define virtio_gpu_edid_enabled(_cfg) \
(_cfg.flags & (1 << VIRTIO_GPU_FLAG_EDID_ENABLED))
+#define virtio_gpu_dmabuf_enabled(_cfg) \
+ (_cfg.flags & (1 << VIRTIO_GPU_FLAG_DMABUF_ENABLED))
struct virtio_gpu_base_conf {
uint32_t max_outputs;