From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id C59EEA0521; Wed, 4 Nov 2020 10:22:44 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id B9D62C8B2; Wed, 4 Nov 2020 10:22:43 +0100 (CET) Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by dpdk.org (Postfix) with ESMTP id 63F1CC864 for ; Wed, 4 Nov 2020 10:22:41 +0100 (CET) IronPort-SDR: k740Ahi8pdMX5VjlXLWgG0pJl8KILZAgP+DufY5Mg2ls351zkiwZyeorTOjkwkW200wsuhG+J2 ygxNY/CD3U9A== X-IronPort-AV: E=McAfee;i="6000,8403,9794"; a="230815954" X-IronPort-AV: E=Sophos;i="5.77,450,1596524400"; d="scan'208";a="230815954" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Nov 2020 01:22:41 -0800 IronPort-SDR: QaA7zn6o33YiIEPBKSNygJGZo+3Os8qBy3PLvO3kH8qqC4+h+isqbHJp5Hg68Ryk3qX8W5dYq6 1LDNB8pMuDgg== X-IronPort-AV: E=Sophos;i="5.77,450,1596524400"; d="scan'208";a="538844446" Received: from unknown (HELO localhost.localdomain) ([10.240.183.55]) by orsmga005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Nov 2020 01:22:39 -0800 From: Haiyang Zhao To: Lijuan.Tu@intel.com, dts@dpdk.org Cc: Haiyang Zhao Date: Wed, 4 Nov 2020 17:21:07 +0800 Message-Id: <20201104092108.13778-3-haiyangx.zhao@intel.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20201104092108.13778-1-haiyangx.zhao@intel.com> References: <20201104092108.13778-1-haiyangx.zhao@intel.com> Subject: [dts] [PATCH V1 2/3] framework/project_dpdk: add check if cpu support avx512 X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org Sender: "dts" *.add warning info and reset rx_mode to default if DUT cpu do not support avx512. Signed-off-by: Haiyang Zhao --- 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