test suite reviews and discussions
 help / color / mirror / Atom feed
* [dts] [PATCH V1 1/2] test_plans/iavf_fdir: replace rules with less consumption TCAM rule
@ 2021-08-31  3:27 Jiale Song
  2021-08-31  3:27 ` [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption of TCAM rule in suite Jiale Song
  2021-09-01  2:47 ` [dts] [PATCH V1 1/2] test_plans/iavf_fdir: replace rules with less consumption TCAM rule Peng, Yuan
  0 siblings, 2 replies; 6+ messages in thread
From: Jiale Song @ 2021-08-31  3:27 UTC (permalink / raw)
  To: dts; +Cc: yuan.peng, Jiale Song

the number of rules created is affected by the profile and TCAM. the maximum profile is 128 and 
the maximum TCAM is 512. in order to test the maximum profile, need to create rules that consume 
less TCAM to ensure that the profile will reach the maximum before TCAM exhausted

Signed-off-by: Jiale Song <songx.jiale@intel.com>
---
 test_plans/iavf_fdir_test_plan.rst | 22 +++++++++++-----------
 1 file changed, 11 insertions(+), 11 deletions(-)

diff --git a/test_plans/iavf_fdir_test_plan.rst b/test_plans/iavf_fdir_test_plan.rst
index ac42390..51cebfe 100644
--- a/test_plans/iavf_fdir_test_plan.rst
+++ b/test_plans/iavf_fdir_test_plan.rst
@@ -4420,20 +4420,19 @@ Subcase 1: 128 profiles
 
 2. create 8 rules with different patterns on each port::
 
-    flow create 0 ingress pattern 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 1 / mark / end
-    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 / end
-    flow create 0 ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / sctp src is 22 dst is 23 / end actions queue index 1 / mark / end
-    flow create 0 ingress pattern eth / 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
-    flow create 0 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / tcp src is 22 dst is 23 / end actions queue index 1 / mark / end
-    flow create 0 ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / sctp src is 22 dst is 23 / end actions queue index 1 / mark / end
-    flow create 0 ingress pattern eth type is 0x8863 / end actions queue index 1 / mark id 1 / end
-    flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions queue index 2 / end
+    flow create 0 ingress pattern eth / ipv4 / l2tpv3oip session_id is 1 / end actions queue index 1 / mark / end
+    flow create 0 ingress pattern eth / ipv6 / l2tpv3oip session_id is 2 / end actions queue index 1 / mark / end
+    flow create 0 ingress pattern eth / ipv4 / tcp / end actions queue index 2 / mark / end
+    flow create 0 ingress pattern eth / ipv6 / tcp / end actions queue index 2 / mark / end
+    flow create 0 ingress pattern eth / ipv4 / esp spi is 1 / end actions queue index 3 / mark / end
+    flow create 0 ingress pattern eth / ipv6 / esp spi is 2 / end actions queue index 3 / mark / end
+    flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions queue index 4 / mark id 1 / end
+    flow create 0 ingress pattern eth / ipv6 / udp / pfcp s_field is 1 / end actions queue index 4 / end
 
    created successfully on port 0-12,
    failed from rule 6 on port 13::
 
-    testpmd> flow create 13 ingress pattern eth type is 0x8863 / end actions queue index 1 / mark id 1 / end
-    eth
+    testpmd> flow create 0 ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions queue index 4 / mark id 1 / end
     iavf_execute_vf_cmd(): No response or return failure (-5) for cmd 47
     iavf_fdir_add(): fail to execute command OP_ADD_FDIR_FILTER
     iavf_flow_create(): Failed to create flow
@@ -4462,6 +4461,7 @@ Subcase 1: 128 profiles
    profile 0 and profile 1 are default profile for specific packet.
    we design case with 2*100G card, so 110 profiles can be used for vf.
    if we use 4*25G card, only 94 profiles can be used for vf.
+   if card is chapman beach 100g*2, one pf port equals a general 100g*2 card,so 118 profiles can be used for vf
 
 4. send matched packets to vf 12,
    the packets are redirected to the expected queue.
