Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F108027585
D27891.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
658 B
Referenced Files
None
Subscribers
None
D27891.diff
View Options
diff --git a/sys/sys/bitset.h b/sys/sys/bitset.h
--- a/sys/sys/bitset.h
+++ b/sys/sys/bitset.h
@@ -193,11 +193,13 @@
#define BIT_TEST_CLR_ATOMIC(_s, n, p) \
(atomic_testandclear_long( \
- &(p)->__bits[__bitset_word((_s), (n))], (n)) != 0)
+ &(p)->__bits[__bitset_word((_s), (n))], \
+ (n) % _BITSET_BITS) != 0)
#define BIT_TEST_SET_ATOMIC(_s, n, p) \
(atomic_testandset_long( \
- &(p)->__bits[__bitset_word((_s), (n))], (n)) != 0)
+ &(p)->__bits[__bitset_word((_s), (n))], \
+ (n) % _BITSET_BITS) != 0)
/* Convenience functions catering special cases. */
#define BIT_AND_ATOMIC(_s, d, s) do { \
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Jan 21, 4:47 PM (19 h, 48 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16016755
Default Alt Text
D27891.diff (658 B)
Attached To
Mode
D27891: bitset: Fix BIT_TEST_SET_ATOMIC and BIT_TEST_CLR_ATOMIC.
Attached
Detach File
Event Timeline
Log In to Comment