drm_atomic_c...r_each_plane(9)
π NAME π
drm_atomic_crtc_for_each_plane β okay so this one iterates over the planes that are currently attached to a CRTC π¦
β¨ SYNOPSIS β¨
drm_atomic_crtc_for_each_plane (plane , crtc );
(it's a macro, bestie, so yes the spacing is a whole vibe π keep it exactly like that)
π ARGUMENTS π
planeβ this is your loop cursor π like, the variable that hops from plane to plane while you're looping.crtcβ the CRTC whose planes are getting iterated π that's the one you're looking at.
πΈ DESCRIPTION πΈ
So here's the tea: this iterates over the current state β useful, for example, when you're applying atomic state after it's already been checked and swapped. Lowkey the "we're done deciding, now commit" moment π«Ά
But if you want to iterate over the planes that will be attached β which is, ngl, more useful in code called from drm_mode_config_funcs.atomic_check β then you want drm_atomic_crtc_state_for_each_plane instead πβ¨ iykyk.
fr fr though, don't mix these two up β one is "what's attached rn", the other is "what's about to be attached". Different vibes, different macros, no cap π
π₯ SEE ALSO π₯
- Kernel file
./include/drm/drm_atomic_helper.hπ drm_atomic_crtc_state_for_each_plane(9)drm_atomic_crtc_state_for_each_plane_state(9)drm_atomic_plane_enabling(9)drm_atomic_plane_disabling(9)
and that's the whole page, periodt π
This little icon lives over in ./include/drm, dated October 2026, and the header on it is drm_atomic_c...r_each_plane(9) β mwah, go slay some atomic state π§π
π¦ 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