__in6_dev_stats_get(9)
π __in6_dev_stats_get β Kernel API Manual, bestie edition β¨
okay so bestie, welcome to the <pink>Kernel API Manual</pink> entry for __in6_dev_stats_get(9) and honestly? this one's short and sweet, we love a low-commitment king π
πΈ NAME πΈ
__in6_dev_stats_get β get inet6_dev pointer for stats π
like, that's the whole gig. it gets you the inet6_dev pointer. for stats. slay.
π¦ SYNOPSIS π¦
struct inet6_dev * __in6_dev_stats_get (const struct net_device *dev ,
const struct sk_buff *skb );
look at that signature, it's giving main character energy fr fr π
β¨ ARGUMENTS β¨
devβ network device π» like, the device, the netdev, the whole vibeskbβ skb for original incoming interface if needed π so if you need the original incoming interface, this bad boy is where it lives
π DESCRIPTION π
okay so here's the important part, and I need you to actually read it, no skimming π
Caller must holdrcu_read_lockorRTNL, because this function does not take a reference on theinet6_dev.
literally that's it. that's the whole caution. it's an icon of efficiency β¨
so like β the function hands you back an inet6_dev pointer and does not bump a reference on it. meaning if you're not holding rcu_read_lock or RTNL, that pointer could be gone before you finish looking at it. so hold one of them. periodt ππ
the way that this is one (1) sentence of actual technical content and yet the stakes are real β ngl, respect π«Ά
π SEE ALSO π
- Kernel file
./include/net/addrconf.h __in6_dev_get(9)__in6_dev_get_safely(9)in6_dev_get(9)
go read those too, bestie, they're the friend group π (and yes, one of them is literally called _safely, iykyk π)
π cute little sign-off π
this little page lives in ./include/net π¦ and it's dated October 2026 β so go forth, hold your rcu_read_lock, and get those stats, you absolute icon π
π₯β¨
π¦ 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