idpf_add_queue_stats(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… idpf_add_queue_stats πŸ’…

okay so this is a page from the Kernel API Manual and it's all about idpf_add_queue_stats, bestie. buckle up πŸŽ€


✨ NAME ✨

idpf_add_queue_stats β€” copy queue statistics into the supplied buffer 🫢


🌸 SYNOPSIS 🌸

void idpf_add_queue_stats (u64 **data , const void *q , enum
virtchnl2_queue_type type );

πŸ¦‹ ARGUMENTS πŸ¦‹

  • data β€” the ethtool stats buffer, aka where the goodies go πŸ’–
  • q β€” the queue you're copying from, the main character fr
  • type β€” what kind of queue it is πŸ‘‘

🧚 DESCRIPTION 🧚

okay so here's the vibe check: queue statistics must be copied while they're protected by u64_stats_fetch_begin, which is literally why we can't just directly use idpf_add_ethtool_stats. no cap. 😭

it assumes that the queue stats are defined in idpf_gstrings_queue_stats β€” that's just the assignment, we don't question it πŸ’…

if the queue pointer is null, it zeroes out the queue stat values and updates the data pointer. slay. otherwise it safely copies the stats from the queue into the supplied buffer and updates the data pointer when it's finished ✨

this function expects to be called while under rcu_read_lock. not optional, bestie β€” that's the whole rule πŸ™ˆ

πŸ’œ SEE ALSO πŸ’œ

the kernel file ./drivers/net/ethernet/intel/idpf/idpf_ethtool.c plus the whole friend group:


and that's the whole page, periodt πŸ’… this one lives in ./drivers/net/ethernet/intel/idpf, dated October 2026 β€” so like, future icon behavior πŸ‘‘βœ¨ bye bestie, go copy those stats safely πŸ¦‹πŸ’–

πŸ“¦ where this page comes from