diff options
Diffstat (limited to 'tools/perf/util/include/linux/bitops.h')
| -rw-r--r-- | tools/perf/util/include/linux/bitops.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tools/perf/util/include/linux/bitops.h b/tools/perf/util/include/linux/bitops.h index bb4ac2e05385..8be0b968ca0b 100644 --- a/tools/perf/util/include/linux/bitops.h +++ b/tools/perf/util/include/linux/bitops.h | |||
| @@ -13,6 +13,11 @@ static inline void set_bit(int nr, unsigned long *addr) | |||
| 13 | addr[nr / BITS_PER_LONG] |= 1UL << (nr % BITS_PER_LONG); | 13 | addr[nr / BITS_PER_LONG] |= 1UL << (nr % BITS_PER_LONG); |
| 14 | } | 14 | } |
| 15 | 15 | ||
| 16 | static inline void clear_bit(int nr, unsigned long *addr) | ||
| 17 | { | ||
| 18 | addr[nr / BITS_PER_LONG] &= ~(1UL << (nr % BITS_PER_LONG)); | ||
| 19 | } | ||
| 20 | |||
| 16 | static __always_inline int test_bit(unsigned int nr, const unsigned long *addr) | 21 | static __always_inline int test_bit(unsigned int nr, const unsigned long *addr) |
| 17 | { | 22 | { |
| 18 | return ((1UL << (nr % BITS_PER_LONG)) & | 23 | return ((1UL << (nr % BITS_PER_LONG)) & |
