[okl4-developer] threads linked to ThreadControl
Nelson Tam
nelson at ok-labs.com
Fri Jun 6 11:02:28 EST 2008
Hi Charles,
On 05/06/2008, at 10:11 PM, Charles.VANWITTENBERGHE at fr.thalesgroup.com
wrote:
> Hello,
>
> I'd like to have some explanations about the exception_handler_thread,
> scheduler_thread, and pager_thread.
>
> * Are the three of them user defined ?
Yes, they are defined by the user when L4_ThreadControl() is called to
create a thread.
> * The purpose of the exception_handler_thread is obvious, but what are
> the purpose of the scheduler_thread and the pager_thread ?
The short answer is that the scheduler thread will have permissions to
call L4_Schedule() on the newly-created thread, which means it can
modify the timeslice and priority of said thread. The details of who
can call L4_Schedule() is documented in the L4 Reference Manual.
The pager thread is the thread who gets sent an IPC from the kernel
when the target thread pagefaults. The IPC is called a pagefault IPC
because it contains information about the pagefault, which allows the
pager to allocate and map memory appropriately.
> * Do exception_handler and scheduler really have to be set to the same
> thread when using SYS_THREAD_CONTROL ?
No. There are no restrictions that they have to be the same, but it
is the general practice for pragmatic reasons.
--
(nt)
Nelson Tam
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 1560 bytes
Desc: not available
Url : http://lists.okl4.org/pipermail/developer/attachments/20080606/67398b54/attachment.bin
More information about the Developer
mailing list