DPDK-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas@monjalon.net>
To: Stephen Hemminger <stephen@networkplumber.org>
Cc: dev@dpdk.org, Anatoly Burakov <anatoly.burakov@intel.com>
Subject: Re: [PATCH 0/2] eal: notify secondaries on primary exit
Date: Wed, 07 Oct 2026 23:17:53 +0200	[thread overview]
Message-ID: <EmFyQLKjR4ynSjBaPSOeMw@monjalon.net> (raw)
In-Reply-To: <20260618090940.6853e9cb@phoenix.local>

18/06/2026 18:09, Stephen Hemminger:
> On Thu,  7 May 2026 13:58:35 -0700
> Stephen Hemminger <stephen@networkplumber.org> wrote:
> 
> > Bugzilla 1942: when a primary process exits cleanly, secondary
> > processes other than testpmd do not get notified.  The notification
> > mechanism added in 25.11 was placed in testpmd and used
> > rte_mp_request_sync() with a testpmd-specific action name, so any
> > non-testpmd secondary (dpdk-dumpcap, dpdk-pdump, dpdk-procinfo, or
> > out-of-tree consumers) would log "Cannot find action: mp_testpmd"
> > and the primary would block on the 5 second request timeout.
> > 
> > Putting application-specific IPC actions on a broadcast request path
> > is the wrong layer.  Notification of primary exit is something every
> > secondary needs and should come from EAL, not from each application.
> > 
> > Patch 1 reverts the testpmd-side mechanism (commit f96273c8e9d3).
> > The secondary-side primary alive monitor (enable_primary_monitor)
> > is preserved and continues to handle detection of primary exit via
> > the existing alarm-based polling of rte_eal_primary_proc_alive().
> > 
> > Patch 2 adds a generic EAL-level notification.  On primary cleanup,
> > rte_mp_channel_cleanup() broadcasts an MP_REQ_QUIT message to all
> > known secondaries via rte_mp_sendmsg().  Secondaries register an
> > internal action handler that tears down their own MP channel on
> > receipt.  No new public API; no application changes required for
> > any secondary, in-tree or out.
> > 
> > This is the minimum fix suitable for backport to 25.11 stable.
> > It addresses the clean exit case.  The crash case (primary killed
> > or signaled) continues to be handled by the existing
> > rte_eal_primary_proc_alive() polling on the secondary side, which
> > detects the primary's release of the config file lock.
> > 
> > A more complete solution using a connected socket type (SOCK_SEQPACKET)
> > is planned since that can handle both planned and forced exiting
> > of the primary.
> > 
> > Tested with testpmd (primary) and dpdk-dumpcap, dpdk-pdump,
> > dpdk-procinfo (secondaries).
> > 
> > 
> > Stephen Hemminger (2):
> >   Revert "app/testpmd: stop forwarding in secondary process"
> >   eal: notify secondary on primary exit
> > 
> >  app/test-pmd/testpmd.c           | 103 ++-----------------------------
> >  lib/eal/common/eal_common_proc.c |  51 ++++++++++++++-
> >  2 files changed, 53 insertions(+), 101 deletions(-)
> > 
> 
> This is a real bug fix. Even if AI is being overly wordy in describing
> it; what it does is move the notification from being testpmd -> testpmd only
> to a more general primary -> secondary mechanism.
> 
> Without it can demonstrate the bug rather trivially with packet
> capture tools (pdump or dumpcap)
> 
> Could this get reviewed?

Anatoly reviewed.
Applied, thanks.



      reply	other threads:[~2026-10-07 21:18 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-07 20:58 [PATCH 0/2] eal: notify secondaries on primary exit Stephen Hemminger
2026-05-07 20:58 ` [PATCH 1/2] Revert "app/testpmd: stop forwarding in secondary process" Stephen Hemminger
2026-09-23 13:02   ` Burakov, Anatoly
2026-05-07 20:58 ` [PATCH 2/2] eal: notify secondary on primary exit Stephen Hemminger
2026-09-23 13:04   ` Burakov, Anatoly
2026-06-18 16:09 ` [PATCH 0/2] eal: notify secondaries " Stephen Hemminger
2026-10-07 21:17   ` Thomas Monjalon [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=EmFyQLKjR4ynSjBaPSOeMw@monjalon.net \
    --to=thomas@monjalon.net \
    --cc=anatoly.burakov@intel.com \
    --cc=dev@dpdk.org \
    --cc=stephen@networkplumber.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox