On Mon, Jul 20, 2020 at 10:44:11AM +0000, Ioana Ciornei wrote: > On 6/30/20 5:29 PM, Russell King wrote: > > When we have a PHY attached, an ethtool ksettings_set() call only > > really needs to call through to the phylib equivalent; phylib will > > call back to us when the link changes so we can update our state. > > Therefore, we can bypass most of our ksettings_set() call for this > > case. > > > > Signed-off-by: Russell King <rmk+ker...@armlinux.org.uk> > > Reviewed-by: Ioana Ciornei <ioana.cior...@nxp.com> > > > + mutex_lock(&pl->state_mutex); > > + linkmode_copy(pl->link_config.advertising, config.advertising); > > + pl->link_config.interface = config.interface; > > + pl->link_config.speed = config.speed; > > + pl->link_config.duplex = config.duplex; > > + pl->link_config.an_enabled = kset->base.autoneg != > > + AUTONEG_DISABLE; > > Is there a specific reason why this is not just using config.an_enabled > to sync back to pl->link_config?
Due to the history of the code; and changing it in this patch would be a distraction and actually a separate change. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!