Commit b71cd957 authored by Oleksij Rempel's avatar Oleksij Rempel Committed by Greg Kroah-Hartman
Browse files

ethtool: linkstate: migrate linkstate functions to support multi-PHY setups



[ Upstream commit fe55b1d4 ]

Adapt linkstate_get_sqi() and linkstate_get_sqi_max() to take a
phy_device argument directly, enabling support for setups with
multiple PHYs. The previous assumption of a single PHY attached to
a net_device no longer holds.

Use ethnl_req_get_phydev() to identify the appropriate PHY device
for the operation. Update linkstate_prepare_data() and related
logic to accommodate this change, ensuring compatibility with
multi-PHY configurations.

Signed-off-by: default avatarOleksij Rempel <o.rempel@pengutronix.de>
Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
Stable-dep-of: 637399bf ("net: ethtool: netlink: Allow NULL nlattrs when getting a phy_device")
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 8aa8a40c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment