1 # SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause)
5 protocol: genetlink-legacy
6 uapi-header: linux/openvswitch.h
9 OVS flow configuration over generic netlink.
16 Header for OVS Generic Netlink messages.
22 ifindex of local port for datapath (0 to make a request not specific
31 doc: Number of matched packets.
35 doc: Number of matched bytes.
37 name: ovs-key-ethernet
57 byte-order: big-endian
65 byte-order: big-endian
70 byte-order: big-endian
93 byte-order: big-endian
99 byte-order: big-endian
104 byte-order: big-endian
118 name: ovs-key-ipv6-exthdrs
126 name-prefix: ovs-frag-type-
131 doc: Packet is not a fragment.
134 doc: Packet is a fragment with offset 0.
137 doc: Packet is a fragment with nonzero offset.
148 byte-order: big-endian
152 byte-order: big-endian
160 byte-order: big-endian
164 byte-order: big-endian
172 byte-order: big-endian
176 byte-order: big-endian
194 byte-order: big-endian
198 byte-order: big-endian
202 byte-order: big-endian
221 byte-order: big-endian
233 name: ovs-key-ct-tuple-ipv4
239 byte-order: big-endian
243 byte-order: big-endian
247 byte-order: big-endian
251 byte-order: big-endian
256 name: ovs-action-push-vlan
262 byte-order: big-endian
263 doc: Tag protocol identifier (TPID) to push.
267 byte-order: big-endian
268 doc: Tag control identifier (TCI) to push.
271 name-prefix: ovs-ufid-f-
278 name: ovs-action-hash
284 doc: Algorithm used to compute hash prior to recirculation.
288 doc: Basis used for computing hash.
293 Data path hash algorithm for computing Datapath hash. The algorithm type only specifies
294 the fields in a flow will be used as part of the hash. Each datapath is free to use its
295 own hash algorithm. The hash value will be opaque to the user space daemon.
300 name: ovs-action-push-mpls
306 byte-order: big-endian
308 MPLS label stack entry to push
312 byte-order: big-endian
314 Ethertype to set in the encapsulating ethernet frame. The only values
315 ethertype should ever be given are ETH_P_MPLS_UC and ETH_P_MPLS_MC,
316 indicating MPLS unicast or multicast. Other are rejected.
318 name: ovs-action-add-mpls
324 byte-order: big-endian
326 MPLS label stack entry to push
330 byte-order: big-endian
332 Ethertype to set in the encapsulating ethernet frame. The only values
333 ethertype should ever be given are ETH_P_MPLS_UC and ETH_P_MPLS_MC,
334 indicating MPLS unicast or multicast. Other are rejected.
339 MPLS tunnel attributes.
343 name-prefix: ovs-cs-f-
347 doc: Beginning of a new connection.
350 doc: Part of an existing connenction
353 doc: Related to an existing connection.
356 doc: Flow is in the reply direction.
359 doc: Could not track the connection.
362 doc: Conntrack has occurred.
365 doc: Packet's source address/port was mangled by NAT.
368 doc: Packet's destination address/port was mangled by NAT.
373 enum-name: ovs-flow-attr
374 name-prefix: ovs-flow-attr-
379 nested-attributes: key-attrs
381 Nested attributes specifying the flow key. Always present in
382 notifications. Required for all requests (except dumps).
386 nested-attributes: action-attrs
388 Nested attributes specifying the actions to take for packets that
389 match the key. Always present in notifications. Required for
390 OVS_FLOW_CMD_NEW requests, optional for OVS_FLOW_CMD_SET requests. An
391 OVS_FLOW_CMD_SET without OVS_FLOW_ATTR_ACTIONS will not modify the
392 actions. To clear the actions, an OVS_FLOW_ATTR_ACTIONS without any
393 nested attributes must be given.
397 struct: ovs-flow-stats
399 Statistics for this flow. Present in notifications if the stats would
400 be nonzero. Ignored in requests.
405 An 8-bit value giving the ORed value of all of the TCP flags seen on
406 packets in this flow. Only present in notifications for TCP flows, and
407 only if it would be nonzero. Ignored in requests.
412 A 64-bit integer giving the time, in milliseconds on the system
413 monotonic clock, at which a packet was last processed for this
414 flow. Only present in notifications if a packet has been processed for
415 this flow. Ignored in requests.
420 If present in a OVS_FLOW_CMD_SET request, clears the last-used time,
421 accumulated TCP flags, and statistics for this flow. Otherwise
422 ignored in requests. Never present in notifications.
426 nested-attributes: key-attrs
428 Nested attributes specifying the mask bits for wildcarded flow
429 match. Mask bit value '1' specifies exact match with corresponding
430 flow key bit, while mask bit value '0' specifies a wildcarded
431 match. Omitting attribute is treated as wildcarding all corresponding
432 fields. Optional for all requests. If not present, all flow key bits
433 are exact match bits.
438 Flow operation is a feature probe, error logging should be suppressed.
443 A value between 1-16 octets specifying a unique identifier for the
444 flow. Causes the flow to be indexed by this value rather than the
445 value of the OVS_FLOW_ATTR_KEY attribute. Optional for all
446 requests. Present in notifications if the flow was created with this
454 A 32-bit value of ORed flags that provide alternative semantics for
455 flow installation and retrieval. Optional for all requests.
462 enum-name: ovs-key-attr
463 name-prefix: ovs-key-attr-
468 nested-attributes: key-attrs
478 struct: ovs-key-ethernet
479 doc: struct ovs_key_ethernet
483 byte-order: big-endian
487 byte-order: big-endian
496 doc: struct ovs_key_ipv6
517 doc: struct ovs_key_arp
522 doc: struct ovs_key_nd
529 nested-attributes: tunnel-key-attrs
537 byte-order: big-endian
541 doc: Value 0 indicates the hash is not computed by the datapath.
557 doc: connection tracking zone
561 doc: connection tracking mark
566 doc: 16-octet connection tracking label
568 name: ct-orig-tuple-ipv4
570 struct: ovs-key-ct-tuple-ipv4
572 name: ct-orig-tuple-ipv6
574 doc: struct ovs_key_ct_tuple_ipv6
578 nested-attributes: ovs-nsh-key-attrs
582 byte-order: big-endian
583 doc: Should not be sent to the kernel
587 doc: Should not be sent to the kernel
591 doc: struct ip_tunnel_info
595 struct: ovs-key-ipv6-exthdrs
596 doc: struct ovs_key_ipv6_exthdr
599 enum-name: ovs-action-attr
600 name-prefix: ovs-action-attr-
605 doc: ovs port number in datapath
609 nested-attributes: userspace-attrs
613 nested-attributes: key-attrs
614 doc: Replaces the contents of an existing header. The single nested attribute specifies a header to modify and its value.
618 struct: ovs-action-push-vlan
619 doc: Push a new outermost 802.1Q or 802.1ad header onto the packet.
623 doc: Pop the outermost 802.1Q or 802.1ad header from the packet.
627 nested-attributes: sample-attrs
629 Probabilistically executes actions, as specified in the nested attributes.
637 struct: ovs-action-hash
641 struct: ovs-action-push-mpls
643 Push a new MPLS label stack entry onto the top of the packets MPLS
644 label stack. Set the ethertype of the encapsulating frame to either
645 ETH_P_MPLS_UC or ETH_P_MPLS_MC to indicate the new packet contents.
649 byte-order: big-endian
654 nested-attributes: key-attrs
656 Replaces the contents of an existing header. A nested attribute
657 specifies a header to modify, its value, and a mask. For every bit set
658 in the mask, the corresponding bit value is copied from the value to
659 the packet header field, rest of the bits are left unchanged. The
660 non-masked value bits must be passed in as zeroes. Masking is not
661 supported for the OVS_KEY_ATTR_TUNNEL attribute.
665 nested-attributes: ct-attrs
667 Track the connection. Populate the conntrack-related entries
672 doc: struct ovs_action_trunc is a u32 max length
676 doc: struct ovs_action_push_eth
686 nested-attributes: ovs-nsh-key-attrs
688 Push NSH header to the packet.
693 Pop the outermost NSH header off the packet.
698 Run packet through a meter, which may drop the packet, or modify the
699 packet (e.g., change the DSCP field)
703 nested-attributes: action-attrs
705 Make a copy of the packet and execute a list of actions without
706 affecting the original packet and key.
710 nested-attributes: check-pkt-len-attrs
712 Check the packet length and execute a set of actions if greater than
713 the specified packet length, else execute another set of actions.
717 struct: ovs-action-add-mpls
719 Push a new MPLS label stack entry at the start of the packet or at the
720 start of the l3 header depending on the value of l3 tunnel flag in the
721 tun_flags field of this OVS_ACTION_ATTR_ADD_MPLS argument.
725 nested-attributes: dec-ttl-attrs
727 name: tunnel-key-attrs
728 enum-name: ovs-tunnel-key-attr
729 name-prefix: ovs-tunnel-key-attr-
734 byte-order: big-endian
739 byte-order: big-endian
743 byte-order: big-endian
766 byte-order: big-endian
770 byte-order: big-endian
774 nested-attributes: vxlan-ext-attrs
779 struct in6_addr source IPv6 address
784 struct in6_addr destination IPv6 address
792 struct erspan_metadata
794 name: ipv4-info-bridge
797 name: check-pkt-len-attrs
798 enum-name: ovs-check-pkt-len-attr
799 name-prefix: ovs-check-pkt-len-attr-
805 name: actions-if-greater
807 nested-attributes: action-attrs
809 name: actions-if-less-equal
811 nested-attributes: action-attrs
814 enum-name: ovs-sample-attr
815 name-prefix: ovs-sample-attr-
823 nested-attributes: action-attrs
825 name: userspace-attrs
826 enum-name: ovs-userspace-attr
827 name-prefix: ovs-userspace-attr-
836 name: egress-tun-port
842 name: ovs-nsh-key-attrs
843 enum-name: ovs-nsh-key-attr
844 name-prefix: ovs-nsh-key-attr-
857 enum-name: ovs-ct-attr
858 name-prefix: ovs-ct-attr-
878 nested-attributes: nat-attrs
890 enum-name: ovs-nat-attr
891 name-prefix: ovs-nat-attr-
922 enum-name: ovs-dec-ttl-attr
923 name-prefix: ovs-dec-ttl-attr-
928 nested-attributes: action-attrs
930 name: vxlan-ext-attrs
931 enum-name: ovs-vxlan-ext-
932 name-prefix: ovs-vxlan-ext-
939 name-prefix: ovs-flow-cmd-
940 fixed-header: ovs-header
944 doc: Get / dump OVS flow configuration and state
946 attribute-set: flow-attrs
965 doc: Create OVS flow configuration in a data path
967 attribute-set: flow-attrs