Commit Graph

73 Commits

Author SHA1 Message Date
Martin Stein
9f95784f02 hw: diversify feedback from IPC node to thread
ref #1108
2014-04-07 17:11:20 +02:00
Martin Stein
f0ec8b27c1 hw: no argument to Ipc_node::_await_ipc_succeeded
ref #1108
2014-04-07 17:10:38 +02:00
Martin Stein
b55646e1b0 hw: remove Ipc_node::_received_ipc_request
ref #1108
2014-04-07 17:10:28 +02:00
Martin Stein
8d1e40eb5b hw: remove Ipc_node::_await_ipc
ref #1108
2014-04-07 17:10:22 +02:00
Martin Stein
ebfd6a55b3 hw: remove useless argument of Thread::_call
ref #1108
2014-04-07 17:10:10 +02:00
Martin Stein
02c16e7106 hw: split resume_local_thread from resume_thread
Kernel::resume_thread was restricted to core when the targeted thread was in
another domain. Now there are two kernel calls, resume_local_thread and
resume_thread, where the former is never restricted and is provided via
public kernel/interface.h and the latter is always restricted to core and
is provided via core-local kernel/core_interface.h.

ref #1101
2014-04-07 17:09:52 +02:00
Martin Stein
c72f91fefb hw: simplify return value of Kernel::resume_thread
ref #1101
2014-04-07 17:09:33 +02:00
Martin Stein
9e089e7e75 hw: don't use assert in Kernel::start_thread
ref #1101
2014-04-07 17:08:11 +02:00
Martin Stein
fba4f54571 hw: split pause_current_thread from pause_thread
Kernel::pause_current_thread can be implemented much simpler and is not
restricted to core threads, in contrast to Kernel::pause_thread which
also benefits from the split and can be moved to core_interface.h.

ref #1101
2014-04-07 17:07:24 +02:00
Martin Stein
e2268c09a0 hw: move core-restricted interface to local header
fix #1096
2014-04-07 17:02:50 +02:00
Martin Stein
852785324f hw: move Processor_client to processor.h
ref #1088
2014-03-14 13:17:37 +01:00
Martin Stein
8818d810a1 hw: clean-up destruction of processor clients
ref #1088
2014-03-14 13:17:36 +01:00
Martin Stein
17f17df74b hw: rename Execution_context in Processor_client
ref #1088
2014-03-14 13:17:36 +01:00
Martin Stein
7bdb8c9007 hw: let Processor inherit from Processor_driver
ref #1083
2014-03-04 19:04:50 +01:00
Martin Stein
5d444a12dc hw: rename Genode::Cpu in Processor_driver
ref #1083
2014-03-04 19:04:16 +01:00
Martin Stein
f9ea52db9a hw: rename cpu.h in processor_driver.h
ref #1083
2014-03-04 19:03:58 +01:00
Martin Stein
1335b7b550 hw: rename handle_exception() in exception()
fix #1078
2014-03-04 19:02:30 +01:00
Martin Stein
7cea03f695 hw: move Thread::_processor to Execution_context
ref #1078
2014-03-04 18:58:51 +01:00
Martin Stein
6a3368ee27 hw_arndale: idle threads on secondary processors
fix #1006
2014-03-04 15:03:43 +01:00
Martin Stein
49eeb485d9 hw: mark caller when printing an activity-table
ref #989
2013-12-20 14:48:06 +01:00
Martin Stein
8eef91f2ac hw: do not block on destruction of signal receiver
As synchronization of signal contexts is now the users business instead of
cores and the signal framework ensures that every context of a receiver gets
synchronously destructed before the destruction of the receiver itself
synchronization and thus blocking at the destruction of a kernel
receiver-object isn't necessary anymore.

ref #989
2013-12-20 14:48:06 +01:00
Martin Stein
1c8c30e1f4 hw: sync signal contexts directly as user
Kernel::signal_context_kill can be used by any program to halt the processing
of a signal context synchronously to prevent broken refs when core destructs
the according kernel object. In turn, Kernel::bin_signal_context doesn't block
anymore and destructs a signal context no matter if there are unacknowledged
signals. This way, cores entrypoint doesn't depend on signal acks of a
untrustworthy client anymore.

ref #989
2013-12-20 14:48:06 +01:00
Martin Stein
3bdf70f771 hw: rename kill_* functions in bin_*
In the future bin_* means the direct destruction of a kernel object
without any blocking. kill_* in contrast is used for bringing a
kernel object such as signal contexts synchronized into a sleeping
state from where they can be destructed without the risk of getting
broken refs in userland.

ref #989
2013-12-20 14:48:06 +01:00
Martin Stein
f356ad2bdf hw: print activity table via Kernel::print_char(0)
ref #964
2013-12-03 08:33:25 +01:00
Martin Stein
d46b30a711 hw: clarify names of messaging kernel-calls
ref #958
2013-12-03 08:33:23 +01:00
Martin Stein
b694045bd9 hw: get rid of Kernel::current_thread_id
Every thread receives a startup message from its creator through the initial
state of its userland thread-context. The thread-startup code remembers the
kernel name of the new thread by reading this message before the userland
thread-context gets polluted. This way, Kernel::current_thread_id becomes
unnecessary.

