31. ICE:Classification:Flow Director

Enable fdir filter for IPv4/IPv6 + TCP/UDP/SCTP (OS default package) Enable fdir filter for UDP tunnel: Vxlan / NVGRE (OS default package) Enable fdir filter for GTP (comm #1 package) Enable fdir filter for L2 Ethertype (comm #1 package) Enable fdir filter for IPv6 Next Protocol ID(comm #1 package)

31.1. Pattern and input set

Packet Type Pattern Input Set
IPv4/IPv6 + TCP/UDP/SCTP MAC_IPV4_PAY [Dest MAC],[Source IP], [Dest IP], [IP protocol], [TTL], [DSCP]
  MAC_IPV4_UDP [Dest MAC],[Source IP], [Dest IP], [TTL], [DSCP], [Source Port], [Dest Port]
  MAC_IPV4_TCP [Dest MAC],[Source IP], [Dest IP], [TTL], [DSCP], [Source Port], [Dest Port]
  MAC_IPV4_SCTP [Dest MAC],[Source IP], [Dest IP], [TTL], [DSCP], [Source Port], [Dest Port]
  MAC_IPV6_PAY [Dest MAC],[Source IP], [Dest IP], [IP protocol], [TTL], [TC]
  MAC_IPV6_UDP [Dest MAC],[Source IP], [Dest IP], [TTL], [TC], [Source Port], [Dest Port]
  MAC_IPV6_TCP [Dest MAC],[Source IP], [Dest IP], [TTL], [TC], [Source Port], [Dest Port]
  MAC_IPV6_SCTP [Dest MAC],[Source IP], [Dest IP], [TTL], [TC], [Source Port], [Dest Port]
UDP tunnel: VXLAN inner only MAC_IPV4_TUN_IPV4_PAY [Inner Source IP], [Inner Dest IP]
  MAC_IPV4_TUN_IPV4_UDP [Inner Source IP], [Inner Dest IP], [Inner Source Port], [Inner Dest Port]
  MAC_IPV4_TUN_IPV4_TCP [Inner Source IP], [Inner Dest IP], [Inner Source Port], [Inner Dest Port]
  MAC_IPV4_TUN_IPV4_SCTP [Inner Source IP], [Inner Dest IP], [Inner Source Port], [Inner Dest Port]
  MAC_IPV4_TUN_MAC_IPV4_PAY [Inner Source IP], [Inner Dest IP]
  MAC_IPV4_TUN_MAC_IPV4_UDP [Inner Source IP], [Inner Dest IP], [Inner Source Port], [Inner Dest Port]
  MAC_IPV4_TUN_MAC_IPV4_TCP [Inner Source IP], [Inner Dest IP], [Inner Source Port], [Inner Dest Port]
  MAC_IPV4_TUN_MAC_IPV4_SCTP [Inner Source IP], [Inner Dest IP], [Inner Source Port], [Inner Dest Port]
IPv4/IPv6 + GTP-U MAC_IPV4_GTPU [Source IP], [Dest IP], [TEID]
  MAC_IPV4_GTPU_EH [Source IP], [Dest IP], [TEID], [QFI]
  MAC_IPV6_GTPU [Source IPV6], [Dest IPV6], [TEID]
  MAC_IPV6_GTPU_EH [Source IPV6], [Dest IPV6], [TEID], [QFI]
L2 Ethertype L2 Ethertype [Ethertype]
ESP MAC_IPV4_ESP [Source IP] [Dest IP] [SPI]
  MAC_IPV6_ESP [Source IP] [Dest IP] [SPI]
  MAC_IPV4_NAT-T-ESP [Source IP] [Dest IP] [SPI]
  MAC_IPV6_NAT-T-ESP [Source IP] [Dest IP] [SPI]
IPv6 Next Protocol + TCP/UDP/SCTP IPV6_NEXT_PROTO [IPv6ExtHdrtype]
  IPV6_NEXT_PROTO_TCP [IPv6ExtHdrtype]
  IPV6_NEXT_PROTO_UDP [IPv6ExtHdrtype]
  IPV6_NEXT_PROTO_SCTP [IPv6ExtHdrtype]

Note

  1. Enable fdir filter for UDP tunnel: Vxlan / NVGRE (OS default package) , share code not support outer header as inputset, so Out Dest IP and VNI/GRE_KEY may not able to be implemented.
  2. For VXLAN case MAC_IPV4_TUN_*** means MAC_IPV4_UDP_VXLAN_***
  3. For Dest MAC, there is package /sharecode limitation on multicast dst mac support for FDIR

31.2. Function type

validate create list destroy flush query

31.3. Action type

queue index drop rss queues passthru count identifier 0x1234 shared on|off mark mark/rss

31.3.1. Prerequisites

  1. Hardware: Intel® Ethernet 810 Series: E810-XXVDA4/E810-CQ design the cases with 2 ports card.

  2. Software: DPDK: http://dpdk.org/git/dpdk scapy: http://www.secdev.org/projects/scapy/

  3. Copy specific ice package to /lib/firmware/intel/ice/ddp/ice.pkg Then reboot server, and compile DPDK

  4. Bind the pf to dpdk driver:

    ./usertools/dpdk-devbind.py -b igb_uio 86:00.0 86:00.1
    
  5. Launch the app testpmd with the following arguments:

    ./dpdk-testpmd -c 0xff -n 6 -a 86:00.0 --log-level="ice,7" -- -i --portmask=0xff --rxq=64 --txq=64 --port-topology=loop
    testpmd> set fwd rxonly
    testpmd> set verbose 1
    

    If set UDP tunnel flow rule:

    testpmd> port config 0 udp_tunnel_port add vxlan 4789
    testpmd> start
    

    Notes: if need two ports environment, launch testpmd with the following arguments:

    ./dpdk-testpmd -c 0xff -n 6 -a 86:00.0 -a 86:00.1 --log-level="ice,7" -- -i --portmask=0xff --rxq=64 --txq=64 --port-topology=loop
    

31.4. Default parameters

MAC:

[Dest MAC]: 00:11:22:33:44:55

IPv4:

[Source IP]: 192.168.0.20
[Dest IP]: 192.168.0.21
[IP protocol]: 255
[TTL]: 2
[DSCP]: 4

IPv6:

[Source IPv6]: 2001::2
[Dest IPv6]: CDCD:910A:2222:5498:8475:1111:3900:2020
[IP protocol]: 1
[TTL]: 2
[TC]: 1

UDP/TCP/SCTP:

[Source Port]: 22
[Dest Port]: 23

VXLAN inner only:

[Inner Source IP]: 192.168.0.20
[Inner Dest IP]: 192.168.0.21
[Inner Source Port]: 22
[Inner Dest Port]: 23

GTP-U data packet:

[TEID]: 0x12345678
[QFI]: 0x34

L2 Ethertype:

[Ethertype]: 0x8863 0x8864 0x0806 0x8100 0x88f7

IPv6 ExtHdrtype:

[IPv6ExtHdrtype]: IPv6ExtHdrDestOpt IPv6ExtHdrRouting IPv6ExtHdrHopByHop IPv6ExtHdrSegmentRouting

31.5. Send packets

  • MAC_IPV4_PAY

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", proto=255, ttl=2, tos=4) / Raw('x' * 80)],iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:56")/IP(src="192.168.0.20",dst="192.168.0.21", proto=255, ttl=2, tos=4) / Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.22",dst="192.168.0.21", proto=255, ttl=2, tos=4) / Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.1.21", proto=255, ttl=2, tos=4) / Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", proto=1, ttl=2, tos=4) / Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", proto=255, ttl=3, tos=4) / Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", proto=255, ttl=2, tos=9) / Raw('x' * 80)],iface="enp175s0f0")
    
  • MAC_IPV4_UDP

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /UDP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:56")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /UDP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.1.19",dst="192.168.0.21", ttl=2, tos=4) /UDP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.22", ttl=2, tos=4) /UDP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /UDP(sport=21,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /UDP(sport=22,dport=24)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=64, tos=4) /UDP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=1) /UDP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /TCP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    
  • MAC_IPV4_TCP

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /TCP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:56")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /TCP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.1.19",dst="192.168.0.21", ttl=2, tos=4) /TCP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.22", ttl=2, tos=4) /TCP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /TCP(sport=21,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /TCP(sport=22,dport=24)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=64, tos=4) /TCP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=1) /TCP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /UDP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    
  • MAC_IPV4_SCTP

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /SCTP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:56")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /SCTP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.1.19",dst="192.168.0.21", ttl=2, tos=4) /SCTP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.22", ttl=2, tos=4) /SCTP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /SCTP(sport=21,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /SCTP(sport=22,dport=24)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=64, tos=4) /SCTP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=1) /SCTP(sport=22,dport=23)/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4)/Raw('x' * 80)],iface="enp175s0f0")
    
  • MAC_IPV6_PAY

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2", nh=0, tc=1, hlim=2)/("X"*480)], iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:56")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2", nh=0, tc=1, hlim=2)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2022", src="2001::2", nh=0, tc=1, hlim=2)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::1", nh=0, tc=1, hlim=2)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2", nh=2, tc=1, hlim=2)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2", nh=0, tc=2, hlim=2)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2", nh=0, tc=1, hlim=5)/("X"*480)], iface="enp175s0f0")
    
  • MAC_IPV6_UDP

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:56")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2021", src="2001::2",tc=1, hlim=2)/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2002::2",tc=1, hlim=2)/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=3, hlim=2)/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=1)/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/UDP(sport=21,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/UDP(sport=22,dport=24)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    
  • MAC_IPV6_TCP

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:56")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2021", src="2001::2",tc=1, hlim=2)/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2002::2",tc=1, hlim=2)/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=3, hlim=2)/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=1)/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/TCP(sport=21,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/TCP(sport=22,dport=24)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    
  • MAC_IPV6_SCTP

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:56")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2021", src="2001::2",tc=1, hlim=2)/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2002::2",tc=1, hlim=2)/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=3, hlim=2)/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=1)/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/SCTP(sport=21,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/SCTP(sport=22,dport=24)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2",tc=1, hlim=2)/("X"*480)], iface="enp175s0f0")
    
  • MAC_IPV4_TUN_IPV4_PAY/MAC_IPV4_TUN_MAC_IPV4_PAY

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN()/Ether()/IP(src='192.168.0.20', dst='192.168.0.21')/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/Ether()/IP(src='192.168.0.20', dst='192.168.0.21')], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21', frag=1)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN(vni=2)/Ether(dst="00:11:22:33:44:55")/IP(dst="192.168.0.21", src="192.168.0.20")/("X"*480)], iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.22')], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.30', dst='192.168.0.21')], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN()/IP(dst="192.168.0.21", src="192.168.0.20")/("X"*480)], iface="enp175s0f0")
    
  • MAC_IPV4_TUN_IPV4_UDP/MAC_IPV4_TUN_MAC_IPV4_UDP

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN()/Ether()/IP(src='192.168.0.20', dst='192.168.0.21')/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/Ether()/IP(src='192.168.0.20', dst='192.168.0.21')/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN(vni=2)/Ether(dst="00:11:22:33:44:55")/IP(dst="192.168.0.21", src="192.168.0.20")/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.22')/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN(vni=2)/Ether(dst="00:11:22:33:44:55")/IP(src='192.168.0.21', dst='192.168.0.23')/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/UDP(sport=21,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/UDP(sport=22,dport=24)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/TCP(sport=22, dport=23)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN()/IP(dst="192.168.0.21", src="192.168.0.20")/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    
  • MAC_IPV4_TUN_IPV4_TCP/MAC_IPV4_TUN_MAC_IPV4_TCP

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN(vni=2)/Ether()/IP(src='192.168.0.20', dst='192.168.0.21')/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/Ether()/IP(src='192.168.0.20', dst='192.168.0.21')/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN(vni=2)/Ether(dst="00:11:22:33:44:55")/IP(dst="192.168.0.21", src="192.168.0.20")/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.22')/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN(vni=2)/Ether(dst="00:11:22:33:44:55")/IP(dst="192.168.0.21", src="192.168.0.23")/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/TCP(sport=21,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/TCP(sport=22,dport=24)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/Raw('x' * 80)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN()/IP(dst="192.168.0.21", src="192.168.0.20")/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    
  • MAC_IPV4_TUN_IPV4_SCTP/MAC_IPV4_TUN_MAC_IPV4_SCTP

    matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN(vni=2)/Ether()/IP(src='192.168.0.20', dst='192.168.0.21')/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/Ether()/IP(src='192.168.0.20', dst='192.168.0.21')/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN(vni=2)/Ether(dst="00:11:22:33:44:55")/IP(dst="192.168.0.21", src="192.168.0.20")/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    

    unmatched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.22')/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN(vni=2)/Ether(dst="00:11:22:33:44:55")/IP(dst="192.168.0.21", src="192.168.0.23")/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/SCTP(sport=21,dport=23)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/SCTP(sport=22,dport=24)/("X"*480)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst='192.168.1.15')/UDP(sport=200, dport=4790)/VXLAN(flags=0xc)/IP(src='192.168.0.20', dst='192.168.0.21')/UDP(sport=22, dport=23)/Raw('x' * 80)], iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN()/IP(dst="192.168.0.21", src="192.168.0.20")/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0")
    
  • MAC_IPV4_GTPU_EH

    matched packets:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/Raw('x'*20)
    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP(frag=1)/Raw('x'*20)
    p_gtpu3 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/UDP()/Raw('x'*20)
    p_gtpu4 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP( dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/TCP(sport=22, dport=23)/Raw('x'*20)
    p_gtpu5 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/ICMP()/Raw('x'*20)
    p_gtpu6 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IPv6()/Raw('x'*20)
    p_gtpu7 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IPv6()/IPv6ExtHdrFragment(1000)/Raw('x'*20)
    p_gtpu8 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IPv6()/UDP()/Raw('x'*20)
    p_gtpu9 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP( dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IPv6()/TCP(sport=22, dport=23)/Raw('x'*20)
    p_gtpu10 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IPv6()/ICMP()/Raw('x'*20)
    p_gtpu11 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/Raw('x'*20)
    

    unmatched packets:

    p_gtpu12 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x1234567)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/Raw('x'*20)
    p_gtpu13 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x35)/IP()/Raw('x'*20)
    p_gtpu14 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/Raw('x'*20)
    
  • MAC_IPV4_GTPU

    matched packets:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/Raw('x'*20)
    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP(frag=1)/Raw('x'*20)
    p_gtpu3 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/UDP()/Raw('x'*20)
    p_gtpu4 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP( dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/TCP(sport=22, dport=23)/Raw('x'*20)
    p_gtpu5 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/ICMP()/Raw('x'*20)
    p_gtpu6 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IPv6()/Raw('x'*20)
    p_gtpu7 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IPv6()/IPv6ExtHdrFragment(1000)/Raw('x'*20)
    p_gtpu8 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IPv6()/UDP()/Raw('x'*20)
    p_gtpu9 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP( dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IPv6()/TCP(sport=22, dport=23)/Raw('x'*20)
    p_gtpu10 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IPv6()/ICMP()/Raw('x'*20)
    p_gtpu11 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x35)/IP()/Raw('x'*20)
    p_gtpu12 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/Raw('x'*20)
    

    unmatched packets:

    p_gtpu13 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x1234567)/IP()/Raw('x'*20)
    
  • MAC_IPV6_GTPU_EH

    matched packets:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/Raw('x'*20)
    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP(frag=1)/Raw('x'*20)
    p_gtpu3 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/UDP()/Raw('x'*20)
    p_gtpu4 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/TCP(sport=22, dport=23)/Raw('x'*20)
    p_gtpu5 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/ICMP()/Raw('x'*20)
    p_gtpu6 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IPv6()/Raw('x'*20)
    p_gtpu7 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IPv6()/IPv6ExtHdrFragment()/Raw('x'*20)
    p_gtpu8 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IPv6()/UDP()/Raw('x'*20)
    p_gtpu9 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP( dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IPv6()/TCP(sport=22, dport=23)/Raw('x'*20)
    p_gtpu10 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IPv6()/ICMP()/Raw('x'*20)
    

    unmatched packets:

    p_gtpu11 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/Raw('x'*20)
    p_gtpu12 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x1234567)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/Raw('x'*20)
    p_gtpu13 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x35)/IP()/ICMP()/Raw('x'*20)
    p_gtpu14 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::3", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/TCP()/Raw('x'*20)
    p_gtpu15 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2021")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/UDP()/Raw('x'*20)
    
  • MAC_IPV6_GTPU

    matched packets:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/Raw('x'*20)
    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP(frag=1)/Raw('x'*20)
    p_gtpu3 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/UDP()/Raw('x'*20)
    p_gtpu4 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP( dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/TCP(sport=22, dport=23)/Raw('x'*20)
    p_gtpu5 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/ICMP()/Raw('x'*20)
    p_gtpu6 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IPv6()/Raw('x'*20)
    p_gtpu7 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IPv6()/IPv6ExtHdrFragment()/Raw('x'*20)
    p_gtpu8 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IPv6()/UDP()/Raw('x'*20)
    p_gtpu9 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP( dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IPv6()/TCP(sport=22, dport=23)/Raw('x'*20)
    p_gtpu10 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IPv6()/ICMP()/Raw('x'*20)
    

    unmatched packets:

    p_gtpu11 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x1234567)/IP()/Raw('x'*20)
    p_gtpu12 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::3", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/TCP()/Raw('x'*20)
    p_gtpu13 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2021")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/UDP()/Raw('x'*20)
    
  • L2 Ethertype

    PPPoED packets:

    sendp([Ether(dst="00:11:22:33:44:55")/PPPoED()/PPP()/IP()/Raw('x' *80)],iface="enp134s0f1")
    sendp([Ether(dst="00:11:22:33:44:55", type=0x8863)/IP()/Raw('x' * 80)],iface="enp134s0f1")
    

    PPPoE packets:

    sendp([Ether(dst="00:11:22:33:44:55")/PPPoE()/PPP(proto=0x0021)/IP()/Raw('x' * 80)],iface="enp134s0f1")
    sendp([Ether(dst="00:11:22:33:44:55", type=0x8864)/IP()/Raw('x' * 80)],iface="enp134s0f1")
    

    ARP packets:

    sendp([Ether(dst="00:11:22:33:44:55")/ARP(pdst="192.168.1.1")],iface="enp134s0f1")
    sendp([Ether(dst="00:11:22:33:44:55", type=0x0806)/Raw('x' *80)],iface="enp134s0f1")
    

    EAPS packets:

    sendp([Ether(dst="00:11:22:33:44:55",type=0x8100)],iface="enp134s0f1")
    sendp([Ether(dst="00:11:22:33:44:55")/Dot1Q(vlan=1)],iface="enp134s0f1")
    

    ieee1588 packet:

    sendp([Ether(dst="00:11:22:33:44:55",type=0x88f7)/"\\x00\\x02"], iface="enp134s0f1")
    
  • MAC_IPV4_ESP

    matched packets:

    sendp(Ether(dst='00:11:22:33:44:55')/IP(src="192.168.0.20",dst="192.168.0.21",proto=50)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    

    mismatched packets:

    sendp(Ether(dst='00:11:22:33:44:55')/IP(src="192.168.0.22",dst="192.168.0.21",proto=50)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    sendp(Ether(dst='00:11:22:33:44:55')/IP(src="192.168.0.20",dst="192.168.0.11",proto=50)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    sendp(Ether(dst='00:11:22:33:44:55')/IP(src="192.168.0.20",dst="192.168.0.21",proto=50)/ESP(spi=17)/Raw('x'*480),iface="enp134s0f1")
    
  • MAC_IPV6_ESP

    matched packets:

    sendp(Ether(dst='00:11:22:33:44:55')/IPv6(src="2001::1",dst="2001::2",nh=50)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    

    mismatched packets:

    sendp(Ether(dst='00:11:22:33:44:55')/IPv6(src="2001::8",dst="2001::2",nh=50)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    sendp(Ether(dst='00:11:22:33:44:55')/IPv6(src="2001::1",dst="2001::9",nh=50)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    sendp(Ether(dst='00:11:22:33:44:55')/IPv6(src="2001::1",dst="2001::2",nh=50)/ESP(spi=17)/Raw('x'*480),iface="enp134s0f1")
    
  • MAC_IPV4_NAT-T-ESP

    matched packets:

    sendp(Ether(dst='00:11:22:33:44:55')/IP(src="192.168.0.20",dst="192.168.0.21")/UDP(dport=4500)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    

    mismatched packets:

    sendp(Ether(dst='00:11:22:33:44:55')/IP(src="192.168.0.22",dst="192.168.0.21")/UDP(dport=4500)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    sendp(Ether(dst='00:11:22:33:44:55')/IP(src="192.168.0.20",dst="192.168.0.11")/UDP(dport=4500)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    sendp(Ether(dst='00:11:22:33:44:55')/IP(src="192.168.0.20",dst="192.168.0.21")/UDP(dport=4500)/ESP(spi=77)/Raw('x'*480),iface="enp134s0f1")
    
  • MAC_IPV6_NAT-T-ESP

    matched packets:

    sendp(Ether(dst='00:11:22:33:44:55')/IPv6(src="2001::1",dst="2001::2")/UDP(dport=4500)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    

    mismatched packets:

    sendp(Ether(dst='00:11:22:33:44:55')/IPv6(src="2001::8",dst="2001::2")/UDP(dport=4500)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    sendp(Ether(dst='00:11:22:33:44:55')/IPv6(src="2001::1",dst="2001::9")/UDP(dport=4500)/ESP(spi=7)/Raw('x'*480),iface="enp134s0f1")
    sendp(Ether(dst='00:11:22:33:44:55')/IPv6(src="2001::1",dst="2001::2")/UDP(dport=4500)/ESP(spi=77)/Raw('x'*480),iface="enp134s0f1")
    
  • IPV6_NEXT_PROTO

    matched packets:

    sendp([Ether(dst='00:11:22:33:44:55')/IPv6(nh=123)/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrDestOpt(nh=123)/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrRouting(nh=123)/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrHopByHop(nh=123)/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrSegmentRouting(nh=123)/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrDestOpt()/IPv6ExtHdrDestOpt(nh=123)/Raw('x'*40)],iface="ens192f0")
    

    mismatched packets:

    sendp([Ether(dst='00:11:22:33:44:55')/IPv6(nh=111)/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/UDP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/TCP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/SCTP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrFragment(nh=123)/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrRouting()/IPv6ExtHdrRouting(nh=111)/Raw('x'*40)],iface="ens192f0")
    
  • IPV6_NEXT_PROTO_UDP

    matched packets:

    sendp([Ether(dst='00:11:22:33:44:55')/IPv6(nh=17)/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/TCP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrDestOpt(nh=17)/UDP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrRouting(nh=17)/UDP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrHopByHop(nh=17)/UDP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrSegmentRouting(nh=17)/UDP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrDestOpt()/IPv6ExtHdrDestOpt(nh=17)/UDP()/Raw('x'*40)],iface="ens192f0")
    

    mismatched packets:

    sendp([Ether(dst='00:11:22:33:44:55')/IPv6(nh=6)/UDP/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/TCP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/SCTP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrFragment(nh=17)/UDP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrRouting()/IPv6ExtHdrRouting(nh=111)/UDP()/Raw('x'*40)],iface="ens192f0")
    
  • IPV6_NEXT_PROTO_TCP

    matched packets:

    sendp([Ether(dst='00:11:22:33:44:55')/IPv6(nh=6)/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/TCP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrDestOpt(nh=6)/TCP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrRouting(nh=6)/TCP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrHopByHop(nh=6)/TCP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrSegmentRouting(nh=6)/TCP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrDestOpt()/IPv6ExtHdrDestOpt(nh=6)/TCP()/Raw('x'*40)],iface="ens192f0")
    

    mismatched packets:

    sendp([Ether(dst='00:11:22:33:44:55')/IPv6(nh=17)/TCP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/UDP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/SCTP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrFragment(nh=6)/TCP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrRouting()/IPv6ExtHdrRouting(nh=111)/TCP()/Raw('x'*40)],iface="ens192f0")
    
  • IPV6_NEXT_PROTO_SCTP

    matched packets:

    sendp([Ether(dst='00:11:22:33:44:55')/IPv6(nh=132)/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/SCTP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrDestOpt(nh=132)/SCTP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrRouting(nh=132)/SCTP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrHopByHop(nh=132)/SCTP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrSegmentRouting(nh=132)/SCTP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrDestOpt(nh=123)/IPv6ExtHdrDestOpt(nh=132)/SCTP()/Raw('x'*40)],iface="ens192f0")
    

    mismatched packets:

    sendp([Ether(dst='00:11:22:33:44:55')/IPv6(nh=123)/SCTP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/TCP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/UDP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrFragment(nh=132)/SCTP()/Raw('x'*40)],iface="ens192f0")
    sendp([Ether(dst='00:11:22:33:44:55')/IPv6()/IPv6ExtHdrRouting()/IPv6ExtHdrRouting(nh=111)/SCTP()/Raw('x'*40)],iface="ens192f0")
    

31.5.1. Test case: flow validation

  1. validate MAC_IPV4_PAY with queue index action:

    flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions queue index 1 / mark / end
    

    get the message:

    Flow rule validated
    
  2. repeat step 1 with all patterns in pattern and input set table, get the same result.

  3. repeat step 1-2 with action rss queues/drop/passthru/mark/mark+rss, get the same result.

  4. validate combined use of actions:

    flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions count / end
    flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions queue index 1 / mark / count / end
    flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions rss queues 0 1 end / mark id 1 / count identifier 0x1234 / end
    flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions passthru / mark id 2 / count identifier 0x34 / end
    flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions mark id 3 / rss / count / end
    flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions drop / count / end
    

    get the message:

    Flow rule validated
    
  5. check the flow list:

    testpmd> flow list 0
    

    there is no rule listed.

31.5.2. Test case: negative validation

Note: there may be error message change.

  1. void action:

    flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / and actions end
    

    get the message:

    Invalid argument
    
  2. conflict action:

    flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues 2 3 end / rss / end
    

    get the message:

    Unsupported action combination: Invalid argument
    
  3. invalid mark id:

    flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions passthru / mark id 4294967296 / end
    

    get the message:

    Bad arguments
    
  4. invalid input set:

    flow validate 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tc is 4 / end actions queue index 1 / end
    

    get the message:

    Bad arguments
    
  5. invalid queue index:

    flow validate 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions queue index 64 / end
    

    get the message:

    Invalid input action: Invalid argument
    
  6. invalid rss queues parameter

    Invalid number of queues:

    flow validate 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues 1 2 3 end / end
    flow validate 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues 0 end / end
    flow validate 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues end / end
    

    get the message:

    'error' in message
    

    Discontinuous queues:

    flow validate 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues 1 2 3 5 end / end
    

    get the message:

    Discontinuous queue region: Invalid argument
    

    invalid rss queues index:

    flow validate 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues 63 64 end / end
    

    get the message:

    Invalid queue region indexes.: Invalid argument
    
  7. Invalid value of input set:

    flow validate 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x100000000 / gtp_psc qfi is 0x5 / end actions queue index 2 / end
    flow validate 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x100000000 / end actions queue index 1 / end
    

    get the message:

    Bad arguments
    
  8. unsupported pattern,validate GTPU rule with OS default package:

    flow validate 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions drop / end
    

    get the message:

    Bad arguments
    
  9. invalid port:

    flow validate 2 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions queue index 1 / end
    

    get the message:

    No such device: No such device
    
  10. check the flow list:

    testpmd> flow list 0
    
there is no rule listed.

31.5.3. Test case: MAC_IPV4_PAY pattern

31.6. Subcase 1: MAC_IPV4_PAY queue index

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions queue index 1 / mark / end
    
  2. send matched packets, check the packets are distributed to queue 1 with FDIR matched ID. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the rule listed. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.7. Subcase 2: MAC_IPV4_PAY rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues 2 3 end / mark / end
    
  2. send matched packets, check the packets are distributed to queue 2 or 3 without with FDIR matched ID. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.8. Subcase 3: MAC_IPV4_PAY passthru

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions passthru / mark / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed to the same queue without FDIR matched ID=0x0. check there is no rule listed.

31.9. Subcase 4: MAC_IPV4_PAY drop

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped send unmatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped. check there is no rule listed.

31.10. Subcase 5: MAC_IPV4_PAY mark+rss

Note: This combined action is mark with RSS which is without queues specified.

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions mark / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x0 send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed to the same queue without FDIR matched ID. check there is no rule listed.

31.11. Subcase 6: MAC_IPV4_PAY mark

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions mark id 1 / end
    
  2. repeat the steps of passthru with mark part in subcase 3, get the same result.

31.12. Subcase 7: MAC_IPV4_PAY protocal

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 proto is 1 / end actions queue index 1 / mark id 1 / end
    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 proto is 17 / end actions passthru / mark id 3 / end
    
  2. send matched packets:

    pkt1 = Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", proto=1) / Raw('x' * 80)
    pkt2 = Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.19",dst="192.168.0.21", proto=1)/Raw('x' * 80)
    pkt3 = Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", ttl=2, tos=4) /UDP(sport=22,dport=23)/Raw('x' * 80)
    pkt4 = Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", proto=17)/TCP(sport=22, dport=23)/Raw('x' * 80)
    pkt5 = Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", proto=17, ttl=2, tos=4)/Raw('x' * 80)
    pkt6 = Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", proto=17, ttl=2, tos=4)/UDP(sport=22,dport=23)/TCP(sport=22, dport=23)/Raw('x' * 80)
    

    check the pkt1 and pkt2 are redirected to queue 1 with FDIR matched ID=0x1. check the pkt3-pkt6 are distributed by RSS with FDIR matched ID=0x3. send unmatched packets:

    pkt7 = Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.22", proto=1) / Raw('x' * 80)
    pkt8 = Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", proto=6) / Raw('x' * 80)
    pkt9 = Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21")/TCP(sport=22,dport=23)/ Raw('x' * 80)
    pkt10 = Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21")/TCP(sport=22,dport=23)/UDP(sport=22,dport=23)/Raw('x' * 80)
    

    check the packets received are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.12.1. Test case: MAC_IPV4_UDP pattern

31.13. Subcase 1: MAC_IPV4_UDP queue index

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / udp src is 22 dst is 23 / end actions queue index 63 / mark id 0 / end
    
  2. send matched packets, check the packets is distributed to queue 63 with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the rule listed. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packet is distributed by RSS without FDIR matched ID. check there is no rule listed.

31.14. Subcase 2: MAC_IPV4_UDP rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / udp src is 22 dst is 23 / end actions rss queues 0 1 2 3 end / mark id 4294967294 / end
    
  2. send matched packets, check the packets is distributed to queue 0-3 with FDIR matched ID=0xfffffffe. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. check there is no rule listed.

31.15. Subcase 3: MAC_IPV4_UDP passthru

  1. create filter rule with mark:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / udp src is 22 dst is 23 / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.16. Subcase 4: MAC_IPV4_UDP drop

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / udp src is 22 dst is 23 / end actions drop / mark / end
    
  2. send matched packet, check the packet is dropped. send unmatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is dropped. check there is no rule listed.

31.17. Subcase 5: MAC_IPV4_UDP mark+rss

Note: This combined action is mark with RSS which is without queues specified.

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / udp src is 22 dst is 23 / end actions mark id 2 / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x2 send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.18. Subcase 6: MAC_IPV4_UDP mark

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / udp src is 22 dst is 23 / end actions mark id 1 / end
    
  2. repeat the step 2-3 of in subcase 3, get the same result.

31.18.1. Test case: MAC_IPV4_TCP pattern

  1. replace “udp” with “tcp” in all the subcases of MAC_IPV4_UDP pattern.
  2. Then repeat all the steps in all the subcases of MAC_IPV4_UDP pattern.
  3. get the same result.

31.18.2. Test case: MAC_IPV4_SCTP pattern

  1. replace “udp” with “sctp” in all the subcases of MAC_IPV4_UDP pattern.
  2. Then repeat all the steps in all the subcases of MAC_IPV4_UDP pattern.
  3. get the same result.

31.18.3. Test case: MAC_IPV6_PAY pattern

31.19. Subcase 1: MAC_IPV6_PAY queue index

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 proto is 0 hop is 2 tc is 1 / end actions queue index 1 / mark / end
    
  2. send matched packets, check the packets is distributed to queue 1 with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the rule listed. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packet is distributed by RSS without FDIR matched ID. check there is no rule listed.

31.20. Subcase 2: MAC_IPV6_PAY rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 proto is 0 hop is 2 tc is 1 / end \
    actions rss queues 56 57 58 59 60 61 62 63 end / mark / end
    
  2. send matched packets, check the packets is distributed to queue 56-63 with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. check there is no rule listed.

31.21. Subcase 3: MAC_IPV6_PAY passthru

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 proto is 0 hop is 2 tc is 1 / end actions passthru / mark / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are destributed by RSS without FDIR matched ID . check there is no rule listed.

31.22. Subcase 4: MAC_IPV6_PAY drop

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 proto is 0 hop is 2 tc is 1 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is dropped. check there is no rule listed.

31.23. Subcase 5: MAC_IPV6_PAY mark+rss

Note: This combined action is mark with RSS which is without queues specified.

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 proto is 0 hop is 2 tc is 1 / end actions mark / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x0 send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.24. Subcase 6: MAC_IPV6_PAY mark

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 proto is 0 hop is 2 tc is 1 / end actions mark / end
    
  2. repeat the steps of passthru in subcase 3, get the same result.

31.25. Subcase 7: MAC_IPV6_PAY protocal

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 proto is 17 / end actions rss queues 5 6 end / mark id 1 / end
    flow create 0 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 proto is 6 / end actions mark id 2 / rss / end
    
  2. send matched packets:

    pkt1 = Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="ABAB:910A:2222:5498:8475:1111:3900:1010", nh=17, tc=1, hlim=2)/("X"*480)
    pkt2 = Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", nh=17)/("X"*480)
    pkt3 = Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="ABAB:910A:2222:5498:8475:1111:3900:1010", nh=17)/TCP(sport=22,dport=23)/("X"*480)
    pkt4 = Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", tc=1, hlim=2)/UDP(sport=22,dport=23)/TCP(sport=22,dport=23)/("X"*480)
    pkt5 = Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", nh=6)/("X"*480)
    pkt6 = Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/TCP(sport=22,dport=23)/("X"*480)
    

    check pkt1-pkt4 are redirected to queue 5 or queue 6 with FDIR matched ID=0x1. check pkt5 and pkt6 are distributed by RSS with FDIR matched ID=0x2. send unmatched packets:

    pkt8 = Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2021", nh=17)/("X"*480)
    pkt9 = Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", nh=1)/("X"*480)
    

    check the packets are distributed by RSS have not FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.25.1. Test case: MAC_IPV6_UDP pattern

31.26. Subcase 1: MAC_IPV6_UDP queue index

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 hop is 2 tc is 1 / udp src is 22 dst is 23 / end actions queue index 1 / mark / end
    
  2. send matched packets, check the packets is distributed to queue 1 with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the rule listed. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packet is distributed by RSS without FDIR matched ID. check there is no rule listed.

31.27. Subcase 2: MAC_IPV6_UDP rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 hop is 2 tc is 1 / udp src is 22 dst is 23 / end actions rss / mark / end
    
  2. send matched packets, check the packets is distributed by RSS with FDIR matched ID. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID too.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. check there is no rule listed.

31.28. Subcase 3: MAC_IPV6_UDP passthru

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 hop is 2 tc is 1 / udp src is 22 dst is 23 / end actions passthru / mark / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are destributed by RSS without FDIR matched ID . check there is no rule listed.

31.29. Subcase 4: MAC_IPV6_UDP drop

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 hop is 2 tc is 1 / udp src is 22 dst is 23 / end actions drop / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is dropped. check there is no rule listed.

31.30. Subcase 5: MAC_IPV6_UDP mark+rss

Note: This combined action is mark with RSS which is without queues specified.

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 hop is 2 tc is 1 / udp src is 22 dst is 23 / end actions mark / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x0 send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.31. Subcase 6: MAC_IPV6_UDP mark

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 hop is 2 tc is 1 / udp src is 22 dst is 23 / end actions mark / end
    
  2. repeat the steps of passthru in subcase 3, get the same result.

31.31.1. Test case: MAC_IPV6_TCP pattern

  1. replace “udp” with “tcp” in all the subcases of MAC_IPV6_UDP pattern.
  2. Then repeat all the steps in all the subcases of MAC_IPV6_UDP pattern.
  3. get the same result.

31.31.2. Test case: MAC_IPV6_SCTP pattern

  1. replace “udp” with “sctp” in all the subcases of MAC_IPV6_UDP pattern.
  2. Then repeat all the steps in all the subcases of MAC_IPV6_UDP pattern.
  3. get the same result.

31.31.3. Test case: MAC_IPV4_TUN_IPV4_PAY pattern

31.32. Subcase 1: MAC_IPV4_TUN_IPV4_PAY queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions queue index 1 / mark / end
    
  2. send matched packets, check the packets are distributed to queue 1 with FDIR matched ID. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow destroy 0 rule 0
    

    verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.33. Subcase 2: MAC_IPV4_TUN_IPV4_PAY passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions passthru / mark / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x0. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.34. Subcase 3: MAC_IPV4_TUN_IPV4_PAY drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions drop / mark / end
    
  2. send matched packets, check the packets dropped. send unmatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. check there is no rule listed. verify the packets hit the rule are not dropped.

31.35. Subcase 4: MAC_IPV4_TUN_IPV4_PAY mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions mark / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x0. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. check there is no rule listed.

31.36. Subcase 5: MAC_IPV4_TUN_IPV4_PAY mark

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions mark / end
    
  2. repeat the steps of passthru in subcase 3, get the same result.

31.36.1. Test case: MAC_IPV4_TUN_IPV4_UDP pattern

31.37. Subcase 1: MAC_IPV4_TUN_IPV4_UDP queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions queue index 1 / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue 1 with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.38. Subcase 2: MAC_IPV4_TUN_IPV4_UDP passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.39. Subcase 3: MAC_IPV4_TUN_IPV4_UDP drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are received without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are received without FDIR matched ID.

31.40. Subcase 4: MAC_IPV4_TUN_IPV4_UDP mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.41. Subcase 5: MAC_IPV4_TUN_IPV4_UDP mark

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions mark id 1 / end
    
  2. repeat the steps of passthru in subcase 3, get the same result.

31.41.1. Test case: MAC_IPV4_TUN_IPV4_TCP pattern

  1. replace inner “udp” with “tcp” in all the subcases of MAC_IPV4_TUN_IPV4_UDP pattern.
  2. Then repeat all the steps in all the subcases of MAC_IPV4_TUN_IPV4_UDP pattern.
  3. get the same result.

31.41.2. Test case: MAC_IPV4_TUN_IPV4_SCTP pattern

  1. replace inner “udp” with “sctp” in all the subcases of MAC_IPV4_TUN_IPV4_UDP pattern.
  2. Then repeat all the steps in all the subcases of MAC_IPV4_TUN_IPV4_UDP pattern.
  3. get the same result.

31.41.3. Test case: MAC_IPV4_TUN_MAC_IPV4_PAY pattern

31.42. Subcase 1: MAC_IPV4_TUN_MAC_IPV4_PAY queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions queue index 0 / mark / end
    
  2. send matched packets, check the packets are distributed to queue 0 with FDIR matched ID. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.43. Subcase 2: MAC_IPV4_TUN_MAC_IPV4_PAY rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions rss queues 0 1 end / mark / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.44. Subcase 3: MAC_IPV4_TUN_MAC_IPV4_PAY passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions passthru / mark / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.45. Subcase 4: MAC_IPV4_TUN_MAC_IPV4_PAY drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are not dropped. check there is no rule listed.

31.46. Subcase 5: MAC_IPV4_TUN_MAC_IPV4_PAY mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions mark / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.47. Subcase 6: MAC_IPV4_TUN_MAC_IPV4_PAY mark

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions mark / end
    
  2. repeat the steps of passthru in subcase 3, get the same result.

31.47.1. Test case: MAC_IPV4_TUN_MAC_IPV4_UDP pattern

31.48. Subcase 1: MAC_IPV4_TUN_MAC_IPV4_UDP queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions queue index 15 / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue 15 with FDIR matched ID=0x1. send unmatched packets, check the packets are received without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.49. Subcase 2: MAC_IPV4_TUN_MAC_IPV4_UDP rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.50. Subcase 3: MAC_IPV4_TUN_MAC_IPV4_UDP passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.51. Subcase 4: MAC_IPV4_TUN_MAC_IPV4_UDP drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions drop / mark id 1 / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.52. Subcase 5: MAC_IPV4_TUN_MAC_IPV4_UDP mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions rss / mark id 1 / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify the packets hit rule are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.53. Subcase 6: MAC_IPV4_TUN_MAC_IPV4_UDP mark

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions mark id 1 / end
    
  2. repeat the steps of passthru in subcase 3, get the same result.

31.53.1. Test case: MAC_IPV4_TUN_MAC_IPV4_TCP pattern

  1. replace inner “udp” with “tcp” in all the subcases of MAC_IPV4_TUN_MAC_IPV4_UDP pattern.
  2. Then repeat all the steps in all the subcases of MAC_IPV4_TUN_MAC_IPV4_UDP pattern.
  3. get the same result.

31.53.2. Test case: MAC_IPV4_TUN_MAC_IPV4_SCTP pattern

  1. replace inner “udp” with “sctp” in all the subcases of MAC_IPV4_TUN_MAC_IPV4_UDP pattern.
  2. Then repeat all the steps in all the subcases of MAC_IPV4_TUN_MAC_IPV4_UDP pattern.
  3. get the same result.

31.53.3. Test case: MAC_IPV4_GTPU_EH pattern

31.54. Subcase 1: MAC_IPV4_GTPU_EH queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions queue index 1 / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue 1 with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.55. Subcase 2: MAC_IPV4_GTPU_EH queue group

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.56. Subcase 3: MAC_IPV4_GTPU_EH passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.57. Subcase 4: MAC_IPV4_GTPU_EH drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.58. Subcase 5: MAC_IPV4_GTPU_EH mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.59. Subcase 6: MAC_IPV4_GTPU_EH mark

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions mark id 1 / end
    
  2. repeat the steps of passthru in subcase 3, get the same result.

31.60. Subcase 7: MAC_IPV4_GTPU_EH QFI queue index / mark

  1. create filter rules on port 0:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc qfi is 0x34 / end actions queue index 1 / mark id 3 / end
    
  2. send matched packets, check the packet is redirected to queue 1 with FDIR matched ID=0x3:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/TCP()/Raw('x'*20)
    

    send unmatched packets, check the packet is distributed by RSS without FDIR matched ID:

    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x35)/IP()/Raw('x'*20)
    
  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.61. Subcase 8: MAC_IPV4_GTPU_EH without QFI rss queues / mark

  1. create filter rules on port 0:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / gtp_psc / end actions rss queues 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packet is distributed to queue 2 or queue 3 with FDIR matched ID=0x3:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0)/IP()/TCP()/Raw('x'*20)
    

    send unmatched packets, check the packet are distributed by RSS without FDIR matched ID:

    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x1234567)/GTP_PDUSession_ExtensionHeader(pdu_type=0)/IP()/TCP()/Raw('x'*20)
    
  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.62. Subcase 9: MAC_IPV4_GTPU_EH 4 tuple queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions queue index 10 / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue 10 with FDIR matched ID=0x1.

    send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.63. Subcase 10: MAC_IPV4_GTPU_EH 4 tuple queue group

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.64. Subcase 11: MAC_IPV4_GTPU_EH 4 tuple passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.65. Subcase 12: MAC_IPV4_GTPU_EH 4 tuple drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions drop / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.66. Subcase 13: MAC_IPV4_GTPU_EH 4 tuple mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.67. Subcase 14: MAC_IPV4_GTPU_EH outer dst ip queue index

  1. create filter rules on port 0:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp / gtpu / gtp_psc  / end actions queue index 10 / mark id 1 / end
    
  2. send matched packets, check the packet is redirected to queue 1 with FDIR matched ID=0x3:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.21", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/TCP()/Raw('x'*20)
    

    send unmatched packets, check the packet is distributed by RSS without FDIR matched ID:

    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.21", dst="192.168.0.22")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/UDP()/Raw('x'*20)
    
  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.68. Subcase 15: MAC_IPV4_GTPU_EH outer dst ip queue group

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp / gtpu / gtp_psc / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.69. Subcase 16: MAC_IPV4_GTPU_EH outer dst ip passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp / gtpu  / gtp_psc  / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.70. Subcase 17: MAC_IPV4_GTPU_EH outer dst ip drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp / gtpu / gtp_psc / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.71. Subcase 18: MAC_IPV4_GTPU_EH outer dst ip mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp / gtpu / gtp_psc  / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.72. Subcase 19: MAC_IPV4_GTPU_EH outer src ip queue index

  1. create filter rules on port 0:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 / udp / gtpu / gtp_psc  / end actions queue index 1 / mark id 3 / end
    
  2. send matched packets, check the packet is redirected to queue 1 with FDIR matched ID=0x3:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.22")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/TCP()/Raw('x'*20)
    

    send unmatched packets, check the packet is distributed by RSS without FDIR matched ID:

    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.21", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/UDP()/Raw('x'*20)
    
  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.73. Subcase 20: MAC_IPV4_GTPU_EH outer src ip queue group

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 / udp / gtpu / gtp_psc / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.74. Subcase 21: MAC_IPV4_GTPU_EH outer src ip passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 / udp / gtpu  / gtp_psc  / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.75. Subcase 22: MAC_IPV4_GTPU_EH outer src ip drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 / udp / gtpu / gtp_psc / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.76. Subcase 23: MAC_IPV4_GTPU_EH outer src ip mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 / udp / gtpu / gtp_psc  / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.76.1. Test case: MAC_IPV4_GTPU pattern

31.77. Subcase 1: MAC_IPV4_GTPU queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / end actions queue index 1 / mark / end
    
  2. send matched packets, check the packets are distributed to queue 1 with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.78. Subcase 2: MAC_IPV4_GTPU queue group

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / end actions rss queues 0 1 end / mark / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.79. Subcase 3: MAC_IPV4_GTPU passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / end actions passthru / mark / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x0. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.80. Subcase 4: MAC_IPV4_GTPU drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.81. Subcase 5: MAC_IPV4_GTPU mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / end actions mark / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x0. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.82. Subcase 6: MAC_IPV4_GTPU mark

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / end actions mark / end
    
  2. repeat the steps of passthru in subcase 3, get the same result.

31.83. Subcase 7: MAC_IPV4_GTPU 3 tuple queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / gtpu teid is 0x12345678  / end actions queue index 10 / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue 10 with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.84. Subcase 8: MAC_IPV4_GTPU 3 tuple queue group

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / gtpu teid is 0x12345678 / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.85. Subcase 9: MAC_IPV4_GTPU 3 tuple passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / gtpu teid is 0x12345678  / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.86. Subcase 10: MAC_IPV4_GTPU 3 tuple drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / gtpu teid is 0x12345678  / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.87. Subcase 11: MAC_IPV4_GTPU 3 tuple mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / gtpu teid is 0x12345678  / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.88. Subcase 12: MAC_IPV4_GTPU outer dst ip queue index

  1. create filter rules on port 0:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp / gtpu  / end actions queue index 1 / mark id 3 / end
    
  2. send matched packets, check the packet is redirected to queue 1 with FDIR matched ID=0x3. send unmatched packets, check the packet is distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.89. Subcase 13: MAC_IPV4_GTPU outer dst ip queue group

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp / gtpu  / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.90. Subcase 14: MAC_IPV4_GTPU outer dst ip passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp / gtpu  / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.91. Subcase 15: MAC_IPV4_GTPU outer dst ip drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp / gtpu / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.92. Subcase 16: MAC_IPV4_GTPU outer dst ip mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp / gtpu / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.93. Subcase 17: MAC_IPV4_GTPU outer src ip queue index

  1. create filter rules on port 0:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 / udp / gtpu / end actions queue index 1 / mark id 3 / end
    
  2. send matched packets, check the packet is redirected to queue 1 with FDIR matched ID=0x3:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.22")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/TCP()/Raw('x'*20)
    

    send unmatched packets, check the packet is distributed by RSS without FDIR matched ID:

    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.21", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/UDP()/Raw('x'*20)
    
  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.94. Subcase 18: MAC_IPV4_GTPU outer src ip queue group

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 / udp / gtpu / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.95. Subcase 19: MAC_IPV4_GTPU outer src ip passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 / udp / gtpu   / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.96. Subcase 20: MAC_IPV4_GTPU outer src ip drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 / udp / gtpu  / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.97. Subcase 21: MAC_IPV4_GTPU outer src ip mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 / udp / gtpu  / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.97.1. Test case: MAC_IPV6_GTPU_EH pattern

31.98. Subcase 1: MAC_IPV6_GTPU_EH 4 tuple queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions queue index 10 / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue 10 with FDIR matched ID=0x1.

    send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.99. Subcase 2: MAC_IPV6_GTPU_EH 4 tuple queue group

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 src is 2001::2 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.100. Subcase 3: MAC_IPV6_GTPU_EH 4 tuple passthru

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 src is 2001::2 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.101. Subcase 4: MAC_IPV6_GTPU_EH 4 tuple drop

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 src is 2001::2 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.102. Subcase 5: MAC_IPV6_GTPU_EH 4 tuple mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 src is 2001::2 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.103. Subcase 6: MAC_IPV6_GTPU_EH outer dst ipv6 queue index

  1. create filter rules on port 0:

    flow create 0 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu / gtp_psc  / end actions queue index 1 / mark id 3 / end
    
  2. send matched packets, check the packet is redirected to queue 1 with FDIR matched ID=0x3:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/TCP()/Raw('x'*20)
    

    send unmatched packets, check the packet is distributed by RSS without FDIR matched ID:

    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2021")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/UDP()/Raw('x'*20)
    
  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.104. Subcase 7: MAC_IPV6_GTPU_EH outer dst ipv6 queue group

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu / gtp_psc / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.105. Subcase 8: MAC_IPV6_GTPU_EH outer dst ipv6 passthru

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu  / gtp_psc  / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.106. Subcase 9: MAC_IPV6_GTPU_EH outer dst ipv6 drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu / gtp_psc / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.107. Subcase 10: MAC_IPV6_GTPU_EH outer dst ipv6 mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu / gtp_psc  / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.108. Subcase 11: MAC_IPV6_GTPU_EH outer src ipv6 queue index

  1. create filter rules on port 0:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 / udp / gtpu / gtp_psc  / end actions queue index 1 / mark id 3 / end
    
  2. send matched packets, check the packet is redirected to queue 1 with FDIR matched ID=0x3:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/TCP()/Raw('x'*20)
    

    send unmatched packets, check the packet is distributed by RSS without FDIR matched ID:

    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::3", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/UDP()/Raw('x'*20)
    
  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.109. Subcase 12: MAC_IPV6_GTPU_EH outer src ipv6 queue group

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 / udp / gtpu / gtp_psc / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.110. Subcase 13: MAC_IPV6_GTPU_EH outer src ipv6 passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 / udp / gtpu  / gtp_psc  / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.111. Subcase 14: MAC_IPV6_GTPU_EH outer src ipv6 drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 / udp / gtpu / gtp_psc / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.112. Subcase 15: MAC_IPV6_GTPU_EH outer src ipv6 mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 / udp / gtpu / gtp_psc  / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.112.1. Test case: MAC_IPV6_GTPU pattern

31.113. Subcase 1: MAC_IPV6_GTPU 4 tuple queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu teid is 0x12345678 / end actions queue index 10 / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue 10 with FDIR matched ID=0x1.

    send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.114. Subcase 2: MAC_IPV6_GTPU 4 tuple queue group

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 src is 2001::2 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu teid is 0x12345678 / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.115. Subcase 3: MAC_IPV6_GTPU 4 tuple passthru

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 src is 2001::2 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu teid is 0x12345678 / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.116. Subcase 4: MAC_IPV6_GTPU 4 tuple drop

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 src is 2001::2 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu teid is 0x12345678 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.117. Subcase 5: MAC_IPV6_GTPU 4 tuple mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 src is 2001::2 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu teid is 0x12345678 / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.118. Subcase 6: MAC_IPV6_GTPU outer dst ipv6 queue index

  1. create filter rules on port 0:

    flow create 0 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu / end actions queue index 1 / mark id 3 / end
    
  2. send matched packets, check the packet is redirected to queue 1 with FDIR matched ID=0x3:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/TCP()/Raw('x'*20)
    

    send unmatched packets, check the packet is distributed by RSS without FDIR matched ID:

    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2021")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/UDP()/Raw('x'*20)
    
  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.119. Subcase 7: MAC_IPV6_GTPU outer dst ipv6 queue group

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.120. Subcase 8: MAC_IPV6_GTPU outer dst ipv6 passthru

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu  / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.121. Subcase 9: MAC_IPV6_GTPU outer dst ipv6 drop

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.122. Subcase 10: MAC_IPV6_GTPU outer dst ipv6 mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth /  ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 / udp / gtpu / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.123. Subcase 11: MAC_IPV6_GTPU outer src ipv6 queue index

  1. create filter rules on port 0:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 / udp / gtpu / end actions queue index 1 / mark id 3 / end
    
  2. send matched packets, check the packet is redirected to queue 1 with FDIR matched ID=0x3:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/TCP()/Raw('x'*20)
    

    send unmatched packets, check the packet is distributed by RSS without FDIR matched ID:

    p_gtpu2 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IPv6(src="2001::3", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/UDP()/Raw('x'*20)
    
  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.124. Subcase 12: MAC_IPV6_GTPU outer src ipv6 queue group

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 / udp / gtpu / end actions rss queues 0 1 2 3 end / mark id 1 / end
    
  2. send matched packets, check the packets are distributed to queue group with FDIR matched ID=0x1. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. Then check there is no rule listed.

31.125. Subcase 13: MAC_IPV6_GTPU outer src ipv6 passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 / udp / gtpu / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR ID. check there is no rule listed.

31.126. Subcase 14: MAC_IPV6_GTPU outer src ipv6 drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 / udp / gtpu / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped without FDIR matched ID. Then check there is no rule listed.

31.127. Subcase 15: MAC_IPV6_GTPU outer src ipv6 mark/rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::2 / udp / gtpu / end actions mark id 1 / rss / end
    
  2. send matched packets, check the packets are redirected by RSS with FDIR matched ID=0x1. send unmatched packets, check the packets are redirected by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.127.1. Test case: L2 Ethertype pattern

31.128. Subcase 1: L2 Ethertype queue index

  1. create rule for PPPoED:

    flow create 0 ingress pattern eth type is 0x8863 / end actions queue index 1 / mark id 1 / end
    

    send PPPoED packet, check the packets are distributed to expected queue with specific FDIR matched ID.

  2. create rule for PPPoE:

    flow create 0 ingress pattern eth type is 0x8864 / end actions queue index 2 / mark id 2 / end
    

    send PPPoE packet, check the packets are distributed to expected queue with specific FDIR matched ID.

  3. create rule for ARP:

    flow create 0 ingress pattern eth type is 0x0806 / end actions queue index 3 / mark id 3 / end
    

    send ARP packet, Check the packets are distributed to expected queue with specific FDIR matched ID.

  4. create rule for EAPS:

    flow create 0 ingress pattern eth type is 0x8100 / end actions queue index 4 / mark id 4 / end
    

    send EAPS packet, check the packets are distributed to expected queue with specific FDIR matched ID.

  5. create rule for ieee1588:

    flow create 0 ingress pattern eth type is 0x88f7 / end actions queue index 5 / mark id 5 / end
    

    send ieee1588 packet, check the packets are distributed to expected queue with specific FDIR matched ID.

  6. send a unmatched packet:

    sendp([Ether(dst="00:11:22:33:44:55",type=0x8847)],iface="enp134s0f1")
    

    check the packet received has not FDIR matched ID.

  7. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the 5 rules listed. flush all the rules:

    testpmd> flow flush 0
    
  8. verify matched packets are received without FDIR matched ID. Then check there is no rule listed.

31.129. Subcase 2: L2 Ethertype rss queues

  1. create rules for PPPoED with rss queues action:

    flow create 0 ingress pattern eth type is 0x8863 / end actions rss queues 2 3 end / mark id 2 / end
    
  2. send matched packet, check the packets received have FDIR matched ID=0x2, the packets are directed to queue 0, because L2 Ethertype are not supported by RSS.

  3. Repeat step 1-2 with PPPoE/ARP/EAPS/ieee1588, get the same result.

  4. repeat step 6-7 of subcase 1.

  5. verify matched packets received have not FDIR matched ID. Then check there is no rule listed.

31.130. Subcase 3: L2 Ethertype passthru

  1. create rules for PPPoED with passthru action:

    flow create 0 ingress pattern eth type is 0x8863 / end actions passthru / mark id 2 / end
    
  2. send matched packet, check the packets received have FDIR matched ID=0x2, the packets are directed to queue 0, because L2 Ethertype are not supported by RSS.

  3. Repeat step 1-2 with PPPoE/ARP/EAPS/ieee1588, get the same result.

  4. repeat step 6-7 of subcase 1.

  5. verify matched packets received have not FDIR matched ID. Then check there is no rule listed.

31.131. Subcase 4: L2 Ethertype drop

  1. create rules for PPPoED with drop action:

    flow create 0 ingress pattern eth type is 0x8863 / end actions drop / mark / end
    
  2. send matched packet, check the packets are dropped,

  3. Repeat step 1-2 with PPPoE/ARP/EAPS/ieee1588, get the same result.

  4. repeat step 6-7 of subcase 1.

  5. verify matched packets are received. Then check there is no rule listed.

31.132. Subcase 5: L2 Ethertype mark+rss

  1. create rules for PPPoED with rss queues action:

    flow create 0 ingress pattern eth type is 0x8863 / end actions mark id 1 / rss / end
    
  2. send matched packet, check the packets received have FDIR matched ID=0x1, the packets are directed to queue 0, because L2 Ethertype are not supported by RSS.

  3. Repeat step 1-2 with PPPoE/ARP/EAPS/ieee1588, get the same result.

  4. repeat step 6-7 of subcase 1.

  5. verify matched packets received have not FDIR matched ID. Then check there is no rule listed.

31.133. Subcase 6: L2 Ethertype mark

  1. create rules for PPPoED with mark action:

    flow create 0 ingress pattern eth type is 0x8863 / end actions mark / end
    
  2. send matched packet, check the packets received have FDIR matched ID=0x0,

  3. Repeat step 1-2 with PPPoE/ARP/EAPS/ieee1588, get the same result.

  4. repeat step 6-7 of subcase 1.

  5. verify matched packets received have not FDIR matched ID. Then check there is no rule listed.

31.134. Subcase 7: unsupported Ethertype

  1. create rules for IP/IPV6:

    flow create 0 ingress pattern eth type is 0x0800 / end actions queue index 1 / end
    flow create 0 ingress pattern eth type is 0x86dd / end actions queue index 1 / end
    

    the two rules can be created successfully, but report below message:

    ice_flow_create(): Succeeded to create (2) flow
    Flow rule #0 created
    

    the number “2” stands for switch rule, fdir doesn’t support IPV4/IPV6 ethertype.

31.134.1. Test case: MAC_IPV4_ESP pattern

31.135. Subcase 1: MAC_IPV4_ESP queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / esp spi is 7 / end actions queue index 13 / mark id 7 / end
    
  2. send matched packets, check the packets are distributed to queue 13 with FDIR matched ID. send mismatched packets, check the packets are not distributed to queue 13 without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the rule listed. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packets are not distributed to queue 13 without FDIR matched ID. check there is no rule listed.

31.136. Subcase 2: MAC_IPV4_ESP rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / esp spi is 7 / end actions rss queues 1 2 3 4 end / mark id 6 / end
    
  2. send matched packets, check the packets are distributed to queue 1 or 2 or 3 or 4 with FDIR matched ID. send mismatched packets, check the packets are not distributed to queue 1 or 2 or 3 or 4 without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not distributed to queue 1 or 2 or 3 or 4 without FDIR matched ID. check there is no rule listed.

31.137. Subcase 3: MAC_IPV4_ESP passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / esp spi is 7 / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID. send mismatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed to the same queue without FDIR matched ID. check there is no rule listed.

31.138. Subcase 4: MAC_IPV4_ESP drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / esp spi is 7 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped send mismatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped. check there is no rule listed.

31.139. Subcase 5: MAC_IPV4_ESP mark+rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / esp spi is 7 / end actions mark id 2 / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID. send mismatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed to the same queue without FDIR matched ID. check there is no rule listed.

31.140. Subcase 6: MAC_IPV4_ESP mark

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / esp spi is 7 / end actions mark id 15 / end
    
  2. send matched packets, check the packets are received with FDIR matched ID. send mismatched packets, check the packets are received without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are received without FDIR matched ID. check there is no rule listed.

31.140.1. Test case: MAC_IPV6_ESP pattern

31.141. Subcase 1: MAC_IPV6_ESP queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / esp spi is 7 / end actions queue index 13 / mark id 7 / end
    
  2. send matched packets, check the packets are distributed to queue 13 with FDIR matched ID. send mismatched packets, check the packets are not distributed to queue 13 without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the rule listed. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packets are not distributed to queue 13 without FDIR matched ID. check there is no rule listed.

31.142. Subcase 2: MAC_IPV6_ESP rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / esp spi is 7 / end actions rss queues 1 2 3 4 end / mark id 6 / end
    
  2. send matched packets, check the packets are distributed to queue 1 or 2 or 3 or 4 with FDIR matched ID. send mismatched packets, check the packets are not distributed to queue 1 or 2 or 3 or 4 without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not distributed to queue 1 or 2 or 3 or 4 without FDIR matched ID. check there is no rule listed.

31.143. Subcase 3: MAC_IPV6_ESP passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / esp spi is 7 / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID. send mismatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed to the same queue without FDIR matched ID=0x0. check there is no rule listed.

31.144. Subcase 4: MAC_IPV6_ESP drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / esp spi is 7 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped send mismatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped. check there is no rule listed.

31.145. Subcase 5: MAC_IPV6_ESP mark+rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / esp spi is 7 / end actions mark id 2 / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID. send mismatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed to the same queue without FDIR matched ID. check there is no rule listed.

31.146. Subcase 6: MAC_IPV6_ESP mark

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / esp spi is 7 / end actions mark id 15 / end
    
  2. send matched packets, check the packets are received with FDIR matched ID. send mismatched packets, check the packets are received without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are received without FDIR matched ID. check there is no rule listed.

31.146.1. Test case: MAC_IPV4_NAT-T-ESP pattern

31.147. Subcase 1: MAC_IPV4_NAT-T-ESP queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / esp spi is 7 / end actions queue index 13 / mark id 7 / end
    
  2. send matched packets, check the packets are distributed to queue 13 with FDIR matched ID. send mismatched packets, check the packets are not distributed to queue 13 without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the rule listed. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packets are not distributed to queue 13 without FDIR matched ID. check there is no rule listed.

31.148. Subcase 2: MAC_IPV4_NAT-T-ESP rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / esp spi is 7 / end actions rss queues 1 2 3 4 end / mark id 6 / end
    
  2. send matched packets, check the packets are distributed to queue 1 or 2 or 3 or 4 with FDIR matched ID. send mismatched packets, check the packets are not distributed to queue 1 or 2 or 3 or 4 without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not distributed to queue 1 or 2 or 3 or 4 without FDIR matched ID. check there is no rule listed.

31.149. Subcase 3: MAC_IPV4_NAT-T-ESP passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / esp spi is 7 / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID. send mismatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed to the same queue without FDIR matched ID. check there is no rule listed.

31.150. Subcase 4: MAC_IPV4_NAT-T-ESP drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / esp spi is 7 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped send mismatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped. check there is no rule listed.

31.151. Subcase 5: MAC_IPV4_NAT-T-ESP mark+rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / esp spi is 7 / end actions mark id 2 / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID. send mismatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed to the same queue without FDIR matched ID. check there is no rule listed.

31.152. Subcase 6: MAC_IPV4_NAT-T-ESP mark

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp / esp spi is 7 / end actions mark id 15 / end
    
  2. send matched packets, check the packets are received with FDIR matched ID. send mismatched packets, check the packets are received without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are received without FDIR matched ID. check there is no rule listed.

31.152.1. Test case: MAC_IPV6_NAT-T-ESP pattern

31.153. Subcase 1: MAC_IPV6_NAT-T-ESP queue index

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / udp / esp spi is 7 / end actions queue index 13 / mark id 7 / end
    
  2. send matched packets, check the packets are distributed to queue 13 with FDIR matched ID. send mismatched packets, check the packets are not distributed to queue 13 without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the rule listed. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packets are not distributed to queue 13 without FDIR matched ID. check there is no rule listed.

31.154. Subcase 2: MAC_IPV6_NAT-T-ESP rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / udp / esp spi is 7 / end actions rss queues 1 2 3 4 end / mark id 6 / end
    
  2. send matched packets, check the packets are distributed to queue 1 or 2 or 3 or 4 with FDIR matched ID. send mismatched packets, check the packets are not distributed to queue 1 or 2 or 3 or 4 without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not distributed to queue 1 or 2 or 3 or 4 without FDIR matched ID. check there is no rule listed.

31.155. Subcase 3: MAC_IPV6_NAT-T-ESP passthru

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / udp / esp spi is 7 / end actions passthru / mark id 1 / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID. send mismatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed to the same queue without FDIR matched ID. check there is no rule listed.

31.156. Subcase 4: MAC_IPV6_NAT-T-ESP drop

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / udp / esp spi is 7 / end actions drop / mark / end
    
  2. send matched packets, check the packets are dropped send mismatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are not dropped. check there is no rule listed.

31.157. Subcase 5: MAC_IPV6_NAT-T-ESP mark+rss

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / udp / esp spi is 7 / end actions mark id 2 / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID. send mismatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed to the same queue without FDIR matched ID. check there is no rule listed.

31.158. Subcase 6: MAC_IPV6_NAT-T-ESP mark

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv6 src is 2001::1 dst is 2001::2 / udp / esp spi is 7 / end actions mark id 15 / end
    
  2. send matched packets, check the packets are received with FDIR matched ID. send mismatched packets, check the packets are received without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are received without FDIR matched ID. check there is no rule listed.

31.158.1. Test case: negative cases

Note: the error message may be changed.

31.159. Subcase 1: invalid parameters of queue index

  1. Invalid parameters:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions queue index 64 / mark / end
    

    Failed to create flow, report message:

    'error' in message
    
  2. check there is no rule listed.

31.160. Subcase 2: invalid parameters of rss queues

  1. Invalid number of queues:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues 1 2 3 end / mark / end
    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues 0 end / mark / end
    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues end / mark / end
    

    Failed to create flow, report message:

    Invalid input action: Invalid argument
    
  2. Discontinuous queues:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues 1 2 3 5 end / mark / end
    

    Failed to create flow, report message:

    Discontinuous queue region: Invalid argument
    
  3. invalid queue index:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions rss queues 63 64 end / mark / end
    

    Failed to create flow, report message:

    Invalid queue region indexes.: Invalid argument
    
  4. “–rxq=7 –txq=7”, set queue group 8 queues:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / end actions rss queues 0 1 2 3 4 5 6 7 end / mark / end
    

    Failed to create flow, report message:

    Invalid queue region indexes.: Invalid argument
    
  5. check there is no rule listed.

  6. “–rxq=8 –txq=8”, set queue group 8 queues, create the 8 queues flow successfully. send matched packets, check the packets are distributed to queue 0-7. send unmatched packets, check the packets are distributed to queue 0-7 too.

31.161. Subcase 3: Invalid parameters of input set

  1. Invalid value of teid and qfi:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x100000000 / gtp_psc qfi is 0x5 / end actions queue index 2 / mark / end
    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x100000000 / end actions queue index 1 / mark / end
    

    Failed to create flow, report message “Bad arguments”

  2. check there is no rule listed.

31.162. Subcase 4: Invalid parameters of mark ID

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 / end actions queue index 1 / mark id 4294967296 / end
    

    Failed to create flow, report message “Bad arguments”

  2. check there is no rule listed.

31.163. Subcase 5: Duplicated rules

  1. Create a FDIR rule:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / end actions queue index 1 / mark / end
    

    the rule is created successfully.

  2. Create the same rule again, Failed to create flow, report message:

    Rule already exists!: File exists
    
  3. check there is only one rule listed.

31.164. Subcase 6: conflicted rules

  1. Create a FDIR rule:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / end actions queue index 1 / mark / end
    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / end actions queue index 1 / mark / end
    

    the rule is created successfully.

  2. Create a rule with same input set but different action or with different input set:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / end actions queue index 2 / mark / end
    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / end actions drop / mark / end
    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.21 ttl is 2 tos is 4 / end actions queue index 3 / mark / end
    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / udp src is 22 dst is 23 / end actions queue index 3 / mark / end
    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / end actions queue index 2 / mark / end
    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / end actions rss queues 2 3 end / mark / end
    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2021 / end actions mark / end
    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / udp src is 22 dst is 23 / end actions queue index 1 / mark / end
    

    Failed to create the two flows, report message:

    Rule already exists!: File exists
    

    or:

    'error' in message
    
  3. check there is only one rule listed.

31.165. Subcase 7: conflicted actions

  1. Create a rule with two conflicted actions:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / end actions queue index 1 / rss queues 2 3 end / mark / end
    

    Failed to create flow, report message:

    'error' in message
    
  2. check there is no rule listed.

31.166. Subcase 8: void action

  1. Create a rule with void action:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / end actions end
    

    Failed to create flow, report message:

    Invalid input action: Invalid argument
    
  2. check there is no rule listed.

31.167. Subcase 9: delete a non-existent rule

  1. show the rule list of port 0:

    flow list 0
    

    There is no rule listed.

  2. destroy rule 0 of port 0:

    flow destroy 0 rule 0
    

    There is no error message reported.

  3. check there is no rule listed.

  4. flush rules of port 0:

    flow flush 0
    

    There is no error message reported.

  5. check there is no rule listed.

31.168. Subcase 10: unsupported input set field

  1. Create a IPV4_PAY rule with TC input set:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 tc is 2 / end actions queue index 1 / mark / end
    

    Failed to create flow, report message:

    Bad arguments
    
  2. check there is no rule listed.

31.169. Subcase 11: invalid port

  1. Create a rule on port 2:

    flow create 2 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions queue index 1 / mark / end
    

    Failed to create flow, report message:

    No such device: No such device
    
  2. check there is no rule listed on port 2:

    testpmd> flow list 2
    Invalid port 2
    

31.170. Subcase 12: unsupported pattern

  1. Create a GTPU rule with OS default package:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions drop / mark / end
    

    Failed to create flow, report error message.

  2. check there is no rule listed.

31.171. Subcase 13: conflict patterns

Note: MAC_IPV4_UDP packet can match MAC_IPV4_PAY rule if ip address can match. so if there is a MAC_IPV4_PAY rule existing, MAC_IPV4_UDP rule will be set to switch rule. set “–log-level=ice,7”, then check:

ice_flow_create(): Succeeded to create (1) flow -> FDIR
ice_flow_create(): Succeeded to create (2) flow -> switch
  1. set MAC_IPV4_PAY rule firstly:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / end actions queue index 1 / mark id 1 / end
    

    the first flow rule is set to fdir filter, send matched packet:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21")/Raw('x' * 80)],iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21") /UDP(sport=22, dport=23)/ Raw('x' * 80)],iface="enp175s0f0", count=10)
    

    the two packets are both redirected to queue 1 with mark ID 1. then create MAC_IPV4_UDP flow, it is set to switch filter with mark ID 1:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions queue index 2 / end
    

    send same packets, MAC_IPV4_PAY packet to queue 1, MAC_IPV4_UDP packet to queue 2.

  2. flush the rules.

  3. set MAC_IPV4_UDP rule firstly:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions queue index 2 / mark id 1 / end
    

    the first rule is set to fdir filter, send matched packet:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21") /UDP(sport=22, dport=23)/ Raw('x' * 80)],iface="enp175s0f0", count=10)
    

    the packet is redirected to queue 2 with mark ID 1. then create MAC_IPV4_PAY rule, it is set to switch filter:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / end actions queue index 1 / end
    

    send same packet, it is redirected to queue 1 with mark ID 1, because the packet match switch filter first.

31.171.1. Test case: count/query

31.172. Subcase 1: count for 1 rule

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions queue index 1 / count / mark / end
    flow create 1 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 proto is 255 ttl is 2 tos is 4 / end actions count / mark / end
    
  2. send matched packets to port0 and port1, the packets received by port0 are redirected to queue 1. the packets received by port1 are distributed by RSS. send unmatched packets, check the packets are redirected by RSS. check the count number:

    flow query 0 0 count
    count:
     hits_set: 1
     bytes_set: 0
     hits: 2
     bytes: 0
    
    flow query 1 0 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 2
     bytes: 0
    
  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    testpmd> flow list 1
    

    check the existing rule. destroy the rule:

    testpmd> flow destroy 0 rule 0
    testpmd> flow destroy 1 rule 0
    

    verify matched packets are redirected by RSS. check there is no rule listed.

  4. check the count number:

    testpmd> flow query 0 0 count
    Flow rule #0 not found
    testpmd> flow query 1 0 count
    Flow rule #0 not found
    

31.173. Subcase 2: count query identifier share

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.1 / end actions queue index 1 / count identifier 0x1234 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.2 / end actions rss queues 2 3 end / count identifier 0x1234 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.3 / end actions passthru / mark / count identifier 0x1234 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.4 / end actions mark id 1 / rss / count identifier 0x1234 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.5 / end actions queue index 5 / count / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.6 / end actions drop / count / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.7 / end actions drop / count identifier 0x1235 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.8 / end actions rss / count / mark / end
    
  2. send matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.1",dst="192.168.0.21") / Raw('x' * 80)],iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.2",dst="192.168.0.21") / Raw('x' * 80)],iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.3",dst="192.168.0.21") / Raw('x' * 80)],iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.4",dst="192.168.0.21") / Raw('x' * 80)],iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.5",dst="192.168.0.21") / Raw('x' * 80)],iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.6",dst="192.168.0.21") / Raw('x' * 80)],iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.7",dst="192.168.0.21") / Raw('x' * 80)],iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.8",dst="192.168.0.21") / Raw('x' * 80)],iface="enp175s0f0", count=10)
    

    check the packets, packet 1 to queue 1, packet 2 to queue 2 or queue 3, packet 3 is distributed by RSS with FDIR matched ID=0x0, packet 4 is distributed by RSS with FDIR matched ID=0x1, packet 5 to queue 5, packet 6 dropped, packet 7 dropped. packet 8 is distributed by RSS.

  3. query count:

    testpmd> flow query 0 0 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 1 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 2 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 3 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 4 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 5 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 6 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 7 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    
  4. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow flush 0
    
  5. check there is no rule listed, send matched packets, query count, flow rule not found.

31.174. Subcase 3: multi patterns mark count query

  1. create filter rules:

    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / tcp src is 22 dst is 23 / end actions queue index 1 / mark id 0 / count / mark / end
    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions drop / mark id 1 / count / mark / end
    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 / sctp src is 22 dst is 23 / end actions rss queues 62 63 end / mark id 2 / count / mark / end
    flow create 0 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / end actions queue index 1 / mark id 3 / count / mark / end
    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / udp src is 22 dst is 23 / end actions queue index 3 / mark id 4 / count / mark / end
    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / eth / ipv4 src is 192.168.0.20 / tcp dst is 23 / end actions queue index 4 / count / mark id 5 / mark / end
    flow create 0 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / sctp src is 22 dst is 23 / end actions queue index 5 / mark id 6 / count / mark / end
    flow create 1 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / end actions rss queues 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 \
    32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 end / mark id 100 / count / mark / end
    
  2. send matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21") /TCP(sport=22, dport=23)/ Raw('x' * 80)],iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21") /UDP(sport=22, dport=23)/ Raw('x' * 80)],iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21") /SCTP(sport=22, dport=23)/ Raw('x' * 80)],iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2", nh=0, tc=1, hlim=2)/("X"*480)], iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=4790)/VXLAN(flags=0xc)/IP(dst="192.168.0.21", src="192.168.0.20")/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN(vni=2)/Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20")/TCP(dport=23)/("X"*480)], iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN(vni=2)/Ether()/IP(src='192.168.0.20', dst='192.168.0.21')/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x12345678)/IP()/Raw('x'*20)], iface="enp175s0f0", count=10)
    

    check the packets, packet 1 to queue 1, packet 2 dropped, packet 3 to queue 62-63, packet 4 to queue 1, packet 5 to queue 3, packet 6 to queue 4, packet 7 to queue 5, packet 8 is distributed by RSS. all the packets are received with FDIR matched ID.

  3. query count:

    testpmd> flow query 0 0 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 1 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 2 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 3 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 4 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 5 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 6 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 1 0 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    
  4. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the existing rule. destroy the rule:

    testpmd> flow flush 0
    
  5. check there is no rule listed, send matched packets, query count, flow rule not found.

