From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf0-f195.google.com (mail-pf0-f195.google.com [209.85.192.195]) by dpdk.org (Postfix) with ESMTP id 83A5B1B00E for ; Thu, 14 Dec 2017 03:58:04 +0100 (CET) Received: by mail-pf0-f195.google.com with SMTP id m26so2646121pfj.11 for ; Wed, 13 Dec 2017 18:58:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=/aeRg/NkLwVpZRSBNxan/02icxju0fVAKje/6ViOsVM=; b=AJMRPIrGl7fL0lxOSLx4tXcT08grpFsCXCiiTIuBq0fGpUuWyufDHL9wqGXAkxaVMB K5BpGMSkPtUNnr7TJgmHJwpp1xw2R2NODRwu364KqWf7x3FoD1x9ju6rP0JZRfbk6Jj4 aKtN0LcEg1e9B1ytGWVdjPuZJC0u1Pq62+qcu8VAUV2rInv7iphAh4sXMe/Jrm+vwPMI DAN8euNo1TfqxNJQrH8Dye40BPcwYHCK9JZYaCtlESwihYjn2H8IDopfrf7ewVEOZF0Y jVzb5ikGcsEIxkyrsPVvaAT6SfzoJrqpdeG1OuL2PAoXwKiOuS4VxDSs4LQbnAfAecn6 kGuA== 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=/aeRg/NkLwVpZRSBNxan/02icxju0fVAKje/6ViOsVM=; b=O/cmkX2tbcOkaAl/nASI+69oYaafJzcPHUOvL5ocB+hO15BD7cW6xACo81YwbOeh/Q rAnCuvmNb3Lhy+ub67Pexv42SxLaZhpxWE+VBnyGVWXDOD2LoGvm/GYOG+0fhOKwZXxc 7Tn95P7uxlgI5pdC36A031HSjyCbRx0Vh2G/ue55CSVqMpMcIzAGKmo5o5laCjfsG9fG rtQAT7rOI+CFJ7JMTuc5sf7Wwd3dF+Ik9SeFxaTVerDyqqAB37QhfxB9zURe8JnU6UnB aoCYi9/GU0ODeUjA3WkqJpSLH3sFil1GY71pEJDilZnUQ5OU09x+tcyj4HA5J86hz3H1 fp+w== X-Gm-Message-State: AKGB3mInWYZj921hOQHMrG/9g7nKkfiwqdWnKT6H+O1aLt6FhcjYFdQg 0QdEdLoZdZ769PyQAQDeAWlWUw== X-Google-Smtp-Source: ACJfBoubaQNX5UzT+6GzzYU4Y1O/OzAkd/vIqi6dpzK02ooqGlNepRhS+ju57i9FPWZl2wLooe6ZkQ== X-Received: by 10.99.9.133 with SMTP id 127mr7009951pgj.16.1513220283693; Wed, 13 Dec 2017 18:58:03 -0800 (PST) Received: from xeon-e3 (76-14-207-240.or.wavecable.com. [76.14.207.240]) by smtp.gmail.com with ESMTPSA id r5sm4634179pgq.25.2017.12.13.18.58.03 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 13 Dec 2017 18:58:03 -0800 (PST) Date: Wed, 13 Dec 2017 18:58:01 -0800 From: Stephen Hemminger To: Jiayu Hu Cc: dev@dpdk.org, konstantin.ananyev@intel.com, jianfeng.tan@intel.com, junjie.j.chen@intel.com, john.mcnamara@intel.com, matvejchikov@gmail.com Message-ID: <20171213185801.2add4e46@xeon-e3> In-Reply-To: <1513219779-100115-3-git-send-email-jiayu.hu@intel.com> References: <1511579860-37020-1-git-send-email-jiayu.hu@intel.com> <1513219779-100115-1-git-send-email-jiayu.hu@intel.com> <1513219779-100115-3-git-send-email-jiayu.hu@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v2 2/2] gro: support VxLAN GRO 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: Thu, 14 Dec 2017 02:58:05 -0000 On Thu, 14 Dec 2017 10:49:39 +0800 Jiayu Hu wrote: > + > +static inline int > +is_same_vxlan_tcp4_flow(struct vxlan_tcp4_flow_key k1, > + struct vxlan_tcp4_flow_key k2) > +{ > + return (is_same_ether_addr(&k1.outer_eth_saddr, &k2.outer_eth_saddr) && > + is_same_ether_addr(&k1.outer_eth_daddr, > + &k2.outer_eth_daddr) && > + (k1.outer_ip_src_addr == k2.outer_ip_src_addr) && > + (k1.outer_ip_dst_addr == k2.outer_ip_dst_addr) && > + (k1.outer_src_port == k2.outer_src_port) && > + (k1.outer_dst_port == k2.outer_dst_port) && > + (k1.vxlan_hdr.vx_flags == k2.vxlan_hdr.vx_flags) && > + (k1.vxlan_hdr.vx_vni == k2.vxlan_hdr.vx_vni) && > + is_same_tcp4_flow(k1.inner_key, k2.inner_key)); Maybe this could be optimized with memcmp because many of the fields are contiguous.