backend-drm: Remove Pixman conditional for keep_buffer

The Pixman renderer keeps its own reference to buffers when attached to
surfaces, through its surface state: just use that instead.

Signed-off-by: Daniel Stone <daniels@collabora.com>
This commit is contained in:
Daniel Stone 2022-01-17 18:53:50 +00:00
parent 493a4c013e
commit b38b735e20
1 changed files with 2 additions and 4 deletions

View File

@ -964,10 +964,8 @@ drm_assign_planes(struct weston_output *output_base)
if (weston_view_has_valid_buffer(ev)) {
struct weston_buffer *buffer =
ev->surface->buffer_ref.buffer;
if (b->use_pixman)
ev->surface->keep_buffer = true;
else if (buffer->type == WESTON_BUFFER_DMABUF ||
buffer->type == WESTON_BUFFER_RENDERER_OPAQUE)
if (buffer->type == WESTON_BUFFER_DMABUF ||
buffer->type == WESTON_BUFFER_RENDERER_OPAQUE)
ev->surface->keep_buffer = true;
else if (buffer->type == WESTON_BUFFER_SHM &&
(ev->surface->width <= b->cursor_width &&