summaryrefslogtreecommitdiffstats
path: root/net/dsa
diff options
context:
space:
mode:
authorFlorian Fainelli <f.fainelli@gmail.com>2017-09-19 18:00:37 -0700
committerDavid S. Miller <davem@davemloft.net>2017-09-20 15:49:07 -0700
commit53bade8a3372eea0f1276bc96892735c517330fe (patch)
tree551f4414335c2a364df248b354a0eeb820a86407 /net/dsa
parenteccaa9e51b77e504fa8e8357e4979bde724e22a8 (diff)
downloadlinux-53bade8a3372eea0f1276bc96892735c517330fe.tar.bz2
net: dsa: Utilize dsa_slave_dev_check()
Instead of open coding the check. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Reviewed-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dsa')
-rw-r--r--net/dsa/slave.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/dsa/slave.c b/net/dsa/slave.c
index d51b10450e1b..6fc9eb094267 100644
--- a/net/dsa/slave.c
+++ b/net/dsa/slave.c
@@ -1294,7 +1294,7 @@ static int dsa_slave_netdevice_event(struct notifier_block *nb,
{
struct net_device *dev = netdev_notifier_info_to_dev(ptr);
- if (dev->netdev_ops != &dsa_slave_netdev_ops)
+ if (!dsa_slave_dev_check(dev))
return NOTIFY_DONE;
if (event == NETDEV_CHANGEUPPER)