summaryrefslogtreecommitdiffstats
path: root/patches/systemd-230/0003-missing-define-__NR_kcmp-if-necessary.patch
blob: 871ea1d43d8c519cf43ebb5301056a362b308d43 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
From: Michael Olbrich <m.olbrich@pengutronix.de>
Date: Thu, 5 Mar 2015 10:33:25 +0100
Subject: [PATCH] missing: define __NR_kcmp if necessary

Needed for Kernel Headers < v3.5

Not for upstream, but needed for host-systemd.

Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
---
 src/basic/missing_syscall.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/basic/missing_syscall.h b/src/basic/missing_syscall.h
index d502d3b9cad8..83c60d804531 100644
--- a/src/basic/missing_syscall.h
+++ b/src/basic/missing_syscall.h
@@ -235,6 +235,10 @@ static inline int renameat2(int oldfd, const char *oldname, int newfd, const cha
 
 /* ======================================================================= */
 
+#ifndef __NR_kcmp
+# define __NR_kcmp 0xffffffff
+#endif
+
 #if !HAVE_DECL_KCMP
 static inline int kcmp(pid_t pid1, pid_t pid2, int type, unsigned long idx1, unsigned long idx2) {
 #  ifdef __NR_kcmp