Home | History | Annotate | Download | only in linux

Lines Matching refs:nr

21 #define BITS_TO_LONGS(nr)       DIV_ROUND_UP(nr, BITS_PER_BYTE * sizeof(long))
23 static inline void set_bit(int nr, unsigned long *addr)
25 addr[nr / BITS_PER_LONG] |= 1UL << (nr % BITS_PER_LONG);
28 static inline void clear_bit(int nr, unsigned long *addr)
30 addr[nr / BITS_PER_LONG] &= ~(1UL << (nr % BITS_PER_LONG));
33 static __always_inline int test_bit(unsigned int nr, const unsigned long *addr)
35 return ((1UL << (nr % BITS_PER_LONG)) &
36 (((unsigned long *)addr)[nr / BITS_PER_LONG])) != 0;