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 1C5F646ED2 for ; Fri, 12 Sep 2025 05:27:24 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id D316740652; Fri, 12 Sep 2025 05:27:23 +0200 (CEST) Received: from mail-qv1-f46.google.com (mail-qv1-f46.google.com [209.85.219.46]) by mails.dpdk.org (Postfix) with ESMTP id 77571402C4 for ; Fri, 12 Sep 2025 05:27:22 +0200 (CEST) Received: by mail-qv1-f46.google.com with SMTP id 6a1803df08f44-722e079fa1aso14697516d6.3 for ; Thu, 11 Sep 2025 20:27:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=uetpeshawar-edu-pk.20230601.gappssmtp.com; s=20230601; t=1757647641; x=1758252441; darn=dpdk.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=iOivS1S+YPsa4bpudo+IarsK91AddI4QGdzm8FLPr7w=; b=VRuGSeDQJmF4jfo9HU67h5AbgyPp9ajn/HXMofyZXKA2RjxoAsCf/0c4d2P0IB1tWr 3B0MhrK9SVBB2lhvsOXQLEMi8qg4DTUwFmuKc2UIbgNiTr9iA9HBxtfvGVVppx1/MWfP zqHBF8s9xdtTjMrP8LXdLeIOCuUQIQoNx26oL2mCap8Fm6ObYXJhpIdst78E+MPvatvo KVFQVfs6vSczGg8VgWkNwGYk3pEIu+Euw44IH40IKX7xgntWEkGfRpSl7j+IpgDwgRQ9 dNZXWyYPrhCVL17+dEv7+YsEr6n1Bl05mVeY6tRTVwzVstfFGUF3Zn0uzyn9xZj43Etm WanA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1757647641; x=1758252441; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=iOivS1S+YPsa4bpudo+IarsK91AddI4QGdzm8FLPr7w=; b=XoTHZT+w2U2wrYbJatKfB35k+PJx0KIzniBJ1GvugLzPKC9yLCSrfkDQdLvUTf/v/k ozcQ5lzTBki2Jdayc+n0iaZdJerfZ2ET5tfXxy4HJOgGILxE2/BCgCLGwdaF4b9ebgiJ 3/HANCSKzoM/Ylftb94XnAViJv0+5+jG7tOaELYXTtvT7MmNeQqLkWXEtDvaNcexD7Ay ++qwcjAi0OZ1SCVLdIVd8O0MyRimI42uopOCSebKUOR2Lh01QOMJEi5FVktr772QDByS VFMVhYc+uR9yHq62p0pfvKphmypqmXh8pxe9rGLr3DZZBWMGRPTIh1mmIv1gMmbqu/9C yAiQ== X-Forwarded-Encrypted: i=1; AJvYcCV+hc34hS/w7V+h/Q8DyOUUtP1CgPh3FVCzePLCkzweeEOcrIy01D/eyBOGchVPB61wAPCOouE=@dpdk.org X-Gm-Message-State: AOJu0YwY82CYvyx8vT52Ne8yqeoe/WYUzL99eTqkL3d7H/3Q2OmPcOv6 PigZo+TvJW5L5dOhxAPlvgeZivz8QHi59S5ON+6zbcDN2a2NL+kxJsAjKmOQNMvU9hKNmRTJ1Yd FwbQ2U0Kp+jOz2Tq6Z5rcA2FSePSiL8Xj1jEqn0xXww== X-Gm-Gg: ASbGncvqNAHP3SBJeQsdlxVd8cSmWjSru29h4pwvj+cdi7SZFgCWya4GuvERacgQUjT ZZBKt4aC7qF1ic+d0ndPQLDikmEK0FnK4WFli1BgdtVwxxGJlQazth/gQsqTxM1A+StMHADqTxt OgL+2z0+4FnV1HOZApqnGdt1Yka/kE2RqlfB7jxwfNpbTIShr7PMA0oXc4t+9/kvKiNu7qqapMf Q3pwHOlkeiaS+Ez6RPxnkhe0UrGtJbotM60/ZR7psrzf07JbC4JMN6ZcguZDzxF9FQy/u56a4ch ABbdGlbJE9WbmEb4xjvTTh+L4YHgVCnRwpCwt0gjsjWMww== X-Google-Smtp-Source: AGHT+IERJUTmAcSR4zfUzDabV9tI78CBZMflcLSlOXOIbadEnTBQeVgY+tkENlpkpXDrGsjwL7BLMQgLu4kAo37111Y= X-Received: by 2002:a05:6214:21c5:b0:70d:f50e:afe5 with SMTP id 6a1803df08f44-767c3771b11mr20379626d6.47.1757647641447; Thu, 11 Sep 2025 20:27:21 -0700 (PDT) MIME-Version: 1.0 References: <20250910110237.460825-1-14pwcse1224@uetpeshawar.edu.pk> <20250911102501.473167-1-14pwcse1224@uetpeshawar.edu.pk> <20250911165058.31fd0101@hermes.local> In-Reply-To: <20250911165058.31fd0101@hermes.local> From: Khadem Ullah <14pwcse1224@uetpeshawar.edu.pk> Date: Fri, 12 Sep 2025 08:27:08 +0500 X-Gm-Features: AS18NWBVegnR7Zf0UIDp9-PxhXoElLgbjMHHrlWcdCKo-YdJs8d5S95G8A6ld4w Message-ID: Subject: Re: [PATCH v2] app/testpmd: stop secondary process fwd_lcores during primary teardown To: Stephen Hemminger Cc: Aman Singh , Anatoly Burakov , Ajit Khaparde , Lijun Ou , Ferruh Yigit , Andrew Rybchenko , dev@dpdk.org, dpdk stable Content-Type: multipart/alternative; boundary="0000000000004f1d93063e923b40" X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org --0000000000004f1d93063e923b40 Content-Type: text/plain; charset="UTF-8" Hi Stephen, On Fri, Sep 12, 2025, 04:51 Stephen Hemminger wrote: > > Ok, the Windows #ifdef was confusing me then looked more closely. > This patch is adding a set of rings so that primary and secondary > can communicate, the adding one command. > > The idea is good, but there is a better way to handle this. > There already exists a way for primary and secondary to communicate > through the mp service. This is used for hotplug and pdump and probably > other things as well. > Yeah, agree. Testpmd have also hutplug callbacks, I have tried that too, but it is in lower layer to call any stopping fwd_engines. > > The communication can be either way, for example I proposed patches > to pdump so that primary can tell secondary to participate. > > > https://patchwork.dpdk.org/project/dpdk/patch/20250814165307.12786-7-stephen@networkplumber.org/ > > This of testpmd can be done in similar way. > The handler in secondary should be able to act same as > when SIGINT is received. Set the flag f_exit which will cause the main > loop to exit. > > This can then happen immediately, and the proc monitor alarm function > is only then needed to handle when primary process crashes. > Yeah, we can try that, my only concern is that if it can handle and stop any numbers of secondary processes fwd_engines as the current solution can stop. Best regards, Khadem > > > --0000000000004f1d93063e923b40 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi=C2=A0Stephen,

