test suite reviews and discussions
 help / color / mirror / Atom feed
From: Tadhg Kearney <tadhg.kearney@intel.com>
To: dts@dpdk.org
Cc: reshma.pattan@intel.com, Tadhg Kearney <tadhg.kearney@intel.com>
Subject: [dts][V3 2/2] tests/*: Remove old DPDK flags from power tests
Date: Tue, 29 Mar 2022 10:24:08 +0000	[thread overview]
Message-ID: <20220329102408.1137392-3-tadhg.kearney@intel.com> (raw)
In-Reply-To: <20220329102408.1137392-1-tadhg.kearney@intel.com>

* CONFIG_RTE_LIBRTE_I40E_PMD, CONFIG_RTE_LIBRTE_POWER + _CONFIG option do not exist anymore
* Telemetry is built by default + _LIBRTE_ option also does not exist anymore

Signed-off-by: Tadhg Kearney <tadhg.kearney@intel.com>
---
 tests/TestSuite_power_branch_ratio.py | 39 +--------------------------
 tests/TestSuite_power_telemetry.py    | 18 +------------
 2 files changed, 2 insertions(+), 55 deletions(-)

diff --git a/tests/TestSuite_power_branch_ratio.py b/tests/TestSuite_power_branch_ratio.py
index deb271e0..a2c28478 100644
--- a/tests/TestSuite_power_branch_ratio.py
+++ b/tests/TestSuite_power_branch_ratio.py
@@ -44,8 +44,7 @@ from pprint import pformat
 from framework.exception import VerifyFailure
 from framework.packet import Packet
 from framework.pktgen import TRANSMIT_CONT
-from framework.qemu_libvirt import LibvirtKvm
-from framework.settings import HEADER_SIZE, HOST_BUILD_TYPE_SETTING, load_global_setting
+from framework.settings import HEADER_SIZE
 from framework.test_case import TestCase
 from framework.utils import create_mask as dts_create_mask
 
@@ -227,27 +226,6 @@ class TestPowerBranchRatio(TestCase):
 
         return result
 
-    @property
-    def compile_switch(self):
-        sw_table = [
-            "CONFIG_RTE_LIBRTE_POWER",
-            "CONFIG_RTE_LIBRTE_POWER_DEBUG",
-        ]
-        return sw_table
-
-    def preset_compilation(self):
-        if "meson" == load_global_setting(HOST_BUILD_TYPE_SETTING):
-            compile_SWs = self.compile_switch + ["CONFIG_RTE_LIBRTE_I40E_PMD"]
-            self.dut.set_build_options(dict([(sw[7:], "y") for sw in compile_SWs]))
-        else:
-            for sw in self.compile_switch:
-                cmd = (
-                    "sed -i -e " "'s/{0}=n$/{0}=y/' " "{1}/config/common_base"
-                ).format(sw, self.target_dir)
-                self.d_a_con(cmd)
-        # re-compile dpdk source code
-        self.dut.build_install_dpdk(self.target)
-
     @contextmanager
     def restore_environment(self):
         try:
@@ -258,19 +236,6 @@ class TestPowerBranchRatio(TestCase):
                 self.restore_port_drv()
             except Exception as e:
                 self.logger.error(traceback.format_exc())
-            # restore compilation
-            if "meson" == load_global_setting(HOST_BUILD_TYPE_SETTING):
-                self.dut.set_build_options(
-                    dict([(sw[7:], "n") for sw in self.compile_switch])
-                )
-            else:
-                for sw in self.compile_switch:
-                    cmd = (
-                        "sed -i -e " "'s/{0}=y$/{0}=n/' " "{1}/config/common_base"
-                    ).format(sw, self.target_dir)
-                    self.d_a_con(cmd)
-            # re-compile dpdk source code
-            self.dut.build_install_dpdk(self.target)
 
     def restore_port_drv(self):
         driver = self.drivername
@@ -532,8 +497,6 @@ class TestPowerBranchRatio(TestCase):
         # modprobe msr module to let the application can get the CPU HW info
         self.d_a_con("modprobe msr")
         self.d_a_con("cpupower frequency-set -g userspace > /dev/null 2>&1")
-        # compile
-        self.preset_compilation()
         # init binary
         self.init_vm_power_mgr()
         self.init_testpmd()
diff --git a/tests/TestSuite_power_telemetry.py b/tests/TestSuite_power_telemetry.py
index afb55262..39acdef2 100644
--- a/tests/TestSuite_power_telemetry.py
+++ b/tests/TestSuite_power_telemetry.py
@@ -45,7 +45,7 @@ from pprint import pformat
 from framework.exception import VerifyFailure
 from framework.packet import Packet
 from framework.pktgen import TRANSMIT_CONT
-from framework.settings import HEADER_SIZE, HOST_BUILD_TYPE_SETTING, load_global_setting
+from framework.settings import HEADER_SIZE
 from framework.test_case import TestCase
 from framework.utils import create_mask as dts_create_mask
 
@@ -125,20 +125,6 @@ class TestPowerTelemetry(TestCase):
 
         return result
 
-    def preset_compilation(self):
-        if self.dut.skip_setup:
-            return
-        SW = "CONFIG_RTE_LIBRTE_TELEMETRY"
-        if "meson" == load_global_setting(HOST_BUILD_TYPE_SETTING):
-            self.dut.set_build_options({SW[7:]: "y"})
-        else:
-            cmd = "sed -i -e 's/{0}=n$/{0}=y/' {1}/config/common_base".format(
-                SW, self.target_dir
-            )
-            self.d_a_con(cmd)
-        # re-compile dpdk source code
-        self.dut.build_install_dpdk(self.target)
-
     def prepare_binary(self, name):
         example_dir = "examples/" + name
         out = self.dut.build_dpdk_apps("./" + example_dir)
@@ -445,8 +431,6 @@ class TestPowerTelemetry(TestCase):
 
     def preset_test_environment(self):
         self.is_l3fwd_on = None
-        # open compile switch and re-compile target source code
-        self.preset_compilation()
         # init binary
         self.init_l3fwd_power()
         self.init_telemetry()
-- 
2.25.1


  parent reply	other threads:[~2022-03-29 10:24 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-29 10:24 [dts][V3 0/2] " Tadhg Kearney
2022-03-29 10:24 ` [dts][V3 1/2] test_plans/*: Remove old DPDK RTE " Tadhg Kearney
2022-03-29 10:24 ` Tadhg Kearney [this message]
2022-03-30  7:23   ` [dts][V3 2/2] tests/*: Remove old DPDK " Dong, JunX
2022-03-31  6:31   ` lijuan.tu
2022-03-30  7:19 ` [dts][V3 0/2] " Dong, JunX

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=20220329102408.1137392-3-tadhg.kearney@intel.com \
    --to=tadhg.kearney@intel.com \
    --cc=dts@dpdk.org \
    --cc=reshma.pattan@intel.com \
    /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).