On Tue, Nov 15, 2016 at 2:45 PM, Andrei Vagin <ava...@gmail.com> wrote: > On Tue, Nov 15, 2016 at 2:21 PM, Andrei Vagin <ava...@gmail.com> wrote: >> I would like to agree with you here, but looks like sockets with >> NETLINK_F_LISTEN_ALL_NSID are able to catch these messages. > > Actually I found that I was wrong. > > do_one_broadcast() sends a notification only if a device network > namespace has an id in a socket netns. But cleanup_net() removes all > id-s to a target namespace, so just ignore my last comment.
The point is all sockets in that netns are already gone at that point because of refcount. cleanup_net() also destroys net->netns_ids, so it should not be even accessed after that point.