diff options
Diffstat (limited to 'net/core/skbuff.c')
-rw-r--r-- | net/core/skbuff.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/net/core/skbuff.c b/net/core/skbuff.c index 6edbb90cbcec..a1c9ecf4f1e0 100644 --- a/net/core/skbuff.c +++ b/net/core/skbuff.c | |||
@@ -272,7 +272,7 @@ static void skb_clone_fraglist(struct sk_buff *skb) | |||
272 | skb_get(list); | 272 | skb_get(list); |
273 | } | 273 | } |
274 | 274 | ||
275 | void skb_release_data(struct sk_buff *skb) | 275 | static void skb_release_data(struct sk_buff *skb) |
276 | { | 276 | { |
277 | if (!skb->cloned || | 277 | if (!skb->cloned || |
278 | !atomic_sub_return(skb->nohdr ? (1 << SKB_DATAREF_SHIFT) + 1 : 1, | 278 | !atomic_sub_return(skb->nohdr ? (1 << SKB_DATAREF_SHIFT) + 1 : 1, |
@@ -1848,13 +1848,13 @@ EXPORT_SYMBOL_GPL(skb_pull_rcsum); | |||
1848 | /** | 1848 | /** |
1849 | * skb_segment - Perform protocol segmentation on skb. | 1849 | * skb_segment - Perform protocol segmentation on skb. |
1850 | * @skb: buffer to segment | 1850 | * @skb: buffer to segment |
1851 | * @sg: whether scatter-gather can be used for generated segments | 1851 | * @features: features for the output path (see dev->features) |
1852 | * | 1852 | * |
1853 | * This function performs segmentation on the given skb. It returns | 1853 | * This function performs segmentation on the given skb. It returns |
1854 | * the segment at the given position. It returns NULL if there are | 1854 | * the segment at the given position. It returns NULL if there are |
1855 | * no more segments to generate, or when an error is encountered. | 1855 | * no more segments to generate, or when an error is encountered. |
1856 | */ | 1856 | */ |
1857 | struct sk_buff *skb_segment(struct sk_buff *skb, int sg) | 1857 | struct sk_buff *skb_segment(struct sk_buff *skb, int features) |
1858 | { | 1858 | { |
1859 | struct sk_buff *segs = NULL; | 1859 | struct sk_buff *segs = NULL; |
1860 | struct sk_buff *tail = NULL; | 1860 | struct sk_buff *tail = NULL; |
@@ -1863,6 +1863,7 @@ struct sk_buff *skb_segment(struct sk_buff *skb, int sg) | |||
1863 | unsigned int offset = doffset; | 1863 | unsigned int offset = doffset; |
1864 | unsigned int headroom; | 1864 | unsigned int headroom; |
1865 | unsigned int len; | 1865 | unsigned int len; |
1866 | int sg = features & NETIF_F_SG; | ||
1866 | int nfrags = skb_shinfo(skb)->nr_frags; | 1867 | int nfrags = skb_shinfo(skb)->nr_frags; |
1867 | int err = -ENOMEM; | 1868 | int err = -ENOMEM; |
1868 | int i = 0; | 1869 | int i = 0; |