diff options
author | Jianhua Xie <Jianhua.Xie@freescale.com> | 2014-10-27 10:33:40 (GMT) |
---|---|---|
committer | Jianhua Xie <Jianhua.Xie@freescale.com> | 2015-03-09 06:55:06 (GMT) |
commit | d3572f8ee9062ff8abe489be2e38c5462f482fc3 (patch) | |
tree | 7c1bdede65f5cb090a9f0df353679e9751e4244d /drivers | |
parent | dd08fda785600c8319551c7ae751ea978a15db97 (diff) | |
download | linux-fsl-qoriq-d3572f8ee9062ff8abe489be2e38c5462f482fc3.tar.xz |
bonding: Replace a micro SLAVE_IS_OK with IS_UP
At the hot path, use IS_UP() to instead of SLAVE_IS_OK()
to reduce unnecessary condition checking.
Change-Id: Ib17db501fb214f74e489940912a3c3be3920f633
Reviewed-by: Jiafei Pan <Jiafei.Pan@freescale.com>
Reviewed-on: http://git.am.freescale.net:8181/28615
Signed-off-by: Jianhua Xie <jianhua.xie@freescale.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/bonding/hw_distribution.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/bonding/hw_distribution.c b/drivers/net/bonding/hw_distribution.c index 1881366..d88b9a9 100644 --- a/drivers/net/bonding/hw_distribution.c +++ b/drivers/net/bonding/hw_distribution.c @@ -353,9 +353,8 @@ bool are_all_slaves_linkup(struct bonding *bond) struct slave *slave; bond_for_each_slave(bond, slave) - if (!(SLAVE_IS_OK(slave))) { + if (!(IS_UP(slave->dev))) return false; - } return true; } |