Commit b57c6a0b authored by Daniel Stone's avatar Daniel Stone

compositor-drm: Add shutting_down flag

Does what it says on the box: is true when the compositor is shutting

When we begin to use universal planes, we need divergent destruction
paths. With universal planes, the drm_planes are created at backend
initialisation time, and destroyed with the backend. However, without
universal planes, we create per-output drm_planes to hold the
primary/scanout and cursor planes, whose lifetime is tied to the output.

We will use the new shutting_down flag to determine if output
destruction is hot-unplug or compositor shutdown, and make a decision on
whether or not to destroy the special planes.
Signed-off-by: Daniel Stone's avatarDaniel Stone <>
Reviewed-by: Pekka Paalanen's avatarPekka Paalanen <>
parent 0a543996
......@@ -184,6 +184,8 @@ struct drm_backend {
int32_t cursor_height;
uint32_t pageflip_timeout;
bool shutting_down;
struct drm_mode {
......@@ -3605,6 +3607,8 @@ drm_destroy(struct weston_compositor *ec)
b->shutting_down = true;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment