diff options
| -rw-r--r-- | drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c index be59ec4b2c30..e3fe1ce41522 100644 --- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c +++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c | |||
| @@ -3192,11 +3192,11 @@ static u32 bnx2x_xmit_type(struct bnx2x *bp, struct sk_buff *skb) | |||
| 3192 | rc |= XMIT_CSUM_TCP; | 3192 | rc |= XMIT_CSUM_TCP; |
| 3193 | 3193 | ||
| 3194 | if (skb_is_gso_v6(skb)) { | 3194 | if (skb_is_gso_v6(skb)) { |
| 3195 | rc |= (XMIT_GSO_V6 | XMIT_CSUM_TCP | XMIT_CSUM_V6); | 3195 | rc |= (XMIT_GSO_V6 | XMIT_CSUM_TCP); |
| 3196 | if (rc & XMIT_CSUM_ENC) | 3196 | if (rc & XMIT_CSUM_ENC) |
| 3197 | rc |= XMIT_GSO_ENC_V6; | 3197 | rc |= XMIT_GSO_ENC_V6; |
| 3198 | } else if (skb_is_gso(skb)) { | 3198 | } else if (skb_is_gso(skb)) { |
| 3199 | rc |= (XMIT_GSO_V4 | XMIT_CSUM_V4 | XMIT_CSUM_TCP); | 3199 | rc |= (XMIT_GSO_V4 | XMIT_CSUM_TCP); |
| 3200 | if (rc & XMIT_CSUM_ENC) | 3200 | if (rc & XMIT_CSUM_ENC) |
| 3201 | rc |= XMIT_GSO_ENC_V4; | 3201 | rc |= XMIT_GSO_ENC_V4; |
| 3202 | } | 3202 | } |
| @@ -3483,19 +3483,18 @@ static void bnx2x_update_pbds_gso_enc(struct sk_buff *skb, | |||
| 3483 | { | 3483 | { |
| 3484 | u16 hlen_w = 0; | 3484 | u16 hlen_w = 0; |
| 3485 | u8 outerip_off, outerip_len = 0; | 3485 | u8 outerip_off, outerip_len = 0; |
| 3486 | |||
| 3486 | /* from outer IP to transport */ | 3487 | /* from outer IP to transport */ |
| 3487 | hlen_w = (skb_inner_transport_header(skb) - | 3488 | hlen_w = (skb_inner_transport_header(skb) - |
| 3488 | skb_network_header(skb)) >> 1; | 3489 | skb_network_header(skb)) >> 1; |
| 3489 | 3490 | ||
| 3490 | /* transport len */ | 3491 | /* transport len */ |
| 3491 | if (xmit_type & XMIT_CSUM_TCP) | 3492 | hlen_w += inner_tcp_hdrlen(skb) >> 1; |
| 3492 | hlen_w += inner_tcp_hdrlen(skb) >> 1; | ||
| 3493 | else | ||
| 3494 | hlen_w += sizeof(struct udphdr) >> 1; | ||
| 3495 | 3493 | ||
| 3496 | pbd2->fw_ip_hdr_to_payload_w = hlen_w; | 3494 | pbd2->fw_ip_hdr_to_payload_w = hlen_w; |
| 3497 | 3495 | ||
| 3498 | if (xmit_type & XMIT_CSUM_ENC_V4) { | 3496 | /* outer IP header info */ |
| 3497 | if (xmit_type & XMIT_CSUM_V4) { | ||
| 3499 | struct iphdr *iph = ip_hdr(skb); | 3498 | struct iphdr *iph = ip_hdr(skb); |
| 3500 | pbd2->fw_ip_csum_wo_len_flags_frag = | 3499 | pbd2->fw_ip_csum_wo_len_flags_frag = |
| 3501 | bswab16(csum_fold((~iph->check) - | 3500 | bswab16(csum_fold((~iph->check) - |