31.175. Subcase 4: max count number

  1. create 257 flows with count:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.1 / end actions drop / mark / count / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.2 / end actions drop / mark / count / end
    ……
    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.255 / end actions drop / mark / count / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.1.1 / end actions drop / mark / count / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.1.2 / end actions drop / mark / count / end
    

    the last one failed to create, report the error message:

    No free counter found
    
  2. send matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.1.1",dst="192.168.0.21") / Raw('x' * 80)],iface="enp175s0f0", count=10)
    

    check the packet dropped.

  3. query count:

    testpmd> flow query 0 255 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    
  4. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check that 256 rules listed. destroy the rule:

    testpmd> flow flush 0
    

    verify matched packet are not dropped. check there is no rule listed.

31.175.1. Test case: two ports

31.176. Subcase 1: same rule on two ports

  1. create filter rules on two ports:

    flow create 0 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions queue index 1 / mark / end
    flow create 1 ingress pattern eth / ipv4 / udp / gtpu teid is 0x12345678 / gtp_psc qfi is 0x34 / end actions queue index 1 / mark / end
    

    send matched packets:

    p_gtpu1 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP(src="192.168.0.20", dst="192.168.0.21")/UDP(dport=2152) \
    /GTP_U_Header(gtp_type=255, teid=0x12345678)/GTP_PDUSession_ExtensionHeader(pdu_type=0, qos_flow=0x34)/IP()/Raw('x'*20)
    

    send the packet to two ports, both are distributed to queue 1 with FDIR matched ID=0x0.

  2. list the rules on two ports:

    testpmd> flow list 0
    ID      Group   Prio    Attr    Rule
    0       0       0       i--     ETH IPV4 UDP GTPU GTP_PSC => QUEUE MARK
    testpmd> flow list 1
    ID      Group   Prio    Attr    Rule
    0       0       0       i--     ETH IPV4 UDP GTPU GTP_PSC => QUEUE MARK
    
  3. destroy rule 0 on port 0:

    testpmd> flow destroy 0 rule 0
    Flow rule #0 destroyed
    

    list the rules on two ports:

    testpmd> flow list 0
    testpmd> flow list 1
    ID      Group   Prio    Attr    Rule
    0       0       0       i--     ETH IPV4 UDP GTPU GTP_PSC => QUEUE MARK
    
  4. send the matched packet to port 0, it is redirected by RSS without FDIR matched ID. send the matched packet to port 1, it is still redirected to queue 1 with FDIR matched ID=0x0.

  5. destroy rule 0 on port 1:

    testpmd> flow destroy 1 rule 0
    Flow rule #0 destroyed
    

    list the rules on two ports:

    testpmd> flow list 0
    testpmd> flow list 1
    

    there is no rule listed on both ports. send the matched packet to port 0/1, it is redirected by RSS without FDIR matched ID.

