summaryrefslogtreecommitdiff
path: root/packages/uclibc/uclibc-0.9.29/uClibc-0.9.29-conditional-sched_affinity.patch
diff options
context:
space:
mode:
authorKoen Kooi <koen@openembedded.org>2007-10-12 07:54:22 +0000
committerKoen Kooi <koen@openembedded.org>2007-10-12 07:54:22 +0000
commitac24763c52746d29e474e296392a9d5a1e29fdf2 (patch)
tree51668635e08d0a0c6b60bb5ef9448f40d9e5bc75 /packages/uclibc/uclibc-0.9.29/uClibc-0.9.29-conditional-sched_affinity.patch
parent6e737e8e1c8bf4a168a8f62c5d5ae2f4424319b2 (diff)
parentc751ec57bd75446f7dbc99e1c5a403b383cc0b48 (diff)
merge of '5e25d910364ba4a7edab739d7fd27220ff39668f'
and '90a4eb99d1b346a81de3232bd341d5b76a2bbc2c'
Diffstat (limited to 'packages/uclibc/uclibc-0.9.29/uClibc-0.9.29-conditional-sched_affinity.patch')
-rw-r--r--packages/uclibc/uclibc-0.9.29/uClibc-0.9.29-conditional-sched_affinity.patch53
1 files changed, 53 insertions, 0 deletions
diff --git a/packages/uclibc/uclibc-0.9.29/uClibc-0.9.29-conditional-sched_affinity.patch b/packages/uclibc/uclibc-0.9.29/uClibc-0.9.29-conditional-sched_affinity.patch
new file mode 100644
index 0000000000..509c42af52
--- /dev/null
+++ b/packages/uclibc/uclibc-0.9.29/uClibc-0.9.29-conditional-sched_affinity.patch
@@ -0,0 +1,53 @@
+diff -ur uClibc-0.9.29/libc/sysdeps/linux/common/sched_getaffinity.c uClibc-0.9.29-patched/libc/sysdeps/linux/common/sched_getaffinity.c
+--- uClibc-0.9.29/libc/sysdeps/linux/common/sched_getaffinity.c 2007-02-12 16:52:32.000000000 -0600
++++ uClibc-0.9.29-patched/libc/sysdeps/linux/common/sched_getaffinity.c 2007-05-09 18:05:09.397411811 -0500
+@@ -29,6 +29,7 @@
+ #include <sys/param.h>
+ #include <sys/types.h>
+
++#ifdef __NR_sched_getaffinity
+ libc_hidden_proto(memset)
+
+ #define __NR___syscall_sched_getaffinity __NR_sched_getaffinity
+@@ -48,5 +49,15 @@
+ }
+ return res;
+ }
++#else
++/*
++int sched_getaffinity(pid_t pid, size_t cpusetsize, cpu_set_t *cpuset)
++{
++ __set_errno(ENOSYS);
++ return -1;
++}
++*/
+ #endif
+ #endif
++
++#endif
+diff -ur uClibc-0.9.29/libc/sysdeps/linux/common/sched_setaffinity.c uClibc-0.9.29-patched/libc/sysdeps/linux/common/sched_setaffinity.c
+--- uClibc-0.9.29/libc/sysdeps/linux/common/sched_setaffinity.c 2007-02-12 16:52:32.000000000 -0600
++++ uClibc-0.9.29-patched/libc/sysdeps/linux/common/sched_setaffinity.c 2007-05-09 18:05:09.397411811 -0500
+@@ -31,6 +31,7 @@
+ #include <sys/types.h>
+ #include <alloca.h>
+
++#ifdef __NR_sched_setaffinity
+ libc_hidden_proto(getpid)
+
+ #define __NR___syscall_sched_setaffinity __NR_sched_setaffinity
+@@ -74,5 +75,14 @@
+
+ return INLINE_SYSCALL (sched_setaffinity, 3, pid, cpusetsize, cpuset);
+ }
++#else
++/*
++int sched_setaffinity(pid_t pid, size_t cpusetsize, const cpu_set_t *cpuset)
++{
++ __set_errno(ENOSYS);
++ return -1;
++}
++*/
++#endif
+ #endif
+ #endif