diff --git a/kernel/kernel_compat.c b/kernel/kernel_compat.c index 3e216657e637..9c468ca49086 100644 --- a/kernel/kernel_compat.c +++ b/kernel/kernel_compat.c @@ -3,13 +3,10 @@ #include "linux/nsproxy.h" #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 10, 0) #include "linux/sched/task.h" -#include "linux/uaccess.h" -#elif LINUX_VERSION_CODE >= KERNEL_VERSION(4, 4, 0) -#include "linux/uaccess.h" -#include "linux/sched.h" #else #include "linux/sched.h" #endif +#include "linux/uaccess.h" #include "klog.h" // IWYU pragma: keep #if LINUX_VERSION_CODE < KERNEL_VERSION(4, 10, 0) diff --git a/kernel/ksud.c b/kernel/ksud.c index d571ef091108..95cea5499117 100644 --- a/kernel/ksud.c +++ b/kernel/ksud.c @@ -3,7 +3,15 @@ #include "linux/dcache.h" #include "linux/err.h" #include "linux/fs.h" +#include "linux/version.h" +#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 4, 0) #include "linux/input-event-codes.h" +#else +#include "uapi/linux/input.h" +#endif +#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 1, 0) +#include "linux/aio.h" +#endif #include "linux/kprobes.h" #include "linux/printk.h" #include "linux/types.h"