From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 18D77A04B5 for ; Thu, 29 Oct 2020 05:45:31 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 11B315913; Thu, 29 Oct 2020 05:45:30 +0100 (CET) Received: from unicom145.biz-email.net (unicom145.biz-email.net [210.51.26.145]) by dpdk.org (Postfix) with ESMTP id E39D65913 for ; Thu, 29 Oct 2020 05:45:26 +0100 (CET) Received: from ([60.208.111.195]) by unicom145.biz-email.net (Antispam) with ASMTP (SSL) id VOW20724; Thu, 29 Oct 2020 12:45:24 +0800 Received: from jtjnmail201605.home.langchao.com (10.100.2.5) by jtjnmail201606.home.langchao.com (10.100.2.6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2044.4; Thu, 29 Oct 2020 12:45:21 +0800 Received: from jtjnmail201605.home.langchao.com ([fe80::8d20:4cc5:1116:d16e]) by jtjnmail201605.home.langchao.com ([fe80::8d20:4cc5:1116:d16e%8]) with mapi id 15.01.2044.006; Thu, 29 Oct 2020 12:45:21 +0800 From: =?utf-8?B?WWkgWWFuZyAo5p2o54eaKS3kupHmnI3liqHpm4blm6I=?= To: "luca.boccassi@gmail.com" CC: "jiayu.hu@intel.com" , "stable@dpdk.org" Thread-Topic: patch 'gso: fix payload unit size for UDP' has been queued to stable release 19.11.6 Thread-Index: AQHWrRgY8VfTH5JlcEibg3silGRDhamuAGbQ Importance: high X-Priority: 1 Date: Thu, 29 Oct 2020 04:45:21 +0000 Message-ID: <9cb44a156b104230994d36e08b2285a3@inspur.com> References: <80d133df2f898e981b70b13c36ac63c3@sslemail.net> <20201028104606.3504127-46-luca.boccassi@gmail.com> In-Reply-To: <20201028104606.3504127-46-luca.boccassi@gmail.com> Accept-Language: zh-CN, en-US Content-Language: zh-CN X-MS-Has-Attach: yes X-MS-TNEF-Correlator: x-originating-ip: [10.164.28.32] MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: [dpdk-stable] =?utf-8?b?562U5aSNOiBwYXRjaCAnZ3NvOiBmaXggcGF5bG9h?= =?utf-8?q?d_unit_size_for_UDP=27_has_been_queued_to_stable_release_19=2E1?= =?utf-8?b?MS42?= X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 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" Thanks for picking up it, nice to have it in stable release. By the way, = would you like to cherry-pick GRO patches for stable release? OVS is = using 19.11 stable branch, we had better have GRO support there because = I'm enabling VXLAN TSO support in OVS DPDK, GRO and GSO are necessary = for it. commit e2d81106367321cf49d6b4e5d087e1a7c2e808ba Author: Yi Yang Date: Thu Sep 24 16:57:39 2020 +0800 gro: support VXLAN UDP/IPv4 VXLAN UDP/IPv4 GRO can help improve VM-to-VM UDP performance when UFO or GSO is enabled in VM, GRO must be supported if UFO or GSO is enabled, otherwise, performance can't get big improvement if only GSO is there. With this enabled in DPDK, OVS DPDK can leverage it to improve VM-to-VM UDP performance, it will reassemble VXLAN UDP/IPv4 fragments immediate after they are received from a physical NIC. It is very helpful in OVS DPDK VXLAN use case. Signed-off-by: Yi Yang Acked-by: Jiayu Hu commit 1ca5e67408528b9870bb40f400c5f934aa91dcce Author: Yi Yang Date: Thu Sep 24 16:57:38 2020 +0800 gro: support UDP/IPv4 UDP/IPv4 GRO can help improve VM-to-VM UDP performance when UFO or GSO is enabled in VM, GRO must be supported if UFO or GSO is enabled, otherwise, performance can't get big improvement if only GSO is there. With this enabled in DPDK, OVS DPDK can leverage it to improve VM-to-VM UDP performance, it will reassemble UDP fragments immediate after they are received from a physical NIC. It is very helpful in OVS DPDK VLAN use case. Signed-off-by: Yi Yang Acked-by: Jiayu Hu -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- =E5=8F=91=E4=BB=B6=E4=BA=BA: luca.boccassi@gmail.com = [mailto:luca.boccassi@gmail.com]=20 =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2020=E5=B9=B410=E6=9C=8828=E6=97=A5 18:43 =E6=94=B6=E4=BB=B6=E4=BA=BA: Yi Yang = (=E6=9D=A8=E7=87=9A)-=E4=BA=91=E6=9C=8D=E5=8A=A1=E9=9B=86=E5=9B=A2 = =E6=8A=84=E9=80=81: Jiayu Hu ; dpdk stable = =E4=B8=BB=E9=A2=98: patch 'gso: fix payload unit size for UDP' has been = queued to stable release 19.11.6 Hi, FYI, your patch has been queued to stable release 19.11.6 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 10/30/20. 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. Thanks. Luca Boccassi --- >From 2b26f143b3014d23a31aa59deda659b172edcc32 Mon Sep 17 00:00:00 2001 From: Yi Yang Date: Thu, 17 Sep 2020 10:12:49 +0800 Subject: [PATCH] gso: fix payload unit size for UDP [ upstream commit b9b75d9b5c9dbc71ee12f77e9abe089492708aae ] Fragment offset of IPv4 header is measured in units of 8 bytes. Fragment offset of UDP fragments will be wrong after GSO if = pyld_unit_size isn't multiple of 8. Say pyld_unit_size is 1500, fragment = offset of the second UDP fragment will be 187 (i.e. 1500 / 8), which = means 1496, and it will result in 4-byte data loss (1500 - 1496 =3D 4). So UDP GRO will reassemble out a wrong packet. Fixes: b166d4f30b66 ("gso: support UDP/IPv4 fragmentation") Signed-off-by: Yi Yang Acked-by: Jiayu Hu --- lib/librte_gso/gso_udp4.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/librte_gso/gso_udp4.c b/lib/librte_gso/gso_udp4.c index = 21fea09273..6fa68f243a 100644 --- a/lib/librte_gso/gso_udp4.c +++ b/lib/librte_gso/gso_udp4.c @@ -69,7 +69,10 @@ gso_udp4_segment(struct rte_mbuf *pkt, return 1; } =20 - pyld_unit_size =3D gso_size - hdr_offset; + /* pyld_unit_size must be a multiple of 8 because frag_off + * uses 8 bytes as unit. + */ + pyld_unit_size =3D (gso_size - hdr_offset) & ~7U; =20 /* Segment the payload */ ret =3D gso_do_segment(pkt, hdr_offset, pyld_unit_size, direct_pool, -- 2.20.1 --- Diff of the applied patch vs upstream commit (please double-check if = non-empty: --- --- - 2020-10-28 10:35:13.228089104 +0000 +++ 0046-gso-fix-payload-unit-size-for-UDP.patch 2020-10-28 = 10:35:11.508830082 +0000 @@ -1,8 +1,10 @@ -From b9b75d9b5c9dbc71ee12f77e9abe089492708aae Mon Sep 17 00:00:00 2001 +From 2b26f143b3014d23a31aa59deda659b172edcc32 Mon Sep 17 00:00:00 2001 From: Yi Yang Date: Thu, 17 Sep 2020 10:12:49 +0800 Subject: [PATCH] gso: fix payload unit size for UDP =20 +[ upstream commit b9b75d9b5c9dbc71ee12f77e9abe089492708aae ] + Fragment offset of IPv4 header is measured in units of 8 bytes. Fragment offset of UDP fragments will be wrong after GSO if = pyld_unit_size isn't multiple of 8. Say @@ -12,7 +14,6 @@ So UDP GRO = will reassemble out a wrong packet. =20 Fixes: b166d4f30b66 ("gso: support UDP/IPv4 fragmentation") -Cc: stable@dpdk.org =20 Signed-off-by: Yi Yang Acked-by: Jiayu Hu