Lines Matching refs:nr
6 #define BITOP_MASK(nr) (1UL << ((nr) % BITS_PER_LONG)) argument
7 #define BITOP_WORD(nr) ((nr) / BITS_PER_LONG) argument
18 static inline void __set_bit(int nr, volatile unsigned long *addr) in __set_bit() argument
20 unsigned long mask = BITOP_MASK(nr); in __set_bit()
21 unsigned long *p = ((unsigned long *)addr) + BITOP_WORD(nr); in __set_bit()
26 static inline void __clear_bit(int nr, volatile unsigned long *addr) in __clear_bit() argument
28 unsigned long mask = BITOP_MASK(nr); in __clear_bit()
29 unsigned long *p = ((unsigned long *)addr) + BITOP_WORD(nr); in __clear_bit()
43 static inline void __change_bit(int nr, volatile unsigned long *addr) in __change_bit() argument
45 unsigned long mask = BITOP_MASK(nr); in __change_bit()
46 unsigned long *p = ((unsigned long *)addr) + BITOP_WORD(nr); in __change_bit()
60 static inline int __test_and_set_bit(int nr, volatile unsigned long *addr) in __test_and_set_bit() argument
62 unsigned long mask = BITOP_MASK(nr); in __test_and_set_bit()
63 unsigned long *p = ((unsigned long *)addr) + BITOP_WORD(nr); in __test_and_set_bit()
79 static inline int __test_and_clear_bit(int nr, volatile unsigned long *addr) in __test_and_clear_bit() argument
81 unsigned long mask = BITOP_MASK(nr); in __test_and_clear_bit()
82 unsigned long *p = ((unsigned long *)addr) + BITOP_WORD(nr); in __test_and_clear_bit()
90 static inline int __test_and_change_bit(int nr, in __test_and_change_bit() argument
93 unsigned long mask = BITOP_MASK(nr); in __test_and_change_bit()
94 unsigned long *p = ((unsigned long *)addr) + BITOP_WORD(nr); in __test_and_change_bit()
106 static inline int test_bit(int nr, const volatile unsigned long *addr) in test_bit() argument
108 return 1UL & (addr[BITOP_WORD(nr)] >> (nr & (BITS_PER_LONG-1))); in test_bit()