From d5b3917b25ab5a03f04d640a5ccce0f42b4ccd66 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Wed, 1 Sep 2004 15:48:36 +0000 Subject: [PATCH] Introduced new thread_entry_func type. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@8778 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/kernel/core/thread.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/kernel/core/thread.c b/src/kernel/core/thread.c index 4ecb978d29..ffdcbc72fb 100644 --- a/src/kernel/core/thread.c +++ b/src/kernel/core/thread.c @@ -274,7 +274,8 @@ _create_kernel_thread_kentry(void) static thread_id -create_thread(const char *name, team_id teamID, thread_func entry, void *args1, void *args2, int32 priority, bool kernel) +create_thread(const char *name, team_id teamID, thread_entry_func entry, + void *args1, void *args2, int32 priority, bool kernel) { struct thread *t; struct team *team; @@ -1084,7 +1085,7 @@ thread_per_cpu_init(int32 cpu_num) thread_id spawn_kernel_thread_etc(thread_func function, const char *name, int32 priority, void *arg, team_id team) { - return create_thread(name, team, function, arg, NULL, priority, true); + return create_thread(name, team, (thread_entry_func)function, arg, NULL, priority, true); } @@ -1563,7 +1564,8 @@ resume_thread(thread_id id) thread_id spawn_kernel_thread(thread_func function, const char *name, int32 priority, void *arg) { - return create_thread(name, team_get_kernel_team()->id, function, arg, NULL, priority, true); + return create_thread(name, team_get_kernel_team()->id, (thread_entry_func)function, + arg, NULL, priority, true); } @@ -1657,7 +1659,7 @@ _user_set_thread_priority(thread_id thread, int32 newPriority) thread_id -_user_spawn_thread(thread_func entry, const char *userName, int32 priority, void *data1, void *data2) +_user_spawn_thread(int32 (*entry)(thread_func, void *), const char *userName, int32 priority, void *data1, void *data2) { char name[B_OS_NAME_LENGTH];