31.177. Subcase 2: same input set, different actions on two ports

  1. create filter rules on two ports:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / tcp src is 22 dst is 23 / end actions queue index 1 / mark id 1 / end
    flow create 1 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / tcp src is 22 dst is 23 / end actions rss queues 2 3 end / mark id 1 / end
    

    send matched packets to two ports:

    pkt = Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21")/TCP(sport=22,dport=23)/Raw('x' * 80)
    

    the packet sent to port 0 is redirected to queue 1 with FDIR matched ID=0x1, the packet sent to port 1 is redirected to queue 2 or queue 3 with FDIR matched ID=0x1.

  2. destroy rule 0 on both ports:

    testpmd> flow flush 0
    testpmd> flow flush 1
    

    list the rules on two ports:

    testpmd> flow list 0
    testpmd> flow list 1
    

    there is no rule listed on both ports. send the matched packet to port 0/1, it is redirected by RSS without FDIR matched ID.

31.178. Subcase 3: two ports multi patterns count query

  1. create filter rules:

    flow create 1 ingress pattern eth / ipv4 dst is 192.168.0.21 proto is 255  tos is 4 / end actions queue index 1 / mark id 1 / count identifier 0x1234 / end
    flow create 1 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 hop is 2 tc is 1 / sctp src is 22 dst is 23 / end actions rss queues 6 7 end / mark id 2 / count identifier 0x1234 / end
    flow create 1 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 hop is 2 tc is 1 / udp src is 22 dst is 23 / end actions rss queues 6 7 end / mark id 1 / count / end
    flow create 1 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 hop is 2 tc is 1 / tcp src is 22 dst is 23 / end actions queue index 2 / mark / count / end
    flow create 1 ingress pattern eth / ipv4 / udp / vxlan / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions drop / mark / count / end
    flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.21 tos is 4 / tcp src is 22 dst is 23 / end actions drop / mark / count / end
    flow create 0 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / end actions queue index 1 / mark id 1 / count identifier 0x1234 / end
    
  2. send matched packets:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21", proto=255, ttl=2, tos=4) / Raw('x' * 80)],iface="enp175s0f1", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2", tc=1, hlim=2)/SCTP(sport=22,dport=23)/("X"*480)], iface="enp175s0f1", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2", tc=1, hlim=2)/UDP(sport=22,dport=23)/("X"*480)], iface="enp175s0f1", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2", tc=1, hlim=2)/TCP(sport=22,dport=23)/("X"*480)], iface="enp175s0f1", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP()/VXLAN()/Ether()/IP(src='192.168.0.20', dst='192.168.0.21')/("X"*480)], iface="enp175s0f1", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst="192.168.0.21", ttl=2, tos=4)/TCP(sport=22,dport=23)/Raw(load="X"*480)], iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IPv6(dst="CDCD:910A:2222:5498:8475:1111:3900:2020", src="2001::2", nh=0, tc=1, hlim=2)/("X"*480)], iface="enp175s0f0", count=10)
    sendp([Ether(dst="00:11:22:33:44:55")/IP(dst="192.168.0.21", ttl=2, tos=4)/TCP(sport=22,dport=23)/Raw(load="X"*480)], iface="enp175s0f1", count=10)
    

    check the packets, packet 1 to queue 1 of port 1, packet 2 to queue 6-7 of port 1, packet 3 to queue 6-7 of port 1, packet 4 to queue 2 of port 1, packet 5 dropped of port 1, packet 6 to dropped of port 0, packet 7 to queue 1 of port 0. the received packets have specified FDIR matched ID. packet 8 received by port 1 and not have matched ID.

  3. query count:

    testpmd> flow query 1 0 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 1 1 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 1 2 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
    testpmd> flow query 1 3 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 1 4 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
     bytes: 0
    testpmd> flow query 0 0 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
    testpmd> flow query 0 1 count
    COUNT:
     hits_set: 1
     bytes_set: 0
     hits: 10
    
  4. verify rules can be listed correctly:

    testpmd> flow list 0
    testpmd> flow list 1
    
  5. destroy the rule:

    testpmd> flow flush 0
    testpmd> flow flush 1
    

    verify matched packet are received without FDIR matched ID. check there is no rule listed:

    testpmd> flow list 0
    testpmd> flow list 1
    

    query the count number, all reported:

    Flow rule #[ID] not found
    

31.178.1. Test case: Stress test

31.179. Subcase 1: port stop/port start/port reset

  1. create a rule:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / end actions queue index 1 / mark / end
    
  2. list the rule and send matched packet:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21") / Raw('x' * 80)],iface="enp175s0f0")
    

    check the packet are redirected to queue 1 with FDIR matched ID=0x0

  3. stop the port, then start the port:

    testpmd> port stop 0
    testpmd> port start 0
    
  4. show the rule list, the rule is still there.

  5. verify matched packet can be still redirected to queue 1 with FDIR matched ID=0x0.

  6. reset pf:

    testpmd> port stop 0
    testpmd> port reset 0
    testpmd> port start 0
    
  7. show the rule list, the rule is still there.

  8. verify matched packet can be still redirected to queue 1 with FDIR matched ID=0x0.

  9. add a new rule:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv4 src is 192.168.0.22 dst is 192.168.0.23 / end actions queue index 2 / mark id 1 / end
    
  10. list the rule and send matched packet:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.22",dst="192.168.0.23") / Raw('x' * 80)],iface="enp175s0f0")
    
check the packet are redirected to queue 2 with FDIR matched ID=0x1

31.180. Subcase 2: delete rules

  1. create 3 rules and destory the first rule:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.56.0 dst is 192.1.0.0 tos is 4 / tcp src is 22 dst is 23 / end actions queue index 1 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.56.0 dst is 192.1.0.0 tos is 4 / tcp src is 22 dst is 24 / end actions queue index 2 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.56.0 dst is 192.1.0.0 tos is 4 / tcp src is 22 dst is 25 / end actions queue index 3 / mark / end
    

    there are rule 0/1/2 listed:

    flow list 0
    

    send packets match rule 0, rule 1 and rule 2, Verify all packets can be redirected to expected queue and mark. destory the first rule:

    flow destroy 0 rule 0
    

    list the rules, verify there are only rule 1 and rule 2 listed. send packet matched rule 0, verify it is received without FDIR matched ID. send packets matched rule 1 and rule 2, Verify all packets be redirected and mark. flush rules:

    flow flush 0
    

    send packets match rule 0, rule 1 and rule 2, verify all packets can not mark.

  2. create 3 rules and destory the second rule:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.56.0 dst is 192.1.0.0 tos is 4 / tcp src is 22 dst is 23 / end actions queue index 1 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.56.0 dst is 192.1.0.0 tos is 4 / tcp src is 22 dst is 24 / end actions queue index 2 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.56.0 dst is 192.1.0.0 tos is 4 / tcp src is 22 dst is 25 / end actions queue index 3 / mark / end
    

    there are rule 0/1/2 listed:

    flow list 0
    

    send packets match rule 0, rule 1 and rule 2, Verify all packets can be redirected to expected queue and mark. destory the second rule:

    flow destroy 0 rule 1
    

    list the rules, verify there are only rule 0 and rule 2 listed. send packet matched rule 1, verify it is received without FDIR matched ID. send packets matched rule 0 and rule 2, Verify all packets be redirected and mark. flush rules:

    flow flush 0
    

    send packets match rule 0, rule 1 and rule 2, verify all packets can not mark.

  3. create 3 rules and destory the third rule:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.56.0 dst is 192.1.0.0 tos is 4 / tcp src is 22 dst is 23 / end actions queue index 1 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.56.0 dst is 192.1.0.0 tos is 4 / tcp src is 22 dst is 24 / end actions queue index 2 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.56.0 dst is 192.1.0.0 tos is 4 / tcp src is 22 dst is 25 / end actions queue index 3 / mark / end
    

    there are rule 0/1/2 listed:

    flow list 0
    

    send packets match rule 0, rule 1 and rule 2, Verify all packets can be redirected to expected queue and mark. destory the last rule:

    flow destroy 0 rule 2
    

    list the rules, verify there are only rule 0 and rule 1 listed. send packet matched rule 2, verify it is received without FDIR matched ID. send packets matched rule 0 and rule 1, Verify all packets be redirected and mark. flush rules:

    flow flush 0
    

    send packets match rule 0, rule 1 and rule 2, verify all packets can not mark.

