netfilter: nft_set_rbtree: skip sync GC for new elements in this transaction
authorSasha Levin <sashal@kernel.org>
Fri, 22 Sep 2023 17:01:14 +0000 (19:01 +0200)
committerSalvatore Bonaccorso <carnil@debian.org>
Fri, 29 Sep 2023 04:25:15 +0000 (05:25 +0100)
commit62246dc0db49cc4b59bf5a938df6ccab31bcb19d
treec67d3784519213919a9175a9874e305b8e1ef9c4
parent0b8d30c9a33bebe8fb8efda784cff05068d75901
netfilter: nft_set_rbtree: skip sync GC for new elements in this transaction

commit 2ee52ae94baabf7ee09cf2a8d854b990dac5d0e4 upstream.

New elements in this transaction might expired before such transaction
ends. Skip sync GC for such elements otherwise commit path might walk
over an already released object. Once transaction is finished, async GC
will collect such expired element.

Fixes: f6c383b8c31a ("netfilter: nf_tables: adapt set backend to use GC transaction API")
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Gbp-Pq: Topic bugfix/all
Gbp-Pq: Name netfilter-nft_set_rbtree-skip-sync-gc-for-new-elemen.patch
net/netfilter/nft_set_rbtree.c