diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2014-07-07 16:39:05 +1000 |
---|---|---|
committer | Gerd Hoffmann <kraxel@redhat.com> | 2015-01-19 13:33:26 +0100 |
commit | 49743df399ca1029f4e22b52e9238d8e25c26bb2 (patch) | |
tree | 6e1df21a5e3c5daccbbcc6b1b055459b9315a29d /include | |
parent | aca7aaf6287b6a9f688c1b115a76fdc056565a7e (diff) |
ui: Add dpy_gfx_check_format() to check backend shared surface support
This allows VGA to decide whether to use a shared surface based on
whether the UI backend supports the format or not. Backends that
don't provide the new callback fallback to native 32 bpp which
is equivalent to what was supported before.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
[ kraxel: fix console check, allow only 32 bpp as fallback ]
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/ui/console.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/ui/console.h b/include/ui/console.h index 22ef8ca6b3..047b6dab8d 100644 --- a/include/ui/console.h +++ b/include/ui/console.h @@ -161,6 +161,8 @@ typedef struct DisplayChangeListenerOps { void (*dpy_gfx_copy)(DisplayChangeListener *dcl, int src_x, int src_y, int dst_x, int dst_y, int w, int h); + bool (*dpy_gfx_check_format)(DisplayChangeListener *dcl, + pixman_format_code_t format); void (*dpy_text_cursor)(DisplayChangeListener *dcl, int x, int y); @@ -235,6 +237,8 @@ void dpy_gfx_update_dirty(QemuConsole *con, MemoryRegion *address_space, uint64_t base, bool invalidate); +bool dpy_gfx_check_format(QemuConsole *con, + pixman_format_code_t format); static inline int surface_stride(DisplaySurface *s) { |