History

psample: Add additional metadata attributes

Extend psample to report the following attributes when available: * Output traffic class as a 16-bit value * Output traffic class occupancy in bytes as a 64-bit value * End-to-end latency of the packet in nanoseconds resolution * Software timestamp in nanoseconds resolution (always available) * Packet's protocol. Needed for packet dissection in user space (always available)

Ido Schimmel committed 5 years ago

Commit 07e1a581 parent a03e99d3 files · +52 −1Browse files

Showing the changes to include/uapi (1 of 3 files). Show all

Unified · Split

include/uapi/linux/psample.h+7−0
@@ -16,6 +16,13 @@ enum { · 15 unmodified lines
16 /* commands attributes */16 /* commands attributes */
17 PSAMPLE_ATTR_GROUP_REFCOUNT,17 PSAMPLE_ATTR_GROUP_REFCOUNT,
18 18
19 PSAMPLE_ATTR_PAD,
20 PSAMPLE_ATTR_OUT_TC, /* u16 */
21 PSAMPLE_ATTR_OUT_TC_OCC, /* u64, bytes */
22 PSAMPLE_ATTR_LATENCY, /* u64, nanoseconds */
23 PSAMPLE_ATTR_TIMESTAMP, /* u64, nanoseconds */
24 PSAMPLE_ATTR_PROTO, /* u16 */
25
19 __PSAMPLE_ATTR_MAX26 __PSAMPLE_ATTR_MAX
20};27};
21 28