summaryrefslogtreecommitdiff
path: root/viengoos/viengoos.c
diff options
context:
space:
mode:
authorneal <neal>2007-11-23 13:39:36 +0000
committerneal <neal>2007-11-23 13:39:36 +0000
commit063d8339dfe16b6035375a00f3a6313f2dff083c (patch)
tree6e37ef358183bf00e277da95f46f2586f597bd64 /viengoos/viengoos.c
parent2b62e6480aaa4c3dcb73f45fa4977d6b2e7de080 (diff)
/
2007-11-23 Neal H. Walfield <neal@gnu.org> * README: Add note that Pistachio must be compiled with the Pager ExchangeRegisters configure option enabled. hurd/ 2007-11-23 Neal H. Walfield <neal@gnu.org> * thread.h: Include <hurd/addr-trans.h>. (HURD_EXREGS_EXCEPTION_THREAD): New definition. (trans_exregs): Take two additional arguments for determining how to copy the aspace address translation bits. Update callers. (thread_stop): New function. * rpc.h (RPC12_4): New macro. (RPC13_4): Likewise. * exceptions.h (exception_handler_init): New declaration. (exception_handler_loop): Likewise. libhurd-mm/ 2007-11-23 Neal H. Walfield <neal@gnu.org> * exceptions.c (exception_thread): Rename from this... (exception_handler_loop): ... to this. Update caller. * Makefile.am (libhurd_mm_a_SOURCES): Remove exceptions.h. * exceptions.h: Remove file. viengoos/ 2007-11-23 Neal H. Walfield <neal@gnu.org> * thread.h (thread_exregs): Take two additional arguments, a cap_addr_trans structure and a corresponding flags. Update users. * thread.c (thread_commission): Don't start thread THREAD. (control_to_string): New function. (thread_exregs): Take two additional arguments, a cap_addr_trans structure and a corresponding flags. Use them when copying a supplied capability into the address space slot of the thread. Support the HURD_EXREGS_EXCEPTION_THREAD flag. Improve error detection and debugging out. * server.c (server_loop): Let a void address for the activity slot imply the caller's current activity. Take two additional arguments, a cap_addr_trans structure and a corresponding flags argument. Pass them to thread_exregs. * viengoos.c (system_task_load): Set THREAD_ACTIVITY. Don't call thread_commission. Instead, call thread_exregs. ruth/ 2007-11-23 Neal H. Walfield <neal@gnu.org> * ruth.c (main): Don't call rm_object_slot_copy_in to update the address space slot. Just use rm_thread_exregs. Add test for pthread library. * ia32-cmain.c (cmain): If _pthread_init_routine is not NULL, call it. Otherwise, just call finish directly.
Diffstat (limited to 'viengoos/viengoos.c')
-rw-r--r--viengoos/viengoos.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/viengoos/viengoos.c b/viengoos/viengoos.c
index 2d66739..26e69e0 100644
--- a/viengoos/viengoos.c
+++ b/viengoos/viengoos.c
@@ -317,8 +317,7 @@ system_task_load (void)
startup_data->thread = csalloc ();
cap = allocate_object (cap_thread, startup_data->thread).cap;
thread = (struct thread *) cap_to_object (root_activity, &cap);
- thread->activity = object_to_cap (root_activity);
- thread_init (thread);
+ thread->activity = object_to_cap ((struct object *) root_activity);
/* Insert the objects we've allocated so far into TASK's address
space. */
@@ -411,7 +410,16 @@ system_task_load (void)
as_dump_from (root_activity, &thread->aspace, "");
}
- thread_commission (thread);
+ error_t err;
+ err = thread_exregs (root_activity, thread,
+ HURD_EXREGS_SET_SP_IP
+ | HURD_EXREGS_START | HURD_EXREGS_ABORT_IPC,
+ NULL, 0, (struct cap_addr_trans) CAP_ADDR_TRANS_VOID,
+ NULL, &thread->sp, &thread->ip, NULL, NULL,
+ NULL, NULL);
+ if (err)
+ panic ("Failed to start initial thread: %d", err);
+
debug (1, "System task started (tid: %x.%x; ip=0x%x).",
l4_thread_no (thread->tid), l4_version (thread->tid), thread->ip);
}