Christophe Devriese <[EMAIL PROTECTED]> wrote:

[...]
>Would it be acceptable to have an interface flag IFF_SILENT that can be set on 
>an interface, which prevents it from receiving packets in both forwarding 
>paths ?

        Starting with kernel version 2.6.17, there is code in skb_bond()
to suppress traffic on inactive slaves, but it looks like that will
bypassed by hardware accelerated VLAN packets (which, if I'm reading the
code correctly, have their skb->dev directly assigned to the VLAN
interface, so they go into netif_receive_skb with skb->dev not set to
the slave device, which will bypass the stuff in skb_bond).

        An IFF_SILENT type of flag would work fine (if checked in both
input paths) for the active-backup mode, but the 802.3ad and balance-alb
modes need differing types of traffic dropping, e.g., the balance-alb
mode just needs to suppress broadcast and multicasts.

        One possible solution for this would be to have bonding remove
the vlan registration for inactive slaves, which would cause the errant
packets to pass through skb_bond() normally and presumably be dropped.
That would work for the active-backup case, but would cause balance-alb
mode to lose VLAN acceleration on all interfaces except for one.

        Another possibility would be to have __vlan_hwaccel_rx check the
VLAN_DEV_INFO(skb->dev)->real_dev, and if that's a bonding device, apply
the same logic found in skb_bond().  Or, if there's some way to ask the
question "is dev a VLAN device?", then that same test could be put into
skb_bond() and all of the packet suppression fru fru could stay there.

        -J

---
        -Jay Vosburgh, IBM Linux Technology Center, [EMAIL PROTECTED]
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to