From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id DFEE1A034E; Mon, 21 Feb 2022 11:24:26 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C9BF1410F2; Mon, 21 Feb 2022 11:24:26 +0100 (CET) Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by mails.dpdk.org (Postfix) with ESMTP id 2EBC1410F0; Mon, 21 Feb 2022 11:24:24 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1645439064; x=1676975064; h=message-id:date:subject:to:cc:references:from: in-reply-to:mime-version; bh=BafLzkscRH3hJwjSCSTP9YVptgJqBmUSjXwuGUF2EKs=; b=Vce1PgaeH3DOA5GR8d4xrOA892AeGePSLaGgl45qAHNMQToXUO8X7/A8 mAuwKlPZyu2byFP9hAThuoLVmjFwB5gfELquU0AoZeHBgPSZXbGWOcVxl rga1P/MnnD/fJIy9xSA6rgHLWqT4lycxfLJzAjY/OseavdIWJ4+jigJI6 SyFCf9cMrcreHbUv5PKX3R1NWD3cxCFhHGHpIxY6y511E+2IpbPjdwLhK CSrBS5lYAnYL0SoBMy/W8uPkEUQQCnCTK2zPc1zOnI1whfphagWfgaJHZ fnHjYn1T+eszMBskadAqXVURV54Dc5OI/cZxzspvwoCSMG0uSbuXdNiQY Q==; X-IronPort-AV: E=McAfee;i="6200,9189,10264"; a="235022428" X-IronPort-AV: E=Sophos;i="5.88,385,1635231600"; d="scan'208,217";a="235022428" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 Feb 2022 02:24:23 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,385,1635231600"; d="scan'208,217";a="636617838" Received: from orsmsx601.amr.corp.intel.com ([10.22.229.14]) by fmsmga002.fm.intel.com with ESMTP; 21 Feb 2022 02:24:22 -0800 Received: from orsmsx612.amr.corp.intel.com (10.22.229.25) by ORSMSX601.amr.corp.intel.com (10.22.229.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20; Mon, 21 Feb 2022 02:24:22 -0800 Received: from orsmsx607.amr.corp.intel.com (10.22.229.20) by ORSMSX612.amr.corp.intel.com (10.22.229.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20; Mon, 21 Feb 2022 02:24:22 -0800 Received: from orsedg603.ED.cps.intel.com (10.7.248.4) by orsmsx607.amr.corp.intel.com (10.22.229.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20 via Frontend Transport; Mon, 21 Feb 2022 02:24:22 -0800 Received: from NAM11-BN8-obe.outbound.protection.outlook.com (104.47.58.173) by edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.20; Mon, 21 Feb 2022 02:24:21 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=SFD5YOmvfDSvHho4d4X+oYwnrzLHKsstBeTqzLMIMQptnrzt4cDruswNWFziVNX3lGiQf6Qp7cVu04iMNPzaysfwBjgQLr2fwShy9W/jkstYVJMc+RQpNGVIWA71XFZ0QBhUsq1Y5H1+BM76qykmwjNIUxNY8Z7K4KrxGcyVsu+FrUkU5DQdegGQHlk1BkOLz4RPEcKedxXpvFSLXhqbHO8QlctSCZK8PnaRF+m8+y+GE4VWa0NPvZiNf4UCy3dUAzHYlNovF+pvdykQH/4iTz13URBSWZf1wGlg4oPXtMY/0z2GgutNm3zzZJNKJhJPrD9tZ+IPrjNU9KlZokunIg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ZVTSVH4DmY+OHkTOEbR97DA+Occ0IpMrresiWjLxaRM=; b=Io7JmoNLIrpJ/CtP0sfBWPuZIk3MOYdJmqEAoQDBHFM0s7jCsPeVwNL9FnqEe84vREqsO5t/spcuPaqEhfjX8KftZWNZWWZvL1ZpAYpk7jvRD+f//HFc6ddKWQyGUGZ6SB9zSdn0KENasfibW8QuzRROEEwb8RMCb4NyFpgiWgDPCJMUIObPUC7EwoCOQa7+zpngu4XKzx9PLEtrmIxWsaostqbwigrWez7yo+82QdPyilDMwMnsPOUecYt793yhVhqginf3j+lOJ+Pav+nNuzisx6i6V9Is6PTr0+m9X2NCB5L4b1R8Wv+K+THJNh1u4bAv08xSuFL8yc/IZarnVA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; Received: from MWHPR11MB0062.namprd11.prod.outlook.com (2603:10b6:301:67::34) by BN6PR11MB1506.namprd11.prod.outlook.com (2603:10b6:405:a::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4995.16; Mon, 21 Feb 2022 10:24:20 +0000 Received: from MWHPR11MB0062.namprd11.prod.outlook.com ([fe80::dd62:304e:c73e:224a]) by MWHPR11MB0062.namprd11.prod.outlook.com ([fe80::dd62:304e:c73e:224a%5]) with mapi id 15.20.4995.027; Mon, 21 Feb 2022 10:24:20 +0000 Content-Type: multipart/alternative; boundary="------------b1A3nnFSbO0ervoMIv37wSay" Message-ID: Date: Mon, 21 Feb 2022 15:54:08 +0530 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.6.0 Subject: Re: [PATCH V3] app/testpmd: fix GENEVE parsing in csum forward mode Content-Language: en-US To: Raja Zidane , CC: , References: <20220216123732.32617-1-rzidane@nvidia.com> <20220220120954.29784-1-rzidane@nvidia.com> From: "Singh, Aman Deep" In-Reply-To: <20220220120954.29784-1-rzidane@nvidia.com> X-ClientProxiedBy: BMXPR01CA0024.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:d::34) To MWHPR11MB0062.namprd11.prod.outlook.com (2603:10b6:301:67::34) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 3bf72952-929c-48d2-46ce-08d9f5245240 X-MS-TrafficTypeDiagnostic: BN6PR11MB1506:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: ITQ8uMpfn7/3seB5zMziFBHotlwto7SPZDp/ohjIgUyuX2V7Air4G6wI5BVZUBWiAJPiHp+JZ7xbQ0TbcfOm4PSYb8WJ4wXmdduAn7Rekdpu82H6waxgn1TvbHRx5j6cF9kNU4eFARgD7yj9392bwLHSpevAehLt65B/1pmvBpsh23M/aAf0aDWZtiBbGeHvvFj1K2TEDZz9rTOqfQvhXHp0mBswjjOu3lOnxPZXbZmvDvh5Ozdzflo5SynnJdtGKPtcXUu2Z/O/p+cXl2iMUoIm48NlfoDie0W2MECq1HI+YM8IBRF0xHstAh3Bck1D5hSOn0nRHJWfipzA/yVr+y9bXtv4iw6ANQeYvtB77/2rXTiR3GR/LWE0XKPWJ5rd2bF1fR0Jr5TApB5pGP40HH3AzVMeZDceqSpmzNfpzfV1kqk3+i/PRwDSlslG6ciEp16hYp+EAehai8yUQb0b+06pAZqBcFUcJAKq6WqTf39XGFww/L9i6rodv4h1N4VGWjr5VdVOGOlOJsBqOUBS7aSaZ+i7Go/BpGsMVEVDG0/dEAERAeBk3TRSaBsPH/lOO8r2haT45X+JiIib0xhh16/YxVczfWqyHlJw+7bADqb4Hb+WVlObwJM6zh3dldA9nHitiJL/N+6L8d/lS2wVK03dZPOruT3mZBZSX8CYasWjjf/DMZYuxrLBBSDkDbOKFfAKZU9Rp75769iLV77jiGr8N5xZ4px/9nFsczvtg50= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:MWHPR11MB0062.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230001)(366004)(6506007)(186003)(8676002)(66476007)(36756003)(66556008)(66946007)(4326008)(31686004)(53546011)(38100700002)(33964004)(26005)(6666004)(83380400001)(6486002)(82960400001)(6512007)(508600001)(5660300002)(316002)(2906002)(2616005)(31696002)(86362001)(8936002)(43740500002)(45980500001); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?WWhIYnFITjBlWEVjRmlGb0J1b04vZTdXa1ZJSkN4ZEZzVnpUUmFRcnV2REw0?= =?utf-8?B?SlNyNDFYVTRXRHMvV05XU2RyY210MElrWEQrWVBESENMRW9NQTY2azBnVy9t?= =?utf-8?B?T29OUUc1eGJkdUhHRGhRZTd3bS9Jdkt0MFZxTXVNYjBCQm91bVFjNGVFbFNn?= =?utf-8?B?b1lwUFB0L0xhZTBCOTB0alI0NWVXa2Npc0kwaStGZ3EyRmZ1RURZUUxTTnlL?= =?utf-8?B?SkxCcFFDMDNWR2pHWllUaWNMMG5CTjNUUEN4OEtjRWlySnBrVWY0Q09ZRVM4?= =?utf-8?B?V1VYc1VNRTZhdlBhaHRLS2R4MWl5M2VZRHIwdkd6cXdrSTJxVzVJbHBtZHpr?= =?utf-8?B?b0s3R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yZjVhaUhML05qaUxNQml6T0NZZythaWls?= =?utf-8?B?cFpRdk9NS0hBM2NpS0VJWFJRQjJzckd3eGg4c2krMDhzVXk2L3hpMXdtYnN1?= =?utf-8?Q?cIt6wBGEQqz8W5ynyUJAR//wBOACeYsLSnDIMWpB+w=3D?= X-MS-Exchange-CrossTenant-Network-Message-Id: 3bf72952-929c-48d2-46ce-08d9f5245240 X-MS-Exchange-CrossTenant-AuthSource: MWHPR11MB0062.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Feb 2022 10:24:20.1269 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: BlkPFjrxEoBz8Bct5MMa3lNsykwz4A9iPa5jfVdyFZVB4PDgA+HlHGjdCfZ7Xa54xGJDVEGQiJc860O4F5GRehxfHbzlDRp4ji+vaEI4TtQ= X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR11MB1506 X-OriginatorOrg: intel.com X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org --------------b1A3nnFSbO0ervoMIv37wSay Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit On 2/20/2022 5:39 PM, Raja Zidane wrote: > The csum FWD mode parses any received packet to set mbuf offloads for the > transmitting burst, mainly in the checksum/TSO areas. > In the case of a tunnel header, the csum FWD tries to detect known tunnels > by the standard definition using the header'sdata and fallback to check the > packet type in the mbuf to see if the Rx port driver already sign the > packet as a tunnel. > In the fallback case, the csum assumes the tunnel is VXLAN and parses the > tunnel as VXLAN. > When the GENEVE tunnel was added to the known tunnels in csum, its parsing > trial was wrongly located after the pkt type detection, causing the csum to > parse the GENEVE header as VXLAN when the Rx port set the tunnel packet > type. > > Remove the fall back case to VxLan. > Log error of unrecognized tunnel if no tunnel was parsed successfully. > > Fixes: c10a026c3b03 ("app/testpmd: introduce vxlan parsing function in csum fwd engine") > Cc:stable@dpdk.org > > Signed-off-by: Raja Zidane > --- > V2: Log error when an unrecognized tunnel is found (unknown UDP dst port), instead of parsing it as VxLan by default. > V3: revert unneeded changes (swapping parse_geneve & parse_vxlan). > app/test-pmd/csumonly.c | 15 +++++++++------ > 1 file changed, 9 insertions(+), 6 deletions(-) > > Acked-by: Aman Singh > --------------b1A3nnFSbO0ervoMIv37wSay Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: 7bit


