Index: kernel/generic/include/proc/thread.h
===================================================================
--- kernel/generic/include/proc/thread.h	(revision cfffb29045b608bdb22354635488347597622ae3)
+++ kernel/generic/include/proc/thread.h	(revision e11ae91fc3a4227bcea74717abb36d585ceb5627)
@@ -53,5 +53,5 @@
 #define THREAD_STACK_SIZE	STACK_SIZE
 
-/**< Thread states. */
+/** Thread states. */
 enum state {
 	Invalid,	/**< It is an error, if thread is found in this state. */
@@ -66,5 +66,5 @@
 extern char *thread_states[];
 
-/**< Join types. */
+/** Join types. */
 typedef enum {
 	None,
@@ -73,6 +73,8 @@
 } thread_join_type_t;
 
-#define X_WIRED		(1<<0)
-#define X_STOLEN	(1<<1)
+/* Thread flags */
+#define THREAD_FLAG_WIRED	(1<<0)	/**< Thread cannot be migrated to another CPU. */
+#define THREAD_FLAG_STOLEN	(1<<1)	/**< Thread was migrated to another CPU and has not run yet. */
+#define THREAD_FLAG_USPACE	(1<<2)	/**< Thread executes in userspace. */
 
 #define THREAD_NAME_BUFLEN	20
@@ -128,5 +130,5 @@
 	 * Defined only if thread doesn't run.
 	 * It means that fpu context is in CPU that last time executes this thread.
-	 * This disables migration
+	 * This disables migration.
 	 */
 	int fpu_context_engaged;
@@ -150,5 +152,5 @@
 	thread_arch_t arch;			/**< Architecture-specific data. */
 
-	uint8_t *kstack;				/**< Thread's kernel stack. */
+	uint8_t *kstack;			/**< Thread's kernel stack. */
 };
 
@@ -171,4 +173,10 @@
 extern void thread_create_arch(thread_t *t);
 #endif
+#ifndef thr_constructor_arch
+extern void thr_constructor_arch(thread_t *t);
+#endif
+#ifndef thr_destructor_arch
+extern void thr_destructor_arch(thread_t *t);
+#endif
 
 extern void thread_sleep(uint32_t sec);
