From: Michal Simek Date: Wed, 14 Sep 2011 08:32:25 +0000 (+0200) Subject: net: emaclite: Disable autonegotiation for 1000Mbit/s X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6c11d5c4706f9c85903328b037e7d1edd28fb448;p=thirdparty%2Fu-boot.git net: emaclite: Disable autonegotiation for 1000Mbit/s Phy can use 1000baseT but emaclite can work just with 10/100 Mbit/s. That's why driver has to setup phydev capability and setup what speeds can be used. Based on this setting generic phydev code disable autonegotiation for 1000baseT. Signed-off-by: Michal Simek --- diff --git a/drivers/net/xilinx_emaclite.c b/drivers/net/xilinx_emaclite.c index 34d26e4f28e..d0d98932174 100644 --- a/drivers/net/xilinx_emaclite.c +++ b/drivers/net/xilinx_emaclite.c @@ -261,9 +261,14 @@ static int setup_phy(struct eth_device *dev) /* interface - look at tsec */ phydev = phy_connect(emaclite->bus, emaclite->phyaddr, dev, 0); - - phydev->supported &= supported; - phydev->advertising = phydev->supported; + /* + * Phy can support 1000baseT but device NOT that's why phydev->supported + * must be setup for 1000baseT. phydev->advertising setups what speeds + * will be used for autonegotiation where 1000baseT must be disabled. + */ + phydev->supported = supported | SUPPORTED_1000baseT_Half | + SUPPORTED_1000baseT_Full; + phydev->advertising = supported; emaclite->phydev = phydev; phy_config(phydev); phy_startup(phydev);