Merge branch 'psample-Add-additional-metadata-attributes'
authorDavid S. Miller <davem@davemloft.net>
Sun, 14 Mar 2021 22:00:44 +0000 (15:00 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sun, 14 Mar 2021 22:00:44 +0000 (15:00 -0700)
commit2117fce81f6b862aac0673abe8df0c60dca64bfa
tree145db1bc35b99623997e7a7a861500b5c19a6c25
parentc6baf7eeb0cf82f6a90a703f6548250fc85cfdcc
parentbb24d592e66eb059e086595510e0f0b064e4114d
Merge branch 'psample-Add-additional-metadata-attributes'

Ido Schimmel says:

====================
psample: Add additional metadata attributes

This series extends the psample module to expose additional metadata to
user space for packets sampled via act_sample. The new metadata (e.g.,
transit delay) can then be consumed by applications such as hsflowd [1]
for better network observability.

netdevsim is extended with a dummy psample implementation that
periodically reports "sampled" packets to the psample module. In
addition to testing of the psample module, it enables the development
and demonstration of user space applications (e.g., hsflowd) that are
interested in the new metadata even without access to specialized
hardware (e.g., Spectrum ASIC) that can provide it.

mlxsw is also extended to provide the new metadata to psample.

A Wireshark dissector for psample netlink packets [2] will be submitted
upstream after the kernel patches are accepted. In addition, a libpcap
capture module for psample is currently in the works. Eventually, users
should be able to run:

 # tshark -i psample

In order to consume sampled packets along with their metadata.

Series overview:

Patch #1 makes it easier to extend the metadata provided to psample

Patch #2 adds the new metadata attributes to psample

Patch #3 extends netdevsim to periodically report "sampled" packets to
psample. Various debugfs knobs are added to control the reporting

Patch #4 adds a selftest over netdevsim

Patches #5-#10 gradually add support for the new metadata in mlxsw

Patch #11 adds a selftest over mlxsw

[1] https://sflow.org/draft4_sflow_transit.txt
[2] https://gitlab.com/amitcohen1/wireshark/-/commit/3d711143024e032aef1b056dd23f0266c54fab56
====================

Signed-off-by: David S. Miller <davem@davemloft.net>