[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <bb9cf9af-2f17-4af6-9d1c-3981cc8468c0@lunn.ch>
Date: Mon, 20 Jan 2025 03:39:18 +0100
From: Andrew Lunn <andrew@...n.ch>
To: Aryan Srivastava <aryan.srivastava@...iedtelesis.co.nz>
Cc: Jiri Pirko <jiri@...nulli.us>, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, Vladimir Oltean <olteanv@...il.com>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
Simon Horman <horms@...nel.org>
Subject: Re: [RFC net-next v1 2/2] net: dsa: add option for bridge port HW
offload
On Mon, Jan 20, 2025 at 01:49:12PM +1300, Aryan Srivastava wrote:
> Currently the DSA framework will HW offload any bridge port if there is
> a driver available to support HW offloading. This may not always be the
> preferred case. In cases where it is preferred that all traffic still
> hit the CPU, do software bridging instead.
>
> To prevent HW bridging (and potential CPU bypass), make the DSA
> framework aware of the devlink port function attr, bridge_offload, and
> add a matching field to the port struct. Add get/set functions to
> configure the field, and use this field to condition HW config for
> offloading a bridge port.
This is not a very convincing description. What is your real use case
for not offloading?
>
> Signed-off-by: Aryan Srivastava <aryan.srivastava@...iedtelesis.co.nz>
> ---
> include/net/dsa.h | 1 +
> net/dsa/devlink.c | 27 ++++++++++++++++++++++++++-
> net/dsa/dsa.c | 1 +
> net/dsa/port.c | 3 ++-
> 4 files changed, 30 insertions(+), 2 deletions(-)
>
> diff --git a/include/net/dsa.h b/include/net/dsa.h
> index a0a9481c52c2..9ee2d7ccfff8 100644
> --- a/include/net/dsa.h
> +++ b/include/net/dsa.h
> @@ -291,6 +291,7 @@ struct dsa_port {
>
> struct device_node *dn;
> unsigned int ageing_time;
> + bool bridge_offloading;
Indentation is not consistent here.
net-next is closed for the merge window.
Andrew
---
pw-bot: cr
Powered by blists - more mailing lists