mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
synced 2026-11-10 20:48:12 +00:00
net: phy: propagate errors from default port setup
phy_default_setup_single_port() ignores errors from phy_add_port() and always reports success. If a PHY driver attach_mdi_port() callback fails, the phy_port is leaked and PHY probing continues without the expected default port. Destroy the port and return the error. Reviewed-by: Maxime Chevallier <maxime.chevallier@bootlin.com> Signed-off-by: Xuanqiang Luo <luoxuanqiang@kylinos.cn> Link: https://patch.msgid.link/20260823035600.188864-6-xuanqiang.luo@linux.dev Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
afd5aecd3c
commit
48378efebb
1 changed files with 5 additions and 2 deletions
Loading…
Add table
Add a link
Reference in a new issue