aboutsummaryrefslogtreecommitdiffstats
path: root/net/netfilter/xt_NOTRACK.c
diff options
context:
space:
mode:
authorEric Dumazet <eric.dumazet@gmail.com>2010-06-08 16:09:52 +0200
committerPatrick McHardy <kaber@trash.net>2010-06-08 16:09:52 +0200
commit5bfddbd46a95c978f4d3c992339cbdf4f4b790a3 (patch)
tree9291ba4e1e3c7bf7ae8b5dfa8271e7127a6a6958 /net/netfilter/xt_NOTRACK.c
parent339bb99e4a8ba1f8960eed21d50be808b35ad22a (diff)
downloadkernel_samsung_smdk4412-5bfddbd46a95c978f4d3c992339cbdf4f4b790a3.zip
kernel_samsung_smdk4412-5bfddbd46a95c978f4d3c992339cbdf4f4b790a3.tar.gz
kernel_samsung_smdk4412-5bfddbd46a95c978f4d3c992339cbdf4f4b790a3.tar.bz2
netfilter: nf_conntrack: IPS_UNTRACKED bit
NOTRACK makes all cpus share a cache line on nf_conntrack_untracked twice per packet. This is bad for performance. __read_mostly annotation is also a bad choice. This patch introduces IPS_UNTRACKED bit so that we can use later a per_cpu untrack structure more easily. A new helper, nf_ct_untracked_get() returns a pointer to nf_conntrack_untracked. Another one, nf_ct_untracked_status_or() is used by nf_nat_init() to add IPS_NAT_DONE_MASK bits to untracked status. nf_ct_is_untracked() prototype is changed to work on a nf_conn pointer. Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: Patrick McHardy <kaber@trash.net>
Diffstat (limited to 'net/netfilter/xt_NOTRACK.c')
-rw-r--r--net/netfilter/xt_NOTRACK.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/netfilter/xt_NOTRACK.c b/net/netfilter/xt_NOTRACK.c
index 512b912..9d78218 100644
--- a/net/netfilter/xt_NOTRACK.c
+++ b/net/netfilter/xt_NOTRACK.c
@@ -23,7 +23,7 @@ notrack_tg(struct sk_buff *skb, const struct xt_action_param *par)
If there is a real ct entry correspondig to this packet,
it'll hang aroun till timing out. We don't deal with it
for performance reasons. JK */
- skb->nfct = &nf_conntrack_untracked.ct_general;
+ skb->nfct = &nf_ct_untracked_get()->ct_general;
skb->nfctinfo = IP_CT_NEW;
nf_conntrack_get(skb->nfct);