From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Miller Subject: Re: [PATCH] net: phy: dp83822: use BMCR_ANENABLE instead of BMSR_ANEGCAPABLE for DP83620 Date: Sun, 10 Jun 2018 12:39:13 -0700 (PDT) Message-ID: <20180610.123913.2160801919208192012.davem@davemloft.net> References: <20180608102339.2572-1-alvaro.gamez@hazent.com> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: andrew@lunn.ch, f.fainelli@gmail.com, netdev@vger.kernel.org To: alvaro.gamez@hazent.com Return-path: Received: from shards.monkeyblade.net ([184.105.139.130]:41534 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753680AbeFJTjO (ORCPT ); Sun, 10 Jun 2018 15:39:14 -0400 In-Reply-To: <20180608102339.2572-1-alvaro.gamez@hazent.com> Sender: netdev-owner@vger.kernel.org List-ID: From: Alvaro Gamez Machado Date: Fri, 8 Jun 2018 12:23:39 +0200 > DP83620 register set is compatible with the DP83848, but it also supports > 100base-FX. When the hardware is configured such as that fiber mode is > enabled, autonegotiation is not possible. > > The chip, however, doesn't expose this information via BMSR_ANEGCAPABLE. > Instead, this bit is always set high, even if the particular hardware > configuration makes it so that auto negotiation is not possible [1]. Under > these circumstances, the phy subsystem keeps trying for autonegotiation to > happen, without success. > > Hereby, we inspect BMCR_ANENABLE bit after genphy_config_init, which on > reset is set to 0 when auto negotiation is disabled, and so we use this > value instead of BMSR_ANEGCAPABLE. > > [1] https://e2e.ti.com/support/interface/ethernet/f/903/p/697165/2571170 > > Signed-off-by: Alvaro Gamez Machado Applied and queued up for -stable, thanks.