STRUCT XDMA_DESC(9)
β¨ struct xdma_desc(9) β¨
okay so bestie, this is a page straight out of the Kernel API Manual and it's literally all about struct xdma_desc β the DMA desc structure. yes, THE descriptor struct. buckle up π
πΈ NAME πΈ
struct xdma_desc β DMA desc structure
like, it's the descriptor. for DMA. that's the whole vibe. π¦
π SYNOPSIS π
here's the literal shape of it, no cap, copy-pasted from the source of truth:
struct xdma_desc {
struct virt_dma_desc vdesc;
struct xdma_chan *chan;
enum dma_transfer_direction dir;
struct xdma_desc_block *desc_blocks;
u32 dblk_num;
u32 desc_num;
u32 completed_desc_num;
bool cyclic;
bool interleaved_dma;
u32 periods;
u32 period_size;
u32 frames_left;
bool error;
};
look at her. thirteen fields. main character energy fr fr π
π Members π
time for the member-by-member breakdown, bestie β every single one, let's go π«Ά
vdescβ the Virtual DMA descriptor. iconic. literally the virtual layer's descriptor π«chanβ DMA channel pointer. it points at the channel, iykyk π₯dirβ Transferring direction of the request. where the data's headed, basically π§desc_blocksβ Hardware descriptor blocks. the actual hardware-side blocks πdblk_numβ Number of hardware descriptor blocks. count 'em πdesc_numβ Number of hardware descriptors. more counting, we love to see it βcompleted_desc_numβ Completed hardware descriptors. the ones that are done done βcyclicβ Cyclic transfer vs. scatter-gather. which flavor of transfer we're on πinterleaved_dmaβ Interleaved DMA transfer. the interleaved situation πperiodsβ Number of periods in the cyclic transfer. how many periods, in the cyclic transfer πperiod_sizeβ Size of a period in bytes in cyclic transfers. bytes! per period! in cyclic transfers! πframes_leftβ Number of frames left in interleaved DMA transfer. frames remaining, interleaved DMA transfer, you get it π¬errorβ tx error flag. it's the error flag. for tx. π
π SEE ALSO π
okay so if you're going deeper (and you ARE, I can tell), the Kernel file to look at is ./drivers/dma/xilinx/xdma.c β that's where the lore lives. and here's the whole friend group, every single one, not skipping a single bestie π«Ά:
struct xdma_desc_block(9)struct xdma_chan(9)struct xdma_device(9)xdma_link_sg_desc_blocks(9)xdma_link_cyclic_desc_blocks(9)xdma_channel_init(9)xdma_free_desc(9)xdma_alloc_desc(9)xdma_xfer_start(9)xdma_xfer_stop(9)xdma_alloc_channels(9)xdma_issue_pending(9)xdma_terminate_all(9)xdma_synchronize(9)xdma_fill_descs(9)xdma_prep_device_sg(9)xdma_prep_dma_cyclic(9)xdma_prep_interleaved_dma(9)xdma_device_config(9)xdma_free_chan_resources(9)xdma_alloc_chan_resources(9)xdma_channel_isr(9)xdma_irq_fini(9)xdma_set_vector_reg(9)xdma_irq_init(9)xdma_disable_user_irq(9)xdma_enable_user_irq(9)xdma_get_user_irq(9)xdma_remove(9)xdma_probe(9)
no because that's a LOT of cross-references and honestly? slay. read them all. periodt π
ok that's the whole page bestie, nothing skipped, nothing hidden π
and that's the wrap, bestie β this one came from ./drivers/dma/xilinx, dated October 2026, and it's struct xdma_desc(9) all the way down. mwah πβ¨
π¦ 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