From dfa77dc6062eeaed426879bf162f58337ed36692 Mon Sep 17 00:00:00 2001 From: Damjan Marion Date: Tue, 10 Sep 2024 17:07:49 +0200 Subject: vlib: process node scheduler rework This commit allow use od cooperative multitasking with multiple descheduling reasons (i.e. event wait and suspend) inside the same process node. In previus code remote node will wake up process node by sending event evein if process node is waiting in vlib_process_ssupend(). This change also allowed new vlib_process_yield() API which deschedules current process and it puts it into the end of queue. Change-Id: I846e5a99b4ea1809eb80895f6ffe0ef0b2fd21ae Type: improvement Signed-off-by: Damjan Marion --- src/plugins/dpdk/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/plugins') diff --git a/src/plugins/dpdk/main.c b/src/plugins/dpdk/main.c index 9781d0ed7f0..437cfbd230e 100644 --- a/src/plugins/dpdk/main.c +++ b/src/plugins/dpdk/main.c @@ -50,7 +50,7 @@ rte_delay_us_override (unsigned us) { /* Only suspend for the admin_down_process */ vlib_process_t *proc = vlib_get_current_process (vm); - if (!(proc->flags & VLIB_PROCESS_IS_RUNNING) || + if (proc->state != VLIB_PROCESS_STATE_RUNNING || (proc->node_runtime.node_index != admin_up_down_process_node.index)) return 0; -- cgit 1.2.3-korg