netfilter: nf_conntrack: use atomic64 for accounting counters
commitb3e0bfa71b1db9d7a9fbea6965867784fd00ca3c
authorEric Dumazet <eric.dumazet@gmail.com>
Wed, 14 Dec 2011 13:45:20 +0000 (14 14:45 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Sun, 18 Dec 2011 00:19:19 +0000 (18 01:19 +0100)
tree2b8463810415b36edcb0e96b17f7a86047c1bfd5
parent76ad94fc5df865e34e09406614f29951a046394a
netfilter: nf_conntrack: use atomic64 for accounting counters

We can use atomic64_t infrastructure to avoid taking a spinlock in fast
path, and remove inaccuracies while reading values in
ctnetlink_dump_counters() and connbytes_mt() on 32bit arches.

Suggested by Pablo.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
include/net/netfilter/nf_conntrack_acct.h
net/netfilter/nf_conntrack_acct.c
net/netfilter/nf_conntrack_core.c
net/netfilter/nf_conntrack_netlink.c
net/netfilter/xt_connbytes.c