From a7dfbe289ede8adb253d735daef88a39709053dc Mon Sep 17 00:00:00 2001 From: Marc-André Lureau Date: Thu, 4 Feb 2021 14:52:23 +0400 Subject: ui: add an optional get_flags callback to GraphicHwOps Those flags can be used to express different requirements for the display or other needs. Signed-off-by: Marc-André Lureau Message-Id: <20210204105232.834642-12-marcandre.lureau@redhat.com> Signed-off-by: Gerd Hoffmann --- hw/vfio/display.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'hw/vfio/display.c') diff --git a/hw/vfio/display.c b/hw/vfio/display.c index 42d67e870b..f04473e3ce 100644 --- a/hw/vfio/display.c +++ b/hw/vfio/display.c @@ -335,7 +335,13 @@ static void vfio_display_dmabuf_update(void *opaque) } } +static int vfio_display_get_flags(void *opaque) +{ + return GRAPHIC_FLAGS_GL | GRAPHIC_FLAGS_DMABUF; +} + static const GraphicHwOps vfio_display_dmabuf_ops = { + .get_flags = vfio_display_get_flags, .gfx_update = vfio_display_dmabuf_update, .ui_info = vfio_display_edid_ui_info, }; -- cgit v1.2.3-55-g7522