del old ipc code && sema support timeout

This commit is contained in:
zhangzheng
2025-02-13 11:18:19 +08:00
parent 00804aaaaa
commit f86daa3169
55 changed files with 359 additions and 182 deletions

View File

@@ -0,0 +1,13 @@
#pragma
#include "thread.h"
typedef struct thread_wait_entry
{
slist_head_t node;
thread_t *th;
umword_t times;
} thread_wait_entry_t;
void thread_check_timeout(void);
thread_wait_entry_t *thread_sleep_del(thread_t *th);
void thread_sleep_del_and_wakeup(thread_t *th);
umword_t thread_sleep(umword_t tick);