MCPcopy Create free account
hub / github.com/F-Stack/f-stack / timer0_cb

Function timer0_cb

dpdk/examples/timer/main.c:26–39  ·  view source on GitHub ↗

timer0 callback. 8< */

Source from the content-addressed store, hash-verified

24
25/* timer0 callback. 8< */
26static void
27timer0_cb(__rte_unused struct rte_timer *tim,
28 __rte_unused void *arg)
29{
30 static unsigned counter = 0;
31 unsigned lcore_id = rte_lcore_id();
32
33 printf("%s() on lcore %u\n", __func__, lcore_id);
34
35 /* this timer is automatically reloaded until we decide to
36 * stop it, when counter reaches 20. */
37 if ((counter ++) == 20)
38 rte_timer_stop(tim);
39}
40/* >8 End of timer0 callback. */
41
42/* timer1 callback. 8< */

Callers

nothing calls this directly

Calls 3

rte_lcore_idFunction · 0.85
rte_timer_stopFunction · 0.85
printfFunction · 0.50

Tested by

no test coverage detected