drm_atomic_s...ode_for_crtc(9)
π drm_atomic_s...ode_for_crtc(9) β like, the whole vibe
okay so bestie, we're in the Kernel API Manual today and this page is genuinely iconic β it's drm_atomic_set_mode_for_crtc, and no cap, it's giving "small function, big responsibilities" energy. β¨
πΈ NAME πΈ
drm_atomic_set_mode_for_crtc β set mode for CRTC. that's it, that's the whole name, slay. π
π SYNOPSIS π
int drm_atomic_set_mode_for_crtc (struct drm_crtc_state *state , const
struct drm_display_mode *mode );
like, look at her. two args, one int coming back. main character energy fr fr. π¦
β¨ ARGUMENTS β¨
stateβ the CRTC whose incoming state to update π«Ά so like, the thing you're about to changemodeβ kernel-internal mode to use for the CRTC, orNULLto disable π yep,NULLis valid and it means "turn it off, bestie"
π DESCRIPTION π
Set a mode β and heads up, this one originates from the kernel, not from userspace, iykyk β on the desired CRTC state, and update the enable property while you're at it. π
so like: pick your CRTC state, hand it a mode, and the enable property gets updated as part of the deal. two birds, one slay. π
π₯ RETURN π₯
Zero on success, error code on failure. and the very important glow-up detail: it cannot return -EDEADLK. β like, not even possible. don't @ me.
π¦ SEE ALSO π¦
- Kernel file
./drivers/gpu/drm/drm_atomic_uapi.coverview(9) π drm_atomic_set_mode_prop_for_crtc(9)drm_atomic_set_crtc_for_plane(9)drm_atomic_set_fb_for_plane(9)drm_atomic_set_colorop_for_plane(9)drm_atomic_set_crtc_for_connector(9)- explicit fencing properties(9) π§
lowkey a whole friend group of atomic setters, and this one's the mode-setting queen π
and that's the page, bestie!! π this lil baddie lives over in ./drivers/gpu/drm, dated October 2026 β go read the whole kernel API manual, it's a vibe. ππΈπ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms