test suite reviews and discussions
 help / color / mirror / Atom feed
* [dts] [PATCH v1 0/2] test_plans:adds, tests:adds
@ 2021-02-23  7:10 Hailin Xu
  2021-02-23  7:10 ` [dts] [PATCH v1 1/2] test_plans/iavf_fdir:add without input set cases Hailin Xu
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Hailin Xu @ 2021-02-23  7:10 UTC (permalink / raw)
  To: dts; +Cc: xueqin.lin, Hailin Xu

add without input set IPv4/IPv6 tcp/udp fdir rule cases.

Hailin Xu (2):
  test_plans/iavf_fdir:add without input set cases
  tests/iavf_fdir:add without input set cases

 test_plans/iavf_fdir_test_plan.rst | 259 ++++++++++++++++++++++++++++
 tests/TestSuite_iavf_fdir.py       | 265 ++++++++++++++++++++++++++++-
 2 files changed, 516 insertions(+), 8 deletions(-)

-- 
2.17.1


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [dts] [PATCH v1 1/2] test_plans/iavf_fdir:add without input set cases
  2021-02-23  7:10 [dts] [PATCH v1 0/2] test_plans:adds, tests:adds Hailin Xu
@ 2021-02-23  7:10 ` Hailin Xu
  2021-03-08  8:20   ` Lin, Xueqin
  2021-02-23  7:10 ` [dts] [PATCH v1 2/2] tests/iavf_fdir:add " Hailin Xu
  2021-02-23  7:37 ` [dts] [PATCH v1 0/2] test_plans:adds, tests:adds Xu, HailinX
  2 siblings, 1 reply; 6+ messages in thread
From: Hailin Xu @ 2021-02-23  7:10 UTC (permalink / raw)
  To: dts; +Cc: xueqin.lin, Hailin Xu

add without input set IPv4/IPv6 tcp/udp fdir rule test plans.

Signed-off-by: Hailin Xu <hailinx.xu@intel.com>
---
 test_plans/iavf_fdir_test_plan.rst | 259 +++++++++++++++++++++++++++++
 1 file changed, 259 insertions(+)

diff --git a/test_plans/iavf_fdir_test_plan.rst b/test_plans/iavf_fdir_test_plan.rst
index 6de28d2c..f63548dc 100644
--- a/test_plans/iavf_fdir_test_plan.rst
+++ b/test_plans/iavf_fdir_test_plan.rst
@@ -4551,3 +4551,262 @@ subcase 3: PFCP FDIR vlan insert on
 8. DUT check the packets are not distributed to expected queue without mark id without "PKT_RX_VLAN_STRIPPED",
    verify that the same number of packet are correctly received on the traffic generator side port A with VLAN tag "1".
    And UDP checksum need be validated as pass by the tester.
+
+ipv4/ipv6 rss tcp/udp without input set cases
+=============================================
+
+* MAC_IPV4_TCP
+
+    matched packets::
+
+        sendp([Ether(dst="00:11:22:33:44:55")/IP()/TCP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+
+    mismatched packets::
+
+        sendp([Ether(dst="00:11:22:33:44:55")/IP(src=RandIP(), dst=RandIP())],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IP(src=RandIP(), dst=RandIP())/SCTP()],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IPv6()/TCP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+
+* MAC_IPV4_UDP
+
+    matched packets::
+
+        sendp([Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+
+    mismatched packets::
+
+        sendp([Ether(dst="00:11:22:33:44:55")/IP(src=RandIP(), dst=RandIP())],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IP(src=RandIP(), dst=RandIP())/SCTP()],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IP()/TCP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IPv6()/UDP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+
+* MAC_IPV6_TCP
+
+    matched packets::
+
+        sendp([Ether(dst="00:11:22:33:44:55")/IPv6()/TCP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+
+    mismatched packets::
+
+        sendp([Ether(dst="00:11:22:33:44:55")/IP()/TCP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IPv6()],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IPv6()/UDP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IPv6()/SCTP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+
+* MAC_IPV6_UDP
+
+    matched packets::
+
+        sendp([Ether(dst="00:11:22:33:44:55")/IPv6()/UDP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+
+    mismatched packets::
+
+        sendp([Ether(dst="00:11:22:33:44:55")/IP()/TCP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IPv6()],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IPv6()/TCP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+        sendp([Ether(dst="00:11:22:33:44:55")/IPv6()/SCTP(sport=RandShort(),dport=RandShort())],iface='ens192f1',count=100)
+
+Test Case: MAC_IPV4_TCP_WITHOUT_INPUT_SET
+=========================================
+
+Subcase 1: MAC_IPV4_TCP queue index
+-----------------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv4 / tcp / end actions queue index 1 / end
+
+2. send matched packets, check all packets are distributed to queue 1.
+   send mismatched packets, check all packets are distributed to all queues.
+
+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 to all queues.
+   check there is no rule listed.
+
+Subcase 2: MAC_IPV4_TCP rss queue
+---------------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv4 / tcp / end actions rss queues 0 1 2 3 end / end
+
+2. send matched packets, check all packets are distributed to queue 0-3.
+   send mismatched packets, check all packets are distributed to all queues.
+
+3. repeat step 3 of subcase 1.
+
+4. verify matched packets are distributed to all queues.
+   check there is no rule listed.
+
+Subcase 3: MAC_IPV4_TCP passthru
+--------------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv4 / tcp / end actions passthru / mark id 1 / end
+
+2. send matched packets, check all packets are distributed to all queue with FDIR matched ID=0x1.
+   send mismatched packets, check all packets are distributed to all queues without FDIR matched ID.
+
+3. repeat step 3 of subcase 1.
+
+4. verify matched packets are distributed to all queues without FDIR matched ID.
+   check there is no rule listed.
+
+Subcase 4: MAC_IPV4_TCP drop
+----------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv4 / tcp / end actions drop / end
+
+2. send matched packets, check all packets are dropped.
+   send mismatched packets, check all packets are not dropped.
+
+3. repeat step 3 of subcase 1.
+
+4. verify matched packets are not dropped.
+   check there is no rule listed.
+
+Subcase 5: MAC_IPV4_TCP mark+rss
+--------------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv4 / tcp / end actions mark id 2 / rss / end
+
+2. send matched packets, check all packets are distributed to all queue with FDIR matched ID=0x2.
+   send mismatched packets, check all packets are distributed to all queues without FDIR matched ID.
+
+3. repeat step 3 of subcase 1.
+
+4. verify matched packets are distributed to all queues without FDIR matched ID.
+   check there is no rule listed.
+
+Subcase 6: MAC_IPV4_TCP mark
+----------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv4 / tcp / end actions mark id 1 / end
+
+2. repeat the step 2-3 of in subcase 3,
+   get the same result.
+
+Test Case: MAC_IPV4_UDP_WITHOUT_INPUT_SET
+=========================================
+
+1. replace "tcp" with "udp" in all the subcases of MAC_IPV4_TCP_WITHOUT_INPUT_SET pattern.
+2. Then repeat all the steps in all the subcases of MAC_IPV4_TCP_WITHOUT_INPUT_SET pattern.
+3. get the same result.
+
+Test Case: MAC_IPV6_TCP_WITHOUT_INPUT_SET
+=========================================
+
+Subcase 1: MAC_IPV6_TCP queue index
+-----------------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv6 / tcp / end actions queue index 1 / end
+
+2. send matched packets, check all packets are distributed to queue 1.
+   send mismatched packets, check all packets are distributed to all queues.
+
+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 to all queues.
+   check there is no rule listed.
+
+Subcase 2: MAC_IPV6_TCP rss queue
+---------------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv6 / tcp / end actions rss queues 0 1 2 3 end / end
+
+2. send matched packets, check all packets are distributed to queue 0-3.
+   send mismatched packets, check all packets are distributed to all queues.
+
+3. repeat step 3 of subcase 1.
+
+4. verify matched packets are distributed to all queues.
+   check there is no rule listed.
+
+Subcase 3: MAC_IPV6_TCP passthru
+--------------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv6 / tcp / end actions passthru / mark id 1 / end
+
+2. send matched packets, check all packets are distributed to all queue with FDIR matched ID=0x1.
+   send mismatched packets, check all packets are distributed to all queues without FDIR matched ID.
+
+3. repeat step 3 of subcase 1.
+
+4. verify matched packets are distributed to all queues without FDIR matched ID.
+   check there is no rule listed.
+
+Subcase 4: MAC_IPV6_TCP drop
+----------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv6 / tcp / end actions drop / end
+
+2. send matched packets, check all packets are dropped.
+   send mismatched packets, check all packets are not dropped.
+
+3. repeat step 3 of subcase 1.
+
+4. verify matched packets are not dropped.
+   check there is no rule listed.
+
+Subcase 5: MAC_IPV6_TCP mark+rss
+--------------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv6 / tcp / end actions mark id 2 / rss / end
+
+2. send matched packets, check all packets are distributed to all queue with FDIR matched ID=0x2.
+   send mismatched packets, check all packets are distributed to all queues without FDIR matched ID.
+
+3. repeat step 3 of subcase 1.
+
+4. verify matched packets are distributed to all queues without FDIR matched ID.
+   check there is no rule listed.
+
+Subcase 6: MAC_IPV6_TCP mark
+----------------------------
+
+1. create filter rules::
+
+    flow create 0 ingress pattern eth / ipv6 / udp / end actions mark id 1 / end
+
+2. repeat the step 2-3 of in subcase 3,
+   get the same result.
+
+Test Case: MAC_IPV6_UDP_WITHOUT_INPUT_SET
+=========================================
+
+1. replace "tcp" with "udp" in all the subcases of MAC_IPV6_TCP_WITHOUT_INPUT_SET pattern.
+2. Then repeat all the steps in all the subcases of MAC_IPV6_TCP_WITHOUT_INPUT_SET pattern.
+3. get the same result.
\ No newline at end of file
-- 
2.17.1


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [dts] [PATCH v1 2/2] tests/iavf_fdir:add without input set cases
  2021-02-23  7:10 [dts] [PATCH v1 0/2] test_plans:adds, tests:adds Hailin Xu
  2021-02-23  7:10 ` [dts] [PATCH v1 1/2] test_plans/iavf_fdir:add without input set cases Hailin Xu
