From: Vitaly Kuznetsov <vkuznets@redhat.com>
To: Li Tian <litian@redhat.com>,
netdev@vger.kernel.org, linux-hyperv@vger.kernel.org
Cc: linux-kernel@vger.kernel.org,
Haiyang Zhang <haiyangz@microsoft.com>,
Wei Liu <wei.liu@kernel.org>, Dexuan Cui <decui@microsoft.com>,
Long Li <longli@microsoft.com>,
Andrew Lunn <andrew+netdev@lunn.ch>,
Eric Dumazet <edumazet@google.com>,
Paolo Abeni <pabeni@redhat.com>, Jakub Kicinski <kuba@kernel.org>,
Jason Wang <jasowang@redhat.com>, Li Tian <litian@redhat.com>
Subject: Re: [PATCH net] netvsc: transfer lower device max tso size during VF transition
Date: Wed, 25 Mar 2026 10:47:44 +0100 [thread overview]
Message-ID: <87a4vwnsu7.fsf@redhat.com> (raw)
In-Reply-To: <20260325045006.18607-1-litian@redhat.com>
Li Tian <litian@redhat.com> writes:
> When netvsc is accelerated by the lower device, we can advertise the
> lower device max tso size in order to get better performance.
> While a long-term migration to user-space bonding is planned, current
> users on RHEL 10 / Azure are experiencing significant performance
> regressions in 802.3ad environments. This patch provides a localized,
> safe fix within netvsc without introducing new core networking helpers.
>
> Signed-off-by: Li Tian <litian@redhat.com>
> ---
> drivers/net/hyperv/netvsc_drv.c | 8 ++++++--
> 1 file changed, 6 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
> index ee5ab5ceb2be..971607c7406f 100644
> --- a/drivers/net/hyperv/netvsc_drv.c
> +++ b/drivers/net/hyperv/netvsc_drv.c
> @@ -2428,10 +2428,14 @@ static int netvsc_vf_changed(struct net_device *vf_netdev, unsigned long event)
> * This value is only increased for netvsc NIC when datapath is
> * switched over to the VF
> */
> - if (vf_is_up)
> + if (vf_is_up) {
> netif_set_tso_max_size(ndev, vf_netdev->tso_max_size);
> - else
> + WRITE_ONCE(ndev->gso_max_size, READ_ONCE(vf_netdev->gso_max_size));
> + WRITE_ONCE(ndev->gso_ipv4_max_size,
> + READ_ONCE(vf_netdev->gso_ipv4_max_size));
It seems netif_set_gso_max_size() helper does exactly that, i.e. sets both
gso_max_size and gso_ipv4_max_size.
> + } else {
> netif_set_tso_max_size(ndev, netvsc_dev->netvsc_gso_max_size);
> + }
> }
>
> return NOTIFY_OK;
--
Vitaly
next prev parent reply other threads:[~2026-03-25 9:47 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-25 4:50 [PATCH net] netvsc: transfer lower device max tso size during VF transition Li Tian
2026-03-25 9:47 ` Vitaly Kuznetsov [this message]
2026-04-14 14:08 ` [EXTERNAL] " Haiyang Zhang
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=87a4vwnsu7.fsf@redhat.com \
--to=vkuznets@redhat.com \
--cc=andrew+netdev@lunn.ch \
--cc=decui@microsoft.com \
--cc=edumazet@google.com \
--cc=haiyangz@microsoft.com \
--cc=jasowang@redhat.com \
--cc=kuba@kernel.org \
--cc=linux-hyperv@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=litian@redhat.com \
--cc=longli@microsoft.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=wei.liu@kernel.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 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.