31.181. Subcase 4: max rules

This case is designed based on 2*100G NIC. If 4*25 NIC, each PF port has 512 fdir rules guaranteed. So there can be created 14848 fdir rules on 1 PF port.

  1. create 15360 rules on port 0:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.100.20 dst is 192.168.0.0 / end actions queue index 1 / mark / end
    flow create 0 ingress pattern eth / ipv4 src is 192.168.100.20 dst is 192.168.0.1 / end actions queue index 1 / mark / end
    ......
    flow create 0 ingress pattern eth / ipv4 src is 192.168.100.20 dst is 192.168.59.255 / end actions queue index 1 / mark / end
    

    all the rules are created successfully.

  2. create one more rule:

    flow create 0 ingress pattern eth / ipv4 src is 192.168.100.20 dst is 192.168.60.0 / end actions queue index 1 / mark / end
    

    the rule failed to create. return the error message:

    Failed to create flow
    
  3. check the rule list, there are 15360 rules listed.

  4. send matched packets for rule 0 and rule 15359:

    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.100.20",dst="192.168.0.0")/Raw('x' * 80)],iface="enp175s0f0")
    sendp([Ether(dst="00:11:22:33:44:55")/IP(src="192.168.100.20",dst="192.168.59.255")/Raw('x' * 80)],iface="enp175s0f0")
    

    check all packets are redirected to expected queue with FDIR matched ID=0x0

  5. flush all the rules, check the rule list, there is no rule listed.

  6. verify matched packets for rule 0 and rule 15359 received without FDIR matched ID.

