netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH nf-next v3 0/7] netfilter: nf_tables: avoid PROVE_RCU_LIST splats
@ 2024-11-04  9:41 Florian Westphal
  2024-11-04  9:41 ` [PATCH nf-next v3 1/7] netfilter: nf_tables: avoid false-positive lockdep splat on rule deletion Florian Westphal
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: Florian Westphal @ 2024-11-04  9:41 UTC (permalink / raw)
  To: netfilter-devel; +Cc: Florian Westphal

v3: don't check for type->owner and add comment saying check on
inner_ops is enough.
Use IS_ERR() instead of ptr == NULL in patch 7/7.
No other changes.

Mathieu reported a lockdep splat on rule deletion with
CONFIG_RCU_LIST=y.

Unfortunately there are many more errors, and not all are false positives.

First patches pass lockdep_commit_lock_is_held() to the rcu list traversal
macro so that those splats are avoided.

The last two patches are real code change as opposed to
'pass the transaction mutex to relax rcu check':

Those two lists are not protected by transaction mutex so could be altered
in parallel in case of module load/removal.

Florian Westphal (7):
  netfilter: nf_tables: avoid false-positive lockdep splat on rule
    deletion
  netfilter: nf_tables: avoid false-positive lockdep splats with sets
  netfilter: nf_tables: avoid false-positive lockdep splats with
    flowtables
  netfilter: nf_tables: avoid false-positive lockdep splats in set
    walker
  netfilter: nf_tables: avoid false-positive lockdep splats with
    basechain hook
  netfilter: nf_tables: must hold rcu read lock while iterating
    expression type list
  netfilter: nf_tables: must hold rcu read lock while iterating object
    type list

 include/net/netfilter/nf_tables.h |   3 +-
 net/netfilter/nf_tables_api.c     | 110 ++++++++++++++++++------------
 net/netfilter/nft_flow_offload.c  |   4 +-
 net/netfilter/nft_set_bitmap.c    |  10 +--
 net/netfilter/nft_set_hash.c      |   3 +-
 5 files changed, 79 insertions(+), 51 deletions(-)

-- 
2.45.2

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2024-11-05 23:15 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-04  9:41 [PATCH nf-next v3 0/7] netfilter: nf_tables: avoid PROVE_RCU_LIST splats Florian Westphal
2024-11-04  9:41 ` [PATCH nf-next v3 1/7] netfilter: nf_tables: avoid false-positive lockdep splat on rule deletion Florian Westphal
2024-11-04  9:41 ` [PATCH nf-next v3 2/7] netfilter: nf_tables: avoid false-positive lockdep splats with sets Florian Westphal
2024-11-04  9:41 ` [PATCH nf-next v3 3/7] netfilter: nf_tables: avoid false-positive lockdep splats with flowtables Florian Westphal
2024-11-04  9:41 ` [PATCH nf-next v3 4/7] netfilter: nf_tables: avoid false-positive lockdep splats in set walker Florian Westphal
2024-11-04  9:41 ` [PATCH nf-next v3 5/7] netfilter: nf_tables: avoid false-positive lockdep splats with basechain hook Florian Westphal
2024-11-04  9:41 ` [PATCH nf-next v3 6/7] netfilter: nf_tables: must hold rcu read lock while iterating expression type list Florian Westphal
2024-11-04  9:41 ` [PATCH nf-next v3 7/7] netfilter: nf_tables: must hold rcu read lock while iterating object " Florian Westphal
2024-11-05 23:14 ` [PATCH nf-next v3 0/7] netfilter: nf_tables: avoid PROVE_RCU_LIST splats Pablo Neira Ayuso

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).