diff options
author | Jakub Jelinek <jakub@redhat.com> | 2007-07-31 17:46:17 +0000 |
---|---|---|
committer | Jakub Jelinek <jakub@redhat.com> | 2007-07-31 17:46:17 +0000 |
commit | 8833066b122427710a9e14a888ce6cfa862332d3 (patch) | |
tree | 29591019d695919417b3698618d6a342e97381d6 /posix/sched.h | |
parent | fedca46896bdb702cb988837a0c2c5447e72ba2b (diff) | |
download | glibc-8833066b122427710a9e14a888ce6cfa862332d3.tar glibc-8833066b122427710a9e14a888ce6cfa862332d3.tar.gz glibc-8833066b122427710a9e14a888ce6cfa862332d3.tar.bz2 glibc-8833066b122427710a9e14a888ce6cfa862332d3.zip |
Updated to fedora-glibc-20070731T1624cvs/fedora-glibc-2_6_90-1
Diffstat (limited to 'posix/sched.h')
-rw-r--r-- | posix/sched.h | 43 |
1 files changed, 38 insertions, 5 deletions
diff --git a/posix/sched.h b/posix/sched.h index becad0f365..c9a0840f7f 100644 --- a/posix/sched.h +++ b/posix/sched.h @@ -25,6 +25,9 @@ /* Get type definitions. */ #include <bits/types.h> +#define __need_size_t +#include <stddef.h> + #define __need_timespec #include <time.h> @@ -66,11 +69,41 @@ extern int sched_rr_get_interval (__pid_t __pid, struct timespec *__t) __THROW; #ifdef __USE_GNU /* Access macros for `cpu_set'. */ # define CPU_SETSIZE __CPU_SETSIZE -# define CPU_SET(cpu, cpusetp) __CPU_SET (cpu, cpusetp) -# define CPU_CLR(cpu, cpusetp) __CPU_CLR (cpu, cpusetp) -# define CPU_ISSET(cpu, cpusetp) __CPU_ISSET (cpu, cpusetp) -# define CPU_ZERO(cpusetp) __CPU_ZERO (cpusetp) -# define CPU_COUNT(cpusetp) __CPU_COUNT (cpusetp) +# define CPU_SET(cpu, cpusetp) __CPU_SET_S (cpu, sizeof (cpu_set_t), cpusetp) +# define CPU_CLR(cpu, cpusetp) __CPU_CLR_S (cpu, sizeof (cpu_set_t), cpusetp) +# define CPU_ISSET(cpu, cpusetp) __CPU_ISSET_S (cpu, sizeof (cpu_set_t), \ + cpusetp) +# define CPU_ZERO(cpusetp) __CPU_ZERO_S (sizeof (cpu_set_t), cpusetp) +# define CPU_COUNT(cpusetp) __CPU_COUNT_S (sizeof (cpu_set_t), cpusetp) + +# define CPU_SET_S(cpu, setsize, cpusetp) __CPU_SET_S (cpu, setsize, cpusetp) +# define CPU_CLR_S(cpu, setsize, cpusetp) __CPU_CLR_S (cpu, setsize, cpusetp) +# define CPU_ISSET_S(cpu, setsize, cpusetp) __CPU_ISSET_S (cpu, setsize, \ + cpusetp) +# define CPU_ZERO_S(setsize, cpusetp) __CPU_ZERO_S (setsize, cpusetp) +# define CPU_COUNT_S(setsize, cpusetp) __CPU_COUNT_S (setsize, cpusetp) + +# define CPU_EQUAL(cpusetp1, cpusetp2) \ + __CPU_EQUAL_S (sizeof (cpu_set_t), cpusetp1, cpusetp2) +# define CPU_EQUAL_S(setsize, cpusetp1, cpusetp2) \ + __CPU_EQUAL_S (setsize, cpusetp1, cpusetp2) + +# define CPU_AND(destset, srcset1, srcset2) \ + __CPU_OP_S (sizeof (cpu_set_t), destset, srcset1, srcset2, &) +# define CPU_OR(destset, srcset1, srcset2) \ + __CPU_OP_S (sizeof (cpu_set_t), destset, srcset1, srcset2, |) +# define CPU_XOR(destset, srcset1, srcset2) \ + __CPU_OP_S (sizeof (cpu_set_t), destset, srcset1, srcset2, ^) +# define CPU_AND_S(setsize, destset, srcset1, srcset2) \ + __CPU_OP_S (setsize, destset, srcset1, srcset2, &) +# define CPU_OR_S(setsize, destset, srcset1, srcset2) \ + __CPU_OP_S (setsize, destset, srcset1, srcset2, |) +# define CPU_XOR_S(setsize, destset, srcset1, srcset2) \ + __CPU_OP_S (setsize, destset, srcset1, srcset2, ^) + +# define CPU_ALLOC_SIZE(count) __CPU_ALLOC_SIZE (count) +# define CPU_ALLOC(count) __CPU_ALLOC (count) +# define CPU_FREE(count) __CPU_FREE (count) /* Set the CPU affinity for a task */ |