OSDN Git Service

netfilter: add and use nf_hook_slow_list()
authorFlorian Westphal <fw@strlen.de>
Thu, 10 Oct 2019 22:30:37 +0000 (00:30 +0200)
committerPablo Neira Ayuso <pablo@netfilter.org>
Thu, 17 Oct 2019 10:20:48 +0000 (12:20 +0200)
commitca58fbe06c54795f00db79e447f94c2028d30124
tree264b0d141987a06c82309fc03fe8d02bab4d6663
parent2ad9d7747c10d17cc06447944fefd4c29ae11eb1
netfilter: add and use nf_hook_slow_list()

At this time, NF_HOOK_LIST() macro will iterate the list and then calls
nf_hook() for each individual skb.

This makes it so the entire list is passed into the netfilter core.
The advantage is that we only need to fetch the rule blob once per list
instead of per-skb.

NF_HOOK_LIST now only works for ipv4 and ipv6, as those are the only
callers.

v2: use skb_list_del_init() instead of list_del (Edward Cree)

Signed-off-by: Florian Westphal <fw@strlen.de>
Acked-by: Edward Cree <ecree@solarflare.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
include/linux/netfilter.h
net/netfilter/core.c