History

net: openvswitch: store sampling probability in cb.

When a packet sample is observed, the sampling rate that was used is important to estimate the real frequency of such event. Store the probability of the parent sample action in the skb's cb area and use it in psample action to pass it down to psample module.

Adrian Moreno committed 2 years ago

Commit 71763d81 parent aae0b824 files · +23 −4Browse files

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

Unified · Split

include/uapi/linux/openvswitch.h+2−1
@@ -649,7 +649,8 @@ enum ovs_flow_attr { · 648 unmodified lines
649 * Actions are passed as nested attributes.649 * Actions are passed as nested attributes.
650 *650 *
651 * Executes the specified actions with the given probability on a per-packet651 * Executes the specified actions with the given probability on a per-packet
652 * basis.652 * basis. Nested actions will be able to access the probability value of the
653 * parent @OVS_ACTION_ATTR_SAMPLE.
653 */654 */
654enum ovs_sample_attr {655enum ovs_sample_attr {
655 OVS_SAMPLE_ATTR_UNSPEC,656 OVS_SAMPLE_ATTR_UNSPEC,