test suite reviews and discussions
 help / color / mirror / Atom feed
From: "zhiwei.he" <zhiwei.he@intel.com>
To: dts@dpdk.org
Cc: "zhiwei.he" <zhiwei.he@intel.com>
Subject: [dts] [PATCH] tests/TestSuite_vxlan: Enable CVL25Gand100g NIC to support VXLAN case
Date: Thu, 29 Aug 2019 13:46:28 +0800	[thread overview]
Message-ID: <1567057588-38070-1-git-send-email-zhiwei.he@intel.com> (raw)

From: "zhiwei.he" <zhiwei.he@intel.com>

Signed-off-by: zhiwei.he <zhiwei.he@intel.com>
---
 tests/TestSuite_vxlan.py | 76 +++++++++++++++++++++++++++++-------------------
 1 file changed, 46 insertions(+), 30 deletions(-)

diff --git a/tests/TestSuite_vxlan.py b/tests/TestSuite_vxlan.py
index ecc3f3a..3bc8071 100644
--- a/tests/TestSuite_vxlan.py
+++ b/tests/TestSuite_vxlan.py
@@ -266,6 +266,8 @@ class TestVxlan(TestCase, IxiaPacketGenerator):
             self.compile_switch = 'CONFIG_RTE_LIBRTE_I40E_INC_VECTOR'
         elif self.nic in ["sageville", "sagepond"]:
             self.compile_switch = 'CONFIG_RTE_IXGBE_INC_VECTOR'
+        elif self.nic in ["columbiaville_25g","columbiaville_100g"]:
+           print "CVL support default none VECTOR"
         else:
             self.verify(False, "%s not support this vxlan" % self.nic)
         # Based on h/w type, choose how many ports to use
@@ -533,13 +535,17 @@ class TestVxlan(TestCase, IxiaPacketGenerator):
         """
         verify vxlan packet detection
         """
-        out = self.dut.send_expect("cat config/common_base", "]# ", 10)
-        src_vec_model = re.findall("%s=." % self.compile_switch, out)[0][-1]
-        if src_vec_model == 'y':
-            self.dut.send_expect("sed -i -e 's/%s=.*$/" % self.compile_switch
-                                + "%s=n/' config/common_base" % self.compile_switch, "# ", 30)
-            self.dut.skip_setup = False
-            self.dut.build_install_dpdk(self.target)
+        if self.nic in ["columbiaville_25g","columbiaville_100g"]:
+           print "CVL support default none VECTOR"
+           src_vec_model = 'n'
+        else:
+           out = self.dut.send_expect("cat config/common_base", "]# ", 10)
+           src_vec_model = re.findall("%s=." % self.compile_switch, out)[0][-1]
+           if src_vec_model == 'y':
+              self.dut.send_expect("sed -i -e 's/%s=.*$/" % self.compile_switch
+                                  + "%s=n/' config/common_base" % self.compile_switch, "# ", 30)
+              self.dut.skip_setup = False
+              self.dut.build_install_dpdk(self.target)
 
         
         pmd_temp = "./%(TARGET)s/app/testpmd -c %(COREMASK)s -n " + \
@@ -571,26 +577,33 @@ class TestVxlan(TestCase, IxiaPacketGenerator):
 
         out = self.dut.send_expect("stop", "testpmd>", 10)
         self.dut.send_expect("quit", "#", 10)
