STRUCT CAL_DMAQUEUE(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ¦‹ struct cal_dmaqueue(9) πŸ¦‹

okay bestie, listen up πŸ’… this is a page from the Kernel API Manual and it's literally about struct cal_dmaqueue β€” the Queue of DMA buffers. yes. a whole queue. of buffers. for DMA. she's iconic, she's organized, she's got a spinlock and she's not afraid to use it ✨


✨ SYNOPSIS ✨

struct cal_dmaqueue {
    spinlock_t lock;
    struct list_head        queue;
    struct cal_buffer       *pending;
    struct cal_buffer       *active;
    enum cal_dma_state      state;
    struct wait_queue_head  wait;
 };

look at her. six fields. main character energy fr fr 🌸


πŸŽ€ Members πŸŽ€

like. the whole cast. one by one. no skips, no cap πŸ‘‘

  • lock β€” the bouncer at the door 🫢 protects all fields in the cal_dmaqueue. every single one. don't touch anything without her.
  • queue β€” the waiting room πŸ’– buffers queued to the driver and waiting for DMA processing. buffers get added to the list by the vb2 .buffer_queue operation, and then they move to pending when they're scheduled for the next frame. the way that pipeline just flows 😭
  • pending β€” the buffer handed to the hardware to DMA the next frame ⭐ will move to active at the end of the current frame. she's next up, she's ready, she's waiting her turn.
  • active β€” the buffer being DMA'ed to for the current frame πŸ”₯ at the end of the current frame she gets retired and given back to vb2 β€” but only if a pending buffer has been scheduled to replace her. if not? she stays. periodt.
  • state β€” the state of the DMA engine. that's it. that's the field. vibe check on the whole engine πŸ’€
  • wait β€” the wait queue that signals a state transition to CAL_DMA_STOPPED πŸ™ˆ so everybody waiting knows what's up.

🌈 SEE ALSO 🌈

  • Kernel file ./drivers/media/platform/ti/cal/cal.h β€” go read it, iykyk πŸ’œ
ngl if you skipped the Members section: go back. every field matters. i said what i said πŸ‘‘

that's the whole page bestie, you ate that πŸ“ this cutie lives in ./drivers/media/platform/ti/cal and the docs are dated October 2026 β€” yes, October 2026, she's from the future, we don't ask questions πŸ’« mwah, go read cal.h πŸ§šβ€β™€οΈπŸ’–

πŸ“¦ where this page comes from