Al Viro a685e08987 Delay struct net freeing while there's a sysfs instance refering to it
* new refcount in struct net, controlling actual freeing of the memory
	* new method in kobj_ns_type_operations (->drop_ns())
	* ->current_ns() semantics change - it's supposed to be followed by
corresponding ->drop_ns().  For struct net in case of CONFIG_NET_NS it bumps
the new refcount; net_drop_ns() decrements it and calls net_free() if the
last reference has been dropped.  Method renamed to ->grab_current_ns().
	* old net_free() callers call net_drop_ns() instead.
	* sysfs_exit_ns() is gone, along with a large part of callchain
leading to it; now that the references stored in ->ns[...] stay valid we
do not need to hunt them down and replace them with NULL.  That fixes
problems in sysfs_lookup() and sysfs_readdir(), along with getting rid
of sb->s_instances abuse.

	Note that struct net *shutdown* logics has not changed - net_cleanup()
is called exactly when it used to be called.  The only thing postponed by
having a sysfs instance refering to that struct net is actual freeing of
memory occupied by struct net.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2011-06-12 17:45:41 -04:00
..
2008-07-24 10:47:33 -07:00
2011-03-11 14:25:50 +00:00
2008-06-06 11:29:10 -07:00
2011-03-31 11:26:23 -03:00
2009-11-03 16:06:53 +01:00
2011-03-31 11:26:23 -03:00
2010-07-11 22:16:32 +02:00
2009-06-18 13:04:05 -07:00
2010-05-25 08:07:06 -07:00
2010-04-06 15:52:11 -07:00
2008-07-26 12:00:07 -07:00
2010-08-09 20:45:05 -07:00
2011-06-01 16:06:04 -04:00
2010-11-22 13:25:13 +10:00
2011-05-25 08:39:52 -07:00
2011-03-31 11:26:23 -03:00
2011-03-11 15:14:48 -05:00
2010-06-16 18:08:13 +02:00
2010-01-11 09:34:05 -08:00
2008-07-26 12:00:10 -07:00
2011-03-31 11:26:23 -03:00
2010-05-19 22:40:47 -04:00