mirror of
https://github.com/torvalds/linux.git
synced 2026-11-06 21:58:01 +01:00
net: dsa: motorcomm: Fix function parameter types
yt921x_fdb_add_index_in12() mistakenly takes the two register images
as u16, while all registers are 32-bit wide, silently losing the upper
half. Widen the parameters to u32.
Discoved by LLM but impacting existing registers.
Fixes: 186623f4aa ("net: dsa: yt921x: Add support for Motorcomm YT921x")
Signed-off-by: David Yang <mmyangfl@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Link: https://patch.msgid.link/20261026083252.12684-1-mmyangfl@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
67ae1b80cf
commit
5d7f3375cd
|
|
@ -679,8 +679,8 @@ yt921x_fdb_flush_port(struct yt921x_priv *priv, int port, bool flush_static)
|
|||
}
|
||||
|
||||
static int
|
||||
yt921x_fdb_add_index_in12(struct yt921x_priv *priv, u16 index, u16 ctrl1,
|
||||
u16 ctrl2)
|
||||
yt921x_fdb_add_index_in12(struct yt921x_priv *priv, u16 index, u32 ctrl1,
|
||||
u32 ctrl2)
|
||||
{
|
||||
u32 ctrl;
|
||||
u32 val;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user