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

Function thread_msg_handle

dpdk/drivers/net/softnic/rte_eth_softnic_thread.c:491–518  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

489}
490
491static void
492thread_msg_handle(struct softnic_thread_data *t)
493{
494 for ( ; ; ) {
495 struct thread_msg_req *req;
496 struct thread_msg_rsp *rsp;
497
498 req = thread_msg_recv(t->msgq_req);
499 if (req == NULL)
500 break;
501
502 switch (req->type) {
503 case THREAD_REQ_PIPELINE_ENABLE:
504 rsp = thread_msg_handle_pipeline_enable(t, req);
505 break;
506
507 case THREAD_REQ_PIPELINE_DISABLE:
508 rsp = thread_msg_handle_pipeline_disable(t, req);
509 break;
510
511 default:
512 rsp = (struct thread_msg_rsp *)req;
513 rsp->status = -1;
514 }
515
516 thread_msg_send(t->msgq_rsp, rsp);
517 }
518}
519
520/**
521 * Data plane threads: main

Callers 1

Calls 4

thread_msg_recvFunction · 0.70
thread_msg_sendFunction · 0.70

Tested by

no test coverage detected