netfilter: nf_tables: GC transaction race with netns dismantle
authorPablo Neira Ayuso <pablo@netfilter.org>
Tue, 15 Aug 2023 13:39:01 +0000 (15:39 +0200)
committerFlorian Westphal <fw@strlen.de>
Tue, 15 Aug 2023 22:05:15 +0000 (00:05 +0200)
commit02c6c24402bf1c1e986899c14ba22a10b510916b
treea3f1e53b7225c02c4793e51ab8e67736d49dec24
parent6a33d8b73dfac0a41f3877894b38082bd0c9a5bc
netfilter: nf_tables: GC transaction race with netns dismantle

Use maybe_get_net() since GC workqueue might race with netns exit path.

Fixes: 5f68718b34a5 ("netfilter: nf_tables: GC transaction API to avoid race with control plane")
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Florian Westphal <fw@strlen.de>
net/netfilter/nf_tables_api.c