#ifndef _KTHREAD_H
#define _KTHREAD_H
-#include <linux/config.h>
#include <linux/version.h>
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,17))
+#include <linux/config.h>
+#endif
#include <linux/kernel.h>
#include <linux/sched.h>
#include <linux/tqueue.h>
#define tasklet_struct tq_struct
#else
- #include <linux/devfs_fs_kernel.h>
+ #if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,17))
+ #include <linux/devfs_fs_kernel.h>
+ #endif
#endif
#include <linux/wait.h>
#include <linux/interrupt.h>
#include <asm/unistd.h>
-#include <asm/semaphore.h>
+
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,27))
+ #include <asm/semaphore.h>
+#else
+ #include <linux/semaphore.h>
+#endif
/* a structure to store all information we need
for our thread */