STRUCT CDNS3_ALIGNED_BUF(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– struct cdns3_aligned_buf(9) πŸ’–

okay so bestie, welcome to the Kernel API Manual β€” yes we're reading kernel docs together, this is our bonding arc 🫢. Today's main character is struct cdns3_aligned_buf, and it's literally just the little guy that represents an aligned buffer used for DMA transfer. humble! iconic! necessary! ✨


🌸 NAME 🌸

struct cdns3_aligned_buf β€” represent aligned buffer used for DMA transfer πŸ’…


πŸŽ€ SYNOPSIS πŸŽ€

struct cdns3_aligned_buf {
    void *buf;
    dma_addr_t dma;
    u32 size;
    enum dma_data_direction dir;
    unsigned in_use:1;
    struct list_head        list;
 };

yes that's the whole vibe check right there, copied exactly, no notes πŸ’€


πŸ¦‹ Members πŸ¦‹

okay so let's meet the cast one by one, no skipping, we appreciate every field here πŸ‘‘

  • buf β€” the aligned to 8 bytes data buffer, bestie. and lowkey important: the buffer address used in TRB shall be aligned to 8. so like, shall. that's not a suggestion, that's a whole requirement 🌈
  • dma β€” the dma address. that's it, that's the field, it's giving "shows up, does its job, leaves" πŸ’œ
  • size β€” size of buffer. short king of a description but fr fr essential πŸ“
  • in_use β€” inform if this buffer is associated with usb_request. literally the yes/no girlie of the struct πŸŽ€
  • list β€” used to adding instance of this object to list. so it's the friend who introduces you to the whole group chat 😭🫢
side note bestie: the struct definition up there also has a dir field of type enum dma_data_direction, but this page's Members list doesn't describe it. not me noticing πŸ‘€ β€” I'm just telling you what's on the page, nothing more, iykyk 🧚

πŸ”₯ SEE ALSO πŸ”₯

go read these next, we're doing a whole marathon, bring snacks πŸ“:

  • Kernel file ./drivers/usb/cdns3/cdns3-gadget.h struct cdns3_usb_regs(9), struct cdns3_trb(9), struct cdns3_endpoint(9), struct cdns3_request(9), struct cdns3_device(9)

like, that's the entire cdns3 extended universe and we're seated for all of it 🌟


and that's the page!! slay πŸ’… this was ./drivers/usb/cdns3, October 2026, struct cdns3_aligned_buf(9) β€” mwah, go forth and align your buffers to 8, ily, bye πŸ’–βœ¨πŸŽ€

πŸ“¦ where this page comes from