]> www.infradead.org Git - users/hch/misc.git/commit
Merge branch 'phonet-convert-all-doit-and-dumpit-to-rcu'
authorPaolo Abeni <pabeni@redhat.com>
Thu, 24 Oct 2024 14:04:27 +0000 (16:04 +0200)
committerPaolo Abeni <pabeni@redhat.com>
Thu, 24 Oct 2024 14:04:28 +0000 (16:04 +0200)
commit8b448f0dbcae0c18c3fb97caf8aeff5fec19a9a2
treeb4400b49c6e28c4f2de27509b4868f1064cb52c3
parent1bf70e6c3a5346966c25e0a1ff492945b25d3f80
parent17a1ac0018ae1cee0b2c2235ce54e91ecbbed7be
Merge branch 'phonet-convert-all-doit-and-dumpit-to-rcu'

Kuniyuki Iwashima says:

====================
phonet: Convert all doit() and dumpit() to RCU.

addr_doit() and route_doit() access only phonet_device_list(dev_net(dev))
and phonet_pernet(dev_net(dev))->routes, respectively.

Each per-netns struct has its dedicated mutex, and RTNL also protects
the structs.  __dev_change_net_namespace() has synchronize_net(), so
we have two options to convert addr_doit() and route_doit().

  1. Use per-netns RTNL
  2. Use RCU and convert each struct mutex to spinlock_t

As RCU is preferable, this series converts all PF_PHONET's doit()
and dumpit() to RCU.

4 doit()s and 1 dumpit() are now converted to RCU, 70 doit()s and
28 dumpit()s are still under RTNL.
====================

Link: https://patch.msgid.link/20241017183140.43028-1-kuniyu@amazon.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>