Lines Matching refs:event
34 static void ndisc_callback(sd_ndisc *ndisc, sd_ndisc_event_t event, sd_ndisc_router *rt) { in ndisc_callback() argument
36 assert(event >= 0 && event < _SD_NDISC_EVENT_MAX); in ndisc_callback()
39 … return (void) log_ndisc(ndisc, "Received '%s' event.", ndisc_event_to_string(event)); in ndisc_callback()
41 log_ndisc(ndisc, "Invoking callback for '%s' event.", ndisc_event_to_string(event)); in ndisc_callback()
42 ndisc->callback(ndisc, event, rt, ndisc->userdata); in ndisc_callback()
103 int sd_ndisc_attach_event(sd_ndisc *nd, sd_event *event, int64_t priority) { in sd_ndisc_attach_event() argument
108 assert_return(!nd->event, -EBUSY); in sd_ndisc_attach_event()
110 if (event) in sd_ndisc_attach_event()
111 nd->event = sd_event_ref(event); in sd_ndisc_attach_event()
113 r = sd_event_default(&nd->event); in sd_ndisc_attach_event()
128 nd->event = sd_event_unref(nd->event); in sd_ndisc_detach_event()
135 return nd->event; in sd_ndisc_get_event()
210 assert(nd->event); in ndisc_recv()
270 assert(nd->event); in ndisc_timeout()
272 assert_se(sd_event_now(nd->event, CLOCK_BOOTTIME, &time_now) >= 0); in ndisc_timeout()
283 r = event_reset_time(nd->event, &nd->timeout_event_source, in ndisc_timeout()
339 assert_return(nd->event, -EINVAL); in sd_ndisc_start()
347 r = sd_event_now(nd->event, CLOCK_BOOTTIME, &time_now); in sd_ndisc_start()
355 r = sd_event_add_io(nd->event, &nd->recv_event_source, nd->fd, EPOLLIN, ndisc_recv, nd); in sd_ndisc_start()
365 r = event_reset_time(nd->event, &nd->timeout_event_source, in sd_ndisc_start()
373 r = event_reset_time(nd->event, &nd->timeout_no_ra, in sd_ndisc_start()