net: phy: smsc: fix link up detection in forced irq mode
authorHeiner Kallweit <hkallweit1@gmail.com>
Sat, 4 Mar 2023 10:52:44 +0000 (11:52 +0100)
committerJakub Kicinski <kuba@kernel.org>
Mon, 6 Mar 2023 21:23:10 +0000 (13:23 -0800)
commit58aac3a2ef414fea6d7fdf823ea177744a087d13
tree26bf9b3b866bd43baa1b8055d42536ac7ce3b3cf
parent89b59a84cb166f1ab5b6de9830e61324937c661e
net: phy: smsc: fix link up detection in forced irq mode

Currently link up can't be detected in forced mode if polling
isn't used. Only link up interrupt source we have is aneg
complete which isn't applicable in forced mode. Therefore we
have to use energy-on as link up indicator.

Fixes: 7365494550f6 ("net: phy: smsc: skip ENERGYON interrupt if disabled")
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/smsc.c