From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f175.google.com (mail-wr0-f175.google.com [209.85.128.175]) by dpdk.org (Postfix) with ESMTP id E995A1CF92 for ; Fri, 6 Apr 2018 14:20:28 +0200 (CEST) Received: by mail-wr0-f175.google.com with SMTP id s12so1575787wrc.8 for ; Fri, 06 Apr 2018 05:20:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=07a4slacJ+iaZwLJzyu0MT/WtxYXsJA103NUdXfrZdk=; b=lJRG9KX6almN+1tF/yAOAdz+8F6CF+vRLdEGCGJ6KEFjceuHD/LTFC5bqcXW/YEmcc V5Z6W6oxKXvU7MqIIDcb6Kr6t7JacGqpkBVujuFxU/t4esKCpB2YAgEWQ9A6/ZlKkT/k +k75MN3P63wIuqixH6kCBpBVEhoov+hy2BVUVfvLKQY7tpKBFgxrxKb4FSsuY5ynUqxX XtrWrBqMdnqpMkTrzFKDApV58281LFs0FBrCDZnVnpfS0qqn+dexdFay7jGQNDMf5UF+ ig3p5fFiMwO5qV5HWN0n5A+1sKIRmNiG4oiENwaGuqbQIefvVgtiglQhcVfDKrirLjZv KXDA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=07a4slacJ+iaZwLJzyu0MT/WtxYXsJA103NUdXfrZdk=; b=GVQ3B5yaaj+vyooSZUljjCj+WzRQGkO+p0G5kh7Jg/o0a0fw4P+GxbJlBWyG11D5me kIyrAcuOkDfsYNN4xvZInunIJHimR9cBJ9UCs4FQ3wh4l99ry8PYawo449KkX6LIGJSS cs4RGKpX4JItul0WpC/NgiNzZz933w1Z3ZvP3rsYOKp6030sl3Gd6sT20ftDsSa3vha2 hsoRqxBk2elNqJWCyRBXwBaEt+ckW1zFZjvcikk+LOA7C1wFhlCf9vJgl5+Epb6/VdpT j6TAeaOBytrV0enNIG0wcLQ1qg16o9Odsiggys5CmVRnYsuSfs+zlHlBy5TsvEAr2+/+ D8ow== X-Gm-Message-State: AElRT7G4JRXQkRLcH/5Farda+nC3WpVFr+UHla5g1YIzx5uo75lWK8q1 pFaV4+XA6yOBsePDDLH8sjA4/g== X-Google-Smtp-Source: AIpwx4992FsNCUMi3vnQsPYynib9w5nxGoa+gh/eRPNrsAkHO5CUpdS3zWkVwWdW4lKSA04O7merZQ== X-Received: by 10.223.134.4 with SMTP id 4mr18726538wrv.230.1523017228570; Fri, 06 Apr 2018 05:20:28 -0700 (PDT) Received: from 6wind.com (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id 6sm5612106wmd.40.2018.04.06.05.20.27 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 06 Apr 2018 05:20:27 -0700 (PDT) Date: Fri, 6 Apr 2018 14:20:12 +0200 From: Adrien Mazarguil To: Thomas Monjalon Cc: Declan Doherty , dev@dpdk.org, Alex Rosenbaum , Ferruh Yigit , Shahaf Shuler , Qi Zhang , Alejandro Lucero , Andrew Rybchenko , Mohammad Abdul Awal , Remy Horton , John McNamara , Rony Efraim , Jingjing Wu , Wenzhuo Lu , Yuanhan Liu , Bruce Richardson Message-ID: <20180406122012.GQ4957@6wind.com> References: <20180405135148.16388-1-declan.doherty@intel.com> <20180405135148.16388-5-declan.doherty@intel.com> <2392634.y0Dprd7BRi@xps> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2392634.y0Dprd7BRi@xps> Subject: Re: [dpdk-dev] [PATCH v2 4/4] ethdev: Add metadata flow and action items support X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 Apr 2018 12:20:29 -0000 On Thu, Apr 05, 2018 at 06:49:32PM +0200, Thomas Monjalon wrote: > 05/04/2018 15:51, Declan Doherty: > > +struct rte_flow_item_metadata { > > + uint32_t id; /**< field identifier */ > > + uint32_t size; /**< field size */ > > + uint8_t bytes[]; /**< field value */ > > +}; > > Spotted C99 syntax of flexible array. > Are we OK with all supported compilers? I also thought they were a good idea at first but got rid of them in rte_flow [1] for the following reasons: - Not valid/standard C++. - Can't be statically initialized. Both can be overcome by relying on compiler extensions, however their use should be restricted to a minimum in public APIs for portability reasons. [1] http://dpdk.org/ml/archives/dev/2018-April/095307.html -- Adrien Mazarguil 6WIND