netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Russell King <rmk@armlinux.org.uk>
To: Florian Fainelli <f.fainelli@gmail.com>
Cc: netdev@vger.kernel.org, Andrew Lunn <andrew@lunn.ch>,
	open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH net-next 5/5] net: phy: marvell10g: Utilize gen10g_soft_reset()
Date: Wed, 28 Feb 2018 19:44:49 +0000	[thread overview]
Message-ID: <20180228194449.GB30733@flint.armlinux.org.uk> (raw)
In-Reply-To: <20180228193612.29409-6-f.fainelli@gmail.com>

On Wed, Feb 28, 2018 at 11:36:12AM -0800, Florian Fainelli wrote:
> We do the same thing as the generic function: nothing, so utilize it.
> 
> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
> ---
>  drivers/net/phy/marvell10g.c | 7 +------
>  1 file changed, 1 insertion(+), 6 deletions(-)
> 
> diff --git a/drivers/net/phy/marvell10g.c b/drivers/net/phy/marvell10g.c
> index 8a0bd98fdec7..da014eae1476 100644
> --- a/drivers/net/phy/marvell10g.c
> +++ b/drivers/net/phy/marvell10g.c
> @@ -75,11 +75,6 @@ static int mv3310_probe(struct phy_device *phydev)
>   * Resetting the MV88X3310 causes it to become non-responsive.  Avoid
>   * setting the reset bit(s).
>   */
> -static int mv3310_soft_reset(struct phy_device *phydev)
> -{
> -	return 0;
> -}
> -

You do realise that getting rid of that function makes a nonsense of the
comment above it - and removing the comment along with the function gets
rid of the very important reason _why_ we have en empty reset method?

>  static int mv3310_config_init(struct phy_device *phydev)
>  {
>  	__ETHTOOL_DECLARE_LINK_MODE_MASK(supported) = { 0, };
> @@ -377,7 +372,7 @@ static struct phy_driver mv3310_drivers[] = {
>  				  SUPPORTED_10000baseT_Full |
>  				  SUPPORTED_Backplane,
>  		.probe		= mv3310_probe,
> -		.soft_reset	= mv3310_soft_reset,
> +		.soft_reset	= gen10g_soft_reset,
>  		.config_init	= mv3310_config_init,
>  		.config_aneg	= mv3310_config_aneg,
>  		.aneg_done	= mv3310_aneg_done,
> -- 
> 2.14.1
> 

-- 
Russell King
ARM architecture Linux Kernel maintainer

  reply	other threads:[~2018-02-28 19:44 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-28 19:36 [PATCH net-next 0/5] net: phy: Reduce duplication Florian Fainelli
2018-02-28 19:36 ` [PATCH net-next 1/5] net: phy: aquantia: Utilize genphy_c45_aneg_done() Florian Fainelli
2018-02-28 19:36 ` [PATCH net-next 2/5] net: phy: Export gen10g_* functions Florian Fainelli
2018-02-28 19:43   ` Russell King
2018-02-28 19:36 ` [PATCH net-next 3/5] net: phy: teranetics: Utilize generic functions Florian Fainelli
2018-02-28 19:36 ` [PATCH net-next 4/5] net: phy: cortina: " Florian Fainelli
2018-02-28 19:36 ` [PATCH net-next 5/5] net: phy: marvell10g: Utilize gen10g_soft_reset() Florian Fainelli
2018-02-28 19:44   ` Russell King [this message]
2018-02-28 19:49     ` Moritz Fischer
2018-02-28 22:07       ` Florian Fainelli

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180228194449.GB30733@flint.armlinux.org.uk \
    --to=rmk@armlinux.org.uk \
    --cc=andrew@lunn.ch \
    --cc=f.fainelli@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).