Lines Matching full:alarm
21 * - The driver does not guarantee that short relative alarm will trigger the
73 struct counter_sam_alarm_data alarm[MAX_ALARMS_PER_TC_CHANNEL]; member
156 if (data->alarm[chan_id].callback != NULL) { in counter_sam_tc_set_alarm()
166 data->alarm[chan_id].callback = alarm_cfg->callback; in counter_sam_tc_set_alarm()
167 data->alarm[chan_id].user_data = alarm_cfg->user_data; in counter_sam_tc_set_alarm()
190 LOG_DBG("set alarm: channel %u, count %u", chan_id, alarm_value); in counter_sam_tc_set_alarm()
210 data->alarm[chan_id].callback = NULL; in counter_sam_tc_cancel_alarm()
211 data->alarm[chan_id].user_data = NULL; in counter_sam_tc_cancel_alarm()
213 LOG_DBG("cancel alarm: channel %u", chan_id); in counter_sam_tc_cancel_alarm()
228 if (data->alarm[i].callback) { in counter_sam_tc_set_top_value()
288 if (data->alarm[0].callback) { in counter_sam_tc_isr()
289 counter_alarm_callback_t cb = data->alarm[0].callback; in counter_sam_tc_isr()
291 data->alarm[0].callback = NULL; in counter_sam_tc_isr()
292 cb(dev, 0, tc_ch->TC_RA, data->alarm[0].user_data); in counter_sam_tc_isr()
298 if (data->alarm[1].callback) { in counter_sam_tc_isr()
299 counter_alarm_callback_t cb = data->alarm[1].callback; in counter_sam_tc_isr()
301 data->alarm[1].callback = NULL; in counter_sam_tc_isr()
302 cb(dev, 1, tc_ch->TC_RB, data->alarm[1].user_data); in counter_sam_tc_isr()