From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f177.google.com (mail-wr0-f177.google.com [209.85.128.177]) by dpdk.org (Postfix) with ESMTP id 6A89114EC for ; Mon, 6 Feb 2017 11:28:41 +0100 (CET) Received: by mail-wr0-f177.google.com with SMTP id i10so21215690wrb.0 for ; Mon, 06 Feb 2017 02:28:41 -0800 (PST) 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:in-reply-to:references :mime-version:content-transfer-encoding; bh=0Ulk3WX7VihqRAKr5SZZORNNTtz8FS+XHzdkEZqzeYc=; b=xcRdc5lip6GWMACIcCbG28E3CALFev0HZWdhDnsOjge7vPr4OV29hSoWZvoNOSomol KFgyTlnDPIkuLLjE6xM3GmTK7OCE5UTIMeJTamrDpFEtMBxT4ZnUXcZzIrkjUf058HF5 KNaoJ2MFNt90AFEz0lj3T2GIHwqiAY2NNFlocPwvvg9qJc05WyVnixbgHmEl9Y5by223 H4UFU47w1GzAN+GYYbpAYHxZ+5izSNnjxlIl2jC95mXKHpZNCbBrIBMeA0gAxG4O6HZb GzPwPUwdHzOGz/L0T736woMr1HCbh7m6Q2pf7AQCKwAMoECzMgS3QflXsKm39r2rOgeB Nonw== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=0Ulk3WX7VihqRAKr5SZZORNNTtz8FS+XHzdkEZqzeYc=; b=FFpXqeqQZER9aCkSOCGmZtyqHYnQrQDalD5rEjouk5SnxuHLwVbNUdhYsbD0a/idu9 WSVxE5E8WYOR+i9fMY/G+KL1XmOYnynznc2FyePmPbZ49x6OsuDlLp3sKsuReJZY4UVO t6MHxl4a3Be+mt19BQuMN1d7Zz3aruq+rS8MUav2flCgkjrCIXoBLXUk7ijeFPuBhB90 qTUZEAF32s4JVQ2F1nTK+B5+XuLoBUflDXFzcBA5OM6AGZkgYGDsclvX+UlqUhoqiXKe zT5iupQbq4KpZQnr91clFnopg6WOGg+Ho556Rs/jVum3psstzK/mL+a4zBWLMkbkO6TB nzJQ== X-Gm-Message-State: AIkVDXL67wW9mEX4kmnlsiSae8cRoidxFSRnssrGal1IcMsl70L5BdPipSsG4nVRnPNCjyWS X-Received: by 10.223.155.140 with SMTP id d12mr8221926wrc.143.1486376920944; Mon, 06 Feb 2017 02:28:40 -0800 (PST) Received: from platinum (2a01cb0c03c651000226b0fffeed02fc.ipv6.abo.wanadoo.fr. [2a01:cb0c:3c6:5100:226:b0ff:feed:2fc]) by smtp.gmail.com with ESMTPSA id z67sm578548wrb.49.2017.02.06.02.28.40 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 06 Feb 2017 02:28:40 -0800 (PST) Date: Mon, 6 Feb 2017 11:28:38 +0100 From: Olivier Matz To: "Wu, Jingjing" Cc: "Yigit, Ferruh" , "dev@dpdk.org" , "Zhang, Helin" Message-ID: <20170206112838.528745e8@platinum> In-Reply-To: <9BB6961774997848B5B42BEC655768F810CD4D95@SHSMSX103.ccr.corp.intel.com> References: <1485258650-86193-1-git-send-email-jingjing.wu@intel.com> <1486179375-133509-1-git-send-email-jingjing.wu@intel.com> <1486179375-133509-3-git-send-email-jingjing.wu@intel.com> <9BB6961774997848B5B42BEC655768F810CD4D95@SHSMSX103.ccr.corp.intel.com> X-Mailer: Claws Mail 3.14.1 (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v2 2/5] net/i40e: fix bitmask of supported Tx flags 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: Mon, 06 Feb 2017 10:28:41 -0000 On Mon, 6 Feb 2017 03:02:12 +0000, "Wu, Jingjing" wrote: > > > > Functionally will be same, but what do you think about following, > > to make easy to see what define adds: > > > > +#define I40E_TX_OFFLOAD_MASK ( \ > > + PKT_TX_IP_CKSUM | \ > > + PKT_TX_IPV4 | \ > > + PKT_TX_IPV6 | \ > > + PKT_TX_L4_MASK | \ > > + PKT_TX_OUTER_IP_CKSUM | \ > > + PKT_TX_OUTER_IPV4 | \ > > + PKT_TX_OUTER_IPV6 | \ > > > > +#ifdef RTE_LIBRTE_IEEE1588 > > + PKT_TX_IEEE1588_TMST | \ > > +#endif > > > > + PKT_TX_TCP_SEG | \ > > + PKT_TX_QINQ_PKT | \ > > + PKT_TX_VLAN_PKT | \ > > + PKT_TX_TUNNEL_MASK) > > > > Hi, Ferruh > > As I know, the above change is incorrect in C code. We cannot use > #ifdef #endif inside #define > > Thanks > Jingjing You can do: #ifdef RTE_LIBRTE_IEEE1588 #define I40_TX_IEEE1588_TMST PKT_TX_IEEE1588_TMST #else #define I40_TX_IEEE1588_TMST 0 #endif #define I40E_TX_OFFLOAD_MASK ( \ I40_TX_IEEE1588_TMST | \ PKT_TX_IP_CKSUM | \ ... Regards, Olivier