STRUCT LIBETH_RQ_NAPI_STATS(9)
π NAME π
struct libeth_rq_napi_stats β the "hot" counters you update in the Rx polling loop, bestie β¨
Like, this is the little stats struct that lives on the fast path, so it's giving "keep it tight, keep it quick" energy fr fr πββοΈπ¨
π¦ SYNOPSIS π¦
struct libeth_rq_napi_stats {
union {
struct {
u32 packets;
u32 bytes;
u32 fragments;
u32 hsplit;
};
u32 raw[];
};
};
No cap, that's the whole thing β nested anonymous union + anonymous struct so you can name the fields or index them like array, your choice π
πΈ Members πΈ
okay so let's go member by member, iykyk π
{unnamed_union}β anonymous, it just vibes there with no name π«Ά{unnamed_struct}β also anonymous, also just existing β¨packetsβ received frames counter, the classic "how many did we get" number π¦bytesβ sum of bytes of the received frames above, so like, the size total for those same frames π’fragmentsβ sum of fragments of received S/G frames, S/G being scatter-gather bestie π§©hsplitβ number of frames the device performed the header split for, so hsplit = header split, iconic πrawβ alias to access all the fields as an array, absolutely main character energy for iterating π
lowkey the whole point: raw lets you loop over everything without naming each field, and the anonymous union/struct makes both access styles work. slay π
π SEE ALSO π
- Kernel file
./include/net/libeth/types.hβ go read it, it ate π₯ struct libeth_sq_napi_stats(9)struct libeth_xdpsq_napi_stats(9)struct libeth_xdpsq_lock(9)struct libeth_xdpsq_timer(9)struct libeth_xdp_buff_stash(9)
the whole squad, fr fr π―ββοΈ
and that's the page, bestie π source lives at ./include/net/libeth, dated October 2026, and the name on the cover is struct libeth_rq_napi_stats(9) β periodt ππ¦
π¦ 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