Skip to content

Commit b04a3d0

Browse files
Kirill Tkhaidavem330
authored andcommitted
net: Convert ctnetlink_net_ops
These pernet_operations register and unregister two conntrack notifiers, and they seem to be safe to be executed in parallel. General/not related to async pernet_operations JFI: ctnetlink_net_exit_batch() actions are grouped in batch, and this could look like there is synchronize_rcu() is forgotten. But there is synchronize_rcu() on module exit patch (in ctnetlink_exit()), so this batch may be reworked as simple .exit method. Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 467d14b commit b04a3d0

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

net/netfilter/nf_conntrack_netlink.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3417,6 +3417,7 @@ static void __net_exit ctnetlink_net_exit_batch(struct list_head *net_exit_list)
34173417
static struct pernet_operations ctnetlink_net_ops = {
34183418
.init = ctnetlink_net_init,
34193419
.exit_batch = ctnetlink_net_exit_batch,
3420+
.async = true,
34203421
};
34213422

34223423
static int __init ctnetlink_init(void)

0 commit comments

Comments
 (0)