summaryrefslogtreecommitdiffstats
path: root/net/dsa
diff options
context:
space:
mode:
authorVivien Didelot <vivien.didelot@gmail.com>2019-06-14 13:49:21 -0400
committerDavid S. Miller <davem@davemloft.net>2019-06-14 20:20:07 -0700
commitf3b78049d4629b4fc565e225dda4e3ffdf907a84 (patch)
treeb6961629e4411c9ab2b15e8600e7dc72021d9b3a /net/dsa
parent68b2d4a844e157c08773fcd8f412ba1a37bf45b8 (diff)
downloadlinux-f3b78049d4629b4fc565e225dda4e3ffdf907a84.tar.bz2
net: dsa: make dsa_slave_dev_check use const
The switchdev handle helpers make use of a device checking helper requiring a const net_device. Make dsa_slave_dev_check compliant to this. Signed-off-by: Vivien Didelot <vivien.didelot@gmail.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dsa')
-rw-r--r--net/dsa/slave.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/dsa/slave.c b/net/dsa/slave.c
index 289a6aa4b51c..cb436a05c9a8 100644
--- a/net/dsa/slave.c
+++ b/net/dsa/slave.c
@@ -22,7 +22,7 @@
#include "dsa_priv.h"
-static bool dsa_slave_dev_check(struct net_device *dev);
+static bool dsa_slave_dev_check(const struct net_device *dev);
/* slave mii_bus handling ***************************************************/
static int dsa_slave_phy_read(struct mii_bus *bus, int addr, int reg)
@@ -1408,7 +1408,7 @@ void dsa_slave_destroy(struct net_device *slave_dev)
free_netdev(slave_dev);
}
-static bool dsa_slave_dev_check(struct net_device *dev)
+static bool dsa_slave_dev_check(const struct net_device *dev)
{
return dev->netdev_ops == &dsa_slave_netdev_ops;
}