STRUCT LIBETH_SQE(9)
π struct libeth_sqe(9) π
okay bestie, buckle up β this is a page from the Kernel API Manual, and it's genuinely one of the cuter little structs in the networking corner of the kernel. it represents a Send Queue Element / Tx buffer, which is exactly what it sounds like: one entry in your Tx ring, holding everything the driver needs to send a thing and then clean up after itself. no cap. π
β¨ NAME β¨
struct libeth_sqe β represents a Send Queue Element / Tx buffer π¦
πΈ SYNOPSIS πΈ
struct libeth_sqe {
enum libeth_sqe_type type:32;
u32 rs_idx;
union {
void *raw;
struct sk_buff *skb;
struct skb_shared_info *sinfo;
struct xdp_frame *xdpf;
struct libeth_xdp_buff *xsk;
};
dma_addr_t dma;
__u32 len;
u32 nr_frags;
u32 packets;
u32 bytes;
unsigned long priv;
};
likeβ¦ look at her. she's got range. ππ
π MEMBERS π
typeβ the type of the buffer, see the enum above (enum libeth_sqe_type, iykyk). this is the field that tells you which member of the union down there is actually the real one. main character energy fr fr. βrs_idxβ index of the last buffer from the batch this one was sent in π{unnamed_union}β anonymous. yeah, she has no name. mysterious. iconic. πrawβ slab buffer to free viakfreeπskbβsk_buffto consume πΈsinfoβ skb shared info of anXDP_TXframe π₯xdpfβ XDP frame from::ndo_xdp_xmitβ‘xskβ XSk Rx frame fromXDP_TXaction π¦
dmaβ DMA address to unmap πlenβ length of the mapped region to unmap πnr_fragsβ number of frags in the frame this buffer belongs to β¨packetsβ number of physical packets sent for this frame πbytesβ number of physical bytes sent for this frame πprivβ driver-private scratchpad π (the driver's own little diary entry, basically)
heads up bestie:typeis the vibe check for the whole struct β it's what tells you which union member is valid. don't go readingskbwhen it's actually anxdpf, that's not slay behaviour. π
π SEE ALSO π
- Kernel file
./include/net/libeth/tx.h enum libeth_sqe_type(9)LIBETH_SQE_CHECK_PRIV(9)struct libeth_cq_pp(9)libeth_tx_complete(9)
go read those next, bestie, they're all part of the same little friend group π«Άπ§
and that's the page!! this one lives in ./include/net/libeth and it's dated October 2026 β so yeah, she's from the future, we stan a forward-thinking struct πβ¨π
π¦ 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