User:Lionel/James Molloy's Kernel Development Tutorials
James Molly's Kernel Development Tutorials are a set of 10 tutorials written in C that teach and guide an individual on how to create a unix-style kernel. This tutorial, while notorious for several bad design decisions, is still a great learning resource. It can be seen as a successor to Bran's Kernel Development Tutorials.
The kernel created with this tutorial has some... interesting design choices. In this context "interesting" equals "potentially destructive". http://wiki.osdev.org/James_Molloy%27s_Tutorial_Known_Bugs points out most of them.
The tutorial can be accessed at http://www.jamesmolloy.co.uk/tutorial_html/index.html
Google Code Version
There is an experimental version of the tutorial avalable at https://code.google.com/p/jamesm-tutorials/ . The tutorial seems to be more advanced, to the point of even including a working printf implementation.
Analysis of the tutorial
This tutorial implements:
- A bootable kernel
- A text mode terminal
- Interrupts & (x86) Exception support
- The PIT
- A kernel heap
- A Virtual Filesystem & Initrd
- Preemptive Multitasking
- Usermode (Ring 3)
Customising the Kernel
I would recommend changing the function names to your liking. I would also recommend implementing printf().
Create your own paging implementation, as this one makes several bad design decisions which can cripple a kernel in the long run.
Create your own memory allocation system or use a premade one.
VFS & Initrd
Create your own Initrd filesystem.