From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id BFE586A68 for ; Thu, 9 Jun 2016 06:43:47 +0200 (CEST) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga103.fm.intel.com with ESMTP; 08 Jun 2016 21:43:46 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.26,442,1459839600"; d="scan'208";a="983866539" Received: from yliu-dev.sh.intel.com (HELO yliu-dev) ([10.239.67.162]) by fmsmga001.fm.intel.com with ESMTP; 08 Jun 2016 21:43:45 -0700 Date: Thu, 9 Jun 2016 12:45:00 +0800 From: Yuanhan Liu To: Rich Lane Cc: dev@dpdk.org, "huawei.xie" , Thomas Monjalon , Panu Matilainen , Traynor Kevin , Tetsuya Mukawa Message-ID: <20160609044500.GK10038@yliu-dev.sh.intel.com> References: <1463117111-27050-1-git-send-email-yuanhan.liu@linux.intel.com> <1465271530-27878-1-git-send-email-yuanhan.liu@linux.intel.com> <1465271530-27878-9-git-send-email-yuanhan.liu@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) Subject: Re: [dpdk-dev] [PATCH v3 08/20] vhost: introduce new API to export numa node X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jun 2016 04:43:48 -0000 On Wed, Jun 08, 2016 at 02:51:33PM -0700, Rich Lane wrote: > On Mon, Jun 6, 2016 at 8:51 PM, Yuanhan Liu > wrote: > > @@ -248,14 +248,9 @@ new_device(struct virtio_net *dev) >         internal = eth_dev->data->dev_private; > >  #ifdef RTE_LIBRTE_VHOST_NUMA > -       ret  = get_mempolicy(&newnode, NULL, 0, dev, > -                       MPOL_F_NODE | MPOL_F_ADDR); > -       if (ret < 0) { > -               RTE_LOG(ERR, PMD, "Unknown numa node\n"); > -               return -1; > -       } > - > -       eth_dev->data->numa_node = newnode; > +       newnode = rte_vhost_get_numa_node(dev->vid); > +       if (newnode > 0) > > > Should be "newnode >= 0".  Nice catch! Thanks. --yliu