Hi Francesco, > - Philippe, email address is no longer valid. OK, thanks for the heads up. > Therefore is not straightforward to provide valuable feedback to you > now. Thanks for answering anyhow. > > +static int ksz9x31_resume(struct phy_device *phydev) > > +{ > > + phy_device_reset(phydev, 1); > > + phy_device_reset(phydev, 0); > > Is something like that fine? > Don't we need to reconfigure the ethernet phy completely on resume > if we do reset it? kszphy_config_reset() is taking care of something, > but I think that the phy being reset on resume is not handled > correctly. If the interface is up before suspending, then suspend will assert the reset-line. If the interface is disabled before suspending, then close will assert the reset line. Deassertion will happen on resume/open. So, unless I am overlooking something, my code does not really add something new. It only makes sure that the reset line always gets asserted before deasserting. Because in the case that the interface has never been up before, there is no instance which could assert reset. Or, at least, I could not find one. Makes sense? Tests work fine here, at least. All the best, Wolfram
Attachment:
signature.asc
Description: PGP signature