[dts] [PATCH] TestSuite_rss_to_rte_flow.py: Adding priority to rules to avoid overlapping in cavium_a063

nareddy at marvell.com nareddy at marvell.com
Thu Oct 31 07:22:20 CET 2019


From: Praneeth Reddy <nareddy at marvell.com>

According to RTE FLow spec, if we add the overlapping rules with same priority, behavior is unknown
So added priority for each rule

Signed-off-by: Praneeth Reddy <nareddy at marvell.com>
---
 tests/TestSuite_rss_to_rte_flow.py | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/tests/TestSuite_rss_to_rte_flow.py b/tests/TestSuite_rss_to_rte_flow.py
index 1198c3e..e745e14 100644
--- a/tests/TestSuite_rss_to_rte_flow.py
+++ b/tests/TestSuite_rss_to_rte_flow.py
@@ -538,8 +538,12 @@ class TestRSS_to_Rteflow(TestCase):
         time.sleep(2)
 
         # Create a rss queue rule
-        self.dut.send_expect(
-            "flow create 0 ingress pattern end actions rss types udp end queues 3 4 5 end / end", "created")
+        if (self.nic in ["cavium_a063", "cavium_a064"]):
+            self.dut.send_expect(
+                "flow create 0 ingress priority 2 pattern end actions rss types udp end queues 3 4 5 end / end", "created")
+        else:
+            self.dut.send_expect(
+                "flow create 0 ingress pattern end actions rss types udp end queues 3 4 5 end / end", "created")
         # send the packets and verify the results
         rss_queue = ["3", "4", "5"]
         self.send_and_check(self.pkt2, rss_queue)
@@ -551,6 +555,10 @@ class TestRSS_to_Rteflow(TestCase):
             rss_queue = ["1"]
             pkt = "Ether(dst='%s')/IP(src='10.0.0.1',dst='192.168.0.2',proto=6)/UDP(dport=50, sport=50)/('X'*48)" % self.pf_mac
             self.send_and_check(pkt, rss_queue)
+        elif (self.nic in ["cavium_a063", "cavium_a064"]):
+            # Create a flow director rule
+            self.dut.send_expect(
+                "flow create 0 ingress priority 1 pattern eth / ipv4 src is 10.0.0.1 dst is 192.168.0.2 / udp src is 50 dst is 50 / end actions queue index 1 / end", "created")
         else:
             # Create a flow director rule
             self.dut.send_expect(
-- 
1.8.3.1



More information about the dts mailing list