[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3D5EE67D3FC948CAB5D11ABBBFD60A6F@realtek.com.tw>
Date: Fri, 20 Jul 2012 10:11:17 +0800
From: hayeswang <hayeswang@...ltek.com>
To: 'Francois Romieu' <romieu@...zoreil.com>,
'David Miller' <davem@...emloft.net>
CC: <eric.dumazet@...il.com>, <netdev@...r.kernel.org>
Subject: RE: [RFC] r8169 : why SG / TX checksum are default disabled
Francois Romieu [mailto:romieu@...zoreil.com]
[...]
> A part of the apparent problem may stem from the fact that
> Realtek's 8168
> driver claims a modified length but it does not really skb_padto...
>
> Hayes, would the patch below fix the original problem ?
According to the response from our hw engineer, it still has the problem even
though you pad the packet to 60 bytes with zeroes. I would still test this patch
to verify it.
> static netdev_tx_t rtl8169_start_xmit(struct sk_buff *skb,
> @@ -5797,7 +5804,8 @@ static netdev_tx_t
> rtl8169_start_xmit(struct sk_buff *skb,
> opts[1] = cpu_to_le32(rtl8169_tx_vlan_tag(tp, skb));
> opts[0] = DescOwn;
>
> - rtl8169_tso_csum(tp, skb, opts);
> + if (!rtl8169_tso_csum(tp, skb, opts))
> + goto err_update_stats;
>
I think you should check the length of opts1 of the descriptor, too. Besides,
how about the length of dma_map_xxx? Should it use the original length or the
modified length?
> frags = rtl8169_xmit_frags(tp, skb, opts);
> if (frags < 0)
> @@ -5853,6 +5861,7 @@ err_dma_1:
> rtl8169_unmap_tx_skb(d, tp->tx_skb + entry, txd);
> err_dma_0:
> dev_kfree_skb(skb);
> +err_update_stats:
> dev->stats.tx_dropped++;
> return NETDEV_TX_OK;
>
Best Regards,
Hayes
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists