net: bcmgenet: improve bcmgenet_mii_setup()
bcmgenet_mii_setup() is called from the PHY state machine every 1-2 seconds when the PHYs are in PHY_POLL mode. Improve bcmgenet_mii_setup() so that it touches the MAC registers only when the link is up and there was a change to link, speed, duplex, or pause status. Signed-off-by: Petri Gynther <pgynther@google.com> Tested-by: Florian Fainelli <f.fainelli@gmail.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
f13909cdab
commit
5ad6e6c508
@@ -548,8 +548,9 @@ struct bcmgenet_priv {
|
||||
u16 gphy_rev;
|
||||
|
||||
/* PHY device variables */
|
||||
int old_duplex;
|
||||
int old_link;
|
||||
int old_speed;
|
||||
int old_duplex;
|
||||
int old_pause;
|
||||
phy_interface_t phy_interface;
|
||||
int phy_addr;
|
||||
|
Reference in New Issue
Block a user