On 2/20/2022 5:39 PM, Raja Zidane wrote:
The csum FWD mode parses any received packet to set mbuf offloads for the
transmitting burst, mainly in the checksum/TSO areas.
In the case of a tunnel header, the csum FWD tries to detect known tunnels
by the standard definition using the header'sdata and fallback to check the
packet type in the mbuf to see if the Rx port driver already sign the
packet as a tunnel.
In the fallback case, the csum assumes the tunnel is VXLAN and parses the
tunnel as VXLAN.
When the GENEVE tunnel was added to the known tunnels in csum, its parsing
trial was wrongly located after the pkt type detection, causing the csum to
parse the GENEVE header as VXLAN when the Rx port set the tunnel packet
type.

Remove the fall back case to VxLan.
Log error of unrecognized tunnel if no tunnel was parsed successfully.

Fixes: c10a026c3b03 ("app/testpmd: introduce vxlan parsing function in csum fwd engine")
Cc: stable@dpdk.org

Signed-off-by: Raja Zidane <rzidane@nvidia.com>
---
V2: Log error when an unrecognized tunnel is found (unknown UDP dst port), instead of parsing it as VxLan by default.
V3: revert unneeded changes (swapping parse_geneve & parse_vxlan).
 app/test-pmd/csumonly.c | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)


Acked-by: Aman Singh <aman.deep.singh@intel.com>


<snip>
 
--------------b1A3nnFSbO0ervoMIv37wSay--