fix #953
2013-11-25 09:46:08 +01:00
Martin Stein
fde150b052 hw: rename delete_thread in kill_thread
ref #953
2013-11-25 09:45:31 +01:00
Martin Stein
99c649c42f hw: simplify Kernel::new_thread
Don't set priority and label in platform thread and then communicate this
core object via Kernel::new_thread but communicate priority and label directly.
This way kernel doesn't need to know anymore what a platform thread is.

ref #953
2013-11-25 09:45:31 +01:00
Martin Stein
210216e5e1 hw: simplify Kernel::start_thread
Instead of writing initial thread context to the platform-thread members
and then communicating this core object to kernel, core calls
Kernel::access_thread_regs first to initialize thread context and then
Kernel::start_thread without a platform-thread pointer. This way
the frontend as well as the backend of Kernel::start_thread loose
complexity and it is a first step to remove platform thread from the
vocabulary of the kernel.

ref #953
2013-11-25 09:45:31 +01:00
Martin Stein
77f55232fd hw: remove Kernel::get_thread
ref #953
2013-11-25 09:45:31 +01:00
Martin Stein
e0419b2401 hw: clearer naming scheme in kernel API
Rename kernel syscall in kernel call and the kernel-API
files in kernel/interface* .

ref #953
2013-11-25 09:45:30 +01:00
Martin Stein
909ab8dcd0 hw: communicate page faults via signals
Enable routing of thread events to signal contexts via
Kernel::route_thread_event.

Replace Kernel::set_pager by Kernel::route_thread_event.

In base-hw a pager object is a signal context and a pager activation
is a signal receiver. If a thread wants to start communicating its page
faults via a pager object, the thread calls Kernel::route_thread_event with
its thread ID, event ID "FAULT", and the signal context ID of the pager object.
If a pager activation wants to start handling page faults of a pager object,
the pager activation assigns the corresponding signal context to its signal
receiver. If a pager activation wants to stop handling page faults of a pager
object, the pager activation dissolves the corresponding signal context from
its signal receiver. If a thread wants to start communicating its page faults
via a pager object, the thread calls Kernel::route_thread_event with its
thread ID, event ID "FAULT", and the invalid signal context ID.

Remove Kernel::resume_faulter.

Move all page fault related code from generic kernel sources to CPU
specific cpu_support.h and cpu_support.cc.

fix #935
2013-11-14 19:57:31 +01:00
Martin Stein
15a56bd682 hw: provide and use syscall access_thread_regs
ref #935
2013-11-14 19:57:30 +01:00
Martin Stein
47744e0019 hw: handle interrupts via signals
fix #874
2013-11-14 19:57:30 +01:00
Martin Stein
002a5b8978 hw: distinct pagefault and IPC message type
ref #874
2013-11-14 19:56:39 +01:00
Martin Stein
96bbca6191 hw: send reply size & receive request size by UTCB
ref #874
2013-11-14 19:56:38 +01:00
Martin Stein
6b9376bb01 hw: clean up interface of Kernel::Thread
ref #874
2013-11-14 19:56:38 +01:00
Martin Stein
ffb26eb501 hw: make syscall backend private to Kernel::Thread
ref #874
2013-11-14 19:56:38 +01:00
Martin Stein
0bb6ffa98d hw: header and source file for Kernel::Vm
ref #874
2013-11-14 19:56:38 +01:00
Martin Stein
22d61c241e hw: remove useless function handle_invalid_excpt
ref #874
2013-11-14 19:56:38 +01:00
Stefan Kalkowski
265ec48c20 hw: implement priority-based scheduling (fix #945) 2013-11-12 15:01:54 +01:00
Martin Stein
c56927b76e hw: differ ID allocators even with same size
Previously, if two ID allocators for different kernel objects had the
same size, the kernel-object framework managed both objects types
through the same allocator instance. This is caused by the use of
unsynchronized singletons in the accessor functions and can be avoided
by creating new types through inheritance instead of using typedefs.
Anyways, this fix is a little bit ugly and should replaced by avoiding
the use of unsynchronized singletons in the future.

fix #906
2013-10-22 08:00:14 +02:00
Martin Stein
0ad655f4be hw: return error code on IPC replies
ref #899
2013-10-16 09:26:10 +02:00
Martin Stein
ae76e441b1 hw: fix bug in Kernel::Thread::resume
ref #899
2013-10-16 09:26:10 +02:00
Martin Stein
b85126a638 hw: enable verbose thread starts
ref #899
2013-10-16 09:26:10 +02:00
Martin Stein
d961b9ae1e hw: enable multiple compilation units in kernel
ref #899
2013-10-16 09:26:10 +02:00
Martin Stein
d6d4938916 hw: fix bug in Kernel::yield_thread
ref #899
2013-10-16 09:26:10 +02:00
Martin Stein
6912e638fb hw: kill signal receivers
ref #899
2013-10-16 09:26:10 +02:00
Martin Stein
c3be0b417a hw: fix bug in Kernel::Thread::crash
ref #589
2013-09-26 16:09:55 +02:00
Martin Stein
a596fa56a6 hw: destruct scheduling contexts
ref #589
2013-09-26 15:58:05 +02:00