From: Haiyang Zhao <haiyangx.zhao@intel.com>
To: Lijuan.Tu@intel.com, dts@dpdk.org
Cc: Haiyang Zhao <haiyangx.zhao@intel.com>
Subject: [dts] [PATCH V1 2/3] framework/project_dpdk: add check if cpu support avx512
Date: Wed, 4 Nov 2020 17:21:07 +0800 [thread overview]
Message-ID: <20201104092108.13778-3-haiyangx.zhao@intel.com> (raw)
In-Reply-To: <20201104092108.13778-1-haiyangx.zhao@intel.com>
*.add warning info and reset rx_mode to default
if DUT cpu do not support avx512.
Signed-off-by: Haiyang Zhao <haiyangx.zhao@intel.com>
---
framework/project_dpdk.py | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/framework/project_dpdk.py b/framework/project_dpdk.py
index d45ce47..1711d86 100644
--- a/framework/project_dpdk.py
+++ b/framework/project_dpdk.py
@@ -32,7 +32,7 @@
import os
import re
-from settings import NICS, load_global_setting, accepted_nic
+from settings import NICS, load_global_setting, save_global_setting, accepted_nic
from settings import DPDK_RXMODE_SETTING, HOST_DRIVER_SETTING, HOST_DRIVER_MODE_SETTING, HOST_BUILD_TYPE_SETTING
from settings import HOST_SHARED_LIB_SETTING, HOST_SHARED_LIB_PATH
from ssh_connection import SSHConnection
@@ -41,6 +41,7 @@ from dut import Dut
from tester import Tester
from logger import getLogger
from settings import IXIA, DRIVERS
+from utils import RED
class DPDKdut(Dut):
@@ -217,6 +218,12 @@ class DPDKdut(Dut):
self.set_build_options({'RTE_IXGBE_INC_VECTOR': 'n',
'RTE_LIBRTE_I40E_INC_VECTOR': 'n',
'RTE_LIBRTE_FM10K_INC_VECTOR': 'n'})
+ if mode == 'avx512':
+ out = self.send_expect('lscpu | grep avx512', '#')
+ if 'avx512f' not in out or 'no-avx512f' in out:
+ self.logger.warning(RED('*********The DUT CPU do not support AVX512 test!!!********'))
+ self.logger.warning(RED('*********Now set the rx_mode to default!!!**********'))
+ save_global_setting(DPDK_RXMODE_SETTING, 'default')
def set_package(self, pkg_name="", patch_list=[]):
self.package = pkg_name
--
2.17.1
next prev parent reply other threads:[~2020-11-04 9:22 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-04 9:21 [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes Haiyang Zhao
2020-11-04 9:21 ` [dts] [PATCH V1 1/3] framework/dts: optimize code Haiyang Zhao
2020-11-04 9:21 ` Haiyang Zhao [this message]
2020-11-04 9:21 ` [dts] [PATCH V1 3/3] framework/dut: add eal parameters for different rx_mode Haiyang Zhao
2020-11-04 9:29 ` [dts] [PATCH V1 0/3] framework: add eal paramters for different rx modes Zhao, HaiyangX
2020-11-05 2:51 ` 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=20201104092108.13778-3-haiyangx.zhao@intel.com \
--to=haiyangx.zhao@intel.com \
--cc=Lijuan.Tu@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).