parent
a507928cde
commit
16deaa9a72
|
@ -19,6 +19,7 @@
|
||||||
#include <util/string.h>
|
#include <util/string.h>
|
||||||
#include <base/thread.h>
|
#include <base/thread.h>
|
||||||
#include <base/heap.h>
|
#include <base/heap.h>
|
||||||
|
#include <os/timed_semaphore.h>
|
||||||
|
|
||||||
/* base-internal includes */
|
/* base-internal includes */
|
||||||
#include <base/internal/unmanaged_singleton.h>
|
#include <base/internal/unmanaged_singleton.h>
|
||||||
|
@ -679,6 +680,9 @@ void Component::construct(Genode::Env &env)
|
||||||
|
|
||||||
Link_map::dump();
|
Link_map::dump();
|
||||||
|
|
||||||
|
/* FIXME: remove 'Timeout_thread' from the base library */
|
||||||
|
Timeout_thread::env(env);
|
||||||
|
|
||||||
binary_ready_hook_for_gdb();
|
binary_ready_hook_for_gdb();
|
||||||
|
|
||||||
/* start binary */
|
/* start binary */
|
||||||
|
|
|
@ -47,7 +47,9 @@ class Genode::Timeout_thread : public Thread_deprecated<2048*sizeof(long)>,
|
||||||
|
|
||||||
enum { JIFFIES_STEP_MS = 10 };
|
enum { JIFFIES_STEP_MS = 10 };
|
||||||
|
|
||||||
Timer::Connection _timer; /* timer session */
|
static Genode::Env *_env;
|
||||||
|
|
||||||
|
Timer::Connection _timer { *_env }; /* timer session */
|
||||||
Signal_context _context;
|
Signal_context _context;
|
||||||
Signal_receiver _receiver;
|
Signal_receiver _receiver;
|
||||||
|
|
||||||
|
@ -68,6 +70,8 @@ class Genode::Timeout_thread : public Thread_deprecated<2048*sizeof(long)>,
|
||||||
* Returns the singleton timeout-thread used for all timeouts.
|
* Returns the singleton timeout-thread used for all timeouts.
|
||||||
*/
|
*/
|
||||||
static Timeout_thread *alarm_timer();
|
static Timeout_thread *alarm_timer();
|
||||||
|
|
||||||
|
static void env(Genode::Env &env) { _env = &env; }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -14,6 +14,9 @@
|
||||||
#include <os/timed_semaphore.h>
|
#include <os/timed_semaphore.h>
|
||||||
|
|
||||||
|
|
||||||
|
Genode::Env *Genode::Timeout_thread::_env = nullptr;
|
||||||
|
|
||||||
|
|
||||||
void Genode::Timeout_thread::entry()
|
void Genode::Timeout_thread::entry()
|
||||||
{
|
{
|
||||||
while (true) {
|
while (true) {
|
||||||
|
|
Loading…
Reference in New Issue