From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id BD95A8E87 for ; Thu, 21 Jan 2016 03:57:09 +0100 (CET) Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga101.fm.intel.com with ESMTP; 20 Jan 2016 18:57:08 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.22,323,1449561600"; d="scan'208";a="33330497" Received: from shvmail01.sh.intel.com ([10.239.29.42]) by fmsmga004.fm.intel.com with ESMTP; 20 Jan 2016 18:57:08 -0800 Received: from shecgisg003.sh.intel.com (shecgisg003.sh.intel.com [10.239.29.90]) by shvmail01.sh.intel.com with ESMTP id u0L2v610031111; Thu, 21 Jan 2016 10:57:06 +0800 Received: from shecgisg003.sh.intel.com (localhost [127.0.0.1]) by shecgisg003.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP id u0L2v3kU019085; Thu, 21 Jan 2016 10:57:05 +0800 Received: (from yliu84x@localhost) by shecgisg003.sh.intel.com (8.13.6/8.13.6/Submit) id u0L2v3Be019081; Thu, 21 Jan 2016 10:57:03 +0800 From: Yong Liu To: dts@dpdk.org Date: Thu, 21 Jan 2016 10:57:00 +0800 Message-Id: <1453345020-19042-2-git-send-email-yong.liu@intel.com> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1453345020-19042-1-git-send-email-yong.liu@intel.com> References: <1453345020-19042-1-git-send-email-yong.liu@intel.com> Subject: [dts] [PATCH 2/2] framework dut: fix hugepage not allocate to all numa 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: , X-List-Received-Date: Thu, 21 Jan 2016 02:57:10 -0000 From: Marvin Liu When numa allocate only to numa 0, testpmd may failed to startup for NIC attached to numa 1. Signed-off-by: Marvin Liu diff --git a/framework/dut.py b/framework/dut.py index afb5204..bd437cb 100644 --- a/framework/dut.py +++ b/framework/dut.py @@ -289,21 +289,27 @@ class Dut(Crb): return hugepages_size = self.send_expect("awk '/Hugepagesize/ {print $2}' /proc/meminfo", "# ") total_huge_pages = self.get_total_huge_pages() + force_socket = False if int(hugepages_size) < (1024 * 1024): if self.architecture == "x86_64": arch_huge_pages = hugepages if hugepages > 0 else 4096 elif self.architecture == "i686": arch_huge_pages = hugepages if hugepages > 0 else 512 + force_socket = True # set huge pagesize for x86_x32 abi target elif self.architecture == "x86_x32": arch_huge_pages = hugepages if hugepages > 0 else 256 + force_socket = True if total_huge_pages != arch_huge_pages: - # before all hugepage average distribution by all socket, - # but sometimes crete mbuf pool on socket 0 failed when setup testpmd, + # before all hugepage average distribution by all socket, + # but sometimes create mbuf pool on socket 0 failed when setup testpmd, # so set all huge page on socket 0 - self.set_huge_pages(arch_huge_pages, 0) + if force_socket: + self.set_huge_pages(arch_huge_pages, 0) + else: + self.set_huge_pages(arch_huge_pages) self.mount_huge_pages() self.hugepage_path = self.strip_hugepage_path() -- 2.4.3