Skip to content

Freeze clock when headless

This series moves the frame clock freezing from the legacy "eglnative" clutter backend to the mutter backend classes. The frame clock freeze/thaw API is moved into MetaStage (even though it doesn't need the stage pointer it seemed like a good entry point), and the native backends suspend/resume handling is changed to use the meta_stage_* API.

The generic backend is changed to always freeze the frame clock when headless, making it so that gnome-shell doesn't try to render anything when nothing is to be rendered. I have tested this on the nested, the native and the X11 backend with going headless (temporary xrandr --off on X11 and hacking the KMS resource code for the native backend and the test suite for the nested backend), and it seems to work well.

This is partly to fix a flaky test in the test suite. It was already fixed for the test suite itself in !17 (merged) but I imagine it is better to do in on a generic level than in the test suite backend.

Merge request reports