From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tiwei Bie Subject: Re: [PATCH] net/vhost: convert to new Rx offload API Date: Tue, 22 May 2018 19:53:57 +0800 Message-ID: <20180522115357.GA24273@debian> References: <20180522113639.32233-1-maxime.coquelin@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Cc: dev@dpdk.org, ferruh.yigit@intel.com To: Maxime Coquelin Return-path: Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id 330662BF4 for ; Tue, 22 May 2018 13:53:38 +0200 (CEST) Content-Disposition: inline In-Reply-To: <20180522113639.32233-1-maxime.coquelin@redhat.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Tue, May 22, 2018 at 01:36:39PM +0200, Maxime Coquelin wrote: > Signed-off-by: Maxime Coquelin > --- > drivers/net/vhost/rte_eth_vhost.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/net/vhost/rte_eth_vhost.c b/drivers/net/vhost/rte_eth_vhost.c > index f473bbbb3..aadb2327c 100644 > --- a/drivers/net/vhost/rte_eth_vhost.c > +++ b/drivers/net/vhost/rte_eth_vhost.c > @@ -491,9 +491,9 @@ eth_dev_configure(struct rte_eth_dev *dev __rte_unused) > struct pmd_internal *internal = dev->data->dev_private; > const struct rte_eth_rxmode *rxmode = &dev->data->dev_conf.rxmode; > > - internal->vlan_strip = rxmode->hw_vlan_strip; > + internal->vlan_strip = !!(rxmode->offloads & DEV_RX_OFFLOAD_VLAN_STRIP); > > - if (rxmode->hw_vlan_filter) > + if (rxmode->offloads & DEV_RX_OFFLOAD_VLAN_FILTER) > VHOST_LOG(WARNING, > "vhost(%s): vlan filtering not available\n", > internal->dev_name); To better align with the new offload API, I think we also need to announce those features in dev_infos_get. Best regards, Tiwei Bie