backend/drm: log drm_connector_alloc_crtc() failures

Helps figuring out why e.g. get_primary_formats fails.
This commit is contained in:
Simon Ser 2023-03-20 20:21:28 +01:00
parent 5602fb1373
commit 1d64e12391
1 changed files with 5 additions and 1 deletions

View File

@ -852,7 +852,11 @@ static bool drm_connector_alloc_crtc(struct wlr_drm_connector *conn) {
if (conn->crtc == NULL) {
realloc_crtcs(conn->backend, conn);
}
return conn->crtc != NULL;
bool ok = conn->crtc != NULL;
if (!ok) {
wlr_drm_conn_log(conn, WLR_DEBUG, "Failed to find free CRTC");
}
return ok;
}
static struct wlr_drm_mode *drm_mode_create(const drmModeModeInfo *modeinfo) {