diff options
author | Jay Vosburgh <fubar@us.ibm.com> | 2006-02-21 19:36:44 -0500 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2006-03-03 20:58:00 -0500 |
commit | 8f903c708fcc2b579ebf16542bf6109bad593a1d (patch) | |
tree | 8fb890c05d962c2dd63f8dbc960efbd0b09802d2 /drivers/net/bonding/bond_sysfs.c | |
parent | ebe19a4ed78d4a11a7e01cdeda25f91b7f2fcb5a (diff) |
[PATCH] bonding: suppress duplicate packets
Originally submitted by Kenzo Iwami; his original description is:
The current bonding driver receives duplicate packets when broadcast/
multicast packets are sent by other devices or packets are flooded by the
switch. In this patch, new flags are added in priv_flags of net_device
structure to let the bonding driver discard duplicate packets in
dev.c:skb_bond().
Modified by Jay Vosburgh to change a define name, update some
comments, rearrange the new skb_bond() for clarity, clear all bonding
priv_flags on slave release, and update the driver version.
Signed-off-by: Kenzo Iwami <k-iwami@cj.jp.nec.com>
Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/bonding/bond_sysfs.c')
-rw-r--r-- | drivers/net/bonding/bond_sysfs.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/bonding/bond_sysfs.c b/drivers/net/bonding/bond_sysfs.c index 041bcc583557..5a9bd95884be 100644 --- a/drivers/net/bonding/bond_sysfs.c +++ b/drivers/net/bonding/bond_sysfs.c | |||
@@ -424,6 +424,12 @@ static ssize_t bonding_store_mode(struct class_device *cd, const char *buf, size | |||
424 | ret = -EINVAL; | 424 | ret = -EINVAL; |
425 | goto out; | 425 | goto out; |
426 | } else { | 426 | } else { |
427 | if (bond->params.mode == BOND_MODE_8023AD) | ||
428 | bond_unset_master_3ad_flags(bond); | ||
429 | |||
430 | if (bond->params.mode == BOND_MODE_ALB) | ||
431 | bond_unset_master_alb_flags(bond); | ||
432 | |||
427 | bond->params.mode = new_value; | 433 | bond->params.mode = new_value; |
428 | bond_set_mode_ops(bond, bond->params.mode); | 434 | bond_set_mode_ops(bond, bond->params.mode); |
429 | printk(KERN_INFO DRV_NAME ": %s: setting mode to %s (%d).\n", | 435 | printk(KERN_INFO DRV_NAME ": %s: setting mode to %s (%d).\n", |