diff options
author | "Steven J. Hill" <sjhill@realitydiluted.com> | 2005-07-22 08:00:47 +0000 |
---|---|---|
committer | "Steven J. Hill" <sjhill@realitydiluted.com> | 2005-07-22 08:00:47 +0000 |
commit | 6e8c30a9b99892f23293bd13b7a544197627fa69 (patch) | |
tree | c0867f0f50982f79dfb9465c9c8557257ce0d3e0 /libpthread/nptl/sysdeps/unix/sysv | |
parent | 4ace63889357f5ffc8b96a8a6144352e7ce56eec (diff) | |
download | uClibc-alpine-6e8c30a9b99892f23293bd13b7a544197627fa69.tar.bz2 uClibc-alpine-6e8c30a9b99892f23293bd13b7a544197627fa69.tar.xz |
Added new files for TLS functionality in libpthreads and for the dynamic loader. The headers may be moved to the 'ldso' directory hierarchy at a later date depending on what we run into when implementating changes to the loader.
Diffstat (limited to 'libpthread/nptl/sysdeps/unix/sysv')
-rw-r--r-- | libpthread/nptl/sysdeps/unix/sysv/linux/kernel-posix-cpu-timers.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/libpthread/nptl/sysdeps/unix/sysv/linux/kernel-posix-cpu-timers.h b/libpthread/nptl/sysdeps/unix/sysv/linux/kernel-posix-cpu-timers.h new file mode 100644 index 000000000..164a90dde --- /dev/null +++ b/libpthread/nptl/sysdeps/unix/sysv/linux/kernel-posix-cpu-timers.h @@ -0,0 +1,18 @@ +/* Parameters for the Linux kernel ABI for CPU clocks. */ + +#define CPUCLOCK_PID(clock) ((pid_t) ~((clock) >> 3)) +#define CPUCLOCK_PERTHREAD(clock) \ + (((clock) & (clockid_t) CPUCLOCK_PERTHREAD_MASK) != 0) +#define CPUCLOCK_PID_MASK 7 +#define CPUCLOCK_PERTHREAD_MASK 4 +#define CPUCLOCK_WHICH(clock) ((clock) & (clockid_t) CPUCLOCK_CLOCK_MASK) +#define CPUCLOCK_CLOCK_MASK 3 +#define CPUCLOCK_PROF 0 +#define CPUCLOCK_VIRT 1 +#define CPUCLOCK_SCHED 2 +#define CPUCLOCK_MAX 3 + +#define MAKE_PROCESS_CPUCLOCK(pid, clock) \ + ((~(clockid_t) (pid) << 3) | (clockid_t) (clock)) +#define MAKE_THREAD_CPUCLOCK(tid, clock) \ + MAKE_PROCESS_CPUCLOCK((tid), (clock) | CPUCLOCK_PERTHREAD_MASK) |