From mboxrd@z Thu Jan 1 00:00:00 1970 From: Adrien Mazarguil Subject: Re: [PATCH v2 3/6] librte_ether: initialise IPv4 protocol mask for rte_flow Date: Wed, 30 Aug 2017 14:39:12 +0200 Message-ID: <20170830123912.GJ4301@6wind.com> References: <1503496275-27492-1-git-send-email-bernard.iremonger@intel.com> <1503677438-27591-4-git-send-email-bernard.iremonger@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: dev@dpdk.org, ferruh.yigit@intel.com, konstantin.ananyev@intel.com, cristian.dumitrescu@intel.com To: Bernard Iremonger Return-path: Received: from mail-wm0-f51.google.com (mail-wm0-f51.google.com [74.125.82.51]) by dpdk.org (Postfix) with ESMTP id BB82E2BF3 for ; Wed, 30 Aug 2017 14:39:23 +0200 (CEST) Received: by mail-wm0-f51.google.com with SMTP id r202so1321540wmd.0 for ; Wed, 30 Aug 2017 05:39:23 -0700 (PDT) Content-Disposition: inline In-Reply-To: <1503677438-27591-4-git-send-email-bernard.iremonger@intel.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" Hi Bernard, On Fri, Aug 25, 2017 at 05:10:35PM +0100, Bernard Iremonger wrote: > Initialise the next_proto_id mask in the default mask for > rte_flow_item_type_ipv4. > > Signed-off-by: Bernard Iremonger > --- > lib/librte_ether/rte_flow.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/lib/librte_ether/rte_flow.h b/lib/librte_ether/rte_flow.h > index bba6169..59c42fa 100644 > --- a/lib/librte_ether/rte_flow.h > +++ b/lib/librte_ether/rte_flow.h > @@ -489,6 +489,7 @@ struct rte_flow_item_ipv4 { > #ifndef __cplusplus > static const struct rte_flow_item_ipv4 rte_flow_item_ipv4_mask = { > .hdr = { > + .next_proto_id = 0xff, Please don't change the default mask to cover this field as it means all rte_flow-based applications that do not provide a specific mask (.mask == NULL) have to always set this field to some valid value. This is not a convenient default behavior. > .src_addr = RTE_BE32(0xffffffff), > .dst_addr = RTE_BE32(0xffffffff), > }, > -- > 1.9.1 > I'll have to NACK this change. The example application should define its own mask if next_proto_id must be always set. -- Adrien Mazarguil 6WIND