diff options
author | Joe Stringer <joe@ovn.org> | 2016-05-02 11:19:13 -0700 |
---|---|---|
committer | Joe Stringer <joe@ovn.org> | 2016-05-02 17:06:36 -0700 |
commit | 4b65333195848bee09add1347fc7410add1bd62b (patch) | |
tree | 1d4927247069ada218d8d097e7f3c360d4502346 /datapath/linux/compat/include/net/netfilter | |
parent | 01f35e09e07c9413596ce8055a891106bd3e2c6e (diff) | |
download | openvswitch-4b65333195848bee09add1347fc7410add1bd62b.tar.gz |
compat: nf_defrag_ipv6: avoid/free clone operations.
Upstream commit:
netfilter: ipv6: nf_defrag: avoid/free clone operations
commit 6aafeef03b9d9ecf
("netfilter: push reasm skb through instead of original frag skbs")
changed ipv6 defrag to not use the original skbs anymore.
So rather than keeping the original skbs around just to discard them
afterwards just use the original skbs directly for the fraglist of
the newly assembled skb and remove the extra clone/free operations.
The skb that completes the fragment queue is morphed into a the
reassembled one instead, just like ipv4 defrag.
openvswitch doesn't need any additional skb_morph magic anymore to deal
with this situation so just remove that.
A followup patch can then also remove the NF_HOOK (re)invocation in
the ipv6 netfilter defrag hook.
Cc: Joe Stringer <joestringer@nicira.com>
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Upstream: 029f7f3b8701 ("netfilter: ipv6: nf_defrag: avoid/free clone operations")
Signed-off-by: Joe Stringer <joe@ovn.org>
Acked-by: Jesse Gross <jesse@kernel.org>
Diffstat (limited to 'datapath/linux/compat/include/net/netfilter')
-rw-r--r-- | datapath/linux/compat/include/net/netfilter/ipv6/nf_defrag_ipv6.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/datapath/linux/compat/include/net/netfilter/ipv6/nf_defrag_ipv6.h b/datapath/linux/compat/include/net/netfilter/ipv6/nf_defrag_ipv6.h index fe99ced37..a3b86dab2 100644 --- a/datapath/linux/compat/include/net/netfilter/ipv6/nf_defrag_ipv6.h +++ b/datapath/linux/compat/include/net/netfilter/ipv6/nf_defrag_ipv6.h @@ -16,17 +16,17 @@ #define OVS_NF_DEFRAG6_BACKPORT 1 struct sk_buff *rpl_nf_ct_frag6_gather(struct net *net, struct sk_buff *skb, u32 user); +#define nf_ct_frag6_gather rpl_nf_ct_frag6_gather +#endif /* HAVE_NF_CT_FRAG6_CONSUME_ORIG */ + +#ifdef OVS_NF_DEFRAG6_BACKPORT int __init rpl_nf_ct_frag6_init(void); void rpl_nf_ct_frag6_cleanup(void); -void rpl_nf_ct_frag6_consume_orig(struct sk_buff *skb); -#define nf_ct_frag6_gather rpl_nf_ct_frag6_gather -#else /* HAVE_NF_CT_FRAG6_CONSUME_ORIG */ +#else /* !OVS_NF_DEFRAG6_BACKPORT */ static inline int __init rpl_nf_ct_frag6_init(void) { return 0; } static inline void rpl_nf_ct_frag6_cleanup(void) { } -static inline void rpl_nf_ct_frag6_consume_orig(struct sk_buff *skb) { } -#endif /* HAVE_NF_CT_FRAG6_CONSUME_ORIG */ +#endif /* OVS_NF_DEFRAG6_BACKPORT */ #define nf_ct_frag6_init rpl_nf_ct_frag6_init #define nf_ct_frag6_cleanup rpl_nf_ct_frag6_cleanup -#define nf_ct_frag6_consume_orig rpl_nf_ct_frag6_consume_orig #endif /* __NF_DEFRAG_IPV6_WRAPPER_H */ |