1
linux/include/net/netns
Eric W. Biederman 5ee4433efe netns: Fail conspicously if someone uses net_generic at an inappropriate time.
By definition net_generic should never be called when it can return
NULL.  Fail conspicously with a BUG_ON to make it clear when people mess
up that a NULL return should never happen.

Recently there was a bug in the CAIF subsystem where it was registered
with register_pernet_device instead of register_pernet_subsys.  It was
erroneously concluded that net_generic could validly return NULL and
that net_assign_generic was buggy (when it was just inefficient).
Hopefully this BUG_ON will prevent people to coming to similar erroneous
conclusions in the futrue.

Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Tested-by: Sasha Levin <levinsasha928@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2012-01-27 21:06:02 -05:00
..
conntrack.h netfilter: nf_conntrack: make event callback registration per-netns 2011-11-22 00:34:47 +01:00
core.h
dccp.h
generic.h netns: Fail conspicously if someone uses net_generic at an inappropriate time. 2012-01-27 21:06:02 -05:00
hash.h
ipv4.h per-netns ipv4 sysctl_tcp_mem 2011-12-12 19:04:11 -05:00
ipv6.h ipv6: ip6mr: support multiple tables 2010-05-11 14:40:55 +02:00
mib.h net: use IS_ENABLED(CONFIG_IPV6) 2011-12-11 18:25:16 -05:00
packet.h
unix.h
x_tables.h
xfrm.h net: use IS_ENABLED(CONFIG_IPV6) 2011-12-11 18:25:16 -05:00