On Fri, Sep 12, = 2025, 04:51 Stephen Hemminger <stephen@networkplumber.org> wrote:

Ok, the Windows #ifdef was confusing me then looked more closely.
This patch is adding a set of rings so that primary and secondary
can communicate, the adding one command.

The idea is good, but there is a better way to handle this.
There already exists a way for primary and secondary to communicate
through the mp service. This is used for hotplug and pdump and probably
other things as well.
Yeah, a= gree. Testpmd have also hutplug callbacks, I have tried that too, but it is= in lower layer to call any stopping fwd_engines.=C2=A0

The communication can be either way, for example I proposed patches
to pdump so that primary can tell secondary to participate.

https://patchwork.dpdk.org/project/dpdk/patch/20250814165307.12786-7= -stephen@networkplumber.org/

This of testpmd can be done in similar way.
The handler in secondary should be able to act same as
when SIGINT is received. Set the flag f_exit which will cause the main
loop to exit.

This can then happen immediately, and the proc monitor alarm function
is only then needed to handle when primary process crashes.
Yeah, we can try that, my only concern is th= at if it can handle and stop any numbers of secondary processes fwd_engines= as the current solution can stop.=C2=A0

<= div dir=3D"auto">Best regards,
Khadem


--0000000000004f1d93063e923b40--