macvlan: Set IFF_UNICAST_FLT flag to prevent unnecessary promisc mode.
authorVlad Yasevich <vyasevic@redhat.com>
Thu, 7 Mar 2013 10:21:48 +0000 (10:21 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 7 Mar 2013 21:36:59 +0000 (16:36 -0500)
Macvlan already supports hw address filters.  Set the IFF_UNICAST_FLT
so that it doesn't needlesly enter PROMISC mode when macvlans are
stacked.

Signed-of-by: Vlad Yasevich <vyasevic@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/macvlan.c

index 417b2af1aa8097fd3e158e8b9e09b59885d8c723..73abbc1655d5c7b793601f93027dad37d2923150 100644 (file)
@@ -660,6 +660,7 @@ void macvlan_common_setup(struct net_device *dev)
        ether_setup(dev);
 
        dev->priv_flags        &= ~(IFF_XMIT_DST_RELEASE | IFF_TX_SKB_SHARING);
+       dev->priv_flags        |= IFF_UNICAST_FLT;
        dev->netdev_ops         = &macvlan_netdev_ops;
        dev->destructor         = free_netdev;
        dev->header_ops         = &macvlan_hard_header_ops,