From 462a088c474832b19ff2730de1e6bea66d399c23 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karel=20Ko=C4=8D=C3=AD?= Date: Sat, 15 Oct 2022 23:01:29 +0200 Subject: Add Turris kernel (includes patches from OpenWrt) --- ...only-include-asm-rwonce.h-for-kernel-code.patch | 29 ++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 pkgs/patches-linux-5.15/100-compiler.h-only-include-asm-rwonce.h-for-kernel-code.patch (limited to 'pkgs/patches-linux-5.15/100-compiler.h-only-include-asm-rwonce.h-for-kernel-code.patch') diff --git a/pkgs/patches-linux-5.15/100-compiler.h-only-include-asm-rwonce.h-for-kernel-code.patch b/pkgs/patches-linux-5.15/100-compiler.h-only-include-asm-rwonce.h-for-kernel-code.patch new file mode 100644 index 0000000..22f52c1 --- /dev/null +++ b/pkgs/patches-linux-5.15/100-compiler.h-only-include-asm-rwonce.h-for-kernel-code.patch @@ -0,0 +1,29 @@ +From: Felix Fietkau +Date: Thu, 22 Oct 2020 22:00:03 +0200 +Subject: [PATCH] compiler.h: only include asm/rwonce.h for kernel code + +This header file is not in uapi, which makes any user space code that includes +linux/compiler.h to fail with the error 'asm/rwonce.h: No such file or directory' + +Fixes: e506ea451254 ("compiler.h: Split {READ,WRITE}_ONCE definitions out into rwonce.h") +Signed-off-by: Felix Fietkau +--- + +--- a/include/linux/compiler.h ++++ b/include/linux/compiler.h +@@ -220,6 +220,8 @@ void ftrace_likely_update(struct ftrace_ + #define function_nocfi(x) (x) + #endif + ++#include ++ + #endif /* __KERNEL__ */ + + /* +@@ -252,6 +254,4 @@ static inline void *offset_to_ptr(const + */ + #define prevent_tail_call_optimization() mb() + +-#include +- + #endif /* __LINUX_COMPILER_H */ -- cgit v1.2.3