public inbox for newlib-cvs@sourceware.org
help / color / mirror / Atom feed
* [newlib-cygwin] Fix RTEMS CPU_EQUAL_S()
@ 2017-06-07 13:47 Sebastian Huber
0 siblings, 0 replies; only message in thread
From: Sebastian Huber @ 2017-06-07 13:47 UTC (permalink / raw)
To: newlib-cvs
https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=c29f5b219d450d68d38feb20990ae18c7945f035
commit c29f5b219d450d68d38feb20990ae18c7945f035
Author: Sebastian Huber <sebastian.huber@embedded-brains.de>
Date: Wed Jun 7 08:38:22 2017 +0200
Fix RTEMS CPU_EQUAL_S()
According to the FreeBSD man page BIT_CMP() returns true in case the two
sets are NOT equal.
Signed-off-by: Sebastian Huber <sebastian.huber@embedded-brains.de>
Diff:
---
newlib/libc/sys/rtems/include/sys/cpuset.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/newlib/libc/sys/rtems/include/sys/cpuset.h b/newlib/libc/sys/rtems/include/sys/cpuset.h
index 1e09b02..f928a37 100644
--- a/newlib/libc/sys/rtems/include/sys/cpuset.h
+++ b/newlib/libc/sys/rtems/include/sys/cpuset.h
@@ -202,7 +202,7 @@ static __inline int CPU_COUNT(const cpu_set_t *set)
static __inline int CPU_EQUAL_S(size_t setsize, const cpu_set_t *set1,
const cpu_set_t *set2)
{
- return BIT_CMP(_cpu_set_bits(setsize), set1, set2);
+ return !BIT_CMP(_cpu_set_bits(setsize), set1, set2);
}
static __inline int CPU_EQUAL(const cpu_set_t *set1, const cpu_set_t *set2)
@@ -212,7 +212,7 @@ static __inline int CPU_EQUAL(const cpu_set_t *set1, const cpu_set_t *set2)
static __inline int CPU_CMP(const cpu_set_t *set1, const cpu_set_t *set2)
{
- return CPU_EQUAL(set1, set2);
+ return BIT_CMP(CPU_SETSIZE, set1, set2);
}
static __inline int CPU_EMPTY(const cpu_set_t *set)
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-06-07 13:47 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-07 13:47 [newlib-cygwin] Fix RTEMS CPU_EQUAL_S() Sebastian Huber
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 read-only IMAP folder(s) and NNTP newsgroup(s).