xsk_buff_raw_get_ctx(9)
π xsk_buff_raw_get_ctx(9) β like, the Kernel API Manual page, bestie
okay so real talk, this one lives in the Kernel API Manual section 9 (kernel developer vibes only, no cap), and it's literally called xsk_buff_raw_get_ctx. Say that five times fast. Or don't. I couldn't. π«Ά
β¨ NAME β¨
xsk_buff_raw_get_ctx β get a &xdp_desc context, periodt
πΈ SYNOPSIS πΈ
struct xdp_desc_ctx xsk_buff_raw_get_ctx (const struct xsk_buff_pool
*pool , u64 addr , u32 options );
yes bestie that's the whole signature, copy it exactly, don't @ me π
π ARGUMENTS π
poolβ the XSk buff pool that the desc address belongs to π like, which pool this address is swimming inaddrβ the desc address (and it comes from userspace, iykyk π)optionsβ the desc options (also straight from userspace, fr fr)
π¦ DESCRIPTION π¦
So this is a wrapper for xp_raw_get_ctx, and it's the one you use in drivers β yes, drivers specifically, main character energy only πβ¨. For all the actual details, go read its kdoc, because that's where the lore lives. This page is giving "see the source for the plot" π
π RETURN π
It hands you back a new xdp_desc_ctx struct containing the desc's DMA address and the metadata pointer β but only if that metadata pointer is actually present, bestie. If it's not there, it's initialized to NULL instead. Slay. πβ¨
π SEE ALSO π
- Kernel file
./include/net/xdp_sock_drv.hπ xsk_tx_metadata_request(9)π₯
ok that's the whole page, go be iconic with your xdp descs π§ββοΈ
mwah π this one's signed off from ./include/net and dated October 2026 β and it's xsk_buff_raw_get_ctx(9) all the way down, bestie ππ«Άβ
π¦ 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