diff options
Diffstat (limited to 'net/ipv4/xfrm4_output.c')
| -rw-r--r-- | net/ipv4/xfrm4_output.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/net/ipv4/xfrm4_output.c b/net/ipv4/xfrm4_output.c index 193363e22932..04403fb01a58 100644 --- a/net/ipv4/xfrm4_output.c +++ b/net/ipv4/xfrm4_output.c | |||
| @@ -48,13 +48,13 @@ static int xfrm4_output_one(struct sk_buff *skb) | |||
| 48 | struct xfrm_state *x = dst->xfrm; | 48 | struct xfrm_state *x = dst->xfrm; |
| 49 | int err; | 49 | int err; |
| 50 | 50 | ||
| 51 | if (skb->ip_summed == CHECKSUM_HW) { | 51 | if (skb->ip_summed == CHECKSUM_PARTIAL) { |
| 52 | err = skb_checksum_help(skb, 0); | 52 | err = skb_checksum_help(skb); |
| 53 | if (err) | 53 | if (err) |
| 54 | goto error_nolock; | 54 | goto error_nolock; |
| 55 | } | 55 | } |
| 56 | 56 | ||
| 57 | if (x->props.mode) { | 57 | if (x->props.mode == XFRM_MODE_TUNNEL) { |
| 58 | err = xfrm4_tunnel_check_size(skb); | 58 | err = xfrm4_tunnel_check_size(skb); |
| 59 | if (err) | 59 | if (err) |
| 60 | goto error_nolock; | 60 | goto error_nolock; |
| @@ -66,7 +66,7 @@ static int xfrm4_output_one(struct sk_buff *skb) | |||
| 66 | if (err) | 66 | if (err) |
| 67 | goto error; | 67 | goto error; |
| 68 | 68 | ||
| 69 | err = x->mode->output(skb); | 69 | err = x->mode->output(x, skb); |
| 70 | if (err) | 70 | if (err) |
| 71 | goto error; | 71 | goto error; |
| 72 | 72 | ||
| @@ -85,7 +85,7 @@ static int xfrm4_output_one(struct sk_buff *skb) | |||
| 85 | } | 85 | } |
| 86 | dst = skb->dst; | 86 | dst = skb->dst; |
| 87 | x = dst->xfrm; | 87 | x = dst->xfrm; |
| 88 | } while (x && !x->props.mode); | 88 | } while (x && (x->props.mode != XFRM_MODE_TUNNEL)); |
| 89 | 89 | ||
| 90 | IPCB(skb)->flags |= IPSKB_XFRM_TRANSFORMED; | 90 | IPCB(skb)->flags |= IPSKB_XFRM_TRANSFORMED; |
| 91 | err = 0; | 91 | err = 0; |
| @@ -134,7 +134,7 @@ static int xfrm4_output_finish(struct sk_buff *skb) | |||
| 134 | } | 134 | } |
| 135 | #endif | 135 | #endif |
| 136 | 136 | ||
| 137 | if (!skb_shinfo(skb)->gso_size) | 137 | if (!skb_is_gso(skb)) |
| 138 | return xfrm4_output_finish2(skb); | 138 | return xfrm4_output_finish2(skb); |
| 139 | 139 | ||
| 140 | skb->protocol = htons(ETH_P_IP); | 140 | skb->protocol = htons(ETH_P_IP); |
