From: Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com>
To: netdev@vger.kernel.org
Cc: Anton Blanchard <anton@samba.org>,
Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com>
Subject: [PATCH 05/15] ehea: Dont check NETIF_F_TSO in TX path
Date: Fri, 14 Oct 2011 12:31:02 -0300 [thread overview]
Message-ID: <1318606272-27647-6-git-send-email-cascardo@linux.vnet.ibm.com> (raw)
In-Reply-To: <1318606272-27647-1-git-send-email-cascardo@linux.vnet.ibm.com>
From: Anton Blanchard <anton@samba.org>
It seems like the ehea xmit routine and an ethtool change of TSO
mode could race, resulting in corrupt packets. Checking gso_size
is enough and we can use the helper function.
Signed-off-by: Anton Blanchard <anton@samba.org>
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com>
---
drivers/net/ethernet/ibm/ehea/ehea_main.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/net/ethernet/ibm/ehea/ehea_main.c b/drivers/net/ethernet/ibm/ehea/ehea_main.c
index 6ded42a..0cb3a9b 100644
--- a/drivers/net/ethernet/ibm/ehea/ehea_main.c
+++ b/drivers/net/ethernet/ibm/ehea/ehea_main.c
@@ -1787,7 +1787,7 @@ static inline void write_swqe2_data(struct sk_buff *skb, struct net_device *dev,
swqe->descriptors = 0;
sg1entry_contains_frag_data = 0;
- if ((dev->features & NETIF_F_TSO) && skb_shinfo(skb)->gso_size)
+ if (skb_is_gso(skb))
write_swqe2_TSO(skb, swqe, lkey);
else
write_swqe2_nonTSO(skb, swqe, lkey);
--
1.7.4.4
next prev parent reply other threads:[~2011-10-14 15:31 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-14 15:30 EHEA updates Thadeu Lima de Souza Cascardo
2011-10-14 15:30 ` [PATCH 01/15] ehea: Remove NETIF_F_LLTX Thadeu Lima de Souza Cascardo
2011-10-14 15:30 ` [PATCH 02/15] ehea: Update multiqueue support Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 03/15] ehea: Remove force_irq logic in napi poll routine Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 04/15] ehea: Remove num_tx_qps module option Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` Thadeu Lima de Souza Cascardo [this message]
2011-10-14 15:31 ` [PATCH 06/15] ehea: Add vlan_features Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 07/15] ehea: Allocate large enough skbs to avoid partial cacheline DMA writes Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 08/15] ehea: Simplify ehea_xmit2 and ehea_xmit3 Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 09/15] ehea: Merge swqe2 TSO and non TSO paths Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 10/15] ehea: Simplify type 3 transmit routine Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 11/15] ehea: Remove some unused definitions Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 12/15] ehea: Add 64bit statistics Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 13/15] ehea: Remove LRO support Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 14/15] ehea: Add GRO support Thadeu Lima de Souza Cascardo
2011-10-14 15:31 ` [PATCH 15/15] ehea: Remove unused tcp_end field in send WQ Thadeu Lima de Souza Cascardo
2011-10-17 23:06 ` EHEA updates David Miller
-- strict thread matches above, loose matches on Subject: below --
2011-05-12 0:52 [PATCH 00/15] ehea updates v2 Anton Blanchard
2011-05-12 0:52 ` [PATCH 05/15] ehea: Dont check NETIF_F_TSO in TX path Anton Blanchard
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=1318606272-27647-6-git-send-email-cascardo@linux.vnet.ibm.com \
--to=cascardo@linux.vnet.ibm.com \
--cc=anton@samba.org \
--cc=netdev@vger.kernel.org \
/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).