dev_get_stats(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– dev_get_stats(9) πŸ’–

okay bestie, welcome to the Kernel API Manual entry for dev_get_stats(9) β€” no cap, this is the one about grabbing network device statistics, and it’s lowkey iconic. ✨


🌸 NAME 🌸

dev_get_stats - get network device statistics


✨ SYNOPSIS ✨

struct rtnl_link_stats64 * dev_get_stats (struct net_device *dev ,
struct rtnl_link_stats64 *storage );

πŸŽ€ ARGUMENTS πŸŽ€

  • dev β€” the device you’re getting statistics from, bestie.
  • storage β€” the place to store stats. literally the stats go here. 🫢

πŸ’… DESCRIPTION πŸ’…

Get network statistics from device. Return storage. 🫢

The device driver may provide its own method by setting dev->netdev_ops->get_stats64 or dev->netdev_ops->get_stats; otherwise the internal statistics structure is used. that’s the whole vibe check, fr fr. πŸ¦‹


🌈 SEE ALSO 🌈

Kernel file ./net/core/dev.c πŸ’–

the whole SEE ALSO squad, in original order:


mwah πŸ’‹ that’s the whole page, bestie. source/version vibes: ./net/core; dated October 2026; and the main character is dev_get_stats(9). πŸ‘‘βœ¨

πŸ“¦ where this page comes from