From: David Wilder <dwilder@us.ibm.com>
To: netdev@vger.kernel.org
Cc: tlfalcon@linux.ibm.com, cris.forno@ibm.com,
pradeeps@linux.vnet.ibm.com, wilder@us.ibm.com,
willemdebruijn.kernel@gmail.com, kuba@kernel.org
Subject: [ PATCH v2 1/2] ibmveth: Switch order of ibmveth_helper calls.
Date: Tue, 13 Oct 2020 16:20:13 -0700 [thread overview]
Message-ID: <20201013232014.26044-2-dwilder@us.ibm.com> (raw)
In-Reply-To: <20201013232014.26044-1-dwilder@us.ibm.com>
ibmveth_rx_csum_helper() must be called after ibmveth_rx_mss_helper()
as ibmveth_rx_csum_helper() may alter ip and tcp checksum values.
Fixes: 66aa0678efc2 ("ibmveth: Support to enable LSO/CSO for Trunk
VEA.")
Signed-off-by: David Wilder <dwilder@us.ibm.com>
Reviewed-by: Thomas Falcon <tlfalcon@linux.ibm.com>
Reviewed-by: Cristobal Forno <cris.forno@ibm.com>
Reviewed-by: Pradeep Satyanarayana <pradeeps@linux.vnet.ibm.com>
---
drivers/net/ethernet/ibm/ibmveth.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/net/ethernet/ibm/ibmveth.c b/drivers/net/ethernet/ibm/ibmveth.c
index c5c732601e35..3935a7e22ce5 100644
--- a/drivers/net/ethernet/ibm/ibmveth.c
+++ b/drivers/net/ethernet/ibm/ibmveth.c
@@ -1385,16 +1385,16 @@ static int ibmveth_poll(struct napi_struct *napi, int budget)
skb_put(skb, length);
skb->protocol = eth_type_trans(skb, netdev);
- if (csum_good) {
- skb->ip_summed = CHECKSUM_UNNECESSARY;
- ibmveth_rx_csum_helper(skb, adapter);
- }
-
if (length > netdev->mtu + ETH_HLEN) {
ibmveth_rx_mss_helper(skb, mss, lrg_pkt);
adapter->rx_large_packets++;
}
+ if (csum_good) {
+ skb->ip_summed = CHECKSUM_UNNECESSARY;
+ ibmveth_rx_csum_helper(skb, adapter);
+ }
+
napi_gro_receive(napi, skb); /* send it up */
netdev->stats.rx_packets++;
--
1.8.3.1
next prev parent reply other threads:[~2020-10-13 23:21 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-13 23:20 [ PATCH v2 0/2] ibmveth gso fix David Wilder
2020-10-13 23:20 ` David Wilder [this message]
2020-10-14 16:22 ` [ PATCH v2 1/2] ibmveth: Switch order of ibmveth_helper calls Willem de Bruijn
2020-10-15 3:23 ` Jakub Kicinski
2020-10-13 23:20 ` [ PATCH v2 2/2] ibmveth: Identify ingress large send packets David Wilder
2020-10-14 16:23 ` Willem de Bruijn
2020-10-15 3:23 ` [ PATCH v2 0/2] ibmveth gso fix Jakub Kicinski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201013232014.26044-2-dwilder@us.ibm.com \
--to=dwilder@us.ibm.com \
--cc=cris.forno@ibm.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pradeeps@linux.vnet.ibm.com \
--cc=tlfalcon@linux.ibm.com \
--cc=wilder@us.ibm.com \
--cc=willemdebruijn.kernel@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).