summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorEric Dumazet <eric.dumazet@gmail.com>2011-07-19 11:44:17 +0200
committerPatrick McHardy <kaber@trash.net>2011-07-19 11:44:17 +0200
commit5863702a3421b0d2a63a473cf96afeb9fe09070d (patch)
treed462b775b7702a4ae44ec50ec28a2217d5ab2338 /include
parent84a797dd0b9f7130357b70577fcbda8e638c71a7 (diff)
netfilter: nfnetlink_queue: assert monotonic packet ids
Packet identifier is currently setup in nfqnl_build_packet_message(), using one atomic_inc_return(). Problem is that since several cpus might concurrently call nfqnl_enqueue_packet() for the same queue, we can deliver packets to consumer in non monotonic way (packet N+1 being delivered after packet N) This patch moves the packet id setup from nfqnl_build_packet_message() to nfqnl_enqueue_packet() to guarantee correct delivery order. This also removes one atomic operation. Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> CC: Florian Westphal <fw@strlen.de> CC: Pablo Neira Ayuso <pablo@netfilter.org> CC: Eric Leblond <eric@regit.org> Signed-off-by: Patrick McHardy <kaber@trash.net>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions