projects
/
platform
/
kernel
/
linux-starfive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0e7b492
)
tools/nolibc/sys: add syscall definition for getppid()
author
Willy Tarreau
<w@1wt.eu>
Mon, 21 Mar 2022 17:33:11 +0000
(18:33 +0100)
committer
Paul E. McKenney
<paulmck@kernel.org>
Thu, 21 Apr 2022 00:05:45 +0000
(17:05 -0700)
This is essentially for completeness as it's not the most often used
in regtests.
Signed-off-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
tools/include/nolibc/sys.h
patch
|
blob
|
history
diff --git
a/tools/include/nolibc/sys.h
b/tools/include/nolibc/sys.h
index
2843786
..
4d4308d
100644
(file)
--- a/
tools/include/nolibc/sys.h
+++ b/
tools/include/nolibc/sys.h
@@
-465,6
+465,23
@@
pid_t getpid(void)
/*
+ * pid_t getppid(void);
+ */
+
+static __attribute__((unused))
+pid_t sys_getppid(void)
+{
+ return my_syscall0(__NR_getppid);
+}
+
+static __attribute__((unused))
+pid_t getppid(void)
+{
+ return sys_getppid();
+}
+
+
+/*
* pid_t gettid(void);
*/