[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <35d469ba-6ff5-42da-b4b2-cec11c50857d@lunn.ch>
Date: Mon, 27 Oct 2025 00:54:41 +0100
From: Andrew Lunn <andrew@...n.ch>
To: David Yang <mmyangfl@...il.com>
Cc: netdev@...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>,
Russell King <linux@...linux.org.uk>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next 1/3] net: dsa: yt921x: Add STP/MST support
> +static int
> +yt921x_dsa_vlan_msti_set(struct dsa_switch *ds, struct dsa_bridge bridge,
> + const struct switchdev_vlan_msti *msti)
> +{
> + struct yt921x_priv *priv = to_yt921x_priv(ds);
> + u64 mask64;
> + u64 ctrl64;
> + int res;
> +
> + if (!msti->vid)
> + return -EINVAL;
> + if (msti->msti <= 0 || msti->msti >= YT921X_MSTI_NUM)
> + return -EINVAL;
I see there are a bunch of build bot warning emails, so this might be
covered already?
msti->msti is a u16. It cannot by < 0, so <= should be =.
Andrew
Powered by blists - more mailing lists