[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250425062325.GA21110@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net>
Date: Thu, 24 Apr 2025 23:23:25 -0700
From: Erni Sri Satya Vennela <ernis@...ux.microsoft.com>
To: Simon Horman <horms@...nel.org>
Cc: Jakub Kicinski <kuba@...nel.org>,
Stephen Hemminger <stephen@...workplumber.org>, kys@...rosoft.com,
haiyangz@...rosoft.com, wei.liu@...nel.org, decui@...rosoft.com,
andrew+netdev@...n.ch, davem@...emloft.net, edumazet@...gle.com,
pabeni@...hat.com, longli@...rosoft.com, kotaranov@...rosoft.com,
kent.overstreet@...ux.dev, brett.creeley@....com,
schakrabarti@...ux.microsoft.com, shradhagupta@...ux.microsoft.com,
ssengar@...ux.microsoft.com, rosenp@...il.com,
paulros@...rosoft.com, linux-hyperv@...r.kernel.org,
netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-rdma@...r.kernel.org
Subject: Re: [PATCH 2/3] net: mana: Add sched HTB offload support
On Thu, Apr 24, 2025 at 10:38:16AM +0100, Simon Horman wrote:
> On Fri, Apr 18, 2025 at 09:53:24AM -0700, Erni Sri Satya Vennela wrote:
> > On Thu, Apr 17, 2025 at 05:00:52PM -0700, Jakub Kicinski wrote:
> > > On Thu, 17 Apr 2025 12:47:27 -0700 Erni Sri Satya Vennela wrote:
> > > > > A single leaf is just Token Bucket Filter (TBF).
> > > > > Are you just trying to support some vendor config?
> > > > TBF does not support hardware offloading.
> > >
> > > Did you take a look at net_shapers? Will it not let you set a global
> > > config the way you intend?
> > Yes, Jakub. I have reviewed net-shapers and noted that it is not
> > integrated into the kernel like tc. I mean there isn't a standard,
> > general-purpose command for net-shaper in Linux. It is used by other
> > tools or potentially device-specific drivers that want to leverage the
> > NIC's hardware shaping capabilities.
> >
> > To configure shaping with net-shapers, users would need to execute a
> > command similar to:
> >
> > ./tools/net/ynl/cli.py --spec Documentation/netlink/specs/shaper.yaml
> > --do set --json '{"ifindex":'$IFINDEX',
> > "shaper": {"handle":
> > {"scope": "node", "id":'$NODEID' },
> > "bw-max": 2000000}}'
> >
> > Ref: https://lore.kernel.org/all/cover.1722357745.git.pabeni@redhat.com/
> >
> > Given the simplicity of code implementation and ease of use for users in
> > writing commands, I opted for tc-htb.
>
> Hi Erni,
>
> As someone who was involved with the design of net-shapers, I think it is
> reasonable to instead use the Kernel API which appears to have been
> designed specifically for this purpose: to control HW TX rate limiting.
>
> If tooling isn't intuitive or otherwise doesn't meet user's needs
> then that is something that can be addressed. But it's not a Kernel issue.
Thank you, Simon and Jakub, for helping me understand the advantages of
using net-shapers over tc-htb. I will work on it and send the next
version using net-shapers in a few weeks, as I will be on leave for
the next two weeks.
- Vennela
Powered by blists - more mailing lists