From: Stephen Hemminger <stephen@networkplumber.org>
To: Dariusz Sosnowski <dsosnowski@nvidia.com>
Cc: Slava Ovsiienko <viacheslavo@nvidia.com>,
Bing Zhao <bingz@nvidia.com>, Ori Kam <orika@nvidia.com>,
Suanming Mou <suanmingm@nvidia.com>,
Matan Azrad <matan@nvidia.com>, "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [PATCH v2 0/2] net/mlx5: improvements to link status handling
Date: Wed, 4 Nov 2026 08:29:26 +0100 [thread overview]
Message-ID: <20261104082926.47f4ff38@stephen-xps.local> (raw)
In-Reply-To: <PH0PR12MB7077AFBC1E81E2E489F6CAE1A4692@PH0PR12MB7077.namprd12.prod.outlook.com>
On Tue, 3 Nov 2026 11:04:39 +0000
Dariusz Sosnowski <dsosnowski@nvidia.com> wrote:
> > -----Original Message-----
> > From: Stephen Hemminger <stephen@networkplumber.org>
> > Sent: Monday, November 2, 2026 9:08 AM
> > To: Dariusz Sosnowski <dsosnowski@nvidia.com>
> > Cc: Slava Ovsiienko <viacheslavo@nvidia.com>; Bing Zhao
> > <bingz@nvidia.com>; Ori Kam <orika@nvidia.com>; Suanming Mou
> > <suanmingm@nvidia.com>; Matan Azrad <matan@nvidia.com>;
> > dev@dpdk.org
> > Subject: Re: [PATCH v2 0/2] net/mlx5: improvements to link status handling
> >
> > On Fri, 30 Oct 2026 18:28:41 +0100
> > Dariusz Sosnowski <dsosnowski@nvidia.com> wrote:
> >
> > > This series is a result of splitting patch:
> > > https://patches.dpdk.org/project/dpdk/patch/20261026160400.1290443-1-
> > d
> > > sosnowski@nvidia.com/
> > >
> > > Patch 1 - Fix for mlx5 link update function to query current link
> > > carrier status, bypassing the delay introduced by linkwatch in Linux kernel.
> > >
> > > Patch 2 - Move to link status polling, in place of relying on netlink
> > > events which can be delayed by linkwatch for up to 1s.
> >
> > Instead of polling is there a way to get the lsc directly from devx or ibv on
> > mlx5? That would work around the issue and avoid the overhead.
>
> From DevX, unfortunately no.
>
> In ibv there are 2 options:
>
> - IBV_EVENT_PORT_ACTIVE/ERR - generated on up/down respectively;
> On ethernet devices, these are generated from netdev carrier state, so they are
> subjected to the same linkwatch delay.
>
> - IBV_EVENT_DEVICE_SPEED_CHANGE - generated on up and down;
> Is generated immediately on FW event reception.
> It is available from Linux kernel v7.0 and rdma-core v62.0.
>
> IBV_EVENT_DEVICE_SPEED_CHANGE would be ideal here,
> but there's no good way to discover whether currently running kernel supports it.
>
> Theoretically, this event was added alongside ibv_query_port_speed() IB verb.
> Following logic could be implemented (for DPDK compiled with recent rdma-core)
>
> - Call ibv_query_port_speed()
> - If error:
> - start listening on device speed change async event
> - on event: query link status of DPDK ports on that device
> - else if ENOTSUP:
> - start link status poll loop
>
> >
> > Long term, it would be good if kernel had sysctl to set linkwatch per interface
> > but it doesn't
I have a patch to allow link watch timeout to be set via netlink or sysfs.
But needs more testing. In future, mlx5 could detect and configure that.
prev parent reply other threads:[~2026-11-04 7:29 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-26 16:04 [PATCH] net/mlx5: move to polling for LSC interrupts Dariusz Sosnowski
2026-10-26 17:03 ` Stephen Hemminger
2026-10-29 17:21 ` Dariusz Sosnowski
2026-10-26 17:13 ` Stephen Hemminger
2026-10-29 17:19 ` Dariusz Sosnowski
2026-10-30 17:28 ` [PATCH v2 0/2] net/mlx5: improvements to link status handling Dariusz Sosnowski
2026-10-30 17:28 ` [PATCH v2 1/2] net/mlx5: fix link status query Dariusz Sosnowski
2026-11-05 7:37 ` Raslan Darawsheh
2026-10-30 17:28 ` [PATCH v2 2/2] net/mlx5: move to polling for LSC interrupts Dariusz Sosnowski
2026-11-05 7:37 ` Raslan Darawsheh
2026-11-02 8:07 ` [PATCH v2 0/2] net/mlx5: improvements to link status handling Stephen Hemminger
2026-11-03 11:04 ` Dariusz Sosnowski
2026-11-04 7:29 ` Stephen Hemminger [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=20261104082926.47f4ff38@stephen-xps.local \
--to=stephen@networkplumber.org \
--cc=bingz@nvidia.com \
--cc=dev@dpdk.org \
--cc=dsosnowski@nvidia.com \
--cc=matan@nvidia.com \
--cc=orika@nvidia.com \
--cc=suanmingm@nvidia.com \
--cc=viacheslavo@nvidia.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.