posted by Julien Quintard on Tue 27th Jun 2006 17:33 UTC

"kaneton Microkernel, 2/7"

4. The kaneton microkernel

A microkernel based operating system is composed of two parts: a microkernel which runs on every processor machine of the system and a collection of servers that provide most of traditional operating system functionalities: drivers, file servers etc..

The microkernel has four primary functionalities to provide:

  1. Communication.
  2. Memory management.
  3. Process management.
  4. I/O.

Although the microkernel architecture is modular, the kaneton microkernel is also subdivided into managers. This subdivision leads to a better understanding since each manager provides an interface to control a precise type of kaneton object.

For example, there exists an address space manager, a task manager, a thread manager etc.. So the reader interested in understanding how the threads are implemented in kaneton just has to read the source code in relation with the thread manager, nothing more.

Moreover, each manager interface's functions naming follows a precise nomenclature. This nomenclature leads to a better coherence of the whole microkernel.

We will now describe microkernel's components to understand how the kaneton microkernel provides communication, memory management, process management etc..

4.1 Communication

The kaneton microkernel and more generally the distributed operating system use messages to communicate with everything.

Keep in mind that the kaneton project must be as simple as possible to be understood by students.

To unify communications via messages, the microkernel translates every event into a message. For example, when an interrupt is received by the kernel interrupt handler, a message is built and forwarded to the server dedicated to this interrupt. So, each server just has to take care of how to receive messages and how to reply to them.

Note that no group communication is provided by the microkernel. Indeed, the group communication concept is inherent to the distributed operating system. Therefore, the group communication will not be explained in this paper.

Moreover, unlike UNIX-like operating systems, the kaneton microkernel does not use signals. Indeed, the goal of the kaneton microkernel is not to be as fast as a monolithic type kernel like Linux.

The kaneton project focuses on genericity, coherency, abstractions etc.

Finally, the kaneton message passing interface was designed based on well-known parallel and distributed programming libraries like MPI. From this fact, the kaneton microkernel directly includes parallel and distributed facilities.

4.2 Memory

The memory model of the kaneton microkernel is very simple.

Each address space of the system is composed of segments and regions.

A segment consists in a linear sequence of physical addresses. A segment describes one area of physical memory including the first address, the last but also some properties like the owner of this segment, the permissions: execution, read, write etc.. and some extra attributes. Segments can be accessed via mappings or directly via the segment manager interface provided by the kaneton microkernel.

A region consists in a linear sequence of virtual addresses. A region has no properties and is only used to map a valid segment. Using a region in the virtual memory will reference the segment's data it maps.

An address space is a list of memory locations. In the kaneton microkernel, an address space includes the list of the segments and regions. So, an address space describes the available process' memory.

Like the entire system, the kaneton memory model is based on little objects which are linked to build more complex objects. An address space is composed of segments and regions. This model implies that a program is allowed to manage its entire memory itself, its physical memory like its virtual one.

Note that we do not explain the memory algorithm used to manage physical memory areas. Indeed, the memory manager uses the set manager to store its data. For this reason, the segment manager can easily change the algorithm used for storing its data.

By easily we mean that a single word has to be modified in the source code.

For more information about the set manager, please refer to its specific section.

Table of contents
  1. "kaneton Microkernel, 1/7"
  2. "kaneton Microkernel, 2/7"
  3. "kaneton Microkernel, 3/7"
  4. "kaneton Microkernel, 4/7"
  5. "kaneton Microkernel, 5/7"
  6. "kaneton Microkernel, 6/7"
  7. "kaneton Microkernel, 7/7"
e p (0)    20 Comment(s)

Technology White Papers

See More