From: Paolo Abeni <pabeni@redhat.com>
To: David Yang <mmyangfl@gmail.com>, netdev@vger.kernel.org
Cc: Vladimir Oltean <vladimir.oltean@nxp.com>,
Claudiu Manoil <claudiu.manoil@nxp.com>,
Alexandre Belloni <alexandre.belloni@bootlin.com>,
UNGLinuxDriver@microchip.com, Andrew Lunn <andrew@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Simon Horman <horms@kernel.org>,
Russell King <linux@armlinux.org.uk>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next 3/3] net: dsa: ocelot: check policer entry
Date: Thu, 29 Jan 2026 12:20:02 +0100 [thread overview]
Message-ID: <f65fa8c9-651b-4a38-b1aa-bb923011f450@redhat.com> (raw)
In-Reply-To: <20260126061340.757543-4-mmyangfl@gmail.com>
On 1/26/26 7:13 AM, David Yang wrote:
> rate_bytes_per_sec might be 0, check for it.
>
> Signed-off-by: David Yang <mmyangfl@gmail.com>
> ---
> drivers/net/dsa/ocelot/felix.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/net/dsa/ocelot/felix.c b/drivers/net/dsa/ocelot/felix.c
> index 9e5ede932b42..fb2d02ff0fe7 100644
> --- a/drivers/net/dsa/ocelot/felix.c
> +++ b/drivers/net/dsa/ocelot/felix.c
> @@ -2011,6 +2011,10 @@ static int felix_port_policer_add(struct dsa_switch *ds, int port,
> .burst = policer->burst,
> };
>
> + if (dsa_mall_policer_tc_entry_type(policer) !=
> + DSA_MALL_POLICER_TC_KNOWN)
> + return -EOPNOTSUPP;
I'm not sure this strict mode is what we want or even we can apply it
now: it could cause functional regression with setup previously
completing successfully in presence of 'new' params and working to some
degree and now failing to start.
Generally speaking some/most offloads are free to ignore
tunable/parameter not available in the H/W.
I think a way to opt-in the new behavior could help.
/P
prev parent reply other threads:[~2026-01-29 11:20 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-26 6:13 [PATCH net-next 0/3] net: dsa: sync dsa_mall_policer_tc_entry with FLOW_ACTION_POLICE David Yang
2026-01-26 6:13 ` [PATCH net-next 1/3] " David Yang
2026-01-29 23:22 ` Jakub Kicinski
2026-01-26 6:13 ` [PATCH net-next 2/3] net: dsa: add dsa_mall_policer_tc_entry_type() helper David Yang
2026-01-26 6:13 ` [PATCH net-next 3/3] net: dsa: ocelot: check policer entry David Yang
2026-01-29 11:20 ` Paolo Abeni [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=f65fa8c9-651b-4a38-b1aa-bb923011f450@redhat.com \
--to=pabeni@redhat.com \
--cc=UNGLinuxDriver@microchip.com \
--cc=alexandre.belloni@bootlin.com \
--cc=andrew@lunn.ch \
--cc=claudiu.manoil@nxp.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=mmyangfl@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=vladimir.oltean@nxp.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®