Re: understanding the kernel

2006-10-31 Thread Damian Wiest
On Sun, Oct 29, 2006 at 11:18:28PM -0700, George Mihai IACOB wrote:
 Jonathan Gray wrote:
 On Sun, Oct 29, 2006 at 08:24:16PM -0700, George Mihai IACOB wrote:
 Hello!
 
 I am a not-so-experienced programmer and I started a personal project 
 which requires a deep understanding of the OpenBSD kernel - no, I am not 
 going to fork another BSD style operating system. I wonder if there is 
 documentation describing the kernel, other that the comments in the 
 source. For a start, I am reading Andrew Tanenbaum's Modern Operating 
 Systems, 2nd edition and trying to follow the code in the kernel 
 source, starting with sys/kern/init_main.c
 Is this a wrong approach? Do you have other suggestions? I know there's 
 no easy way and I am not looking for one, all I want is a starting point.
 Regards,
 George
 
 You don't mention what you had in mind so it is hard to point at anything.
 The Design and Implementation of the 4.4 BSD Operating System by
 McKusick and friends is likely to be more relevant for implementation
 details, Tanebaum's book is more high level theory.
 
 
 Well, I want to be able to write software which should run in kernel 
 mode and/or modify the kernel. Basically, I'm just like a college 
 student taking an operating systems course and using OpenBSD as an example.

Operating System Concepts by Silbershatz, Galvin and Gagne:
http://codex.cs.yale.edu/avi/os-book/os7/

As a bonus, there are pretty dinosaur pictures at the start of each 
chapter.

Also, get the BSD book mentioned above.

-Damian



understanding the kernel

2006-10-29 Thread George Mihai IACOB

Hello!

I am a not-so-experienced programmer and I started a personal project 
which requires a deep understanding of the OpenBSD kernel - no, I am not 
going to fork another BSD style operating system. I wonder if there is 
documentation describing the kernel, other that the comments in the 
source. For a start, I am reading Andrew Tanenbaum's Modern Operating 
Systems, 2nd edition and trying to follow the code in the kernel 
source, starting with sys/kern/init_main.c
Is this a wrong approach? Do you have other suggestions? I know there's 
no easy way and I am not looking for one, all I want is a starting point.

Regards,
George



Re: understanding the kernel

2006-10-29 Thread Jonathan Gray
On Sun, Oct 29, 2006 at 08:24:16PM -0700, George Mihai IACOB wrote:
 Hello!
 
 I am a not-so-experienced programmer and I started a personal project 
 which requires a deep understanding of the OpenBSD kernel - no, I am not 
 going to fork another BSD style operating system. I wonder if there is 
 documentation describing the kernel, other that the comments in the 
 source. For a start, I am reading Andrew Tanenbaum's Modern Operating 
 Systems, 2nd edition and trying to follow the code in the kernel 
 source, starting with sys/kern/init_main.c
 Is this a wrong approach? Do you have other suggestions? I know there's 
 no easy way and I am not looking for one, all I want is a starting point.
 Regards,
 George

You don't mention what you had in mind so it is hard to point at anything.
The Design and Implementation of the 4.4 BSD Operating System by
McKusick and friends is likely to be more relevant for implementation
details, Tanebaum's book is more high level theory.



Re: understanding the kernel

2006-10-29 Thread Otto Moerbeek
On Sun, 29 Oct 2006, George Mihai IACOB wrote:

 Hello!
 
 I am a not-so-experienced programmer and I started a personal project which
 requires a deep understanding of the OpenBSD kernel - no, I am not going to
 fork another BSD style operating system. I wonder if there is documentation
 describing the kernel, other that the comments in the source. For a start, I
 am reading Andrew Tanenbaum's Modern Operating Systems, 2nd edition and
 trying to follow the code in the kernel source, starting with
 sys/kern/init_main.c
 Is this a wrong approach? Do you have other suggestions? I know there's no
 easy way and I am not looking for one, all I want is a starting point.
 Regards,
 George

A lot of internal kernel APIs are documented in section 9 of the man
pages.  And, while this may be superfluous, the public API, also known
as system calls are described in section 2. 

-Otto