From f4eb1f99847ac24e010227c882a3e8eef116caf4 Mon Sep 17 00:00:00 2001 From: Open vSwitch CI Date: Oct 28 2021 07:15:37 +0000 Subject: Import openvswitch2.15-2.15.0-51 from Fast DataPath --- diff --git a/SOURCES/openvswitch-2.15.0.patch b/SOURCES/openvswitch-2.15.0.patch index f24aad2..d514e38 100644 --- a/SOURCES/openvswitch-2.15.0.patch +++ b/SOURCES/openvswitch-2.15.0.patch @@ -251,7 +251,7 @@ index fd82d7d270..4a14ffb748 100644 AC_CONFIG_MACRO_DIR([m4]) AC_CONFIG_AUX_DIR([build-aux]) diff --git a/datapath-windows/ovsext/Actions.c b/datapath-windows/ovsext/Actions.c -index 4f43369844..592cb7467c 100644 +index 4f43369844..0c18c62548 100644 --- a/datapath-windows/ovsext/Actions.c +++ b/datapath-windows/ovsext/Actions.c @@ -1112,9 +1112,9 @@ OvsPopFieldInPacketBuf(OvsForwardingContext *ovsFwdCtx, @@ -293,7 +293,32 @@ index 4f43369844..592cb7467c 100644 } -@@ -1550,9 +1561,21 @@ OvsUpdateAddressAndPort(OvsForwardingContext *ovsFwdCtx, +@@ -1516,6 +1527,7 @@ OvsUpdateAddressAndPort(OvsForwardingContext *ovsFwdCtx, + + csumInfo.Value = NET_BUFFER_LIST_INFO(ovsFwdCtx->curNbl, + TcpIpChecksumNetBufferListInfo); ++ + /* + * Adjust the IP header inline as dictated by the action, and also update + * the IP and the TCP checksum for the data modified. +@@ -1524,6 +1536,7 @@ OvsUpdateAddressAndPort(OvsForwardingContext *ovsFwdCtx, + * ChecksumUpdate32(). Ignoring this for now, since for the most common + * case, we only update the TTL. + */ ++ /*Only tx direction the checksum value will be reset to be PseudoChecksum*/ + + if (isSource) { + addrField = &ipHdr->saddr; +@@ -1540,7 +1553,7 @@ OvsUpdateAddressAndPort(OvsForwardingContext *ovsFwdCtx, + ((BOOLEAN)csumInfo.Receive.UdpChecksumSucceeded || + (BOOLEAN)csumInfo.Receive.UdpChecksumFailed); + } +- if (l4Offload) { ++ if (isTx && l4Offload) { + *checkField = IPPseudoChecksum(&newAddr, &ipHdr->daddr, + tcpHdr ? IPPROTO_TCP : IPPROTO_UDP, + ntohs(ipHdr->tot_len) - ipHdr->ihl * 4); +@@ -1550,15 +1563,27 @@ OvsUpdateAddressAndPort(OvsForwardingContext *ovsFwdCtx, if (tcpHdr) { portField = &tcpHdr->dest; checkField = &tcpHdr->check; @@ -308,14 +333,35 @@ index 4f43369844..592cb7467c 100644 + (BOOLEAN)csumInfo.Receive.UdpChecksumFailed); + } + -+ if (l4Offload) { ++ if (isTx && l4Offload) { + *checkField = IPPseudoChecksum(&ipHdr->saddr, &newAddr, + tcpHdr ? IPPROTO_TCP : IPPROTO_UDP, + ntohs(ipHdr->tot_len) - ipHdr->ihl * 4); } } -@@ -1780,9 +1803,11 @@ OvsExecuteRecirc(OvsForwardingContext *ovsFwdCtx, + if (*addrField != newAddr) { + UINT32 oldAddr = *addrField; +- if (checkField && *checkField != 0 && !l4Offload) { ++ if ((checkField && *checkField != 0) && (!l4Offload || !isTx)) { + /* Recompute total checksum. */ + *checkField = ChecksumUpdate32(*checkField, oldAddr, + newAddr); +@@ -1567,11 +1592,12 @@ OvsUpdateAddressAndPort(OvsForwardingContext *ovsFwdCtx, + ipHdr->check = ChecksumUpdate32(ipHdr->check, oldAddr, + newAddr); + } ++ + *addrField = newAddr; + } + + if (portField && *portField != newPort) { +- if (checkField && !l4Offload) { ++ if ((checkField) && (!l4Offload || !isTx)) { + /* Recompute total checksum. */ + *checkField = ChecksumUpdate16(*checkField, *portField, + newPort); +@@ -1780,9 +1806,11 @@ OvsExecuteRecirc(OvsForwardingContext *ovsFwdCtx, } if (newNbl) { @@ -329,7 +375,7 @@ index 4f43369844..592cb7467c 100644 } if (deferredAction) { -@@ -1952,7 +1977,7 @@ OvsExecuteSampleAction(OvsForwardingContext *ovsFwdCtx, +@@ -1952,7 +1980,7 @@ OvsExecuteSampleAction(OvsForwardingContext *ovsFwdCtx, return STATUS_SUCCESS; } @@ -338,7 +384,7 @@ index 4f43369844..592cb7467c 100644 OVS_LOG_INFO( "Deferred actions limit reached, dropping sample action."); OvsCompleteNBL(ovsFwdCtx->switchContext, newNbl, TRUE); -@@ -2088,6 +2113,7 @@ OvsDoExecuteActions(POVS_SWITCH_CONTEXT switchContext, +@@ -2088,6 +2116,7 @@ OvsDoExecuteActions(POVS_SWITCH_CONTEXT switchContext, */ status = OvsPopVlanInPktBuf(&ovsFwdCtx); if (status != NDIS_STATUS_SUCCESS) { @@ -346,7 +392,7 @@ index 4f43369844..592cb7467c 100644 dropReason = L"OVS-pop vlan action failed"; goto dropit; } -@@ -2337,7 +2363,7 @@ OvsActionsExecute(POVS_SWITCH_CONTEXT switchContext, +@@ -2337,7 +2366,7 @@ OvsActionsExecute(POVS_SWITCH_CONTEXT switchContext, if (status == STATUS_SUCCESS) { status = OvsProcessDeferredActions(switchContext, completionList, diff --git a/SPECS/openvswitch2.15.spec b/SPECS/openvswitch2.15.spec index 0072ce0..5b72eb1 100644 --- a/SPECS/openvswitch2.15.spec +++ b/SPECS/openvswitch2.15.spec @@ -57,7 +57,7 @@ Summary: Open vSwitch Group: System Environment/Daemons daemon/database/utilities URL: http://www.openvswitch.org/ Version: 2.15.0 -Release: 50%{?dist} +Release: 51%{?dist} # Nearly all of openvswitch is ASL 2.0. The bugtool is LGPLv2+, and the # lib/sflow*.[ch] files are SISSL @@ -699,6 +699,12 @@ exit 0 %endif %changelog +* Thu Oct 28 2021 Open vSwitch CI - 2.15.0-51 +- Merging upstream branch-2.15 [RH git: a134a530c9] + Commit list: + eca2d50d40 datapath-windows:Reset PseudoChecksum value only for TX direction offload case + + * Wed Oct 27 2021 Open vSwitch CI - 2.15.0-50 - Merging upstream branch-2.15 [RH git: 16dad85706] Commit list: