[Top] [All Lists]

when does "init" become usermode process

Subject: when does "init" become usermode process
Date: Fri, 14 Feb 2003 13:01:33 -0500
Original-recipient: rfc822;
  I was reading the kernel boot code toward the end where kernel's init thread 
execve("/sbin/init",x,x). Execve() calls sys_execve() and do_execve(). All the 
manpage and kernel document told us the init is the first usermode process 
running in the system. However, when the execve("/sbin/init",x,x) runs in the 
kernel (init/main.c), I believe we are still in the kernel mode, aren't we? 
Unless execve() does the trick to turn init into usermode by setting the KU bit 
in the STATUS register. I checked the execve() code and its not obvious whether 
it does this or not. I then check the init source code and it does not mess 
around the KU bit either.

My question is when and how does init turn itself into usermode.



The NEW Netscape 7.0 browser is now available. Upgrade now! 

Get your own FREE, personal Netscape Mail account today at

<Prev in Thread] Current Thread [Next in Thread>