31.181.1. Test_Case: IPV6_NEXT_PROTO pattern

31.182. Subcase 1: IPV6_NEXT_PROTO queue index

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 123 / end actions queue index 1 / mark / end
    
  2. send matched packets, check the packets is distributed to queue 1 with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the rule listed. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packet is distributed by RSS without FDIR matched ID. check there is no rule listed.

31.183. Subcase 2: IPV6_NEXT_PROTO rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 123 / end actions rss queues 1 2 end / mark id 1 / end
    
  2. send matched packets, check the packets is distributed to queue 56-63 with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. check there is no rule listed.

31.184. Subcase 3: IPV6_NEXT_PROTO passthru

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 123 / end actions passthru / mark / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are destributed by RSS without FDIR matched ID . check there is no rule listed.

31.185. Subcase 4: IPV6_NEXT_PROTO drop

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 123 / end actions drop / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is dropped. check there is no rule listed.

31.186. Subcase 5: IPV6_NEXT_PROTO mark+rss

Note: This combined action is mark with RSS which is without queues specified.

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 123 / end actions mark / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x0 send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.187. Subcase 6: IPV6_NEXT_PROTO mark

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 123 / end actions mark / end
    
  2. repeat the steps of passthru in subcase 3, get the same result.

31.187.1. Test_Case: IPV6_NEXT_PROTO_UDP pattern

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 17 / udp / end actions queue index 3 / mark / end
    
  2. send matched packets, check the packets is distributed to queue 1 with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. verify rules can be listed and destroyed:

    testpmd> flow list 0
    

    check the rule listed. destroy the rule:

    testpmd> flow destroy 0 rule 0
    
  4. verify matched packet is distributed by RSS without FDIR matched ID. check there is no rule listed.

