[newlib 15/22] sched.h: add CPU_EQUAL() for better compatibility with Linux
Sebastian Huber
sebastian.huber at embedded-brains.de
Wed Jun 22 08:24:38 UTC 2022
From: Konstantin Belousov <kib at FreeBSD.org>
Reviewed by: jhb
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D32901
---
newlib/libc/sys/rtems/include/sys/cpuset.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/newlib/libc/sys/rtems/include/sys/cpuset.h b/newlib/libc/sys/rtems/include/sys/cpuset.h
index 7779f0639..e46090b8a 100644
--- a/newlib/libc/sys/rtems/include/sys/cpuset.h
+++ b/newlib/libc/sys/rtems/include/sys/cpuset.h
@@ -205,7 +205,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) == 0;
}
static __inline int CPU_EQUAL(const cpu_set_t *set1, const cpu_set_t *set2)
--
2.35.3
More information about the devel
mailing list