Lines Matching refs:bit
39 * int bit = bitmask_ffz(resource_bits, num_resources);
40 * bitmask_set(resource_bits, bit);
42 * if (bitmask_test(resource_bits, bit)) { ... }
44 * bitmask_clear(resource_bits, bit);
61 int bit, result;
65 bit = ffs(~bitmask[i]);
66 if (bit) {
68 bit--;
69 result = BITS_PER_WORD * i + bit;
78 static inline void bitmask_set(unsigned int *bitmask, int bit)
80 bitmask[BIT_WORD(bit)] |= BIT_MASK(bit);
83 static inline void bitmask_clear(unsigned int *bitmask, int bit)
85 bitmask[BIT_WORD(bit)] &= ~BIT_MASK(bit);
88 static inline bool bitmask_test(unsigned int *bitmask, int bit)
90 return bitmask[BIT_WORD(bit)] & BIT_MASK(bit);