aboutsummaryrefslogtreecommitdiffstats
path: root/net/core/dev.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/core/dev.c')
-rw-r--r--net/core/dev.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/core/dev.c b/net/core/dev.c
index 75c3f7f4edd5..7aa01125287e 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -3330,7 +3330,7 @@ static int dev_ifsioc(struct net *net, struct ifreq *ifr, unsigned int cmd)
3330 return -EOPNOTSUPP; 3330 return -EOPNOTSUPP;
3331 3331
3332 case SIOCADDMULTI: 3332 case SIOCADDMULTI:
3333 if (!dev->set_multicast_list || 3333 if ((!dev->set_multicast_list && !dev->set_rx_mode) ||
3334 ifr->ifr_hwaddr.sa_family != AF_UNSPEC) 3334 ifr->ifr_hwaddr.sa_family != AF_UNSPEC)
3335 return -EINVAL; 3335 return -EINVAL;
3336 if (!netif_device_present(dev)) 3336 if (!netif_device_present(dev))
@@ -3339,7 +3339,7 @@ static int dev_ifsioc(struct net *net, struct ifreq *ifr, unsigned int cmd)
3339 dev->addr_len, 1); 3339 dev->addr_len, 1);
3340 3340
3341 case SIOCDELMULTI: 3341 case SIOCDELMULTI:
3342 if (!dev->set_multicast_list || 3342 if ((!dev->set_multicast_list && !dev->set_rx_mode) ||
3343 ifr->ifr_hwaddr.sa_family != AF_UNSPEC) 3343 ifr->ifr_hwaddr.sa_family != AF_UNSPEC)
3344 return -EINVAL; 3344 return -EINVAL;
3345 if (!netif_device_present(dev)) 3345 if (!netif_device_present(dev))