dma_resv_get_fences(9)
π dma_resv_get_fences(9) β¨
okay so this is a page from the Kernel API Manual, and bestie, we're talking about dma_resv_get_fences(9) β she's the one who grabs an object's fences fences without the update side lock held. yes, the NAME literally says "fences fences," no cap, that's what it says, we don't ask questions π«Ά
πΈ NAME πΈ
dma_resv_get_fences β get an object's fences fences without update side lock held
like... she gets you the fences. unlocked. iconic behaviour fr fr π
β¨ SYNOPSIS β¨
int dma_resv_get_fences (struct dma_resv *obj , enum dma_resv_usage
usage , unsigned int *num_fences , struct dma_fence ***fences );
that's the whole signature, copy it exactly, don't be weird about it π
π ARGUMENTS π
objβ the reservation object. the main character of this whole situation πusageβ controls which fences to include. seeenum dma_resv_usagefor the deets, iykyk.num_fencesβ the number of fences returned. she's telling you how many you got πfencesβ the array of fence ptrs returned. the array iskrealloc'd to the required size, and must be freed by the caller. that's you. you're the caller. don't forget. π
not me reminding you again: the caller frees it. the caller frees it. the caller frees it. π
π¦ DESCRIPTION π¦
Retrieve all fences from the reservation object. that's it, that's the job, and she does it without the update side lock held β main character energy only β¨
Returns either zero or -ENOMEM. that's the whole return menu, two options, pick one π
π SEE ALSO π
- Kernel file
./drivers/dma-buf/dma-resv.c Reservation Object Overview(9)dma_resv_init(9)dma_resv_fini(9)dma_resv_reserve_fences(9)dma_resv_reset_max_fences(9)dma_resv_add_fence(9)dma_resv_replace_fences(9)dma_resv_iter_first_unlocked(9)dma_resv_iter_next_unlocked(9)dma_resv_iter_first(9)dma_resv_iter_next(9)dma_resv_copy_fences(9)dma_resv_get_singleton(9)dma_resv_wait_timeout(9)dma_resv_set_deadline(9)dma_resv_test_signaled(9)dma_resv_describe(9)
the whole friend group, all linked up, obsessed honestly π
k that's the page!! sourced from ./drivers/dma-buf, dated October 2026, signed off as dma_resv_get_fences(9) β mwah, go free your fences 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