@@ -6429,4 +6429,4 @@ packets::
    pkt11 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header()/GTPPDUSessionContainer(type=1)/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/TCP(sport=22, dport=23)/Raw('x'*20)
    pkt12 = Ether(src="a4:bf:01:51:27:ca", dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header()/GTPPDUSessionContainer(type=1)/IPv6(src="2001::2", dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=22, dport=23)/Raw('x'*20)
 
-repeat step 1-12 of subcase 1.
\ No newline at end of file
+repeat step 1-12 of subcase 1.
-- 
1.8.3.1


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

* [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption of TCAM rule in suite
  2021-08-31  3:27 [dts] [PATCH V1 1/2] test_plans/iavf_fdir: replace rules with less consumption TCAM rule Jiale Song
@ 2021-08-31  3:27 ` Jiale Song
  2021-09-01  2:48   ` Peng, Yuan
  2021-09-29  3:29   ` Tu, Lijuan
  2021-09-01  2:47 ` [dts] [PATCH V1 1/2] test_plans/iavf_fdir: replace rules with less consumption TCAM rule Peng, Yuan
  1 sibling, 2 replies; 6+ messages in thread
From: Jiale Song @ 2021-08-31  3:27 UTC (permalink / raw)
  To: dts; +Cc: yuan.peng, Jiale Song

modify the suite according to the testplan

Signed-off-by: Jiale Song <songx.jiale@intel.com>
---
 tests/TestSuite_iavf_fdir.py | 59 +++++++++++++++++++++++++++-----------------
 1 file changed, 36 insertions(+), 23 deletions(-)

diff --git a/tests/TestSuite_iavf_fdir.py b/tests/TestSuite_iavf_fdir.py
index d79829e..a737331 100644
--- a/tests/TestSuite_iavf_fdir.py
+++ b/tests/TestSuite_iavf_fdir.py
@@ -8453,6 +8453,14 @@ class TestIAVFFdir(TestCase):
             nex_cnt = 94 // 8
         elif len(self.dut_ports) == 2:
             nex_cnt = 110 // 8
+            # check the card is chapman beach 100g*2 or not
+            pf_pci = self.dut.ports_info[0]['pci']
+            out = self.dut.send_expect('lspci -s {} -vvv |grep "Product Name"'.format(pf_pci), '#')
+            res = re.search(r"Network Adapter\s+(?P<product_name>E810-.*)", out)
+            self.verify(res, "product name not found'")
+            # if card is chapman beach 100g*2, one pf port equals a general 100g*2 card,so 118 profiles can be used for vf
+            if 'E810-2CQDA2' in res.group('product_name'):
+                nex_cnt = 118 // 8
         else:
             self.verify(False, 'The number of ports is not supported')
 
@@ -8462,43 +8470,48 @@ class TestIAVFFdir(TestCase):
         self.config_testpmd()
 
         for port_id in range(nex_cnt):
+            #The number of rules created is affected by the profile and TCAM. The maximum profile is 128 and the maximum
+            #TCAM is 512. In order to test the maximum profile, need to create rules that consume less TCAM to ensure
+            #that the profile will reach the maximum before TCAM exhausted
             rules = [
-                "flow create %d ingress pattern 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 1 / mark / end" % port_id,
-                "flow create %d 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 / end" % port_id,
-                "flow create %d ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / sctp src is 22 dst is 23 / end actions queue index 1 / mark / end" % port_id,
-                "flow create %d ingress pattern eth / 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" % port_id,
-                "flow create %d ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / tcp src is 22 dst is 23 / end actions queue index 1 / mark / end" % port_id,
-                "flow create %d ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / sctp src is 22 dst is 23 / end actions queue index 1 / mark / end" % port_id,
-                "flow create %d ingress pattern eth type is 0x8863 / end actions queue index 1 / mark id 1 / end" % port_id,
-                "flow create %d ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions queue index 2 / end" % port_id]
-            self.create_fdir_rule(rules, check_stats=True)
+                "flow create {} ingress pattern eth / ipv4 / l2tpv3oip session_id is 1 / end actions queue index 1 / mark / end",
+                "flow create {} ingress pattern eth / ipv6 / l2tpv3oip session_id is 2 / end actions queue index 1 / mark / end",
+                "flow create {} ingress pattern eth / ipv4 / tcp / end actions queue index 2 / mark / end",
+                "flow create {} ingress pattern eth / ipv6 / tcp / end actions queue index 2 / mark / end",
+                "flow create {} ingress pattern eth / ipv4 / esp spi is 1 / end actions queue index 3 / mark / end",
+                "flow create {} ingress pattern eth / ipv6 / esp spi is 2 / end actions queue index 3 / mark / end",
+                "flow create {} ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions queue index 4 / mark id 1 / end",
+                "flow create {} ingress pattern eth / ipv6 / udp / pfcp s_field is 1 / end actions queue index 4 / end"
+            ]
+            self.create_fdir_rule([rule.format(port_id) for rule in rules], check_stats=True)
 
         rules = [
-            "flow create {} ingress pattern 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 1 / mark / end".format(nex_cnt),
-            "flow create {} 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 / end".format(nex_cnt),
-            "flow create {} ingress pattern eth / ipv4 src is 192.168.0.20 dst is 192.168.0.21 / sctp src is 22 dst is 23 / end actions queue index 1 / mark / end".format(nex_cnt),
-            "flow create {} ingress pattern eth / 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".format(nex_cnt),
-            "flow create {} ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / tcp src is 22 dst is 23 / end actions queue index 1 / mark / end".format(nex_cnt),
-            "flow create {} ingress pattern eth / ipv6 dst is CDCD:910A:2222:5498:8475:1111:3900:2020 src is 2001::2 / sctp src is 22 dst is 23 / end actions queue index 1 / mark / end".format(nex_cnt)]
-        self.create_fdir_rule(rules, check_stats=True)
+            "flow create {} ingress pattern eth / ipv4 / l2tpv3oip session_id is 1 / end actions queue index 1 / mark / end",
+            "flow create {} ingress pattern eth / ipv6 / l2tpv3oip session_id is 2 / end actions queue index 1 / mark / end",
+            "flow create {} ingress pattern eth / ipv4 / tcp / end actions queue index 2 / mark / end",
+            "flow create {} ingress pattern eth / ipv6 / tcp / end actions queue index 2 / mark / end",
+            "flow create {} ingress pattern eth / ipv4 / esp spi is 1 / end actions queue index 3 / mark / end",
+            "flow create {} ingress pattern eth / ipv6 / esp spi is 2 / end actions queue index 3 / mark / end"
+        ]
+        self.create_fdir_rule([rule.format(nex_cnt) for rule in rules], check_stats=True)
 
