| Submitter | Michael S. Tsirkin |
|---|---|
| Date | Feb. 7, 2013, 1:13 p.m. |
| Message ID | <50a60e1293901965901edb46ae49e52da1d469d5.1360236441.git.mst@redhat.com> |
| Download | mbox | patch |
| Permalink | /patch/218925/ |
| State | Accepted |
| Delegated to: | David Miller |
| Headers | show |
Comments
On 2/7/13 5:13 AM, "Michael S. Tsirkin" <mst@redhat.com> wrote: >qlcnic set gso_size but not gso type. This leads to crashes >in macvtap. > >Signed-off-by: Michael S. Tsirkin <mst@redhat.com> >--- > drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c | 7 ++++++- > 1 file changed, 6 insertions(+), 1 deletion(-) > >diff --git a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c >b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c >index 6f82812..09aa310 100644 >--- a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c >+++ b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c >@@ -986,8 +986,13 @@ qlcnic_process_lro(struct qlcnic_adapter *adapter, > th->seq = htonl(seq_number); > length = skb->len; > >- if (adapter->flags & QLCNIC_FW_LRO_MSS_CAP) >+ if (adapter->flags & QLCNIC_FW_LRO_MSS_CAP) { > skb_shinfo(skb)->gso_size = qlcnic_get_lro_sts_mss(sts_data1); >+ if (skb->protocol == htons(ETH_P_IPV6)) >+ skb_shinfo(skb)->gso_type = SKB_GSO_TCPV6; >+ else >+ skb_shinfo(skb)->gso_type = SKB_GSO_TCPV4; >+ } > > if (vid != 0xffff) > __vlan_hwaccel_put_tag(skb, vid); >-- >MST Thanks! Acked-by: Jitendra Kalsaria <jitendra.kalsaria@qlogic.com> -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Patch
diff --git a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c index 6f82812..09aa310 100644 --- a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c +++ b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c @@ -986,8 +986,13 @@ qlcnic_process_lro(struct qlcnic_adapter *adapter, th->seq = htonl(seq_number); length = skb->len; - if (adapter->flags & QLCNIC_FW_LRO_MSS_CAP) + if (adapter->flags & QLCNIC_FW_LRO_MSS_CAP) { skb_shinfo(skb)->gso_size = qlcnic_get_lro_sts_mss(sts_data1); + if (skb->protocol == htons(ETH_P_IPV6)) + skb_shinfo(skb)->gso_type = SKB_GSO_TCPV6; + else + skb_shinfo(skb)->gso_type = SKB_GSO_TCPV4; + } if (vid != 0xffff) __vlan_hwaccel_put_tag(skb, vid);
qlcnic set gso_size but not gso type. This leads to crashes in macvtap. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> --- drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)