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 4F386A00C4; Fri, 24 Apr 2020 04:54:15 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 460831C237; Fri, 24 Apr 2020 04:54:15 +0200 (CEST) Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by dpdk.org (Postfix) with ESMTP id DA9431C22C for ; Fri, 24 Apr 2020 04:54:12 +0200 (CEST) IronPort-SDR: yky4NSIwjsEfTXlGtvdyv8XGGjlEIT6yL3VeCjIw0qBuaNZlIf/MqOqonQ9AI28FOSrflfFdZx jU873jykpnoA== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Apr 2020 19:54:11 -0700 IronPort-SDR: aC01AX/dfbGhvQ5e9UBPmLOASIMcs4NSmhFqPvOYRdQ330fEMCN7vic/s1n13ffYBU88OHz6Bl 7C4qeBbTY7RQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,310,1583222400"; d="scan'208";a="274454407" Received: from unknown (HELO cb-dts.sh.intel.com) ([10.240.183.58]) by orsmga002.jf.intel.com with ESMTP; 23 Apr 2020 19:54:10 -0700 From: ChenBo To: dts@dpdk.org Cc: "ChenBo" Date: Fri, 24 Apr 2020 10:49:36 +0800 Message-Id: <20200424024936.3358-1-box.c.chen@intel.com> X-Mailer: git-send-email 2.17.1 Subject: [dts] [PATCH V1] framework: accurate get cpu info 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" From: "ChenBo" Accurate get cpu info Signed-off-by: ChenBo --- framework/crb.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/framework/crb.py b/framework/crb.py index cf0493f..a47de2c 100644 --- a/framework/crb.py +++ b/framework/crb.py @@ -644,7 +644,8 @@ class Crb(object): "lscpu -p=CPU,CORE,SOCKET,NODE|grep -v \#", "#", alt_session=True) - cpuinfo = cpuinfo.split() + #cpuinfo = cpuinfo.split() + cpuinfo = [i for i in cpuinfo.split() if re.match("^\d.+", i)] # haswell cpu on cottonwood core id not correct # need additional coremap for haswell cpu core_id = 0 -- 2.17.1