STRUCT SDMA_DESC(9)
β¨ struct sdma_desc(9) β¨
okay so bestie, welcome to the Kernel API Manual π this is the page for struct sdma_desc β literally the descriptor structor for one transfer, no cap.
πΈ NAME πΈ
struct sdma_desc β descriptor structor for one transfer π
π¦ SYNOPSIS π¦
struct sdma_desc {
struct virt_dma_desc vd;
unsigned int num_bd;
dma_addr_t bd_phys;
unsigned int buf_tail;
unsigned int buf_ptail;
unsigned int period_len;
unsigned int chn_real_count;
unsigned int chn_count;
struct sdma_channel *sdmac;
struct sdma_buffer_descriptor *bd;
};
like, that's the whole vibe right there π copy it exactly, don't be out here renaming fields fr fr.
π§ MEMBERS π§
okay so here's the member-by-member breakdown, and every single one of these matters π₯
vdβ descriptor for virt dma β¨num_bdβ number of descriptors currently handling πbd_physβ physical address ofbdπ«Άbuf_tailβ ID of the buffer that was processed πΈbuf_ptailβ ID of the previous buffer that was processed π¦period_lenβ period length, used in cyclic. πchn_real_countβ the real count updated frombd->mode.countπ (yes, exactly like that)chn_countβ the transfer count set βsdmacβsdma_channelpointer πbdβ pointer of allocatebdπ
not me noticingbuf_tailandbuf_ptailare lowkey the same but one's the previous one β track them separately bestie, iykyk π
π SEE ALSO π
go read these next, they're iconic, they're all in the Kernel file ./drivers/dma/imx-sdma.c π:
struct sdma_channel_control(9)struct sdma_state_registers(9)struct sdma_context_data(9)struct sdma_channel(9)struct sdma_firmware_header(9)
aaaand that's the page π mwah, slay, periodt β this one came from ./drivers/dma, dated October 2026, and it was absolutely main character energy from start to finish πβ¨π«Ά
π¦ 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