From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.3 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_PASS,USER_AGENT_MUTT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 441F3C4360F for ; Sun, 17 Feb 2019 04:18:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 2669821B69 for ; Sun, 17 Feb 2019 04:18:42 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b="VImn6aa3" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727706AbfBQESk (ORCPT ); Sat, 16 Feb 2019 23:18:40 -0500 Received: from vps0.lunn.ch ([185.16.172.187]:55327 "EHLO vps0.lunn.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726168AbfBQESk (ORCPT ); Sat, 16 Feb 2019 23:18:40 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Type:MIME-Version:References:Message-ID: Subject:Cc:To:From:Date:Sender:Reply-To:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=v5YD8On2saw9EyOpbc/bsSWh8XyZBQXkTP5IMgcRr3U=; b=VImn6aa3zXHDde8IQ6ScdaOyTO gUfdHme+GmUudj6xHIzsvdrymfg36omPy8psG8jV7R4KDuHVdvlR5jG7rwbgcxndRXYtolKQn7UMC d0H22L5y5AAw7pelfn2/dpkSAOY0bH/dCs+TcnW0+f/n6mXCDsIG9hq3wRkV7e1AJUUg=; Received: from andrew by vps0.lunn.ch with local (Exim 4.89) (envelope-from ) id 1gvDuT-0004oR-Gf; Sun, 17 Feb 2019 05:18:33 +0100 Date: Sun, 17 Feb 2019 05:18:33 +0100 From: Andrew Lunn To: Florian Fainelli Cc: Heiner Kallweit , David Miller , Russell King - ARM Linux , "netdev@vger.kernel.org" Subject: Re: [PATCH net-next 2/4] net: phy: add genphy_c45_an_config_an Message-ID: <20190217041833.GU5699@lunn.ch> References: <0423e795-0215-053f-57ff-386242a6d7ce@gmail.com> <407e490f-17f6-c9a5-a128-9a27a3230c39@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <407e490f-17f6-c9a5-a128-9a27a3230c39@gmail.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Sat, Feb 16, 2019 at 06:44:24PM -0800, Florian Fainelli wrote: > > > On 2/16/2019 11:51 AM, Heiner Kallweit wrote: > > From: Andrew Lunn > > C45 configuration of 10/100 and multi-giga bit auto negotiation > > advertisement is standardized. Configuration of 1000Base-T however > > appears to be vendor specific. Move the generic code out of the > > Marvell driver into the common phy-c45.c file. > > > > Signed-off-by: Andrew Lunn > > [hkallweit1@gmail.com: use new helper linkmode_adv_to_mii_10gbt_adv_t and split patch] > > Signed-off-by: Heiner Kallweit > > --- > > drivers/net/phy/phy-c45.c | 44 +++++++++++++++++++++++++++++++++++++++ > > include/linux/phy.h | 1 + > > 2 files changed, 45 insertions(+) > > > > diff --git a/drivers/net/phy/phy-c45.c b/drivers/net/phy/phy-c45.c > > index 0374c50b1..bea1b0c6e 100644 > > --- a/drivers/net/phy/phy-c45.c > > +++ b/drivers/net/phy/phy-c45.c > > @@ -78,6 +78,50 @@ int genphy_c45_pma_setup_forced(struct phy_device *phydev) > > } > > EXPORT_SYMBOL_GPL(genphy_c45_pma_setup_forced); > > > > +/** > > + * genphy_c45_an_config_an - configure advertisement registers > > Nit: are not the two "an" redundant" here? Unless the first one means > something different in which case naming this: > genphy_c45_an_config_aneg() would be clearer? Hi Florian Heiner and I had a brief discussion about this. There is a general trend in the naming to have the device name in the function name. So genphy_c45_pma_setup_forced uses the PMA device registers, genphy_c45_an_disable_aneg uses the AN device registers, etc. However, genphy_c45_an_config_aneg() might be better. Andrew