Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932673AbdHVMAX (ORCPT ); Tue, 22 Aug 2017 08:00:23 -0400 Received: from bhuna.collabora.co.uk ([46.235.227.227]:42327 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932546AbdHVMAW (ORCPT ); Tue, 22 Aug 2017 08:00:22 -0400 Subject: Re: [PATCH v2 1/2] net: stmmac: Delete dead code for MDIO registration To: Florian Fainelli , Giuseppe Cavallaro , Alexandre Torgue , Andrew Lunn Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <20170821114530.13706-1-romain.perier@collabora.com> <20170821114530.13706-2-romain.perier@collabora.com> <6ea649a3-4418-8025-44a9-72330f632f22@gmail.com> From: Romain Perier Message-ID: Date: Tue, 22 Aug 2017 14:00:18 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <6ea649a3-4418-8025-44a9-72330f632f22@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1876 Lines: 55 Hello, Le 22/08/2017 à 02:45, Florian Fainelli a écrit : > On 08/21/2017 04:45 AM, Romain Perier wrote: >> This code is no longer used, the logging function was changed by commit >> fbca164776e4 ("net: stmmac: Use the right logging functi"). >> >> Fixes: fbca164776e4 ("net: stmmac: Use the right logging functi") >> Signed-off-by: Romain Perier >> --- >> drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c | 16 ---------------- >> 1 file changed, 16 deletions(-) >> >> diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c >> index 72ec711fcba2..f5f37bfa1d58 100644 >> --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c >> +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c >> @@ -248,9 +248,6 @@ int stmmac_mdio_register(struct net_device *ndev) >> found = 0; >> for (addr = 0; addr < PHY_MAX_ADDR; addr++) { >> struct phy_device *phydev = mdiobus_get_phy(new_bus, addr); >> - int act = 0; >> - char irq_num[4]; >> - char *irq_str; >> >> if (!phydev) >> continue; >> @@ -273,19 +270,6 @@ int stmmac_mdio_register(struct net_device *ndev) >> if (priv->plat->phy_addr == -1) >> priv->plat->phy_addr = addr; >> >> - act = (priv->plat->phy_addr == addr); >> - switch (phydev->irq) { >> - case PHY_POLL: >> - irq_str = "POLL"; >> - break; >> - case PHY_IGNORE_INTERRUPT: >> - irq_str = "IGNORE"; >> - break; >> - default: >> - sprintf(irq_num, "%d", phydev->irq); >> - irq_str = irq_num; >> - break; >> - } > I was actually just looking into moving these prints to > phy_attached_info(), since it is useful to know whether the interrupt is > POLL, IGNORE, or valid. Can you move that there? Then you can really > migrate over phy_attached_info() with no information loss. > > Thanks! Sure, I can take a look. Thanks, Romain