libeth_rx_alloc(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– libeth_rx_alloc(9) πŸ’–

okay so bestie, we're in the Kernel API Manual today and this little icon is literally the moment a fresh Rx buffer gets born ✨ stay with me, it's gonna slay


🌸 NAME 🌸

libeth_rx_alloc β€” allocate a new Rx buffer πŸŽ€ (yes that's it, that's the whole job, and she does it flawlessly)


✨ SYNOPSIS ✨

dma_addr_t libeth_rx_alloc (const struct libeth_fq_fp *fq , u32 i );

like, look at her. returns a dma_addr_t, takes two things, no drama πŸ’…


🫢 ARGUMENTS 🫢

  • fq β€” the fill queue you're allocating for, bestie. it's a const struct libeth_fq_fp *, so we're just looking at it, not touching πŸ™ˆ
  • i β€” the index of the buffer within the queue. a u32. that's the one you want, go get her ⭐

πŸ”₯ RETURN πŸ”₯

on a successful allocation you get the DMA address back β€” and you pass that straight to HW for Rx, that's the whole point, iykyk πŸ¦‹

otherwise? you get DMA_MAPPING_ERROR. no buffer, no address, just sadness πŸ’€


🌈 SEE ALSO 🌈

the way that these all live in the kernel file ./include/net/libeth/rx.h β€” obsessed, go read them all fr fr:


ngl the whole friend group is in that one header. mwah πŸ’œ

πŸŽ€ that's the page! brought to you by ./include/net/libeth, dated October 2026, and titled libeth_rx_alloc(9) β€” she ate and left no crumbs, periodt πŸ’…βœ¨πŸŒΈ

πŸ“¦ where this page comes from