projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
819ec8e
)
net: phy: Use interrupts when available in NOLINK state
author
Andrew Lunn
<
[email protected]
>
Mon, 16 Nov 2015 22:36:46 +0000
(23:36 +0100)
committer
David S. Miller
<
[email protected]
>
Tue, 17 Nov 2015 20:25:44 +0000
(15:25 -0500)
The NOLINK state will poll the phy once a second to see if the link
has come up. If the phy has an interrupt line, this polling can be
skipped, since the phy should interrupt when the link returns.
Signed-off-by: Andrew Lunn <
[email protected]
>
Signed-off-by: David S. Miller <
[email protected]
>
drivers/net/phy/phy.c
patch
|
blob
|
history
diff --git
a/drivers/net/phy/phy.c
b/drivers/net/phy/phy.c
index adb48abafc872a71e801b5505d676f9db02c7466..48ce6ef400fe7fdda6ae78a9a22943b2307c1c8b 100644
(file)
--- a/
drivers/net/phy/phy.c
+++ b/
drivers/net/phy/phy.c
@@
-863,6
+863,9
@@
void phy_state_machine(struct work_struct *work)
needs_aneg = true;
break;
case PHY_NOLINK:
+ if (phy_interrupt_is_valid(phydev))
+ break;
+
err = phy_read_status(phydev);
if (err)
break;