@ 2021-02-23  7:10 ` Hailin Xu
  2021-03-08  8:21   ` Lin, Xueqin
  2021-02-23  7:37 ` [dts] [PATCH v1 0/2] test_plans:adds, tests:adds Xu, HailinX
  2 siblings, 1 reply; 6+ messages in thread
From: Hailin Xu @ 2021-02-23  7:10 UTC (permalink / raw)
  To: dts; +Cc: xueqin.lin, Hailin Xu

add without input set IPv4/IPv6 tcp/udp fdir rule test cases.

Signed-off-by: Hailin Xu <hailinx.xu@intel.com>
---
 tests/TestSuite_iavf_fdir.py | 265 +++++++++++++++++++++++++++++++++--
 1 file changed, 257 insertions(+), 8 deletions(-)

diff --git a/tests/TestSuite_iavf_fdir.py b/tests/TestSuite_iavf_fdir.py
index 76a320a3..e83855d4 100644
--- a/tests/TestSuite_iavf_fdir.py
+++ b/tests/TestSuite_iavf_fdir.py
@@ -575,6 +575,38 @@ tv_pfcp_drop = {
         {"port_id": 0, "passthru": 1}]
 }
 
+MAC_IPV4_TCP_WITHOUT = {
+    "match": ['Ether(dst="00:11:22:33:44:55")/IP()/TCP(sport=RandShort(),dport=RandShort())'],
+    "mismatch": ['Ether(dst="00:11:22:33:44:55")/IP(src=RandIP(), dst=RandIP())',
+                 'Ether(dst="00:11:22:33:44:55")/IP(src=RandIP(), dst=RandIP())/SCTP()',
+                 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=RandShort(),dport=RandShort())',
+                 'Ether(dst="00:11:22:33:44:55")/IPv6()/TCP(sport=RandShort(),dport=RandShort())']
+}
+
+MAC_IPV4_UDP_WITHOUT = {
+    "match": ['Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=RandShort(),dport=RandShort())'],
+    "mismatch": ['Ether(dst="00:11:22:33:44:55")/IP(src=RandIP(), dst=RandIP())',
+                 'Ether(dst="00:11:22:33:44:55")/IP(src=RandIP(), dst=RandIP())/SCTP()',
+                 'Ether(dst="00:11:22:33:44:55")/IP()/TCP(sport=RandShort(),dport=RandShort())',
+                 'Ether(dst="00:11:22:33:44:55")/IPv6()/UDP(sport=RandShort(),dport=RandShort())']
+}
+
+MAC_IPV6_TCP_WITHOUT = {
+    "match": ['Ether(dst="00:11:22:33:44:55")/IPv6()/TCP(sport=RandShort(),dport=RandShort())'],
+    "mismatch": ['Ether(dst="00:11:22:33:44:55")/IP()/TCP(sport=RandShort(),dport=RandShort())',
+                 'Ether(dst="00:11:22:33:44:55")/IPv6()',
+                 'Ether(dst="00:11:22:33:44:55")/IPv6()/UDP(sport=RandShort(),dport=RandShort())',
+                 'Ether(dst="00:11:22:33:44:55")/IPv6()/SCTP(sport=RandShort(),dport=RandShort())']
+}
+
+MAC_IPV6_UDP_WITHOUT = {
+    "match": ['Ether(dst="00:11:22:33:44:55")/IPv6()/UDP(sport=RandShort(),dport=RandShort())'],
+    "mismatch": ['Ether(dst="00:11:22:33:44:55")/IP()/UDP(sport=RandShort(),dport=RandShort())',
+                 'Ether(dst="00:11:22:33:44:55")/IPv6()',
+                 'Ether(dst="00:11:22:33:44:55")/IPv6()/TCP(sport=RandShort(),dport=RandShort())',
+                 'Ether(dst="00:11:22:33:44:55")/IPv6()/SCTP(sport=RandShort(),dport=RandShort())']
+}
+
 tv_mac_ipv4_pay_queue_index = {
     "name": "test_mac_ipv4_pay_queue_index",
     "rule": "flow create 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 / end",
@@ -1783,6 +1815,186 @@ tv_mac_ipv6_nat_t_esp_mark = {
     "check_param": {"port_id": 0, "passthru": 1, "mark_id": 15}
 }
 
+# mac_ipv4_tcp_without_input_set
+tv_mac_ipv4_tcp_without_input_set_queue_index = {
+    "name": "test_mac_ipv4_tcp_without_input_set_queue_index",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / tcp / end actions queue index 1 / end",
+    "scapy_str": MAC_IPV4_TCP_WITHOUT,
+    "count": 10,
+    "check_param": {"port_id": 0, "queue": 1}
+}
+
+tv_mac_ipv4_tcp_without_input_set_queue_group = {
+    "name": "test_mac_ipv4_tcp_without_input_set_drop",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / tcp / end actions rss queues 0 1 2 3 end / end",
+    "scapy_str": MAC_IPV4_TCP_WITHOUT,
+    "count": 10,
+    "check_param": {"port_id": 0, "queue": [0, 1, 2, 3]}
+}
+
+tv_mac_ipv4_tcp_without_input_set_passthru = {
+    "name": "test_mac_ipv4_tcp_without_input_set_passthru",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / tcp / end actions passthru / mark id 1 / end",
+    "scapy_str": MAC_IPV4_TCP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 1}
+}
+
+tv_mac_ipv4_tcp_without_input_set_drop = {
+    "name": "test_mac_ipv4_tcp_without_input_set_drop",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / tcp / end actions drop / end",
+    "scapy_str": MAC_IPV4_TCP_WITHOUT,
+    "check_param": {"port_id": 0, "drop": 1}
+}
+
+tv_mac_ipv4_tcp_without_input_set_mark_rss = {
+    "name": "test_mac_ipv4_tcp_without_input_set_mark_rss",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / tcp / end actions mark id 2 / rss / end",
+    "scapy_str": MAC_IPV4_TCP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 2}
+}
+
+tv_mac_ipv4_tcp_without_input_set_mark = {
+    "name": "test_mac_ipv4_tcp_without_input_set_mark",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / tcp / end actions mark id 1 / end",
+    "scapy_str": MAC_IPV4_TCP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 1}
+}
+
+# mac_ipv4_udp_without_input_set
+tv_mac_ipv4_udp_without_input_set_queue_index = {
+    "name": "test_mac_ipv4_udp_without_input_set_queue_index",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / udp / end actions queue index 1 / end",
+    "scapy_str": MAC_IPV4_UDP_WITHOUT,
+    "count": 10,
+    "check_param": {"port_id": 0, "queue": 1}
+}
+
+tv_mac_ipv4_udp_without_input_set_queue_group = {
+    "name": "test_mac_ipv4_udp_without_input_set_drop",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / udp / end actions rss queues 0 1 2 3 end / end",
+    "scapy_str": MAC_IPV4_UDP_WITHOUT,
+    "count": 10,
+    "check_param": {"port_id": 0, "queue": [0, 1, 2, 3]}
+}
+
+tv_mac_ipv4_udp_without_input_set_passthru = {
+    "name": "test_mac_ipv4_udp_without_input_set_passthru",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / udp / end actions passthru / mark id 1 / end",
+    "scapy_str": MAC_IPV4_UDP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 1}
+}
+
+tv_mac_ipv4_udp_without_input_set_drop = {
+    "name": "test_mac_ipv4_udp_without_input_set_drop",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / udp / end actions drop / end",
+    "scapy_str": MAC_IPV4_UDP_WITHOUT,
+    "check_param": {"port_id": 0, "drop": 1}
+}
+
+tv_mac_ipv4_udp_without_input_set_mark_rss = {
+    "name": "test_mac_ipv4_udp_without_input_set_mark_rss",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / udp / end actions mark id 2 / rss / end",
+    "scapy_str": MAC_IPV4_UDP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 2}
+}
+
+tv_mac_ipv4_udp_without_input_set_mark = {
+    "name": "test_mac_ipv4_udp_without_input_set_mark",
+    "rule": "flow create 0 ingress pattern eth / ipv4 / udp / end actions mark id 1 / end",
+    "scapy_str": MAC_IPV4_UDP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 1}
+}
+
+# mac_ipv6_tcp_without_input_set
+tv_mac_ipv6_tcp_without_input_set_queue_index = {
+    "name": "test_mac_ipv6_tcp_without_input_set_queue_index",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / tcp / end actions queue index 1 / end",
+    "scapy_str": MAC_IPV6_TCP_WITHOUT,
+    "count": 10,
+    "check_param": {"port_id": 0, "queue": 1}
+}
+
+tv_mac_ipv6_tcp_without_input_set_queue_group = {
+    "name": "test_mac_ipv6_tcp_without_input_set_drop",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / tcp / end actions rss queues 0 1 2 3 end / end",
+    "scapy_str": MAC_IPV6_TCP_WITHOUT,
+    "count": 10,
+    "check_param": {"port_id": 0, "queue": [0, 1, 2, 3]}
+}
+
+tv_mac_ipv6_tcp_without_input_set_passthru = {
+    "name": "test_mac_ipv6_tcp_without_input_set_passthru",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / tcp / end actions passthru / mark id 1 / end",
+    "scapy_str": MAC_IPV6_TCP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 1}
+}
+
+tv_mac_ipv6_tcp_without_input_set_drop = {
+    "name": "test_mac_ipv6_tcp_without_input_set_drop",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / tcp / end actions drop / end",
+    "scapy_str": MAC_IPV6_TCP_WITHOUT,
+    "check_param": {"port_id": 0, "drop": 1}
+}
+
+tv_mac_ipv6_tcp_without_input_set_mark_rss = {
+    "name": "test_mac_ipv6_tcp_without_input_set_mark_rss",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / tcp / end actions mark id 2 / rss / end",
+    "scapy_str": MAC_IPV6_TCP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 2}
+}
+
+tv_mac_ipv6_tcp_without_input_set_mark = {
+    "name": "test_mac_ipv6_tcp_without_input_set_mark",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / tcp / end actions mark id 1 / end",
+    "scapy_str": MAC_IPV6_TCP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 1}
+}
+
+# mac_ipv6_udp_without_input_set
+tv_mac_ipv6_udp_without_input_set_queue_index = {
+    "name": "test_mac_ipv6_udp_without_input_set_queue_index",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / udp / end actions queue index 1 / end",
+    "scapy_str": MAC_IPV6_UDP_WITHOUT,
+    "count": 10,
+    "check_param": {"port_id": 0, "queue": 1}
+}
+
+tv_mac_ipv6_udp_without_input_set_queue_group = {
+    "name": "test_mac_ipv6_udp_without_input_set_drop",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / udp / end actions rss queues 0 1 2 3 end / end",
+    "scapy_str": MAC_IPV6_UDP_WITHOUT,
+    "count": 10,
+    "check_param": {"port_id": 0, "queue": [0, 1, 2, 3]}
+}
+
+tv_mac_ipv6_udp_without_input_set_passthru = {
+    "name": "test_mac_ipv6_udp_without_input_set_passthru",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / udp / end actions passthru / mark id 1 / end",
+    "scapy_str": MAC_IPV6_UDP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 1}
+}
+
+tv_mac_ipv6_udp_without_input_set_drop = {
+    "name": "test_mac_ipv6_udp_without_input_set_drop",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / udp / end actions drop / end",
+    "scapy_str": MAC_IPV6_UDP_WITHOUT,
+    "check_param": {"port_id": 0, "drop": 1}
+}
+
+tv_mac_ipv6_udp_without_input_set_mark_rss = {
+    "name": "test_mac_ipv6_udp_without_input_set_mark_rss",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / udp / end actions mark id 2 / rss / end",
+    "scapy_str": MAC_IPV6_UDP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 2}
+}
+
+tv_mac_ipv6_udp_without_input_set_mark = {
+    "name": "test_mac_ipv6_udp_without_input_set_mark",
+    "rule": "flow create 0 ingress pattern eth / ipv6 / udp / end actions mark id 1 / end",
+    "scapy_str": MAC_IPV6_UDP_WITHOUT,
+    "check_param": {"port_id": 0, "passthru": 1, "mark_id": 1}
+}
+
 vectors_ipv4_pay = [tv_mac_ipv4_pay_queue_index, tv_mac_ipv4_pay_mark_rss,tv_mac_ipv4_pay_passthru,
                          tv_mac_ipv4_pay_drop, tv_mac_ipv4_pay_queue_group, tv_mac_ipv4_pay_mark]
 
@@ -1873,6 +2085,22 @@ vectors_ipv4_nat_t_esp = [tv_mac_ipv4_nat_t_esp_queue_index, tv_mac_ipv4_nat_t_e
 
 vectors_ipv6_nat_t_esp = [tv_mac_ipv6_nat_t_esp_queue_index, tv_mac_ipv6_nat_t_esp_queue_group, tv_mac_ipv6_nat_t_esp_mark]
 
+vectors_ipv4_tcp_without_input_set = [tv_mac_ipv4_tcp_without_input_set_queue_index, tv_mac_ipv4_tcp_without_input_set_queue_group,
+                                      tv_mac_ipv4_tcp_without_input_set_mark_rss, tv_mac_ipv4_tcp_without_input_set_passthru,
+                                      tv_mac_ipv4_tcp_without_input_set_drop, tv_mac_ipv4_tcp_without_input_set_mark]
+
+vectors_ipv4_udp_without_input_set = [tv_mac_ipv4_udp_without_input_set_queue_index, tv_mac_ipv4_udp_without_input_set_queue_group,
+                                      tv_mac_ipv4_udp_without_input_set_mark_rss, tv_mac_ipv4_udp_without_input_set_passthru,
+                                      tv_mac_ipv4_udp_without_input_set_drop, tv_mac_ipv4_udp_without_input_set_mark]
+
+vectors_ipv6_tcp_without_input_set = [tv_mac_ipv6_tcp_without_input_set_queue_index, tv_mac_ipv6_tcp_without_input_set_queue_group,
+                                      tv_mac_ipv6_tcp_without_input_set_mark_rss, tv_mac_ipv6_tcp_without_input_set_passthru,
+                                      tv_mac_ipv6_tcp_without_input_set_drop, tv_mac_ipv6_tcp_without_input_set_mark]
+
+vectors_ipv6_udp_without_input_set = [tv_mac_ipv6_udp_without_input_set_queue_index, tv_mac_ipv6_udp_without_input_set_queue_group,
+                                      tv_mac_ipv6_udp_without_input_set_mark_rss, tv_mac_ipv6_udp_without_input_set_passthru,
+                                      tv_mac_ipv6_udp_without_input_set_drop, tv_mac_ipv6_udp_without_input_set_mark]
+
 class TestIAVFFdir(TestCase):
 
     def rte_flow_process(self, vectors):
@@ -1893,9 +2121,13 @@ class TestIAVFFdir(TestCase):
                         "flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 1 / ipv4 / end actions rss types ipv4 l3-src-only end key_len 0 queues end / end"]
                     gtpu_rss_rule_li = self.create_fdir_rule(gtpu_rss, check_stats=True)
 
-                # send and check match packets
-                out1 = self.send_pkts_getouput(pkts=tv["scapy_str"]["match"])
-                rfc.check_iavf_fdir_mark(out1, pkt_num=len(tv["scapy_str"]["match"]), check_param=tv["check_param"])
+                if "count" in tv:
+                    out1 = self.send_pkts_getouput(pkts=tv["scapy_str"]["match"], count=tv["count"])
+                    rfc.check_iavf_fdir_mark(out1, pkt_num=tv["count"], check_param=tv["check_param"])
+                else:
+                    # send and check match packets
+                    out1 = self.send_pkts_getouput(pkts=tv["scapy_str"]["match"])
+                    rfc.check_iavf_fdir_mark(out1, pkt_num=len(tv["scapy_str"]["match"]), check_param=tv["check_param"])
                 # send and check mismatch packets
                 out2 = self.send_pkts_getouput(pkts=tv["scapy_str"]["mismatch"])
                 rfc.check_iavf_fdir_mark(out2, pkt_num=len(tv["scapy_str"]["mismatch"]), check_param=tv["check_param"],
@@ -2106,17 +2338,17 @@ class TestIAVFFdir(TestCase):
                                       socket=self.ports_socket)
         self.config_testpmd()
 
-    def send_packets(self, packets, pf_id=0):
+    def send_packets(self, packets, pf_id=0, count=1):
         self.pkt.update_pkt(packets)
         tx_port = self.tester_iface0 if pf_id == 0 else self.tester_iface1
-        self.pkt.send_pkt(crb=self.tester, tx_port=tx_port)
+        self.pkt.send_pkt(crb=self.tester, tx_port=tx_port, count=count)
 
-    def send_pkts_getouput(self, pkts, pf_id=0):
+    def send_pkts_getouput(self, pkts, pf_id=0, count=1):
         """
         if pkt_info is True, we need to get packet infomation to check the RSS hash and FDIR.
         if pkt_info is False, we just need to get the packet number and queue number.
         """
-        self.send_packets(pkts, pf_id)
+        self.send_packets(pkts, pf_id, count)
         time.sleep(1)
         out_info = self.dut.get_session_output(timeout=1)
         out_pkt = self.pmd_output.execute_cmd("stop")
@@ -2278,6 +2510,18 @@ class TestIAVFFdir(TestCase):
     def test_mac_ipv6_nat_t_esp(self):
         self.rte_flow_process(vectors_ipv6_nat_t_esp)
 
+    def test_mac_ipv4_tcp_without_input_set(self):
+        self.rte_flow_process(vectors_ipv4_tcp_without_input_set)
+
+    def test_mac_ipv4_udp_without_input_set(self):
+        self.rte_flow_process(vectors_ipv4_udp_without_input_set)
+
+    def test_mac_ipv6_tcp_without_input_set(self):
+        self.rte_flow_process(vectors_ipv6_tcp_without_input_set)
+
+    def test_mac_ipv6_udp_without_input_set(self):
+        self.rte_flow_process(vectors_ipv6_udp_without_input_set)
+
     def test_mac_ipv4_protocol(self):
         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",
@@ -2458,7 +2702,6 @@ class TestIAVFFdir(TestCase):
         out7 = self.send_pkts_getouput(pkts["mismatch"][7])
         rfc.check_iavf_fdir_mark(out7, pkt_num=1, check_param={"port_id": 0, "drop": True}, stats=False)
 
-
     def test_mac_outer_co_exist_gtpu_eh_dst(self):
         rules = ["flow create 0 ingress pattern eth / ipv4 dst is 192.168.0.31 / udp / gtpu / gtp_psc / end actions rss queues 1 2 end / mark id 1 / end", \
                  "flow create 0 ingress pattern eth / ipv6 dst is ::32 / udp / gtpu / gtp_psc / end actions rss queues 3 4 5 6 end / mark id 2 / end",\
@@ -2691,6 +2934,12 @@ class TestIAVFFdir(TestCase):
         self.create_fdir_rule(rule1, check_stats=False)
         rule2 = "flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / end actions drop / end"
         self.create_fdir_rule(rule2, check_stats=False)
+        self.create_fdir_rule(rule2, check_stats=False)
+        self.pmd_output.execute_cmd("flow destroy 0 rule 0", timeout=1)
+        rule3 = "flow create 0 ingress pattern eth / ipv4 / tcp / end actions queue index 1 / end"
+        self.create_fdir_rule(rule3, check_stats=True)
+        rule4 = "flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 ttl is 2 tos is 4 / tcp / end actions queue index 1 / end"
+        self.create_fdir_rule(rule4, check_stats=False)
         self.pmd_output.execute_cmd("flow destroy 0 rule 0", timeout=1)
 
         # delete a non-existent rule
-- 
2.17.1


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [dts] [PATCH v1 0/2] test_plans:adds, tests:adds
  2021-02-23  7:10 [dts] [PATCH v1 0/2] test_plans:adds, tests:adds Hailin Xu
  2021-02-23  7:10 ` [dts] [PATCH v1 1/2] test_plans/iavf_fdir:add without input set cases Hailin Xu
  2021-02-23  7:10 ` [dts] [PATCH v1 2/2] tests/iavf_fdir:add " Hailin Xu
@ 2021-02-23  7:37 ` Xu, HailinX
  2 siblings, 0 replies; 6+ messages in thread
