mirror of
https://github.com/genodelabs/genode.git
synced 2025-06-21 00:23:16 +00:00
base: introduce platform_init function
The new 'init_platform' function performs the platform-specific component-local low-level initialization. It allows for the differentiation between core and regular components as well as kernel-dependent peculiarities. This patch introduces a consistent notion of a 'Platform'. Within core, the 'Platform' contains the kernel-specific initialization. Outside core, the platform sets up the interplay with the parent component. In all cases, the platform is constructed while running on the initial stack. Issue #4784
This commit is contained in:
@ -87,6 +87,9 @@ Platform &Core::platform_specific()
|
||||
Platform_generic &Core::platform() { return platform_specific(); }
|
||||
|
||||
|
||||
void Genode::init_platform() { core_env(); }
|
||||
|
||||
|
||||
Thread_capability Genode::main_thread_cap() { return Thread_capability(); }
|
||||
|
||||
|
||||
@ -185,12 +188,10 @@ class Core_child : public Child_policy
|
||||
****************/
|
||||
|
||||
/*
|
||||
* In contrast to the 'Platform_env' used by non-core components, core disables
|
||||
* the signal thread but overriding 'Genode::init_signal_thread' with a dummy.
|
||||
* Within core, the signal thread is not needed as core is never supposed to
|
||||
* receive any signals. Otherwise, the signal thread would be the only
|
||||
* non-entrypoint thread within core, which would be a problem on NOVA where
|
||||
* the creation of regular threads within core is unsupported.
|
||||
* In contrast to non-core components, core disables the signal thread by
|
||||
* overriding 'Genode::init_signal_thread' with a dummy. Within core, the
|
||||
* signal thread is not needed as core is never supposed to receive any
|
||||
* signals.
|
||||
*/
|
||||
|
||||
void Genode::init_signal_thread(Env &) { }
|
||||
|
Reference in New Issue
Block a user