[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170604194905.GA7045@yuvallap>
Date: Sun, 4 Jun 2017 22:49:06 +0300
From: Yuval Shaia <yuval.shaia@...cle.com>
To: Andrew Lunn <andrew@...n.ch>
Cc: klassert@...hematik.tu-chemnitz.de, pcnet32@...ntier.com,
hsweeten@...ionengravers.com, jeffrey.t.kirsher@...el.com,
cooldavid@...ldavid.org, mcuos.com@...il.com, nic_swsd@...ltek.com,
ralf@...ux-mips.org, romieu@...zoreil.com, nico@...xnic.net,
oneukum@...e.com, davem@...emloft.net, tremyfr@...il.com,
paul.gortmaker@...driver.com, jarod@...hat.com, green.hu@...il.com,
f.fainelli@...il.com, edumazet@...gle.com, shchers@...il.com,
stephen.boyd@...aro.org, fgao@...vckh6395k16k5.yundunddos.com,
tklauser@...tanz.ch, jay.vosburgh@...onical.com,
robert.jarzmik@...e.fr, jeremy.linton@....com,
rmk+kernel@...linux.org.uk, stephen@...workplumber.org,
arnd@...db.de, gerg@...ux-m68k.org, allan@...x.com.tw,
chris.roth@...sk.ca, hayeswang@...ltek.com,
mario_limonciello@...l.com, netdev@...r.kernel.org,
linux-parisc@...r.kernel.org, intel-wired-lan@...ts.osuosl.org,
linux-arm-kernel@...ts.infradead.org, linux-mips@...ux-mips.org,
linux-usb@...r.kernel.org
Subject: Re: [PATCH] net/{mii,smsc}: Make mii_ethtool_get_link_ksettings and
smc_netdev_get_ecmd return void
On Sun, Jun 04, 2017 at 09:01:33PM +0200, Andrew Lunn wrote:
> > diff --git a/drivers/net/cris/eth_v10.c b/drivers/net/cris/eth_v10.c
> > index da02041..017f48c 100644
> > --- a/drivers/net/cris/eth_v10.c
> > +++ b/drivers/net/cris/eth_v10.c
> > @@ -1417,10 +1417,9 @@ static int e100_get_link_ksettings(struct net_device *dev,
> > {
> > struct net_local *np = netdev_priv(dev);
> > u32 supported;
> > - int err;
> >
> > spin_lock_irq(&np->lock);
> > - err = mii_ethtool_get_link_ksettings(&np->mii_if, cmd);
> > + mii_ethtool_get_link_ksettings(&np->mii_if, cmd);
> > spin_unlock_irq(&np->lock);
> >
> > /* The PHY may support 1000baseT, but the Etrax100 does not. */
> > @@ -1432,7 +1431,7 @@ static int e100_get_link_ksettings(struct net_device *dev,
> > ethtool_convert_legacy_u32_to_link_mode(cmd->link_modes.supported,
> > supported);
> >
> > - return err;
> > + return 0;
> > }
>
> How far are going planning on going? It seems like
> *_get_link_ksettings() now all return a useless 0. Do you plan to
> change ethtool_ops and make if void all the way up?
It is not always correct, see for example how xgene_get_link_ksettings
returns non-zero value so i assume that ethtool_ops should remain as it is.
Also, looking at ethtool_get_settings it seems that returned value is
checked.
>
> Andrew
Powered by blists - more mailing lists