diff options
Diffstat (limited to 'drivers/net/ppp/ppp_generic.c')
-rw-r--r-- | drivers/net/ppp/ppp_generic.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/net/ppp/ppp_generic.c b/drivers/net/ppp/ppp_generic.c index 21d7151fb0ab..5c0557222f20 100644 --- a/drivers/net/ppp/ppp_generic.c +++ b/drivers/net/ppp/ppp_generic.c | |||
@@ -1092,13 +1092,13 @@ pad_compress_skb(struct ppp *ppp, struct sk_buff *skb) | |||
1092 | new_skb->data, skb->len + 2, | 1092 | new_skb->data, skb->len + 2, |
1093 | compressor_skb_size); | 1093 | compressor_skb_size); |
1094 | if (len > 0 && (ppp->flags & SC_CCP_UP)) { | 1094 | if (len > 0 && (ppp->flags & SC_CCP_UP)) { |
1095 | kfree_skb(skb); | 1095 | consume_skb(skb); |
1096 | skb = new_skb; | 1096 | skb = new_skb; |
1097 | skb_put(skb, len); | 1097 | skb_put(skb, len); |
1098 | skb_pull(skb, 2); /* pull off A/C bytes */ | 1098 | skb_pull(skb, 2); /* pull off A/C bytes */ |
1099 | } else if (len == 0) { | 1099 | } else if (len == 0) { |
1100 | /* didn't compress, or CCP not up yet */ | 1100 | /* didn't compress, or CCP not up yet */ |
1101 | kfree_skb(new_skb); | 1101 | consume_skb(new_skb); |
1102 | new_skb = skb; | 1102 | new_skb = skb; |
1103 | } else { | 1103 | } else { |
1104 | /* | 1104 | /* |
@@ -1112,7 +1112,7 @@ pad_compress_skb(struct ppp *ppp, struct sk_buff *skb) | |||
1112 | if (net_ratelimit()) | 1112 | if (net_ratelimit()) |
1113 | netdev_err(ppp->dev, "ppp: compressor dropped pkt\n"); | 1113 | netdev_err(ppp->dev, "ppp: compressor dropped pkt\n"); |
1114 | kfree_skb(skb); | 1114 | kfree_skb(skb); |
1115 | kfree_skb(new_skb); | 1115 | consume_skb(new_skb); |
1116 | new_skb = NULL; | 1116 | new_skb = NULL; |
1117 | } | 1117 | } |
1118 | return new_skb; | 1118 | return new_skb; |
@@ -1178,7 +1178,7 @@ ppp_send_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1178 | !(ppp->flags & SC_NO_TCP_CCID)); | 1178 | !(ppp->flags & SC_NO_TCP_CCID)); |
1179 | if (cp == skb->data + 2) { | 1179 | if (cp == skb->data + 2) { |
1180 | /* didn't compress */ | 1180 | /* didn't compress */ |
1181 | kfree_skb(new_skb); | 1181 | consume_skb(new_skb); |
1182 | } else { | 1182 | } else { |
1183 | if (cp[0] & SL_TYPE_COMPRESSED_TCP) { | 1183 | if (cp[0] & SL_TYPE_COMPRESSED_TCP) { |
1184 | proto = PPP_VJC_COMP; | 1184 | proto = PPP_VJC_COMP; |
@@ -1187,7 +1187,7 @@ ppp_send_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1187 | proto = PPP_VJC_UNCOMP; | 1187 | proto = PPP_VJC_UNCOMP; |
1188 | cp[0] = skb->data[2]; | 1188 | cp[0] = skb->data[2]; |
1189 | } | 1189 | } |
1190 | kfree_skb(skb); | 1190 | consume_skb(skb); |
1191 | skb = new_skb; | 1191 | skb = new_skb; |
1192 | cp = skb_put(skb, len + 2); | 1192 | cp = skb_put(skb, len + 2); |
1193 | cp[0] = 0; | 1193 | cp[0] = 0; |
@@ -1703,7 +1703,7 @@ ppp_receive_nonmp_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1703 | } | 1703 | } |
1704 | skb_reserve(ns, 2); | 1704 | skb_reserve(ns, 2); |
1705 | skb_copy_bits(skb, 0, skb_put(ns, skb->len), skb->len); | 1705 | skb_copy_bits(skb, 0, skb_put(ns, skb->len), skb->len); |
1706 | kfree_skb(skb); | 1706 | consume_skb(skb); |
1707 | skb = ns; | 1707 | skb = ns; |
1708 | } | 1708 | } |
1709 | else | 1709 | else |
@@ -1851,7 +1851,7 @@ ppp_decompress_frame(struct ppp *ppp, struct sk_buff *skb) | |||
1851 | goto err; | 1851 | goto err; |
1852 | } | 1852 | } |
1853 | 1853 | ||
1854 | kfree_skb(skb); | 1854 | consume_skb(skb); |
1855 | skb = ns; | 1855 | skb = ns; |
1856 | skb_put(skb, len); | 1856 | skb_put(skb, len); |
1857 | skb_pull(skb, 2); /* pull off the A/C bytes */ | 1857 | skb_pull(skb, 2); /* pull off the A/C bytes */ |