Lines Matching refs:p_reg

15 static int timer_number_from_ptr(NRF_TIMER_Type * p_reg){  in timer_number_from_ptr()  argument
16 int i = ( (int)p_reg - (int)&NRF_TIMER_regs[0] ) / sizeof(NRF_TIMER_Type); in timer_number_from_ptr()
20 void nrf_timer_cc_set(NRF_TIMER_Type * p_reg, in nrf_timer_cc_set() argument
24 int i = timer_number_from_ptr(p_reg); in nrf_timer_cc_set()
25 p_reg->CC[cc_channel] = cc_value; in nrf_timer_cc_set()
29 void nrf_timer_task_trigger(NRF_TIMER_Type * p_reg, in nrf_timer_task_trigger() argument
32 int i = timer_number_from_ptr(p_reg); in nrf_timer_task_trigger()
34 *((volatile uint32_t *)((uint8_t *)p_reg + (uint32_t)task)) = 0x1UL; in nrf_timer_task_trigger()
57 void nrf_timer_event_clear(NRF_TIMER_Type * p_reg, in nrf_timer_event_clear() argument
60 *((volatile uint32_t *)((uint8_t *)p_reg + (uint32_t)event)) = 0x0UL; in nrf_timer_event_clear()
61 int t = timer_number_from_ptr(p_reg); in nrf_timer_event_clear()
65 void nrf_timer_int_enable(NRF_TIMER_Type * p_reg, in nrf_timer_int_enable() argument
68 int i = timer_number_from_ptr(p_reg); in nrf_timer_int_enable()
69 p_reg->INTENSET = mask; in nrf_timer_int_enable()
73 void nrf_timer_int_disable(NRF_TIMER_Type * p_reg, in nrf_timer_int_disable() argument
76 int i = timer_number_from_ptr(p_reg); in nrf_timer_int_disable()
77 p_reg->INTENCLR = mask; in nrf_timer_int_disable()
83 static void nrf_timer_subscribe_common(NRF_TIMER_Type * p_reg, in nrf_timer_subscribe_common() argument
86 int i = timer_number_from_ptr(p_reg); in nrf_timer_subscribe_common()
109 void nrf_timer_subscribe_set(NRF_TIMER_Type * p_reg, in nrf_timer_subscribe_set() argument
113 *((volatile uint32_t *) ((uint8_t *) p_reg + (uint32_t) task + 0x80uL)) = in nrf_timer_subscribe_set()
115 nrf_timer_subscribe_common(p_reg, task); in nrf_timer_subscribe_set()
118 void nrf_timer_subscribe_clear(NRF_TIMER_Type * p_reg, in nrf_timer_subscribe_clear() argument
121 *((volatile uint32_t *) ((uint8_t *) p_reg + (uint32_t) task + 0x80uL)) = 0; in nrf_timer_subscribe_clear()
122 nrf_timer_subscribe_common(p_reg, task); in nrf_timer_subscribe_clear()