STRUCT DMA_HEAP_ALLOCATION_DATA(9)
β¨ NAME β¨
struct dma_heap_allocation_data β it's the metadata your userspace hands over when it wants an allocation π
Manual: Kernel API Manual, bestie. Yes we're in the kernel docs now, put your seatbelt on π
πΈ SYNOPSIS πΈ
struct dma_heap_allocation_data {
__u64 len;
__u32 fd;
__u32 fd_flags;
__u64 heap_flags;
};
That's literally the whole struct. Four little fields. Iconic behavior, no notes π«Ά
π§© Members π§©
lenβ the size of the allocation. That's how much you're asking for, bestie, so be honest about it πfdβ this bad boy will be populated with a fd, and that fd gives you the handle to the allocated dma-buf. It's giving "I'll fill it in for you, don't worry about it" β¨fd_flagsβ the file descriptor flags used when allocating πΈheap_flagsβ the flags that get passed to the heap. Yeah. They go to the heap. That's the vibe π
π DESCRIPTION π
So the deal is: this struct is provided by userspace as an argument to the ioctl π¦
That's it. That's the description. Userspace hands it over, the ioctl takes it, everybody moves on with their day. Main character energy for a metadata struct, honestly π
π SEE ALSO π
- Kernel file
./include/uapi/linux/dma-heap.hβ the source of truth, iykyk π DMABUF Heaps Userspace API(9)β the whole userspace side of the story π§DMA_HEAP_IOCTL_ALLOC - allocate memory from pool(9)β the ioctl that actually takes this struct, the one we were just talking about π₯
ngl bestie, this page is short and sweet β but every field still matters, so don't skip any of them π
okay that's the whole thing, periodt π
this lil masterpiece lives in ./include/uapi/linux and the docs are dated October 2026 β catch you in the group chat, love u, bye π«Άβ¨π
π¦ 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