提交 cb1cb5c4 编写于 作者: P Pablo Neira Ayuso 提交者: David S. Miller

netfilter: ctnetlink: fix sleep in read-side lock section

Fix allocation with GFP_KERNEL in ctnetlink_create_conntrack() under
read-side lock sections.

This problem was introduced in 2.6.25.
Signed-off-by: NPablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: NPatrick McHardy <kaber@trash.net>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 1575e7ea
...@@ -1139,7 +1139,7 @@ ctnetlink_create_conntrack(struct nlattr *cda[], ...@@ -1139,7 +1139,7 @@ ctnetlink_create_conntrack(struct nlattr *cda[],
rcu_read_lock(); rcu_read_lock();
helper = __nf_ct_helper_find(rtuple); helper = __nf_ct_helper_find(rtuple);
if (helper) { if (helper) {
help = nf_ct_helper_ext_add(ct, GFP_KERNEL); help = nf_ct_helper_ext_add(ct, GFP_ATOMIC);
if (help == NULL) { if (help == NULL) {
rcu_read_unlock(); rcu_read_unlock();
err = -ENOMEM; err = -ENOMEM;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册