STRUCT SKB_SHARED_HWTSTAMPS(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– struct skb_shared_hwtstamps(9) πŸ’–

okay bestie, welcome to the Kernel API Manual β€” today’s main character is struct skb_shared_hwtstamps(9), aka hardware time stamps. it’s a tiny struct with big timestamp energy, and we’re gonna get into every detail. no cap. ✨


🌸 NAME 🌸

struct skb_shared_hwtstamps - hardware time stamps. that’s the assignment, and it ate. πŸ’…


✨ SYNOPSIS ✨

okay so the shape is literally this, anonymous union and all:

       struct skb_shared_hwtstamps {
           union {
             ktime_t hwtstamp;
             void *netdev_data;
           };
        };

πŸ’… Members πŸ’…

member-by-member, no skipping, periodt:

  • {unnamed_union} β€” anonymous. yes, literally no name, shy icon behavior. πŸ™ˆ
  • hwtstamp β€” hardware time stamp transformed into duration since arbitrary point in time. that β€œarbitrary point in time” part is doing a lot, bestie. ⏳
  • netdev_data β€” address/cookie of network device driver used as reference to actual hardware time stamp. it’s the driver’s little address/cookie moment. πŸͺ

πŸ¦‹ Description πŸ¦‹

Software time stamps generated by ktime_get_real are stored in skb->tstamp. that’s the software timestamp home, and it’s giving very specific address energy. πŸ’»βœ¨

hwtstamps can only be compared against other hwtstamps from the same device. like, do not cross-compare them β€” that is not the vibe check you want. 🚫🫢

This structure is attached to packets as part of the skb_shared_info. Use skb_hwtstamps to get a pointer. so yeah, it rides along with the packet crew, and that’s iconic. πŸ“¦πŸ‘‘


🌈 SEE ALSO 🌈

Kernel file ./include/linux/skbuff.h is the home base. then the whole linked manpage squad, in order, because we do not drop references around here:


kisses + sparkles, this was built against ./include/linux, October 2026, for struct skb_shared_hwtstamps(9) πŸ«ΆπŸ’–πŸŽ€

πŸ“¦ where this page comes from