-        rule = "flow create {} ingress pattern eth type is 0x8863 / end actions queue index 1 / mark id 1 / end".format(nex_cnt)
+        rule = "flow create {} ingress pattern eth / ipv4 / udp / pfcp s_field is 0 / end actions queue index 4 / mark id 1 / end".format(nex_cnt)
         self.create_fdir_rule(rule, check_stats=False)
-        pkt1 = '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)'
+        pkt1 =  'Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21")/TCP()/Raw("x" * 80)'
         out = self.send_pkts_getouput(pkts=pkt1)
-        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={"port_id": nex_cnt, "mark_id": 0, "queue": 1}, stats=True)
-        pkt2 = 'Ether(dst="00:11:22:33:44:55", type=0x8863)/IP()/Raw("x" * 80)'
+        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={"port_id": nex_cnt, "mark_id": 0, "queue": 2}, stats=True)
+        pkt2 = 'Ether(dst="00:11:22:33:44:55")/IP(src="192.168.0.20",dst="192.168.0.21")/UDP(dport=8805)/PFCP(S=0)/Raw("x" * 80)'
         out = self.send_pkts_getouput(pkts=pkt2)
-        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={"port_id": nex_cnt, "mark_id": 1, "queue": 1}, stats=False)
+        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={"port_id": nex_cnt, "mark_id": 1, "queue": 4}, stats=False)
 
         self.dut.send_expect("flow flush {}".format(nex_cnt), "testpmd> ")
         self.check_fdir_rule(port_id=(nex_cnt), stats=False)
         out = self.send_pkts_getouput(pkts=pkt1)
-        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={"port_id": nex_cnt, "mark_id": 0, "queue": 1}, stats=False)
+        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={"port_id": nex_cnt, "mark_id": 0, "queue": 2}, stats=False)
 
         self.create_fdir_rule(rule, check_stats=True)
         out = self.send_pkts_getouput(pkts=pkt2)
