From fb19d9f5c0b9d5306a678d6a97b9601886d22cc4 Mon Sep 17 00:00:00 2001 From: Johnny Willemsen Date: Fri, 9 Aug 2013 16:54:08 +0000 Subject: Fri Aug 9 16:53:17 UTC 2013 Johnny Willemsen * ace/config-linux.h: Linux kernel 2.8.8 and newer have sched_getaffinity and sched_getaffinity --- ACE/ChangeLog | 6 ++++++ ACE/ace/config-linux.h | 15 +++++++++------ 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/ACE/ChangeLog b/ACE/ChangeLog index 6590a404339..ec224af4beb 100644 --- a/ACE/ChangeLog +++ b/ACE/ChangeLog @@ -1,3 +1,9 @@ +Fri Aug 9 16:53:17 UTC 2013 Johnny Willemsen + + * ace/config-linux.h: + Linux kernel 2.8.8 and newer have sched_getaffinity and + sched_getaffinity + Fri Aug 9 14:27:56 UTC 2013 Johnny Willemsen * tests/Compiler_Features_22_DLL.h: diff --git a/ACE/ace/config-linux.h b/ACE/ace/config-linux.h index 3115b40d499..641ac9b2541 100644 --- a/ACE/ace/config-linux.h +++ b/ACE/ace/config-linux.h @@ -356,13 +356,14 @@ # define ACE_HAS_GETIFADDRS #endif +#if !defined (ACE_LACKS_LINUX_VERSION_H) +# include +#endif /* !ACE_LACKS_LINUX_VERSION_H */ + #if !defined (ACE_GETNAME_RETURNS_RANDOM_SIN_ZERO) // Detect if getsockname() and getpeername() returns random values in // the sockaddr_in::sin_zero field by evaluation of the kernel // version. Since version 2.5.47 this problem is fixed. -# if !defined (ACE_LACKS_LINUX_VERSION_H) -# include -# endif /* !ACE_LACKS_LINUX_VERSION_H */ # if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,47)) # define ACE_GETNAME_RETURNS_RANDOM_SIN_ZERO 0 # else @@ -371,14 +372,16 @@ #endif /* ACE_GETNAME_RETURNS_RANDOM_SIN_ZERO */ #if !defined (ACE_HAS_EVENT_POLL) && !defined (ACE_HAS_DEV_POLL) -# if !defined (ACE_LACKS_LINUX_VERSION_H) -# include -# endif /* !ACE_LACKS_LINUX_VERSION_H */ # if (LINUX_VERSION_CODE > KERNEL_VERSION (2,6,0)) # define ACE_HAS_EVENT_POLL # endif #endif +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,8)) +# define ACE_HAS_SCHED_GETAFFINITY 1 +# define ACE_HAS_SCHED_SETAFFINITY 1 +#endif + // This is ghastly, but as long as there are platforms supported // which define the right POSIX macros but lack actual support // we have no choice. -- cgit v1.2.1