i915_vma_res...nd_dep_await(9)
πΈ i915_vma_res...nd_dep_await(9) πΈ
okay so this is straight out of the Kernel API Manual bestie, and it's genuinely one of those pages where the name is longer than the function π the title got truncated to i915_vma_res...nd_dep_await which is giving "my group chat nickname when I type too fast" energy β the real one is i915_vma_resource_bind_dep_await and yes she ate.
β¨ NAME β¨
i915_vma_resource_bind_dep_await β like, the whole vibe of this function is: make a struct i915_sw_fence wait for all the pending unbinds happening inside a certain range of a vm. that's it, that's the whole gig π
π¦ SYNOPSIS π¦
int i915_vma_resource_bind_dep_await (struct i915_address_space *vm ,
struct i915_sw_fence *sw_fence , u64 offset , u64 size , bool intr ,
gfp_t gfp );
π ARGUMENTS π
vmβ the vm we're looking at. that's our main character β¨sw_fenceβ thestruct i915_sw_fencethat's gonna be doing the awaiting of the unbinds π«Άoffsetβ where the range starts.sizeβ how big the range is.intrβ whether we wait interruptible (the page spells it interrubtible and honestly? iconic typo, no notes π)gfpβ the allocation mode for memory allocations.
π₯ DESCRIPTION π₯
So the function makes sw_fence await all pending unbinds in a certain vm range before calling the complete notifier. periodt.
now, to be able to await each individual unbind, the function needs to allocate memory using the gpf allocation mode (yes that's how it's written on the page, we're not fixing it, we're vibing π). if that fails, the function doesn't just give up and cry β instead it waits for the unbind fence to signal, using intr to judge whether to wait interruptible or not. lowkey clever.
β οΈ heads up bestie, the page says gfp should ideally be selected so as to avoid any expensive memory allocation stalls and rather fail and synchronize itself. don't be out here asking for the expensive stuff π
ββοΈ
and for now the vm mutex is required when calling this function, which means gfp can't call into direct reclaim. in reality? this means that during heavy memory pressure, we will sync in this function. so yeah, under pressure she syncs. that's the trade-off, no cap. π
β RETURN β
- Zero on success π
-ERESTARTSYSif interrupted andintr==true
π SEE ALSO π
- Kernel file
./drivers/gpu/drm/i915/i915_vma_resource.c Introduction(9)i915_vma_resource_alloc(9)i915_vma_resource_free(9)i915_vma_resource_unhold(9)i915_vma_resource_hold(9)i915_vma_resource_unbind(9)__i915_vma_resource_init(9)i915_vma_resource_bind_dep_sync(9)i915_vma_resource_bind_dep_sync_all(9)
and that's the whole page bestie π it lives at ./drivers/gpu/drm/i915, dated October 2026, and the header on top was literally just i915_vma_res...nd_dep_await(9) again because we love a self-referential moment. go read the source, it slays π§ββοΈπ
π¦ 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