mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-06 16:40:47 +00:00
vtnet: allow IFF_ALLMULTI to be set without VIRTIO_NET_F_CTRL_RX
If the host doesn't announce VIRTIO_NET_F_CTRL_RX we cannot disable all multicast traffic. Previously we'd refuse to set the IFF_ALLMULTI flag, which is the exact opposite of what is actually happening. This broke things such as igmpproxy. See also: https://redmine.pfsense.org/issues/14301 Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D41356
This commit is contained in:
parent
c3046779b2
commit
580cadd6a5
|
@ -1299,8 +1299,11 @@ vtnet_ioctl_ifflags(struct vtnet_softc *sc)
|
|||
if (sc->vtnet_flags & VTNET_FLAG_CTRL_RX)
|
||||
vtnet_rx_filter(sc);
|
||||
else {
|
||||
if ((if_getflags(ifp) ^ sc->vtnet_if_flags) & IFF_ALLMULTI)
|
||||
return (ENOTSUP);
|
||||
/*
|
||||
* We don't support filtering out multicast, so
|
||||
* ALLMULTI is always set.
|
||||
*/
|
||||
if_setflagbits(ifp, IFF_ALLMULTI, 0);
|
||||
if_setflagbits(ifp, IFF_PROMISC, 0);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue