summaryrefslogtreecommitdiffstats
path: root/net/dsa
diff options
context:
space:
mode:
authoryuval.shaia@oracle.com <yuval.shaia@oracle.com>2017-06-13 09:09:46 +0200
committerDavid S. Miller <davem@davemloft.net>2017-06-13 18:59:06 +0200
commit5514174fe9c61c83bd8781c1e048ea6b4bf16a14 (patch)
treebea0cf943d500b7a6ba95506e601e7b885ec47bc /net/dsa
parentMerge branch 'MDIO-bus-reset-GPIO-cleanups' (diff)
downloadlinux-5514174fe9c61c83bd8781c1e048ea6b4bf16a14.tar.xz
linux-5514174fe9c61c83bd8781c1e048ea6b4bf16a14.zip
net: phy: Make phy_ethtool_ksettings_get return void
Make return value void since function never return meaningfull value Signed-off-by: Yuval Shaia <yuval.shaia@oracle.com> Acked-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dsa')
-rw-r--r--net/dsa/slave.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/net/dsa/slave.c b/net/dsa/slave.c
index 5f3caee725ee..5e45ae5c3f71 100644
--- a/net/dsa/slave.c
+++ b/net/dsa/slave.c
@@ -387,12 +387,13 @@ dsa_slave_get_link_ksettings(struct net_device *dev,
struct ethtool_link_ksettings *cmd)
{
struct dsa_slave_priv *p = netdev_priv(dev);
- int err = -EOPNOTSUPP;
- if (p->phy != NULL)
- err = phy_ethtool_ksettings_get(p->phy, cmd);
+ if (!p->phy)
+ return -EOPNOTSUPP;
- return err;
+ phy_ethtool_ksettings_get(p->phy, cmd);
+
+ return 0;
}
static int