Re: [PATCH] net: Convert net_mutex into rw_semaphore and down read it on net->init/->exit

From: Stephen Hemminger
Date: Tue Nov 14 2017 - 13:11:55 EST


On Tue, 14 Nov 2017 16:53:33 +0300
Kirill Tkhai <ktkhai@xxxxxxxxxxxxx> wrote:

> + /*
> + * RCU-protected list, modifiable by pernet-init and -exit methods.
> + * When net namespace is alive (net::count > 0), all the changes
> + * are made under rw_sem held on write.
> + */
> + struct list_head fib_notifier_ops;
>

If you use __rcu annotation then it could be checked (and the comment is not needed).