Index: kernel/generic/include/proc/thread.h
===================================================================
--- kernel/generic/include/proc/thread.h	(revision f429331b6108df4294a421a92f3e9aaa64d95732)
+++ kernel/generic/include/proc/thread.h	(revision da1f9dc1583ac0512bc6f526a7d3e477ee640173)
@@ -54,5 +54,5 @@
 
 /** Thread states. */
-enum state {
+typedef enum {
 	Invalid,	/**< It is an error, if thread is found in this state. */
 	Running,	/**< State of a thread that is currently executing on some CPU. */
@@ -62,5 +62,5 @@
 	Exiting,	/**< After a thread calls thread_exit(), it is put into Exiting state. */
 	Undead		/**< Threads that were not detached but exited are in the Undead state. */
-};
+} state_t;
 
 extern char *thread_states[];
Index: kernel/generic/include/typedefs.h
===================================================================
--- kernel/generic/include/typedefs.h	(revision f429331b6108df4294a421a92f3e9aaa64d95732)
+++ kernel/generic/include/typedefs.h	(revision da1f9dc1583ac0512bc6f526a7d3e477ee640173)
@@ -49,5 +49,4 @@
 
 typedef struct task task_t;
-typedef enum state state_t;
 typedef struct thread thread_t;
 typedef struct context context_t;