-        
-        out = self.dut.send_expect("cat config/common_base", "]# ", 10)
-        dst_vec_model = re.findall("%s=." % self.compile_switch, out)[0][-1]
-        if src_vec_model != dst_vec_model:
-            self.dut.send_expect("sed -i -e 's/%s=.*$/" % self.compile_switch
-                                + "%s=%s/' config/common_base" % (self.compile_switch, src_vec_model), "# ", 30)
-            self.dut.skip_setup = False
-            self.dut.build_install_dpdk(self.target)
+        if self.nic in ["columbiaville_25g","columbiaville_100g"]:
+           print "CVL support default none VECTOR"
+           src_vec_model = 'n'
+        else:
+           out = self.dut.send_expect("cat config/common_base", "]# ", 10)
+           dst_vec_model = re.findall("%s=." % self.compile_switch, out)[0][-1]
+           if src_vec_model != dst_vec_model:
+              self.dut.send_expect("sed -i -e 's/%s=.*$/" % self.compile_switch
+                                  + "%s=%s/' config/common_base" % (self.compile_switch, src_vec_model), "# ", 30)
+              self.dut.skip_setup = False
+              self.dut.build_install_dpdk(self.target)
 
     def test_vxlan_ipv6_detect(self):
         """
         verify vxlan packet detection with ipv6 header
         """
-        out = self.dut.send_expect("cat config/common_base", "]# ", 10)
-        src_vec_model = re.findall("%s=." % self.compile_switch, out)[0][-1]
-        if src_vec_model == 'y':
-            self.dut.send_expect("sed -i -e 's/%s=.*$/" % self.compile_switch
-                                + "%s=n/' config/common_base" % self.compile_switch, "# ", 30)
-            self.dut.skip_setup = False
-            self.dut.build_install_dpdk(self.target)
+        if self.nic in ["columbiaville_25g","columbiaville_100g"]:
+           print "CVL support default none VECTOR"
+           src_vec_model = 'n'
+        else:
+           out = self.dut.send_expect("cat config/common_base", "]# ", 10)
+           src_vec_model = re.findall("%s=." % self.compile_switch, out)[0][-1]
+           if src_vec_model == 'y':
+              self.dut.send_expect("sed -i -e 's/%s=.*$/" % self.compile_switch
+                                  + "%s=n/' config/common_base" % self.compile_switch, "# ", 30)
+              self.dut.skip_setup = False
+              self.dut.build_install_dpdk(self.target)
 
         pmd_temp = "./%(TARGET)s/app/testpmd -c %(COREMASK)s -n " + \
             "%(CHANNEL)d -- -i --disable-rss --rxq=4 --txq=4" + \
@@ -625,14 +638,17 @@ class TestVxlan(TestCase, IxiaPacketGenerator):
 
         out = self.dut.send_expect("stop", "testpmd>", 10)
         self.dut.send_expect("quit", "#", 10)
-
-        out = self.dut.send_expect("cat config/common_base", "]# ", 10)
-        dst_vec_model = re.findall("%s=." % self.compile_switch, out)[0][-1]
-        if src_vec_model != dst_vec_model:
-            self.dut.send_expect("sed -i -e 's/%s=.*$/" % self.compile_switch
-                                + "%s=%s/' config/common_base" % (self.compile_switch, src_vec_model), "# ", 30)
-            self.dut.skip_setup = False
-            self.dut.build_install_dpdk(self.target)
+        if self.nic in ["columbiaville_25g","columbiaville_100g"]:
+           print "CVL support default none VECTOR"
+           src_vec_model = 'n'
+        else:
+           out = self.dut.send_expect("cat config/common_base", "]# ", 10)
+           dst_vec_model = re.findall("%s=." % self.compile_switch, out)[0][-1]
+           if src_vec_model != dst_vec_model:
+              self.dut.send_expect("sed -i -e 's/%s=.*$/" % self.compile_switch
+                                  + "%s=%s/' config/common_base" % (self.compile_switch, src_vec_model), "# ", 30)
+              self.dut.skip_setup = False
+              self.dut.build_install_dpdk(self.target)
 
     def test_vxlan_ipv4_checksum_offload(self):
         """
-- 
1.8.3.1


             reply	other threads:[~2019-08-29  5:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-29  5:46 zhiwei.he [this message]
2019-09-04  5:25 ` Tu, Lijuan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1567057588-38070-1-git-send-email-zhiwei.he@intel.com \
    --to=zhiwei.he@intel.com \
    --cc=dts@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).