Skip to content

Commit 3cea1aa

Browse files
committed
properly set MODE_ID
1 parent 74ed0d9 commit 3cea1aa

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/modesetting.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2347,6 +2347,14 @@ static int kms_req_commit_common(
23472347
drmModeAtomicAddProperty(builder->req, builder->connector->id, builder->connector->ids.crtc_id, builder->crtc->id);
23482348
}
23492349

2350+
if (update_mode) {
2351+
if (mode_blob != NULL) {
2352+
drmModeAtomicAddProperty(builder->req, builder->crtc->id, builder->crtc->ids.mode_id, mode_blob->blob_id);
2353+
} else {
2354+
drmModeAtomicAddProperty(builder->req, builder->crtc->id, builder->crtc->ids.mode_id, 0);
2355+
}
2356+
}
2357+
23502358
/// TODO: If we're on raspberry pi and only have one layer, we can do an async pageflip
23512359
/// on the primary plane to replace the next queued frame. (To do _real_ triple buffering
23522360
/// with fully decoupled framerate, potentially)

0 commit comments

Comments
 (0)