From 0251c05212c695a45c40f09639210c422cd66a4c Mon Sep 17 00:00:00 2001 From: Leandro Ribeiro Date: Mon, 30 May 2022 18:08:51 -0300 Subject: [PATCH] backend-drm: remove scanout tranche when there are no planes available It makes no sense to keep the scanout tranche on the dma-buf feedback if there are no overlay planes available. So start to remove it. Signed-off-by: Leandro Ribeiro --- libweston/backend-drm/state-propose.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libweston/backend-drm/state-propose.c b/libweston/backend-drm/state-propose.c index 03488d3a..be2c7dde 100644 --- a/libweston/backend-drm/state-propose.c +++ b/libweston/backend-drm/state-propose.c @@ -349,7 +349,9 @@ dmabuf_feedback_maybe_update(struct drm_device *device, struct weston_view *ev, const time_t MAX_TIME_SECONDS = 2; /* Find out what we need to do with the dma-buf feedback */ - if (try_view_on_plane_failure_reasons & FAILURE_REASONS_FORCE_RENDERER) + if (try_view_on_plane_failure_reasons & + (FAILURE_REASONS_FORCE_RENDERER | + FAILURE_REASONS_NO_PLANES_AVAILABLE)) action_needed |= ACTION_NEEDED_REMOVE_SCANOUT_TRANCHE; if (try_view_on_plane_failure_reasons & (FAILURE_REASONS_ADD_FB_FAILED |