From 52b67ddcf6086f2d385e1e8c1784645807a8d9b6 Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Mon, 8 Aug 2022 14:46:34 +0200 Subject: resource.h: add missing RUSAGE_THREAD There is a real-world usage of RUSAGE_THREAD by the pistache project, https://github.com/oktal/pistache. Reported-By: Thomas Petazzoni --- libc/sysdeps/linux/sparc64/bits/resource.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'libc/sysdeps/linux/sparc64/bits') diff --git a/libc/sysdeps/linux/sparc64/bits/resource.h b/libc/sysdeps/linux/sparc64/bits/resource.h index 255fb9734..f1e11e239 100644 --- a/libc/sysdeps/linux/sparc64/bits/resource.h +++ b/libc/sysdeps/linux/sparc64/bits/resource.h @@ -180,6 +180,15 @@ enum __rusage_who /* All of its terminated child processes. */ RUSAGE_CHILDREN = -1 #define RUSAGE_CHILDREN RUSAGE_CHILDREN + +#ifdef __USE_GNU + , + /* The calling thread. */ + RUSAGE_THREAD = 1 +# define RUSAGE_THREAD RUSAGE_THREAD + /* Name for the same functionality on Solaris. */ +# define RUSAGE_LWP RUSAGE_THREAD +#endif }; #define __need_timeval -- cgit v1.2.3