diff options
author | Jianhua Xie <jianhua.xie@freescale.com> | 2015-01-02 13:47:04 (GMT) |
---|---|---|
committer | Jianhua Xie <Jianhua.Xie@freescale.com> | 2015-03-09 06:55:07 (GMT) |
commit | 5043c400cd6a60412599f52263b47df9edacbb58 (patch) | |
tree | 61cc5f75028fc9bf5b4d7e390dd6c4fe263f2dfc /drivers | |
parent | 4697720655090e7bead833250a43292912dd597a (diff) | |
download | linux-fsl-qoriq-5043c400cd6a60412599f52263b47df9edacbb58.tar.xz |
bonding: Add ping monitor support when link failover
when one of slaves link is down, ping reportes failed. This patch
adds some debugging information to track it.
Change-Id: Ied9a2f067e0b19ac4c1e94b52ea67245c04169e4
Reviewed-by: Jiafei Pan <Jiafei.Pan@freescale.com>
Reviewed-on: http://git.am.freescale.net:8181/28618
Signed-off-by: Jianhua Xie <jianhua.xie@freescale.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/bonding/hw_distribution.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/drivers/net/bonding/hw_distribution.c b/drivers/net/bonding/hw_distribution.c index d88b9a9..b6dca03 100644 --- a/drivers/net/bonding/hw_distribution.c +++ b/drivers/net/bonding/hw_distribution.c @@ -350,11 +350,15 @@ static bool is_dpa_eth_port(struct net_device *netdev) bool are_all_slaves_linkup(struct bonding *bond) { - struct slave *slave; + struct slave *s; - bond_for_each_slave(bond, slave) - if (!(IS_UP(slave->dev))) + bond_for_each_slave(bond, s) { + hw_lag_dbg("This slave:%s link status is up:%s\n", + s->dev->name, IS_UP(s->dev) ? "true" : "false"); + + if (!(IS_UP(s->dev))) return false; + } return true; } |