mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-23 07:12:09 +00:00
net: phy: improve resuming from hibernation
I got an interesting report [0] that after resuming from hibernation the link has 100Mbps instead of 1Gbps. Reason is that another OS has been used whilst Linux was hibernated. And this OS speeds down the link due to WoL. Therefore, when resuming, we shouldn't expect that what the PHY advertises is what it did when hibernating. Easiest way to do this is removing state PHY_RESUMING. Instead always go via PHY_UP that configures PHY advertisement. [0] https://bugzilla.kernel.org/show_bug.cgi?id=202851 Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
22c0ef6b14
commit
f24098f807
2 changed files with 2 additions and 14 deletions
|
@ -308,13 +308,7 @@ struct phy_device *mdiobus_scan(struct mii_bus *bus, int addr);
|
|||
*
|
||||
* HALTED: PHY is up, but no polling or interrupts are done. Or
|
||||
* PHY is in an error state.
|
||||
*
|
||||
* - phy_start moves to RESUMING
|
||||
*
|
||||
* RESUMING: PHY was halted, but now wants to run again.
|
||||
* - If we are forcing, or aneg is done, timer moves to RUNNING
|
||||
* - If aneg is not done, timer moves to AN
|
||||
* - phy_stop moves to HALTED
|
||||
* - phy_start moves to UP
|
||||
*/
|
||||
enum phy_state {
|
||||
PHY_DOWN = 0,
|
||||
|
@ -324,7 +318,6 @@ enum phy_state {
|
|||
PHY_RUNNING,
|
||||
PHY_NOLINK,
|
||||
PHY_FORCING,
|
||||
PHY_RESUMING
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue