lkml.org 
[lkml]   [1996]   [Mar]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: sys_setup()
Date
Followup to:  <3148227F.2EE9BF1@cacofonix.nt.tuwien.ac.at>
By author: Klaus Kudielka <kkudielk@cacofonix.nt.tuwien.ac.at>
In newsgroup: linux.dev.kernel
>
> Hello,
>
> I'm currently debugging the MCA patches for Linux. I'm at 1.3.72.
>
> What I like to know is:
>
> 1.) Who calls sys_setup() (filesystems.c) during booting? Since the
> function is asmlinkage I assume it is called from an assembler file.
> Anyway, I could not find the call in ANY .S file in the source tree.
>

It's asmlinkage because it is a system call. It is run from the user
mode code in main.c (before it execs init.)

>
> 2.) What is the boot-up sequence of the assembler files -- up to the
> point where start_kernel() (main.c) is called? These files are very
> difficult to read.
>

For Linux/i386:

arch/i386/boot/bootsect.S i386 real mode code, only on raw floppy boots
arch/i386/boot/setup.S i386 real mode code (starts protected mode)
arch/i386/kernel/head.S i386 protected mode (enables paging)
arch/i386/kernel/setup.c i386-specific setup
init/main.c non-architecture specific setup

When booting with LILO, LOADLIN or SYSLINUX, bootsect.S is never
executed; the bootloader does the corresponding work and jumps
directly into setup.S.

-hpa
--
PGP public key available - finger hpa@zytor.com
"The earth is but one country, and mankind its citizens." -- Bahá'u'lláh
I don't work for Yggdrasil, but they sponsor the linux.* hierarchy.


\
 
 \ /
  Last update: 2005-03-22 13:36    [W:0.023 / U:0.568 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site