lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <201009160906134537778@gmail.com>
Date:	Thu, 16 Sep 2010 09:06:16 +0800
From:	"Huangqiang Zhou" <linuxkernel.xqiang@...il.com>
To:	"ly" <ly@...oo.com.cn>
Cc:	"linux-net" <linux-net@...r.kernel.org>,
	"netdev" <netdev@...r.kernel.org>
Subject: How about the order of Network stack initialize

Hi all:

I have a question about the order of  network stack initialize.

From some books it says the order is as below:
1.core_initcall: sock_init
2.fs_initcall: inet_init
3.subsys_initcall: net_dev_init
4.device_initcall: device init

in the source code of linux2.6.18:
#define core_initcall(fn) __define_initcall("1",fn)
#define postcore_initcall(fn) __define_initcall("2",fn)
#define arch_initcall(fn) __define_initcall("3",fn)
#define subsys_initcall(fn) __define_initcall("4",fn)
#define fs_initcall(fn) __define_initcall("5",fn)
#define device_initcall(fn) __define_initcall("6",fn)
#define late_initcall(fn) __define_initcall("7",fn)

obviously:
macro                 section
core_initcall <--> .initcall1.init 
fs_initcall <--> .initcall5.init
subsys_initcall <--> .initcall4.init
device_intcall <--> .initcall6.init

Some also says:
“Every child is to determine the sequence between sections, the first call. Initcall1 init. 
 The function pointer, again. Initcall2 init. Call the function pointer, etc. And in each section 
 of the function pointer is associated with links to order, is uncertain ”

 As the above says, the order should be: core_initcall->subsys_initcall->fs_initcall->device_intcall

So which one is really correct?

2010-09-15 
Huangqiang Zhou

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