From: Xu, HailinX @ 2021-02-23  7:37 UTC (permalink / raw)
  To: dts; +Cc: Lin, Xueqin

[-- Attachment #1: Type: text/plain, Size: 344 bytes --]

Tested-by: Xu, HailinX <hailinx.xu@intel.com>

Regards,
Xu, Hailin

>-----Original Message-----
>From: Xu, HailinX <hailinx.xu@intel.com> 
>Sent: Tuesday, February 23, 2021 3:11 PM
>To: dts@dpdk.org
>Cc: Lin, Xueqin <xueqin.lin@intel.com>; Xu, HailinX <hailinx.xu@intel.com>
>Subject: [dts][PATCH v1 0/2] test_plans:adds, tests:adds

[-- Attachment #2: TestIAVFFdir.log --]
[-- Type: application/octet-stream, Size: 6273050 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [dts] [PATCH v1 1/2] test_plans/iavf_fdir:add without input set cases
  2021-02-23  7:10 ` [dts] [PATCH v1 1/2] test_plans/iavf_fdir:add without input set cases Hailin Xu
@ 2021-03-08  8:20   ` Lin, Xueqin
  0 siblings, 0 replies; 6+ messages in thread
From: Lin, Xueqin @ 2021-03-08  8:20 UTC (permalink / raw)
  To: Xu, HailinX, dts

> -----Original Message-----
> From: Xu, HailinX <hailinx.xu@intel.com>
> Sent: Tuesday, February 23, 2021 3:11 PM
> To: dts@dpdk.org
> Cc: Lin, Xueqin <xueqin.lin@intel.com>; Xu, HailinX <hailinx.xu@intel.com>
> Subject: [dts][PATCH v1 1/2] test_plans/iavf_fdir:add without input set cases
> 
> add without input set IPv4/IPv6 tcp/udp fdir rule test plans.
> 
> Signed-off-by: Hailin Xu <hailinx.xu@intel.com>
Acked-by: Xueqin Lin <Xueqin.lin@intel.com>

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [dts] [PATCH v1 2/2] tests/iavf_fdir:add without input set cases
  2021-02-23  7:10 ` [dts] [PATCH v1 2/2] tests/iavf_fdir:add " Hailin Xu
@ 2021-03-08  8:21   ` Lin, Xueqin
  0 siblings, 0 replies; 6+ messages in thread
From: Lin, Xueqin @ 2021-03-08  8:21 UTC (permalink / raw)
  To: Xu, HailinX, dts

> -----Original Message-----
> From: Xu, HailinX <hailinx.xu@intel.com>
> Sent: Tuesday, February 23, 2021 3:11 PM
> To: dts@dpdk.org
> Cc: Lin, Xueqin <xueqin.lin@intel.com>; Xu, HailinX <hailinx.xu@intel.com>
> Subject: [dts][PATCH v1 2/2] tests/iavf_fdir:add without input set cases
> 
> add without input set IPv4/IPv6 tcp/udp fdir rule test cases.
> 
> Signed-off-by: Hailin Xu <hailinx.xu@intel.com>
Acked-by: Xueqin Lin <Xueqin.lin@intel.com>

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-03-08  8:21 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-23  7:10 [dts] [PATCH v1 0/2] test_plans:adds, tests:adds Hailin Xu
2021-02-23  7:10 ` [dts] [PATCH v1 1/2] test_plans/iavf_fdir:add without input set cases Hailin Xu
2021-03-08  8:20   ` Lin, Xueqin
2021-02-23  7:10 ` [dts] [PATCH v1 2/2] tests/iavf_fdir:add " Hailin Xu
2021-03-08  8:21   ` Lin, Xueqin
2021-02-23  7:37 ` [dts] [PATCH v1 0/2] test_plans:adds, tests:adds Xu, HailinX

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).