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:
6e72917
)
net: phy: Log only PHY state transitions
author
Marc Gonzalez
<
[email protected]
>
Fri, 28 Jul 2017 11:18:30 +0000
(13:18 +0200)
committer
David S. Miller
<
[email protected]
>
Mon, 31 Jul 2017 23:21:31 +0000
(16:21 -0700)
In the current code, old and new PHY states are always logged.
>From now on, log only PHY state transitions.
Signed-off-by: Marc Gonzalez <
[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 ac1dcf0289fab4d3b538942d7f147c46059e9f7f..3aedf415908bfacd19bfb2680f3dc25d00da2b86 100644
(file)
--- a/
drivers/net/phy/phy.c
+++ b/
drivers/net/phy/phy.c
@@
-1225,9
+1225,10
@@
void phy_state_machine(struct work_struct *work)
if (err < 0)
phy_error(phydev);
- phydev_dbg(phydev, "PHY state change %s -> %s\n",
- phy_state_to_str(old_state),
- phy_state_to_str(phydev->state));
+ if (old_state != phydev->state)
+ phydev_dbg(phydev, "PHY state change %s -> %s\n",
+ phy_state_to_str(old_state),
+ phy_state_to_str(phydev->state));
/* Only re-schedule a PHY state machine change if we are polling the
* PHY, if PHY_IGNORE_INTERRUPT is set, then we will be moving