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 9AFF34320A; Thu, 26 Oct 2023 19:38:16 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 668EF402CF; Thu, 26 Oct 2023 19:38:16 +0200 (CEST) Received: from NAM02-DM3-obe.outbound.protection.outlook.com (mail-dm3nam02on2087.outbound.protection.outlook.com [40.107.95.87]) by mails.dpdk.org (Postfix) with ESMTP id 8513140261 for ; Thu, 26 Oct 2023 19:38:14 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=fBNbs6nxs03gpCwN/lHB5juKSMEr17PDjR9dqXNe20/WRbD9e4llec17HPIKhPogX93t0fTNCvdeJueByBgCmYBCfBhDWcXkVE6kd29+NNKIg2M6FV3DC6S+0NaSGgq1RNdbv2Ye+/rsVt8+FL4UR2mJiSJgyf7yZUnPj2tLnUGiKP+qkv0SUCFH5cSp+5RXuOJsPhsIN6GImAVgibECAxL3OY2RaRwGvuhIUSnfP5v99Jd4I05lufGKdRhuxD8qLtY8Wdg+nzFWIgAgJK+XedwfWZpWMJbn1C+WnodjMsMRqDoM9FDwfu1MByZNukuFvQnxw/YnjJAjOhyFa3h3Ig== 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=Vp/j+U7eUNY0ou75IlA2tb79SIafZ9xXQMJpV6thAZ0=; b=LlKyjzt/7rT5uprZlWkvHgMym1sErD5duIf7494EuFTLsDZ2LOhvfslV2rHhtaW73TlaA0Ly1W8OLZFkq0tqDaI4X+tGnWYBCp2sdH29SORH74AeRbZ0UKTV5+4GQulvlAs60VPooSKRgPnHsdS5S213N+9BxU9Tw7FOHhBMQuwOcsvoJPWcGBduDLWONP7fySUYnA8l57ngevKcRcXEOkpgs15LlxTGERzihZ0BLL4L7+xND1T2CzoAq9b9cx3VaxLL/ax2X9HhWsWB+ybXAHctEnh4mTHrO0i2NqqDJVThaxGfXsVaFrQ2rozfKvB8/bwnooPI14mhOUqxLMFXVw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Vp/j+U7eUNY0ou75IlA2tb79SIafZ9xXQMJpV6thAZ0=; b=oqQyL+U20vA4xTtr8ZNXppN6wqIbXkiQTgPXKn4dBwbhGmmkw45dwPIL6ZgcaRrF3gWm30i4F/TIU7HEM6jYbfOXaV4g578ayEoLpIUd5HfGF8W/uDGs8j6Xp+52R5dXE1ZyQwZLaBfpU+mZkbYna9Mah/gLu1B1m1WKIHBfLe0= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from CH2PR12MB4294.namprd12.prod.outlook.com (2603:10b6:610:a9::11) by DM4PR12MB5325.namprd12.prod.outlook.com (2603:10b6:5:390::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6933.19; Thu, 26 Oct 2023 17:38:12 +0000 Received: from CH2PR12MB4294.namprd12.prod.outlook.com ([fe80::2569:edb2:670f:816f]) by CH2PR12MB4294.namprd12.prod.outlook.com ([fe80::2569:edb2:670f:816f%6]) with mapi id 15.20.6933.019; Thu, 26 Oct 2023 17:38:12 +0000 Message-ID: <2d4b3aa4-bebc-4f04-87f8-b75f38e0558e@amd.com> Date: Thu, 26 Oct 2023 18:38:07 +0100 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] net/gve: Update max_rx_pktlen to be based on MTU Content-Language: en-US To: Joshua Washington , Junfeng Guo , Jeroen de Borst , Rushil Gupta Cc: dev@dpdk.org References: <20231016205948.2252342-1-joshwash@google.com> From: Ferruh Yigit Autocrypt: addr=ferruh.yigit@amd.com; keydata= xsFNBGJDD3EBEAC/M7Tk/DfQSmP1K96vyzdhfSBzlCaGtcxNXorq4fALruqVsD3oi0yfyEz9 4YN8x7py0o9EL8ZdpOX0skc0AMCDAaw033uWhCn0GLMeGRKUbfOAPvL6ecSDvGD7CJIO9j0J eZUvasBgPdM/435PEr9DmC6Ggzdzt8IuG4PoLi5jpFSfcqxZFCCxLUDEo/w0nuguk2FTuYJg B2zEZ4JTBZrw7hIHiFh8D8hr6YA6a5uTofq1tr+l048lbtdFUl8TR0aIExVzE4Z8qKZlcE+9 RQaewjK5Al1jLE4sHdmd3GN+IvgDF3D/fLsi25SKJDeGSdeHkOmaX0qGeM4WKIfU6iARRCiQ N3AmBIxZ/A7UXBKLaOyZ+/i3sE6Wb53nrO4i8+0K2Qwyh6LjTeiJAIjYKN43ppxz3DaI+QwQ vI+uyHr4Gg0Da9EPPz/YyKauSeOZCfCB5gIfICO0j6x0SCl8uQ2nLpjxcZkf0gjcwUzP3h+S 3x6NfDji9YEij0zczW/dcSpGgZ6vsFpPrtnP9ZXy6J53yp0kJtOJoOlkEFFdU2yCZnCDseum CoudmGLZVvS0/DzHDJejq+3kK3FDGktZBOxZIIpal+nFqS7lVgOZc4+huVv3jyhzoAUOEyXA XK5j6o7g8STUY+z33QNnHpdLvecMwuzmvqy0jR54yAbZ64mB9QARAQABzSNGZXJydWggWWln aXQgPGZlcnJ1aC55aWdpdEBhbWQuY29tPsLBlwQTAQgAQQIbAwULCQgHAgYVCgkICwIEFgID AQIeAQIXgAIZARYhBEm7aYjps5XGsPHCElRTPtCKKm/6BQJjb9DJBQkC+3/YAAoJEFRTPtCK Km/6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AVhmtXvrqPW6Ku 3FQ= In-Reply-To: <20231016205948.2252342-1-joshwash@google.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-ClientProxiedBy: FR0P281CA0194.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10:ab::18) To CH2PR12MB4294.namprd12.prod.outlook.com (2603:10b6:610:a9::11) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CH2PR12MB4294:EE_|DM4PR12MB5325:EE_ X-MS-Office365-Filtering-Correlation-Id: 83cf2dc7-c0a4-43e7-9d11-08dbd64a536a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: warOC5w7VGKoBIPU3LL4tf0R+ggjJKDMRxMZ8IwSDbUnpvNnVFiTjDqAbuAht0qI1vNUj7YtvXZ5GFeo6uQh+8c13Ac+Tkl+Lju+1XZUSLPRjWcFpzZX7P+0duqi6hEAALGwl7eQJeX5MpmssZfV0wiDFu5wkUkvO9JT0ePMDbs9t1eDPTV7ogfUIlEvvVuPnYEfUChEMBK2ziFt7jhs8GBuYEazUax/GVVJnmkDiInrykDiOiNnyRAL08mDWr+8AGbkLgv4RxkFbnnOYtoFKTW4SCkInBil7I8q6w+spvOsIIhekIVUYbX7sjXzU1vVqy0VTg7fjPyTSUCrM8USkQl2bv8SMbN0XuRy10FY5qJEI3cTur43TMxb4UDRg/qSHC6sdJ8Cdgo8BfE6RWip3IeTyIFAqeI/jnba88vLK3oTpkHh42PHfKdbUWesmXw3gJ6U5hSHXLPTrjjPSRylk6U+pMdzCebn1cKq+vEhDS9L4QmzjqK7rNajIHKDi4UK5Hs7c9XJtyGRLciM3d4mikiSvp3EYS6J+Bz/e9b6BXiN1o1vzBzmDfdzsPJz0dqSSEFHRkjRX3c/U9VXZThiVvZkBO/KV8TU4jF3uDsTVRMC009aSLap9D7Y6uH1De+U54LZz3uYqd2N49tt/InYFw== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CH2PR12MB4294.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(39860400002)(376002)(396003)(366004)(136003)(346002)(230922051799003)(186009)(1800799009)(64100799003)(451199024)(44832011)(53546011)(6666004)(478600001)(6506007)(2616005)(66476007)(66946007)(6512007)(110136005)(36756003)(31696002)(6486002)(86362001)(26005)(38100700002)(8676002)(8936002)(83380400001)(41300700001)(66556008)(4326008)(5660300002)(316002)(31686004)(2906002)(4744005)(43740500002)(45980500001); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?bnBnczFRMmdINjZBdXJqSXVxQ1J0Z3pLMXRSMm56RGlkZGtRNEpNWmpzSU9u?= =?utf-8?B?MDV2ODdVY1pld3NSMXZzc0VvUysySzdWRWVpMm9tVFl1d1NYdWRqcDRwUWYv?= =?utf-8?B?ZFRibXR6UUVzNk1oU1hEZjlab0JPbmxWS3dOZC9UaFI1YVpUdE0vOC8zcFR5?= =?utf-8?B?NEtJckFKNzA2N3JqYmQ3OFR0aCtmRWRCbUhuUWdCNUxtTjVWVmNnNldzVmtl?= =?utf-8?B?Zng2ekhOaGhjaFZLV0JqdUJyYk5PQjNDWDQ0NHZlaW9OYWdtYlFZV3RKb1FU?= =?utf-8?B?anVsT1RMYkZ4NzhGdkFKZ1BGZmIza3ROeCtzbzk0aVM1NW80NC9mK00zd0Fm?= =?utf-8?B?OFIydys1VGlKZnZMb01pUUs5a0J0N25PNFFKTkxsZFV4eG1ZYkNIMnFXcTR4?= =?utf-8?B?S0F2K2lOWnlNeDZtWGdYbEdaQTZBa3o3UWhqZmpTSXVmWXlaYWN6SWZCZGMx?= =?utf-8?B?Ry9LQWMzV2NKenFCUWhKUm5JZGVUZ1drTzZnVk10RENrdVpoKzVLV0pSZDIv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Id2xNbGxsUXF1ZFlI?= =?utf-8?B?K2xQRDJwVWh3RDd2Qmh4TnFNeXBFSndseHovSUJaSWRVdkY1WGtZT3JFTjFs?= =?utf-8?B?UWNJekFQU0JadUwwR2VsQWNzMVp3ZDdnZjQxeDBrMTJ4b3FDY2c4aUVvVERq?= =?utf-8?B?Qkp4VUZpY2xVRngwdGRvd0gvZWdsekFoemE1K2xTTWdrWXRobWwxN0dRcTNB?= =?utf-8?B?QU00Mm8xU1JHQkFuUnYrWS8rS1hhODZZSWl2L0tYOXN3UjhTRHZSNStlTDlk?= =?utf-8?B?bWNvbzJPOUhEU0VDcHIyc3Rra096WEV4MGhuaDl2SmxsS2ZrWDlqNEdNOHE3?= =?utf-8?B?aE1yQm42ZnhOaVV5UnllUDZjUURMQWhzUXJ4TWo4dXdvRjZSYVJWbnBHZEdS?= =?utf-8?B?b3ZaK1N4ak1GTTBZWTJhdGJEZDNnaDZ4V3VkSml6dkV2NW9vQUtXSmJtdWYv?= =?utf-8?B?R3Vya0FSYWRCcjc0UVZWYlVpRXBUT3dtM3U2SE5kekhEaDRKMWtLNnZEZ2JV?= =?utf-8?B?UzhZWWF1WUVyblJHVDM5ZWhocUtaRUFoUE1RZGZtbjh1YUsyOFJiUG94SXg0?= =?utf-8?B?bUJpNXNJV3dBWjJtRndyZkxCRC96VUpYZWxxbTh6Z1orR2lMZnZHMVE0OVFt?= =?utf-8?B?QU12K3ROWWlpaHBnSkN3TkZKUmpBUXpDM1BoQWZiUjZnRUVycTVnaXJ4aHFS?= =?utf-8?Q?dtRU=3D?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 83cf2dc7-c0a4-43e7-9d11-08dbd64a536a X-MS-Exchange-CrossTenant-AuthSource: CH2PR12MB4294.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 26 Oct 2023 17:38:12.1087 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: SKMnW8ltrOCM36l3jeu5wQ5lFIbJ/SibhNNwESDJoZ9kot6sed3iQ4+XdJlAxo6T X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM4PR12MB5325 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 On 10/16/2023 9:59 PM, Joshua Washington wrote: > Before this patch, max_rx_pktlen was always set to UINT16_MAX. This, in > conjunction with the MTU fix, causes problems with testpmd, as setting the > packet length with the --max-pkt-len flag causes the MTU to be set > higher than possible due to underflow. > > As an example, setting --max-pkt-len=1460 (the default MTU on Google > Cloud VMs) causes testpmd to set the following: > mtu = 1460 - eth_overhead, > > where eth_overhead = dev->max_rx_pktlen - dev->max_mtu = 65535 - 1460. > > Thus, mtu = 1460 - 65535 + 1460 = 2921 due to underflow. > > Signed-off-by: Joshua Washington > > Fixes: 030025b74202 ("net/gve: fix max MTU limit") > Cc: joshwash@google.com > Cc: stable@dpdk.org Applied to dpdk-next-net/main, thanks.