diff options
author | Drew DeVault <sir@cmpwn.com> | 2017-09-27 20:25:34 -0400 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2017-09-27 20:25:34 -0400 |
commit | 7cf4ee128e278108b0326344be01ded93ce7148b (patch) | |
tree | c5d7291b1aebf130c701af6936c7cc5614383c45 /backend/drm/drm-legacy.c | |
parent | 38bb3b960852f9e358ec40c516f99eafeaf83ab2 (diff) | |
parent | d7d73cd2985d4c5d1fdadcfb63680c638e29a4a0 (diff) |
Merge remote-tracking branch 'origin/master' into rootston
Diffstat (limited to 'backend/drm/drm-legacy.c')
-rw-r--r-- | backend/drm/drm-legacy.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/backend/drm/drm-legacy.c b/backend/drm/drm-legacy.c index 5077fcab..9b7cd301 100644 --- a/backend/drm/drm-legacy.c +++ b/backend/drm/drm-legacy.c @@ -9,11 +9,17 @@ static bool legacy_crtc_pageflip(struct wlr_drm_backend *backend, struct wlr_drm_output *output, struct wlr_drm_crtc *crtc, uint32_t fb_id, drmModeModeInfo *mode) { if (mode) { - drmModeSetCrtc(backend->fd, crtc->id, fb_id, 0, 0, - &output->connector, 1, mode); + if (drmModeSetCrtc(backend->fd, crtc->id, fb_id, 0, 0, + &output->connector, 1, mode)) { + wlr_log_errno(L_ERROR, "%s: Failed to set CRTC", output->output.name); + return false; + } } - drmModePageFlip(backend->fd, crtc->id, fb_id, DRM_MODE_PAGE_FLIP_EVENT, output); + if (drmModePageFlip(backend->fd, crtc->id, fb_id, DRM_MODE_PAGE_FLIP_EVENT, output)) { + wlr_log_errno(L_ERROR, "%s: Failed to page flip", output->output.name); + return false; + } return true; } |