dma_buf_map...ent_unlocked(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… dma_buf_map_attachment_unlocked(9) β€” from the Kernel API Manual, bestie ✨

okay so picture this: it's a kernel API manual page, the vibe is immaculate, and the function is dma_buf_map_attachment_unlocked. yes that's a mouthful, no we're not changing it, it's iconic and it's staying. πŸŽ€


🌸 NAME 🌸

dma_buf_map_attachment_unlocked β€” Returns the scatterlist table of the attachment; mapped into _device_ address space. Is a wrapper for map_dma_buf() of the dma_buf_ops.

like literally, that's the whole job. it hands you the scatterlist table, mapped into _device_ address space, and under the hood it's just wrapping map_dma_buf() from the dma_buf_ops. slay. πŸ’…


✨ SYNOPSIS ✨

struct sg_table * dma_buf_map_attachment_unlocked (struct
dma_buf_attachment *attach , enum dma_data_direction direction );

look at her go. returns a struct sg_table *, takes a struct dma_buf_attachment *attach and an enum dma_data_direction direction. copy it exactly, don't freestyle, i'm begging 🫢


πŸ¦‹ ARGUMENTS πŸ¦‹

  • attach β€” [in] attachment whose scatterlist is to be returned 🌈
  • direction β€” [in] direction of DMA transfer 🌸

two args, both [in], both doing their little part. main character energy from both of them honestly.


πŸ’– DESCRIPTION πŸ’–

Unlocked variant of dma_buf_map_attachment.

that's it. that's the description. it's the unlocked version, periodt. πŸ”₯


πŸ‘‘ SEE ALSO πŸ‘‘

okay the friend group is LARGE and honestly every one of them is a baddie, let's do the roll call πŸŽ€

Kernel file ./drivers/dma-buf/dma-buf.c β€” the source file, the mothership πŸ’œ

that's the whole squad, no cap. go read them, they ate. ⭐


and that's the page!! 🧚 this absolute gem lives in ./drivers/dma-buf, dated October 2026 β€” so yeah, she's from the future, lowkey. bye bestie, go map some attachments (the unlocked way) πŸ’–βœ¨πŸ“

πŸ“¦ where this page comes from