Tenok
A Linux-like Real-Time Operating System for Robotics and Internet of Things
thread.h
Go to the documentation of this file.
1 
4 #ifndef __KERNEL_THREAD_H__
5 #define __KERNEL_THREAD_H__
6 
7 #include <stddef.h>
8 #include <sys/sched.h>
9 
10 #include <common/list.h>
11 
12 #define CURRENT_THREAD_INFO(var) struct thread_info *var = current_thread_info()
13 
14 struct thread_attr {
15  struct sched_param schedparam;
16  void *stackaddr;
17  size_t stacksize; /* Bytes */
18  int schedpolicy;
19  int detachstate;
20 };
21 
22 struct thread_once {
23  struct list_head wait_list;
24  bool finished;
25 };
26 
27 struct thread_info *current_thread_info(void);
28 struct thread_info *acquire_thread(int tid);
29 
30 #endif
Definition: list.h:111
Definition: sched.h:12
Definition: thread.h:14
Definition: kernel.h:68
Definition: thread.h:22