OpenVZ Forum


Home » Mailing lists » Devel » [PATCH 0/12 net-2.6.26] icmp_socket namespacing
Re: Purpose of __net_exit & friends [message #27886 is a reply to message #27885] Fri, 29 February 2008 20:23 Go to previous messageGo to previous message
davem is currently offline  davem
Messages: 463
Registered: February 2006
Senior Member
From: Sam Ravnborg <sam@ravnborg.org>
Date: Fri, 29 Feb 2008 21:12:47 +0100

> On Fri, Feb 29, 2008 at 11:23:42AM -0800, David Miller wrote:
> > From: "Denis V. Lunev" <den@openvz.org>
> > Date: Fri, 29 Feb 2008 16:40:58 +0300
> > 
> > > +static void __net_exit icmpv6_sk_exit(struct net *net)
> > > +{
> > 
> > Since you call this from __new_init code, won't this
> > create a section conflict when ipv6 is built statically
> > into the kernel?
> 
> I have noticed this __net_init/__net_exit stuff before
> but never got around to ask about it.
> 
> Whats the actual purpose and are there any strict
> rules as to what may be called from where?
> If there are we should apply the same checks as we do
> for __devinit/__devexit and friends.

Basically, if network namespace support isn't enabled,
these functions can act like normal __init and __exit
functions.

Otherwise we have to keep them around so that they can
be called when namespaces are created and destroyed.
_______________________________________________
Containers mailing list
Containers@lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/containers
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: A strange behavior of sched_fair
Next Topic: Re: [PATCH 0/2] Fix /proc/net in presence of net namespaces
Goto Forum:
  


Current Time: Wed Sep 18 15:49:43 GMT 2024

Total time taken to generate the page: 0.04622 seconds