From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id F3576426CF; Fri, 6 Oct 2023 12:03:49 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8F1C4402A8; Fri, 6 Oct 2023 12:03:49 +0200 (CEST) Received: from dkmailrelay1.smartsharesystems.com (smartserver.smartsharesystems.com [77.243.40.215]) by mails.dpdk.org (Postfix) with ESMTP id 26B024014F for ; Fri, 6 Oct 2023 12:03:48 +0200 (CEST) Received: from smartserver.smartsharesystems.com (smartserver.smartsharesys.local [192.168.4.10]) by dkmailrelay1.smartsharesystems.com (Postfix) with ESMTP id E8D3720602; Fri, 6 Oct 2023 12:03:47 +0200 (CEST) Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Subject: How to rte_epoll_wait for IPC? X-MimeOLE: Produced By Microsoft Exchange V6.5 Date: Fri, 6 Oct 2023 12:03:46 +0200 Message-ID: <98CBD80474FA8B44BF855DF32C47DC35E9EF02@smartserver.smartshare.dk> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: How to rte_epoll_wait for IPC? Thread-Index: Adn4PGUtGWTIu5zhQqCKF/jptdJoNQ== From: =?iso-8859-1?Q?Morten_Br=F8rup?= To: "Harman Kalra" , "Anatoly Burakov" , "David Hunt" Cc: X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Dear Harman, Anatoly and David, I have been looking somewhat into power management, and have a question = about rte_epoll: Can I use rte_epoll to wait for an event (or interrupt/signal) in one = EAL thread, generated by another EAL thread? Here's a simple use case with two EAL threads: 1. The "ingress" thread receives its packets from the NICs, filters the = packets and puts them into a an rte_ring for the "processing" thread. = The "ingress" thread can sleep and use RX interrupts to wake up, as = shown in the l3fwd-power example. All good. 2. The "processing" thread receives its packets from the rte_ring. This = thread should sleep until packets are ready for it in the rte_ring. The "ingress" thread knows when it puts packets into the rte_ring, so it = can signal that event to the "processing" thread, to wake it up; either = as an interrupt/signal, or through a file descriptor. Is this supported = by rte_epoll (or other DPDK APIs), and how? In a generic scenario, an EAL thread could be rte_epoll_wait'ing for a = variety of event sources. This may require a different, more advanced, = solution. A solution to the simple use case suffices. PS: I'm using the standard acronym IPC in the subject, although I'm = asking about Inter Thread Communication, not Inter Process = Communication. I'm not looking for a multi process solution. Med venlig hilsen / Kind regards, -Morten Br=F8rup