31.188. Subcase 2: IPV6_NEXT_PROTO_UDP rss queues

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 17 / udp / end actions rss queues 5 6 end / mark id 1 / end
    
  2. send matched packets, check the packets is distributed to queue 56-63 with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is distributed by RSS without FDIR matched ID. check there is no rule listed.

31.189. Subcase 3: IPV6_NEXT_PROTO_UDP passthru

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 17 / udp / end actions passthru / mark / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x0. send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are destributed by RSS without FDIR matched ID . check there is no rule listed.

31.190. Subcase 4: IPV6_NEXT_PROTO_UDP drop

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 17 / udp / end actions drop / end
    
  2. send matched packets, check the packets are dropped. send unmatched packets, check the packets are not dropped.

  3. repeat step 3 of subcase 1.

  4. verify matched packet is dropped. check there is no rule listed.

31.191. Subcase 5: IPV6_NEXT_PROTO_UDP mark+rss

Note: This combined action is mark with RSS which is without queues specified.

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 17 / udp / end actions mark / rss / end
    
  2. send matched packets, check the packets are distributed by RSS with FDIR matched ID=0x0 send unmatched packets, check the packets are distributed by RSS without FDIR matched ID.

  3. repeat step 3 of subcase 1.

  4. verify matched packets are distributed by RSS without FDIR matched ID. check there is no rule listed.

31.192. Subcase 6: IPV6_NEXT_PROTO_UDP mark

  1. create filter rules:

    flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 17 / udp / end actions mark / end
    
  2. repeat the steps of passthru in subcase 3, get the same result.

31.192.1. Test_Case: IPV6_NEXT_PROTO_TCP pattern

  1. replace “udp” with “tcp”, replace “proto is 17” with “proto is 6” in all the subcases of IPV6_NEXT_PROTO_UDP pattern.
  2. Then repeat all the steps in all the subcases of IPV6_NEXT_PROTO_UDP pattern.
  3. get the same result.

31.192.2. Test_Case: IPV6_NEXT_PROTO_SCTP pattern

  1. replace “udp” with “sctp”, replace “proto is 17” with “proto is 132” in all the subcases of IPV6_NEXT_PROTO_UDP pattern.
  2. Then repeat all the steps in all the subcases of IPV6_NEXT_PROTO_UDP pattern.
  3. get the same result.

31.192.3. exclusive test cases

support priority:

rule1: flow create 0 priority 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 123 / end actions queue index 1 / mark / end

same proto value can’t be created twice:

rule1: flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 123 / end actions queue index 1 / mark / end
rule2: flow create 0 ingress pattern eth dst is 00:11:22:33:44:55 / ipv6 proto is 123 / end actions rss queues 2 3 end / mark / end