Lines Matching full:bit

52  * Function for checking if bit in the multi-byte bit mask is set.
54 * @param bit Bit index.
55 * @param p_mask A pointer to mask with bit fields.
57 * @return 0 if bit is not set, positive value otherwise.
59 __STATIC_INLINE uint32_t nrf_bitmask_bit_is_set(uint32_t bit, void const * p_mask) in nrf_bitmask_bit_is_set() argument
62 uint32_t byte_idx = BITMASK_BYTE_GET(bit); in nrf_bitmask_bit_is_set()
63 bit = BITMASK_RELBIT_GET(bit); in nrf_bitmask_bit_is_set()
64 return (1 << bit) & p_mask8[byte_idx]; in nrf_bitmask_bit_is_set()
68 * Function for setting a bit in the multi-byte bit mask.
70 * @param bit Bit index.
71 * @param p_mask A pointer to mask with bit fields.
73 __STATIC_INLINE void nrf_bitmask_bit_set(uint32_t bit, void * p_mask) in nrf_bitmask_bit_set() argument
76 uint32_t byte_idx = BITMASK_BYTE_GET(bit); in nrf_bitmask_bit_set()
77 bit = BITMASK_RELBIT_GET(bit); in nrf_bitmask_bit_set()
78 p_mask8[byte_idx] |= (1 << bit); in nrf_bitmask_bit_set()
82 * Function for clearing a bit in the multi-byte bit mask.
84 * @param bit Bit index.
85 * @param p_mask A pointer to mask with bit fields.
87 __STATIC_INLINE void nrf_bitmask_bit_clear(uint32_t bit, void * p_mask) in nrf_bitmask_bit_clear() argument
90 uint32_t byte_idx = BITMASK_BYTE_GET(bit); in nrf_bitmask_bit_clear()
91 bit = BITMASK_RELBIT_GET(bit); in nrf_bitmask_bit_clear()
92 p_mask8[byte_idx] &= ~(1 << bit); in nrf_bitmask_bit_clear()
96 * Function for performing bitwise OR operation on two multi-byte bit masks.
98 * @param p_mask1 A pointer to the first bit mask.
99 * @param p_mask2 A pointer to the second bit mask.
100 * @param p_out_mask A pointer to the output bit mask.
119 * Function for performing bitwise AND operation on two multi-byte bit masks.
121 * @param p_mask1 A pointer to the first bit mask.
122 * @param p_mask2 A pointer to the second bit mask.
123 * @param p_out_mask A pointer to the output bit mask.