diff options
author | Florian Westphal <fw@strlen.de> | 2016-09-21 11:35:02 -0400 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2016-09-24 21:25:49 +0200 |
commit | fe72926b792e52ab00abfa81a201805bfb2247d6 (patch) | |
tree | 52b2a3533cd57daafceb5c3fbb13e5a1ed04bbf8 /include/linux/netfilter_ingress.h | |
parent | netfilter: bridge: add and use br_nf_hook_thresh (diff) | |
download | linux-dev-fe72926b792e52ab00abfa81a201805bfb2247d6.tar.xz linux-dev-fe72926b792e52ab00abfa81a201805bfb2247d6.zip |
netfilter: call nf_hook_state_init with rcu_read_lock held
This makes things simpler because we can store the head of the list
in the nf_state structure without worrying about concurrent add/delete
of hook elements from the list.
A future commit will make use of this to implement a simpler
linked-list.
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Aaron Conole <aconole@bytheb.org>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'include/linux/netfilter_ingress.h')
-rw-r--r-- | include/linux/netfilter_ingress.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/netfilter_ingress.h b/include/linux/netfilter_ingress.h index 5fcd375ef175..6965ba09eba7 100644 --- a/include/linux/netfilter_ingress.h +++ b/include/linux/netfilter_ingress.h @@ -14,6 +14,7 @@ static inline bool nf_hook_ingress_active(const struct sk_buff *skb) return !list_empty(&skb->dev->nf_hooks_ingress); } +/* caller must hold rcu_read_lock */ static inline int nf_hook_ingress(struct sk_buff *skb) { struct nf_hook_state state; |