1 /* 2 * Copyright 2009, Ingo Weinhold, ingo_weinhold@gmx.de. 3 * Distributed under the terms of the MIT License. 4 */ 5 #ifndef THREAD_H 6 #define THREAD_H 7 8 #include <OS.h> 9 10 11 struct thread; 12 13 14 static inline struct thread* 15 get_current_thread() 16 { 17 return (struct thread*)find_thread(NULL); 18 } 19 20 21 static inline thread_id 22 get_thread_id(struct thread* thread) 23 { 24 return (thread_id)thread; 25 } 26 27 28 #endif // THREAD_H 29