On Fri, Oct 04, 2013 at 03:18:45PM +0200, Martin Pieuchot wrote:
> tl;dr
> 
>   This diff stop (ab)using the actual SIOC{ADD,DEL}MULTI ioctls with a
> magic value for the whole range of multicast addresses used for IPv4/6
> to turn the interface into promiscuous mode.
> 
> 
> Long story
> 
>   Ethernet multicast records are currently represented by the ``struct
> ether_multi'' as range of addresses between enm_addrlo and enm_addrlhi.
> But most of the time this range represents a single address (lo == hi),
> and the only cases where this is not true are changed below.
> 
> What happens in our drivers, is that as soon as the list of Ethernet
> multicast records associated to an interface contains a range, we set
> the IFF_ALLMULTI flag which turns the promiscuous mode on.  So the
> diff below directly set the interface into promiscuous mode instead
> of relying on this overcomplicated feature.

Well there is a difference between promiscuity for multicast traffic
and what is usually refered to as promiscuous mode.

> Apart from helping me to reduce the complexity of the multicast
> representation, which could be represented as one address instead of a
> range, this diff has another benefit.  With it, the IFF_ALLMULTI flag
> is now set on an interface only if we try to configure more multicast
> filters than it can handle (hardware limit).

The last part isn't true.

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

Reply via email to