Lines Matching refs:timer
12 struct bpf_timer timer; member
69 static int timer_cb1(void *map, int *key, struct bpf_timer *timer) in timer_cb1() argument
84 if (bpf_timer_start(timer, 1ull << 35, 0) != 0) in timer_cb1()
123 if (bpf_timer_cancel(timer) != -EINVAL) in timer_cb1()
172 bpf_timer_start(&val->timer, 1000, 0); in timer_cb2()
190 if (bpf_timer_cancel(&val->timer) != -EDEADLK) in timer_cb2()
203 if (bpf_timer_start(&val->timer, 1000, 0) != -EINVAL) in timer_cb2()
211 if (bpf_timer_cancel(&val->timer) != -EDEADLK) in timer_cb2()
231 if (bpf_timer_init(&val->timer, &hmap, CLOCK_BOOTTIME) != 0) in bpf_timer_test()
233 bpf_timer_set_callback(&val->timer, timer_cb2); in bpf_timer_test()
234 bpf_timer_start(&val->timer, 1000, 0); in bpf_timer_test()
238 if (bpf_timer_init(&val->timer, &hmap_malloc, CLOCK_BOOTTIME) != 0) in bpf_timer_test()
240 bpf_timer_set_callback(&val->timer, timer_cb2); in bpf_timer_test()
241 bpf_timer_start(&val->timer, 1000, 0); in bpf_timer_test()
256 bpf_timer_init(&val->timer, &hmap, CLOCK_BOOTTIME); in BPF_PROG2()
263 bpf_timer_init(&val->timer, &hmap_malloc, CLOCK_BOOTTIME); in BPF_PROG2()
274 bpf_timer_init(&val->timer, &hmap, CLOCK_BOOTTIME); in BPF_PROG2()
279 bpf_timer_init(&val->timer, &hmap, CLOCK_BOOTTIME); in BPF_PROG2()
286 bpf_timer_init(&val->timer, &hmap_malloc, CLOCK_BOOTTIME); in BPF_PROG2()
291 bpf_timer_init(&val->timer, &hmap_malloc, CLOCK_BOOTTIME); in BPF_PROG2()
297 static int timer_cb3(void *map, int *key, struct bpf_timer *timer) in timer_cb3() argument
302 bpf_timer_start(timer, bpf_ktime_get_boot_ns() + 1000, in timer_cb3()
306 bpf_timer_start(timer, bpf_ktime_get_boot_ns() + (1ull << 35), in timer_cb3()
317 struct bpf_timer *timer; in BPF_PROG2() local
321 timer = bpf_map_lookup_elem(&abs_timer, &key); in BPF_PROG2()
322 if (timer) { in BPF_PROG2()
323 if (bpf_timer_init(timer, &abs_timer, CLOCK_BOOTTIME) != 0) in BPF_PROG2()
325 bpf_timer_set_callback(timer, timer_cb3); in BPF_PROG2()
326 bpf_timer_start(timer, bpf_ktime_get_boot_ns() + 1000, in BPF_PROG2()