Menu

Nucleo kernel architecture

0xJarno

Nucleo kernel architecture

DOCUMENT NOT UP TO DATE

This document describes the internal architecture of the Nucleo kernel

As in the kernel.txt file

message pasing ("http://wiki.osdev.org/Message_Passing")
type: reliable on top of unreliable
length: variable length
sync: asynchronous
each proces has a messagebox, actually this is a bunch of strings (messages) terminated by a zero, two zero's detarminate the stack (messagebox) and three zero's end up the whole message buffer (array)
to send a message a systemcall is used, the register values are: ax: pointer to procces name; bx: pid, cx: tid, dx: pointer to message. the send_message syntax is: type (boolean: reliable or unreliable), message, 0. the recieve_message syntax is the same exept the type and the procces name, pid and tid are the one's of the sender in place of the reciever
each proces has to check what messages it has, or it can tell the kernel it wants to be notificated when it has one or more, a app that uses notification needs a special function that will be called when it has one or more messages. when the messagehandler has finished it's work it will tell the kernel by way setting a boolean flag from O to 1. (before the kernel jumps to the proces handler it will set the flag to 1)
an exeption is when the flag is still 1, this means the proces isn't ready reading it's messages and is still reading and therefore ti's not needed to notificate it again.
* procces name : the name of the proces withoud special characters etc. (needs to be registered on teh central app_db) if there still occurs an error the procces names get numbered ex: hello_1 and hello_2 (hello_3 etc...)
pid : this is a number used by the system and / or applications to point to procceses (it's just counting up, ex: first executed: 0, second executed 1 etc...)
tid : this is the same as the pid but for a thread
type : reliable / unreliable (boolean)
flag : this is tha flag that sais if the messagehandler is present.
revice_message : the form of the message the reciever gets
*** send_message : the form of the message the sender gives
shared memory ("http://wiki.osdev.org/Shared_Memory")
the kernel supports shared memory, asking the memory mapper to give a application shared memory is done by way of a systemcall.
an application first need to confirm and then the memory will be shared. if the procces doen't confirm the the asking procces gets an error
remote procedure call's ("http://wiki.osdev.org/RPC")


Related

Wiki: Home

MongoDB Logo MongoDB