drm_exec_until_all_locked(9)
π drm_exec_until_all_locked(9) β a Kernel API Manual moment
okay so bestie, welcome to the drm_exec_until_all_locked page, freshly delivered from the Kernel API Manual and honestly? it's giving "small macro, big responsibilities" β¨
πΈ NAME
drm_exec_until_all_locked β loop until all GEM objects are locked π
β¨ SYNOPSIS
drm_exec_until_all_locked (exec );
π¦ ARGUMENTS
execβ thedrm_execobject, your main character for this whole operation π
π DESCRIPTION
This right here is the core functionality of the drm_exec object, no cap. It loops until all GEM objects are locked and no more contention exists π₯
And here's the cute little promise at the top of every loop: at the beginning of the loop it is guaranteed that no GEM object is locked. clean slate energy, we love to see it π§
A global label name drm_exec_retry is used. so if you need to use more than one instance of this macro in the same function, the label needs to be made local to the block with the __label__ keyword π
iykyk β otherwise those labels are gonna vibe-check each other and it will not slay.
not me having to say this but fr fr: multiple instances in one function without __label__ = name clash city π
π SEE ALSO
Kernel file ./include/drm/drm_exec.h plus the whole friend group:
struct drm_exec(9)drm_exec_obj(9)drm_exec_for_each_locked_object(9)drm_exec_for_each_locked_object_reverse(9)drm_exec_retry_on_contention(9)drm_exec_is_contended(9)drm_exec_retry(9)drm_exec_ticket(9)
π«Ά and that's the page!! sourced straight from ./include/drm, dated October 2026 β periodt, go lock some GEM objects bestie π
π¦ 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