-        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={"port_id": nex_cnt, "mark_id": 1, "queue": 1}, stats=True)
+        rfc.check_iavf_fdir_mark(out, pkt_num=1, check_param={"port_id": nex_cnt, "mark_id": 1, "queue": 4}, stats=True)
 
     def test_stress_port_stop_start(self):
         """
-- 
1.8.3.1


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

* Re: [dts] [PATCH V1 1/2] test_plans/iavf_fdir: replace rules with less consumption TCAM rule
  2021-08-31  3:27 [dts] [PATCH V1 1/2] test_plans/iavf_fdir: replace rules with less consumption TCAM rule Jiale Song
  2021-08-31  3:27 ` [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption of TCAM rule in suite Jiale Song
@ 2021-09-01  2:47 ` Peng, Yuan
  1 sibling, 0 replies; 6+ messages in thread
From: Peng, Yuan @ 2021-09-01  2:47 UTC (permalink / raw)
  To: Jiale, SongX, dts

Acked-by Peng, Yuan <yuan.peng@intel.com>

-----Original Message-----
From: Jiale, SongX <songx.jiale@intel.com> 
Sent: Tuesday, August 31, 2021 11:28 AM
To: dts@dpdk.org
Cc: Peng, Yuan <yuan.peng@intel.com>; Jiale, SongX <songx.jiale@intel.com>
Subject: [dts] [PATCH V1 1/2] test_plans/iavf_fdir: replace rules with less consumption TCAM rule

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

* Re: [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption of TCAM rule in suite
  2021-08-31  3:27 ` [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption of TCAM rule in suite Jiale Song
@ 2021-09-01  2:48   ` Peng, Yuan
  2021-09-29  3:20     ` Tu, Lijuan
  2021-09-29  3:29   ` Tu, Lijuan
  1 sibling, 1 reply; 6+ messages in thread
From: Peng, Yuan @ 2021-09-01  2:48 UTC (permalink / raw)
  To: Jiale, SongX, dts

Acked-by Peng, Yuan <yuan.peng@intel.com>

-----Original Message-----
From: Jiale, SongX <songx.jiale@intel.com> 
Sent: Tuesday, August 31, 2021 11:28 AM
To: dts@dpdk.org
Cc: Peng, Yuan <yuan.peng@intel.com>; Jiale, SongX <songx.jiale@intel.com>
Subject: [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption of TCAM rule in suite

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

* Re: [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption of TCAM rule in suite
  2021-09-01  2:48   ` Peng, Yuan
@ 2021-09-29  3:20     ` Tu, Lijuan
  0 siblings, 0 replies; 6+ messages in thread
From: Tu, Lijuan @ 2021-09-29  3:20 UTC (permalink / raw)
  To: Peng, Yuan, Jiale, SongX, dts



> -----Original Message-----
> From: dts <dts-bounces@dpdk.org> On Behalf Of Peng, Yuan
> Sent: 2021年9月1日 10:48
> To: Jiale, SongX <songx.jiale@intel.com>; dts@dpdk.org
> Subject: Re: [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less
> consumption of TCAM rule in suite
> 
> Acked-by Peng, Yuan <yuan.peng@intel.com>
> 
> -----Original Message-----
> From: Jiale, SongX <songx.jiale@intel.com>
> Sent: Tuesday, August 31, 2021 11:28 AM
> To: dts@dpdk.org
> Cc: Peng, Yuan <yuan.peng@intel.com>; Jiale, SongX <songx.jiale@intel.com>
> Subject: [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption
> of TCAM rule in suite

Applied, thanks

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

* Re: [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption of TCAM rule in suite
  2021-08-31  3:27 ` [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption of TCAM rule in suite Jiale Song
  2021-09-01  2:48   ` Peng, Yuan
@ 2021-09-29  3:29   ` Tu, Lijuan
  1 sibling, 0 replies; 6+ messages in thread
From: Tu, Lijuan @ 2021-09-29  3:29 UTC (permalink / raw)
  To: Jiale, SongX, dts; +Cc: Peng, Yuan, Jiale, SongX

> -----Original Message-----
> From: dts <dts-bounces@dpdk.org> On Behalf Of Jiale Song
> Sent: 2021年8月31日 11:28
> To: dts@dpdk.org
> Cc: Peng, Yuan <yuan.peng@intel.com>; Jiale, SongX <songx.jiale@intel.com>
> Subject: [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption
> of TCAM rule in suite
> 
> modify the suite according to the testplan
> 
> Signed-off-by: Jiale Song <songx.jiale@intel.com>

Sorry, apply failed, could you please rework your patches on latest dts.

CONFLICT (content): Merge conflict in test_plans/iavf_fdir_test_plan.rst

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

end of thread, other threads:[~2021-09-29  3:29 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-31  3:27 [dts] [PATCH V1 1/2] test_plans/iavf_fdir: replace rules with less consumption TCAM rule Jiale Song
2021-08-31  3:27 ` [dts] [PATCH V1 2/2] tests/iavf_fdir: create rules with less consumption of TCAM rule in suite Jiale Song
2021-09-01  2:48   ` Peng, Yuan
2021-09-29  3:20     ` Tu, Lijuan
2021-09-29  3:29   ` Tu, Lijuan
2021-09-01  2:47 ` [dts] [PATCH V1 1/2] test_plans/iavf_fdir: replace rules with less consumption TCAM rule Peng, Yuan

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).