]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net: dsa: mv88e6xxx: add field to specify internal phys layout
authorAlexis Lothoré <alexis.lothore@bootlin.com>
Mon, 29 May 2023 08:02:43 +0000 (10:02 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 2 May 2025 05:46:50 +0000 (07:46 +0200)
commit4db3e956ca3870e64154b9b22bb3fd805106d6af
treefa51332603134c5d535bba6015ae1241c04f7061
parent7cdba14d7554fd66ee43e35d77aa02a30480f417
net: dsa: mv88e6xxx: add field to specify internal phys layout

[ Upstream commit 3ba89b28adb21a5d5d78e905e2c3972816606bb4 ]

mv88e6xxx currently assumes that switch equipped with internal phys have
those phys mapped contiguously starting from port 0 (see
mv88e6xxx_phy_is_internal). However, some switches have internal PHYs but
NOT starting from port 0. For example 88e6393X, 88E6193X and 88E6191X have
integrated PHYs available on ports 1 to 8
To properly support this offset, add a new field to allow specifying an
internal PHYs layout. If field is not set, default layout is assumed (start
at port 0)

Signed-off-by: Alexis Lothoré <alexis.lothore@bootlin.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Stable-dep-of: 52fdc41c3278 ("net: dsa: mv88e6xxx: fix internal PHYs for 6320 family")
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/dsa/mv88e6xxx/chip.c
drivers/net/dsa/mv88e6xxx/chip.h
drivers/net/dsa/mv88e6xxx/global2.c