From 68362b37a890916d4c98aaee9d29497951c28c67 Mon Sep 17 00:00:00 2001 From: emersion Date: Mon, 29 Oct 2018 20:38:57 +0100 Subject: backend/drm: fix frame scheduling on secondary GPUs There was a missing copy_drm_surface_mgpu call in drm_connector_schedule_frame so we asked for a pageflip with an unknown BO, resulting in ENOENT. Additionally, this commit makes schedule_frame return a bool indicating failures. This allows schedule_frame_handle_idle_timer to only set frame_pending to true if a frame has been successfully scheduled. Thus, if a pageflip fails, rendering won't be blocked forever anymore. In case a pageflip is already pending, true is returned because a frame has already been scheduled and will be sent sometime soon. --- include/wlr/interfaces/wlr_output.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/wlr/interfaces/wlr_output.h b/include/wlr/interfaces/wlr_output.h index da37cba1..f7ffe3b4 100644 --- a/include/wlr/interfaces/wlr_output.h +++ b/include/wlr/interfaces/wlr_output.h @@ -33,7 +33,7 @@ struct wlr_output_impl { size_t (*get_gamma_size)(struct wlr_output *output); bool (*export_dmabuf)(struct wlr_output *output, struct wlr_dmabuf_attributes *attribs); - void (*schedule_frame)(struct wlr_output *output); + bool (*schedule_frame)(struct wlr_output *output); }; void wlr_output_init(struct wlr_output *output, struct wlr_backend *backend, -- cgit v1.2.3