linux-rt-users.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] cyclictest: fix #ifdef broken by NO_PTHREAD_SETAFFINITY
@ 2015-10-21 16:34 John Kacur
  2015-10-21 18:13 ` Henrik Austad
  0 siblings, 1 reply; 2+ messages in thread
From: John Kacur @ 2015-10-21 16:34 UTC (permalink / raw)
  To: linux-rt-users; +Cc: Clark Williams, Henrik Austad

>From 73bc7345eebb2244efc527928fdac7b8e29193cd Mon Sep 17 00:00:00 2001
From: John Kacur <jkacur@redhat.com>
Date: Wed, 21 Oct 2015 18:25:37 +0200
Subject: [PATCH] cyclictest: fix #ifdef broken by NO_PTHREAD_SETAFFINITY

Unfortunately c869f3cdcd023eec2f767eb4094caa88178717a4 wasn't sufficient
to fix #ifdef #else functionality for uclib, broken by the changes for
bionic.

In practice this probably didn't break anyone though, except possibly
for the new bionic code which probaly doesn't have too many adapters
(yet).

This should also help Henrik move the NO_PTHREAD_SETAFFINITY functionality to
the bionic file.

Signed-off-by: John Kacur <jkacur@redhat.com>
---
 src/cyclictest/cyclictest.c | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/src/cyclictest/cyclictest.c b/src/cyclictest/cyclictest.c
index 00168e22fc7f..975e7858fb8e 100644
--- a/src/cyclictest/cyclictest.c
+++ b/src/cyclictest/cyclictest.c
@@ -83,6 +83,10 @@ int sched_setaffinity (__pid_t __pid, size_t __cpusetsize,
 #define CPU_SET(cpu, cpusetp)
 #define CPU_ZERO(cpusetp)
 
+#else
+extern int clock_nanosleep(clockid_t __clock_id, int __flags,
+			   __const struct timespec *__req,
+			   struct timespec *__rem);
 #endif
 
 #ifdef NO_PTHREAD_SETAFFINITY
@@ -91,11 +95,6 @@ static inline int pthread_setaffinity_np(pthread_t thread, size_t cpusetsize,
 {
     return sched_setaffinity(0, cpusetsize, cpuset);
 }

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-10-21 18:13 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-21 16:34 [PATCH] cyclictest: fix #ifdef broken by NO_PTHREAD_SETAFFINITY John Kacur
2015-10-21 18:13 ` Henrik Austad

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).