Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 08 Feb 2010 16:12:48 +0100
From:      Ivan Voras <ivoras@freebsd.org>
To:        freebsd-questions@freebsd.org
Subject:   Re: The first file loaded is?
Message-ID:  <hkp9la$ip5$1@ger.gmane.org>
In-Reply-To: <3C2D9FDCACFBCB4183516E784E9DC7DE17D09128@cocoaex3.brevard.cc.fl.us>
References:  <3C2D9FDCACFBCB4183516E784E9DC7DE17D09128@cocoaex3.brevard.cc.fl.us>

next in thread | previous in thread | raw e-mail | index | archive | help
On 02/08/10 15:23, Decker, Ross wrote:
> I'm just starting my adventure into BSD along with C++.  I know that
> this OS gives you all the source files that are used in the OS. What I'm
> asking, is what is the name of the first file that is loaded and where
> is the source file for it? I want to start with the very first line of
> code and see if I can step my way through the entire boot process. There
> are many things that I see during boot up that I have no idea what they
> are (SMAP Type....) that aren't that Google Friendly.
>
> So if anyone knows the names of the source files and their locations for
> the boot sequence could you please post them..... SUPER thank you's!

Your question is very vague.

The first executed code on an IBM-PC is the boot loader, look at 
sys/boot/boot0.

First executed lines of the kernel are at mi_startup() in 
sys/kern/init_main.c.

First executed lines of userland code are in the "init" process, in 
sbin/init/init.c.

All paths are relative to /usr/src.




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?hkp9la$ip5$1>