From: David S. Miller Date: Sun, 1 Apr 2018 02:24:58 +0000 (-0400) Subject: Merge branch 'net_rwsem-fixes' X-Git-Tag: v5.15~9146^2~27 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b3834acdd78e2b626d576e90c502727da5a46e3c;p=platform%2Fkernel%2Flinux-starfive.git Merge branch 'net_rwsem-fixes' Kirill Tkhai says: ==================== net_rwsem fixes there is wext_netdev_notifier_call()->wireless_nlevent_flush() netdevice notifier, which takes net_rwsem, so we can't take net_rwsem in {,un}register_netdevice_notifier(). Since {,un}register_netdevice_notifier() is executed under pernet_ops_rwsem, net_namespace_list can't change, while we holding it, so there is no need net_rwsem in these functions [1/2]. The same is in [2/2]. We make callers of __rtnl_link_unregister() take pernet_ops_rwsem, and close the race with setup_net() and cleanup_net(), so __rtnl_link_unregister() does not need it. This also fixes the problem of that __rtnl_link_unregister() does not see initializing and exiting nets. ==================== Signed-off-by: David S. Miller --- b3834acdd78e2b626d576e90c502727da5a46e3c