]> www.infradead.org Git - users/jedix/linux-maple.git/commit
net: stmmac: check if MAC needs to attach to a PHY
authorMichael Sit Wei Hong <michael.wei.hong.sit@intel.com>
Thu, 30 Mar 2023 09:14:03 +0000 (17:14 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 13 Apr 2023 14:55:20 +0000 (16:55 +0200)
commit1aca718e1a840f65b60488433a1f1dd56f37dd73
treee78bc08039c259ab65c6c1bbc026099b6b90c340
parent2b15feabc95b902cd77c6ce820768360d9a06eac
net: stmmac: check if MAC needs to attach to a PHY

[ Upstream commit fe2cfbc9680356a3d9f8adde8a38e715831e32f5 ]

After the introduction of the fixed-link support, the MAC driver
no longer attempt to scan for a PHY to attach to. This causes the
non fixed-link setups to stop working.

Using the phylink_expects_phy() to check and determine if the MAC
should expect and attach a PHY.

Fixes: ab21cf920928 ("net: stmmac: make mdio register skips PHY scanning for fixed-link")
Signed-off-by: Michael Sit Wei Hong <michael.wei.hong.sit@intel.com>
Signed-off-by: Lai Peter Jun Ann <peter.jun.ann.lai@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c