compositor: Don't check for cached data in synchronized_commit

It really doesn't matter if we do a little extra work here,
weston_subsurface_commit_from_cache() is harmless if called on clean state.

If this turns out to waste some cycles we can add some more dirty bits
later.

Signed-off-by: Derek Foreman <derek.foreman@collabora.com>
This commit is contained in:
Derek Foreman 2025-07-03 14:44:06 -05:00
parent 26625a4928
commit 3db7d41642

View file

@ -5474,7 +5474,7 @@ static enum weston_surface_status
weston_subsurface_synchronized_commit(struct weston_subsurface *sub)
{
struct weston_surface *surface = sub->surface;
enum weston_surface_status status = WESTON_SURFACE_CLEAN;
enum weston_surface_status status;
struct weston_subsurface *tmp;
/* From now on, commit_from_cache the whole sub-tree, regardless of
@ -5483,8 +5483,7 @@ weston_subsurface_synchronized_commit(struct weston_subsurface *sub)
* all the way down.
*/
if (sub->has_cached_data)
status |= weston_subsurface_commit_from_cache(sub);
status = weston_subsurface_commit_from_cache(sub);
wl_list_for_each(tmp, &surface->subsurface_list, parent_link) {
if (tmp->surface != surface)