diff options
author | Florian Westphal <fw@strlen.de> | 2014-12-31 07:33:41 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-01-02 16:04:29 -0500 |
commit | e8768f971558019ed83eee8210375cd2143deef2 (patch) | |
tree | dc40361eb9be9d2cb3a2303f4600a16b6fd6dd5d /net/core | |
parent | 6c032edc8a338f7a5d7bbd3dd8a08ac80d37dd86 (diff) |
net: skbuff: don't zero tc members when freeing skb
Not needed, only four cases:
- kfree_skb (or one of its aliases).
Don't need to zero, memory will be freed.
- kfree_skb_partial and head was stolen: memory will be freed.
- skb_morph: The skb header fields (including tc ones) will be
copied over from the 'to-be-morphed' skb right after
skb_release_head_state returns.
- skb_segment: Same as before, all the skb header
fields are copied over from the original skb right away.
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core')
-rw-r--r-- | net/core/skbuff.c | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/net/core/skbuff.c b/net/core/skbuff.c index 395c15b82087..5a2a2e887a12 100644 --- a/net/core/skbuff.c +++ b/net/core/skbuff.c | |||
@@ -677,13 +677,6 @@ static void skb_release_head_state(struct sk_buff *skb) | |||
677 | #if IS_ENABLED(CONFIG_BRIDGE_NETFILTER) | 677 | #if IS_ENABLED(CONFIG_BRIDGE_NETFILTER) |
678 | nf_bridge_put(skb->nf_bridge); | 678 | nf_bridge_put(skb->nf_bridge); |
679 | #endif | 679 | #endif |
680 | /* XXX: IS this still necessary? - JHS */ | ||
681 | #ifdef CONFIG_NET_SCHED | ||
682 | skb->tc_index = 0; | ||
683 | #ifdef CONFIG_NET_CLS_ACT | ||
684 | skb->tc_verd = 0; | ||
685 | #endif | ||
686 | #endif | ||
687 | } | 680 | } |
688 | 681 | ||
689 | /* Free everything but the sk_buff shell. */ | 682 | /* Free everything but the sk_buff shell. */ |