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 0D7BAA034F for ; Wed, 10 Nov 2021 07:38:44 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 03EB840E28; Wed, 10 Nov 2021 07:38:44 +0100 (CET) Received: from NAM11-DM6-obe.outbound.protection.outlook.com (mail-dm6nam11on2041.outbound.protection.outlook.com [40.107.223.41]) by mails.dpdk.org (Postfix) with ESMTP id 00D3940E03 for ; Wed, 10 Nov 2021 07:38:42 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RoePmzX4qoDHsUd8l55FuVKGsgiKa5rumt+zP6hrp0Z/cV0P0J34fEexHrvF0U5j1PjcC0s2UhFyrBBdLNJciwk01n4F3djuuMlYSUiqYp3haBNjUEH3DWPJKB5XlBfsFcm3PfdIf8E4m5ZhFZqlrn+GmEODcaeztJcuwOCvYgmrbp28siu6B/rzACcAMd25pEvcVSrSaEKuWjd8iFWlUo8YU2tDUeyN9kpAxw0mlB7lAABpRftI7oQoiDF/001XRoD1x4lz2KRy0JPaHYZbmL4OY2U49qTQqb2WoB/O48HVW6WKLbgeJ4+/1RrlSFaDx/1mnz/NYHehhxTJP+yMFQ== 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=WFGDNQVw0hvbdu8/dy3K6JlzBmigXbiklAEl0wC/Fr8=; b=ZNyTIXLUMDGTl6JKxVJEUbIFiwPXua9kKaxU+a3bwbD8ZXegKCaLIMT+KQRJ4KN5sUozE7nKJmVf+mZx+rEPUKTKuoESx+5KzBUC92CUmMYZs5vPi9FLD2h/zWSP9wl39Tu7FXELB3OWspL8nhuA8yiiQbxKSh/l6nLynlZDTlNPa24a/kImCHKRm7dxUNvCycP9I5W+fqGFxMN6+U3Kr5NFcq4sFSRwgOGzFj9HnCd09Rl45LXeyAsMFWM77hvl4PrxDabvybbwYgM2Skm9FadYIcJ5GtgB2SkkVYX1DPi8DFQY3QqocGIuFH7hpFKBM+UaQ0zqewnVxm/B1HloLg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.112.34) smtp.rcpttodomain=redhat.com smtp.mailfrom=nvidia.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=WFGDNQVw0hvbdu8/dy3K6JlzBmigXbiklAEl0wC/Fr8=; b=JLpOdM73c7HnnzAbWd1JqWr9v+l8y98RYQ6E2M8KxfqA1pl4g/fqnSQ9zzf0mkuizjrqtd4ZhiJwga8JnUzPyf7tOrSSj5gqSDh5E1GbCnAwS0pL9G9oURVcLfNRlAZfsgYAFBlCVC0h25h1h/dvLapb99A280CPPA8RRJ7YbcR5klkRaDTudVh0EZgsovVnjolwLIBTq9OFiTD0OPMPm5qbJvLO0wtY7a0wuYYiNOZv5sfniP+krZmYpZdiRpkOvs6e+Ietv8saZS74a9EsEmd2JgYOxyHpLlJOyJ6xWOiIv0RcuRCBln51vUugm0/DuInnUD58rUbEeoFVKcCs7A== Received: from DM6PR01CA0009.prod.exchangelabs.com (2603:10b6:5:296::14) by DM6PR12MB2810.namprd12.prod.outlook.com (2603:10b6:5:41::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4669.11; Wed, 10 Nov 2021 06:38:40 +0000 Received: from DM6NAM11FT044.eop-nam11.prod.protection.outlook.com (2603:10b6:5:296:cafe::2a) by DM6PR01CA0009.outlook.office365.com (2603:10b6:5:296::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4669.11 via Frontend Transport; Wed, 10 Nov 2021 06:38:40 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.112.34) smtp.mailfrom=nvidia.com; redhat.com; dkim=none (message not signed) header.d=none;redhat.com; dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 216.228.112.34 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.112.34; helo=mail.nvidia.com; Received: from mail.nvidia.com (216.228.112.34) by DM6NAM11FT044.mail.protection.outlook.com (10.13.173.185) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.4690.15 via Frontend Transport; Wed, 10 Nov 2021 06:38:40 +0000 Received: from nvidia.com (172.20.187.5) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Wed, 10 Nov 2021 06:38:36 +0000 From: Xueming Li To: Ivan Ilchenko CC: Luca Boccassi , Andrew Rybchenko , Maxime Coquelin , dpdk stable Date: Wed, 10 Nov 2021 14:29:00 +0800 Message-ID: <20211110063216.2744012-57-xuemingl@nvidia.com> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20211110063216.2744012-1-xuemingl@nvidia.com> References: <20211110063216.2744012-1-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [172.20.187.5] X-ClientProxiedBy: HQMAIL101.nvidia.com (172.20.187.10) To HQMAIL107.nvidia.com (172.20.187.13) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 2b9b8959-f4b5-4bf1-02b9-08d9a414bbb2 X-MS-TrafficTypeDiagnostic: DM6PR12MB2810: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:10000; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: g/FLFblH9dkwgoKI8iNWXbKnz8r19a7XCaHqPxcEZmqnFIJNZFfCV/YtAn/Iy1ughWJjuYwkaDlMB4IPNrdKwVmuD/lJZaRpl5y+HeVQ5p6jP73KqxQM6pcxg9r0lHvPI2W++VVnCPQeSRMiaK7MporHSHh4wgSY2lPus6zANk/0W8Q+JZpf+Hd/ytRa3SDCGUvbZqjh8o2KpUPHsR/rD34Xp0s5RvVoFtMtH99uRGySNwbCTOVsu6kfpO4OuTTabBPFGL5mu3F/VoMFGaqVnPqFRMicZM++NFC2P0ySHF3mAtT98CiDTXmHVu/yQxhlqdg068sKFzdQXhT+81LXSiLypUsG/pymUj9o6PTZT1dTPhaI1XiJsALM/H7f7w9Hj0kGHP64ee6zC9Z31I8mEvHiO806TbTDG0lzaNM8yINFEPavWDGWlBiXmQyGZ5eWQeYJhBRoYD8Lf3KXcKOwvNSioIgXQ+qD6M2b+xYT3qfLuYXyUhRqkORbuShlVZ4Q5IcMTX5mn46eCBhd5tHZi2GcU1kOOzSaunpIaqR41nH5vyTDhSzMzhIJeoasNcAyBXZtCtbnv1Tp7sSQxsHA7/Nb3q1DAD2SBr7nB3+O1eahhLw7yE90yrUvr9CsTOFCsuHiLD6USyjaG3IrimHlrOTRog+Hq7z3nUKKvTW+HrhuT1Fx+SzTuwxYtTPfZaE/1cQxKlYhVqrr7p1wH+Jww3rHlF953yyT2zGkPyJgHWfLb8OR1a7ZR8LaEHvW2UroPPdJUjU1vzwyYFAQhQKlSGUgV3yTwgP2DjbLhvXZIV79i3vLW/jjoDu5bU6IUr1Aonqs60QGhk/EIcdmGamQXw== X-Forefront-Antispam-Report: CIP:216.228.112.34; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:schybrid03.nvidia.com; CAT:NONE; SFS:(4636009)(46966006)(36840700001)(8936002)(6666004)(6916009)(86362001)(53546011)(8676002)(426003)(70586007)(2616005)(36906005)(4001150100001)(4326008)(7636003)(508600001)(316002)(1076003)(55016002)(82310400003)(54906003)(2906002)(966005)(5660300002)(16526019)(186003)(83380400001)(6286002)(26005)(336012)(36860700001)(47076005)(7696005)(36756003)(70206006)(356005); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Nov 2021 06:38:40.3863 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2b9b8959-f4b5-4bf1-02b9-08d9a414bbb2 X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.112.34]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: DM6NAM11FT044.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB2810 Subject: [dpdk-stable] patch 'net/virtio: fix device configure without jumbo Rx offload' has been queued to stable release 20.11.4 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" Hi, FYI, your patch has been queued to stable release 20.11.4 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 11/12/21. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/steevenlee/dpdk This queued commit can be viewed at: https://github.com/steevenlee/dpdk/commit/92569f9804d1ea7ab44a916fae55aec220823349 Thanks. Xueming Li --- >From 92569f9804d1ea7ab44a916fae55aec220823349 Mon Sep 17 00:00:00 2001 From: Ivan Ilchenko Date: Thu, 2 Sep 2021 17:39:39 +0300 Subject: [PATCH] net/virtio: fix device configure without jumbo Rx offload Cc: Xueming Li [ upstream commit 580f3af31c99824bdd1cc331035096e34de5ca01 ] Use max-pkt-len only if jumbo frames offload is requested since otherwise this field isn't valid. Fixes: 8b90e4358112 ("net/virtio: set offload flag for jumbo frames") Fixes: 4e8169eb0d2d ("net/virtio: fix Rx scatter offload") Signed-off-by: Ivan Ilchenko Signed-off-by: Andrew Rybchenko Reviewed-by: Maxime Coquelin --- drivers/net/virtio/virtio_ethdev.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c index 25f1b951f9..7bbd483952 100644 --- a/drivers/net/virtio/virtio_ethdev.c +++ b/drivers/net/virtio/virtio_ethdev.c @@ -2302,10 +2302,14 @@ virtio_dev_configure(struct rte_eth_dev *dev) return ret; } - if (rxmode->max_rx_pkt_len > hw->max_mtu + ether_hdr_len) + if ((rx_offloads & DEV_RX_OFFLOAD_JUMBO_FRAME) && + (rxmode->max_rx_pkt_len > hw->max_mtu + ether_hdr_len)) req_features &= ~(1ULL << VIRTIO_NET_F_MTU); - hw->max_rx_pkt_len = rxmode->max_rx_pkt_len; + if (rx_offloads & DEV_RX_OFFLOAD_JUMBO_FRAME) + hw->max_rx_pkt_len = rxmode->max_rx_pkt_len; + else + hw->max_rx_pkt_len = ether_hdr_len + dev->data->mtu; if (rx_offloads & (DEV_RX_OFFLOAD_UDP_CKSUM | DEV_RX_OFFLOAD_TCP_CKSUM)) -- 2.33.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2021-11-10 14:17:04.587367188 +0800 +++ 0056-net-virtio-fix-device-configure-without-jumbo-Rx-off.patch 2021-11-10 14:17:01.807413276 +0800 @@ -1 +1 @@ -From 580f3af31c99824bdd1cc331035096e34de5ca01 Mon Sep 17 00:00:00 2001 +From 92569f9804d1ea7ab44a916fae55aec220823349 Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit 580f3af31c99824bdd1cc331035096e34de5ca01 ] @@ -11 +13,0 @@ -Cc: stable@dpdk.org @@ -21 +23 @@ -index 51fa85b078..da1633d77e 100644 +index 25f1b951f9..7bbd483952 100644 @@ -24 +26 @@ -@@ -2103,10 +2103,14 @@ virtio_dev_configure(struct rte_eth_dev *dev) +@@ -2302,10 +2302,14 @@ virtio_dev_configure(struct rte_eth_dev *dev)