1. Mar 20, 2018
  2. Mar 14, 2018
  3. Mar 06, 2018
  4. Mar 05, 2018
    • David S. Miller's avatar
      Merge branch 'convert-pernet_operations-part4' · 229952d1
      David S. Miller authored
      
      
      Kirill Tkhai says:
      
      ====================
      Converting pernet_operations (part #4)
      
      this series continues to review and to convert pernet_operations
      to make them possible to be executed in parallel for several
      net namespaces in the same time. The patches touch mostly netfilter,
      also there are small number of changes in other places.
      ====================
      
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      229952d1
    • Kirill Tkhai's avatar
      net: Convert proto_gre_net_ops · c29babb7
      Kirill Tkhai authored
      
      
      These pernet_operations register and unregister sysctl.
      nf_conntrack_l4proto_gre4->init_net is simple memory
      initializer. Also, exit method removes gre keymap_list,
      which is per-net. This looks safe to be executed
      in parallel with other pernet_operations.
      
      Signed-off-by: default avatarKirill Tkhai <ktkhai@virtuozzo.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      c29babb7
    • Kirill Tkhai's avatar
      net: Convert ctnetlink_net_ops · b04a3d09
      Kirill Tkhai authored
      
      
      These pernet_operations register and unregister
      two conntrack notifiers, and they seem to be safe
      to be executed in parallel.
      
      General/not related to async pernet_operations JFI:
      ctnetlink_net_exit_batch() actions are grouped in batch,
      and this could look like there is synchronize_rcu()
      is forgotten. But there is synchronize_rcu() on module
      exit patch (in ctnetlink_exit()), so this batch may
      be reworked as simple .exit method.
      
      Signed-off-by: default avatarKirill Tkhai <ktkhai@virtuozzo.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b04a3d09
    • Kirill Tkhai's avatar
      net: Convert nf_conntrack_net_ops · 467d14b3
      Kirill Tkhai authored
      
      
      These pernet_operations register and unregister sysctl and /proc
      entries. Exit batch method also waits till all per-net conntracks
      are dead. Thus, they are safe to be marked as async.
      
      Signed-off-by: default avatarKirill Tkhai <ktkhai@virtuozzo.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      467d14b3
    • Kirill Tkhai's avatar
      net: Convert ip_set_net_ops · a5a179b6
      Kirill Tkhai authored
      
      
      These pernet_operations initialize and destroy
      net_generic(net, ip_set_net_id)-related data.
      Since ip_set is under CONFIG_IP_SET, it's easy
      to watch drivers, which depend on this config.
      All of them are in net/netfilter/ipset directory,
      except of net/netfilter/xt_set.c. There are no
      more drivers, which use ip_set, and all of
      the above don't register another pernet_operations.
      Also, there are is no indirect users, as header
      file include/linux/netfilter/ipset/ip_set.h does
      not define indirect users by something like this:
      
      	#ifdef CONFIG_IP_SET
      	extern func(void);
      	#else
      	static inline func(void);
      	#endif
      
      So, there are no more pernet operations, dereferencing
      net_generic(net, ip_set_net_id).
      
      ip_set_net_ops are OK to be executed in parallel
      for several net, so we mark them as async.
      
      Signed-off-by: default avatarKirill Tkhai <ktkhai@virtuozzo.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a5a179b6
    • Kirill Tkhai's avatar
      net: Convert fou_net_ops · 6c6c566e
      Kirill Tkhai authored
      
      
      These pernet_operations initialize and destroy
      pernet net_generic(net, fou_net_id) list.
      The rest of net_generic(net, fou_net_id) accesses
      may happen after netlink message, and in-tree
      pernet_operations do not send FOU_GENL_NAME messages.
      So, these pernet_operations are safe to be marked
      as async.
      
      Signed-off-by: default avatarKirill Tkhai <ktkhai@virtuozzo.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6c6c566e
    • Kirill Tkhai's avatar
      net: Convert dccp_v6_ops · 16b0c0c4
      Kirill Tkhai authored
      
      
      These pernet_operations looks similar to dccp_v4_ops,
      and they are also safe to be marked as async.
      
      Signed-off-by: default avatarKirill Tkhai <ktkhai@virtuozzo.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      16b0c0c4
    • Kirill Tkhai's avatar
      net: Convert dccp_v4_ops · 5368bd72
      Kirill Tkhai authored
      
      
      These pernet_operations create and destroy net::dccp::v4_ctl_sk.
      It looks like another pernet_operations don't want to send
      dccp packets to dying or creating net. Batch method similar
      to ipv4/ipv6 sockets and it has to be safe to be executed
      in parallel with anything else. So, we mark them as async.
      
      Signed-off-by: default avatarKirill Tkhai <ktkhai@virtuozzo.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      5368bd72